mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Ian Abbott <abbotti@mev.co.uk>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH] of_path: only handle no driver for device if it is on a bus
Date: Fri, 13 Jan 2017 08:37:00 +0100	[thread overview]
Message-ID: <20170113073700.j3djezdqqkncucyh@pengutronix.de> (raw)
In-Reply-To: <20170112122005.805-1-abbotti@mev.co.uk>

On Thu, Jan 12, 2017 at 12:20:05PM +0000, Ian Abbott wrote:
> This fixes a regression in __of_find_path() for flash devices created by
> the cadence-quadspi driver, which do not have 'dev->driver' set.  Such
> devices do not have 'dev->bus' set either, so we can use that to qualify
> the existing test.
> 
> Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
> ---
>  drivers/of/of_path.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/of/of_path.c b/drivers/of/of_path.c
> index 946b9c7aa..e0b2dc124 100644
> --- a/drivers/of/of_path.c
> +++ b/drivers/of/of_path.c
> @@ -66,7 +66,7 @@ static int __of_find_path(struct device_node *node, const char *part, char **out
>  			return -ENODEV;
>  	}
>  
> -	if (!dev->driver)
> +	if (dev->bus && !dev->driver)
>  		return -ENODEV;

I am not entirely happy with this patch. Let's hope it won't fall on our
feet later. Applied for now, let's see.

Sascha


-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  reply	other threads:[~2017-01-13  7:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-12 12:20 Ian Abbott
2017-01-13  7:37 ` Sascha Hauer [this message]
2017-01-13 11:13   ` Ian Abbott

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170113073700.j3djezdqqkncucyh@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=abbotti@mev.co.uk \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox