From: Sascha Hauer <s.hauer@pengutronix.de>
To: Alexander Shiyan <eagle.alexander923@gmail.com>
Cc: Barebox List <barebox@lists.infradead.org>
Subject: Re: Possible regression 2024.12.0 in parsing "aliases"
Date: Thu, 12 Dec 2024 12:31:42 +0100 [thread overview]
Message-ID: <Z1rJniSaV7iWgr6F@pengutronix.de> (raw)
In-Reply-To: <CAP1tNvRmBaoHOgvti4_cPexSir7isbuDuo+RMCoT35Avm+d21Q@mail.gmail.com>
On Thu, Dec 12, 2024 at 12:30:18PM +0300, Alexander Shiyan wrote:
> Hello.
>
> There seems to be a bug in getting the ID in i2c_add_numbered_adapter()
> It uses dev.parent instead of dev, for example:
> of_alias_get_id(adapter->dev.of_node, "i2c");
>
> And with this everything works as expected.
I don't understand this. In i2c-rockchip.c we have:
i2c->adapter.dev.parent = dev;
i2c->adapter.dev.of_node = dev->of_node;
i2c_add_numbered_adapter(&i2c->adapter);
With that it shouldn't make a difference whether we do this:
adapter->nr = of_alias_get_id(adapter->dev.parent->of_node, "i2c");
or that:
adapter->nr = of_alias_get_id(adapter->dev->of_node, "i2c");
Should be the same device node both times.
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 |
next prev parent reply other threads:[~2024-12-12 11:33 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-11 6:14 Possible regression 2024.12.0 in parsing "aliases" Alexander Shiyan
2024-12-12 9:03 ` Sascha Hauer
2024-12-12 9:30 ` Alexander Shiyan
2024-12-12 11:31 ` Sascha Hauer [this message]
2024-12-12 12:23 ` Alexander Shiyan
2024-12-12 12:13 ` Alexander Shiyan
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=Z1rJniSaV7iWgr6F@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=eagle.alexander923@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.