mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <sha@pengutronix.de>
To: Trent Piepho <tpiepho@gmail.com>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH] drivers: base: Check all compatible strings for modalias match
Date: Wed, 16 Jun 2021 10:26:25 +0200	[thread overview]
Message-ID: <20210616082625.GQ9782@pengutronix.de> (raw)
In-Reply-To: <20210531145414.1210207-1-tpiepho@gmail.com>

On Mon, May 31, 2021 at 07:54:14AM -0700, Trent Piepho wrote:
> When attempting a modalias match in device_match_of_modalias(), only the
> first string in the compatible property, which is a list of strings, was
> used.
> 
> A modalias (which is a bit of a misnomer in Barebox) match is used when
> a driver does not have an of_compatible match table, e.g. the at24
> driver.  The compatible string after the comma is matched against the
> driver's id table.
> 
> Extend modalias match to try all strings in from the OF node's
> compatible property.  This will cause a compatible like
> "rohm,br24g04-3", "atmel,24c04" to match against the "24c04" ID in the
> at24 driver.  Or "isil,isl12057", "dallas,ds1337" will match the ds1307
> driver's table, which doesn't know about isl12057 in Barebox.
> 
> Signed-off-by: Trent Piepho <tpiepho@gmail.com>
> ---
>  drivers/base/bus.c | 27 +++++++++------------------
>  1 file changed, 9 insertions(+), 18 deletions(-)

Applied, thanks

Sascha


-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
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:[~2021-06-16  8:27 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-31 14:54 Trent Piepho
2021-06-16  8:26 ` Sascha Hauer [this message]

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=20210616082625.GQ9782@pengutronix.de \
    --to=sha@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=tpiepho@gmail.com \
    /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