kernelnewbies.kernelnewbies.org archive mirror
 help / color / mirror / Atom feed
From: "Nuno Sá" <noname.nuno@gmail.com>
To: kernelnewbies <kernelnewbies@kernelnewbies.org>
Subject: i2c possible patch
Date: Wed, 22 Jul 2020 11:49:05 +0100	[thread overview]
Message-ID: <60679735286c92124b44355df3b7d1230c26e4ea.camel@gmail.com> (raw)

Hi all,

I was looking at the i2c core code and I stumbled in a condition that
looks like some "legacy" thing. While I'm not sure about this, this
mailing list feels like a good place to get some feedback. The
condition in question is this

https://elixir.bootlin.com/linux/latest/source/drivers/i2c/i2c-core-base.c#L356

So, my first question is: Can we actually get into `i2c_device_probe()`
without `i2c_device_match()` being called first? If not, it looks that
this condition could just be removed...

If we can get there without `i2c_device_match()`, I can see a problem
in the condition if we just use of_id_table in ACPI.
`i2c_acpi_match_device()` just calls `acpi_match_device()` whereas I
think `acpi_driver_match_device()` should be used if we want to take
of_id_table into account. Does this really look like an issue or Am I
missing something?


- Nuno Sá


_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

                 reply	other threads:[~2020-07-22 10:52 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=60679735286c92124b44355df3b7d1230c26e4ea.camel@gmail.com \
    --to=noname.nuno@gmail.com \
    --cc=kernelnewbies@kernelnewbies.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;
as well as URLs for NNTP newsgroup(s).