lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1753469.EDefOSO2YU@aspire.rjw.lan>
Date:   Mon, 16 Jul 2018 12:07:20 +0200
From:   "Rafael J. Wysocki" <rjw@...ysocki.net>
To:     Benjamin Gaignard <benjamin.gaignard@...aro.org>
Cc:     gregkh@...uxfoundation.org, broonie@...nel.org, p.paillet@...com,
        linux-kernel@...r.kernel.org, m.szyprowski@...sung.com,
        Benjamin Gaignard <benjamin.gaignard@...com>
Subject: Re: [PATCH v2] base: core: Remove WARN_ON from link dependencies check

On Monday, July 16, 2018 11:59:52 AM CEST Benjamin Gaignard wrote:
> In some cases the link between between customer and supplier
> already exist, for example when a device use it parent as supplier [1].

I think this should be "its parent as a supplier".

> Do not warn about already existing dependencies because device_link_add()
> take care of this case.

"device_link_add() takes care of"

> [1] https://lkml.org/lkml/2018/7/9/356

There is the Link: tag for links and it is better to not use lkml.org
as it is not reliable enough.  You can use lore.kernel.org/lkml/ instead.

> Reported-by: Marek Szyprowski <m.szyprowski@...sung.com>
> Reviewed-by: Mark Brown <broonie@...nel.org>
> Signed-off-by: Benjamin Gaignard <benjamin.gaignard@...com>
> ---
>  drivers/base/core.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/base/core.c b/drivers/base/core.c
> index df3e1a44707a..fcdc17f0f349 100644
> --- a/drivers/base/core.c
> +++ b/drivers/base/core.c
> @@ -105,7 +105,7 @@ static int device_is_dependent(struct device *dev, void *target)
>  	struct device_link *link;
>  	int ret;
>  
> -	if (WARN_ON(dev == target))
> +	if (dev == target)
>  		return 1;
>  
>  	ret = device_for_each_child(dev, target, device_is_dependent);
> @@ -113,7 +113,7 @@ static int device_is_dependent(struct device *dev, void *target)
>  		return ret;
>  
>  	list_for_each_entry(link, &dev->links.consumers, s_node) {
> -		if (WARN_ON(link->consumer == target))
> +		if (link->consumer == target)
>  			return 1;
>  
>  		ret = device_is_dependent(link->consumer, target);
> 


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ