All of lore.kernel.org
 help / color / mirror / Atom feed
From: Cyril Brulebois <cyril@debamax.com>
To: "Uwe Kleine-König" <uwe@kleine-koenig.org>
Cc: Nicolas Saenz Julienne <nsaenz@kernel.org>,
	Rob Herring <robh+dt@kernel.org>,
	devicetree@vger.kernel.org,
	bcm-kernel-feedback-list@broadcom.com,
	linux-rpi-kernel@lists.infradead.org,
	linux-arm-kernel@lists.infradead.org,
	Stefan Wahren <stefan.wahren@i2se.com>,
	Dave Stevenson <dave.stevenson@raspberrypi.com>,
	Maxime Ripard <maxime@cerno.tech>
Subject: Re: [PATCH v3] ARM: dts: bcm2711-rpi-cm4-io: Add rtc on a pinctrl-muxed i2c bus
Date: Sun, 2 Jan 2022 07:34:18 +0100	[thread overview]
Message-ID: <20220102063418.acneigxran2a6cpr@debamax.com> (raw)
In-Reply-To: <20220102043322.zv4r255yha5pvsp4@debamax.com>

[-- Attachment #1: Type: text/plain, Size: 1066 bytes --]

Cyril Brulebois <cyril@debamax.com> (2022-01-02):
> In passing, I'm seeing the RTC exclusively on (userspace) i2c-2 while
> I'm seeing the LED matrix on both (userspace) i2c-2 and i2c-3: […]

After a few more tests/reboots, checking the output of `i2cdetect -l`
gives the appropriate information, so that one can pick the right i2c-N
device, by looking at the *-mux entries and their channel IDs:

    …
    i2c-2	i2c       	bcm2835 (i2c@7e205000)          	I2C adapter
    …
    i2c-4	i2c       	i2c-2-mux (chan_id 0)           	I2C adapter
    i2c-5	i2c       	i2c-2-mux (chan_id 1)           	I2C adapter

And indeed, those channel IDs match what's been defined in the DTB, with
#0 set to i2c0_gpio0 (e.g. LED matrix on 40-pin header) and #1 set to
i2c0_gpio44 (e.g. RTC, fan control, etc.), which seem quite consistent
this time:

 - `i2cdetect -y 4` reports only 74 (the LED matrix);
 - `i2cdetect -y 5` reports 0c, 2f, and 51 as UU (the RTC).


Cheers,
-- 
Cyril Brulebois -- Debian Consultant @ DEBAMAX -- https://debamax.com/

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

WARNING: multiple messages have this Message-ID (diff)
From: Cyril Brulebois <cyril@debamax.com>
To: "Uwe Kleine-König" <uwe@kleine-koenig.org>
Cc: Nicolas Saenz Julienne <nsaenz@kernel.org>,
	Rob Herring <robh+dt@kernel.org>,
	devicetree@vger.kernel.org,
	bcm-kernel-feedback-list@broadcom.com,
	linux-rpi-kernel@lists.infradead.org,
	linux-arm-kernel@lists.infradead.org,
	Stefan Wahren <stefan.wahren@i2se.com>,
	Dave Stevenson <dave.stevenson@raspberrypi.com>,
	Maxime Ripard <maxime@cerno.tech>
Subject: Re: [PATCH v3] ARM: dts: bcm2711-rpi-cm4-io: Add rtc on a pinctrl-muxed i2c bus
Date: Sun, 2 Jan 2022 07:34:18 +0100	[thread overview]
Message-ID: <20220102063418.acneigxran2a6cpr@debamax.com> (raw)
In-Reply-To: <20220102043322.zv4r255yha5pvsp4@debamax.com>


[-- Attachment #1.1: Type: text/plain, Size: 1066 bytes --]

Cyril Brulebois <cyril@debamax.com> (2022-01-02):
> In passing, I'm seeing the RTC exclusively on (userspace) i2c-2 while
> I'm seeing the LED matrix on both (userspace) i2c-2 and i2c-3: […]

After a few more tests/reboots, checking the output of `i2cdetect -l`
gives the appropriate information, so that one can pick the right i2c-N
device, by looking at the *-mux entries and their channel IDs:

    …
    i2c-2	i2c       	bcm2835 (i2c@7e205000)          	I2C adapter
    …
    i2c-4	i2c       	i2c-2-mux (chan_id 0)           	I2C adapter
    i2c-5	i2c       	i2c-2-mux (chan_id 1)           	I2C adapter

And indeed, those channel IDs match what's been defined in the DTB, with
#0 set to i2c0_gpio0 (e.g. LED matrix on 40-pin header) and #1 set to
i2c0_gpio44 (e.g. RTC, fan control, etc.), which seem quite consistent
this time:

 - `i2cdetect -y 4` reports only 74 (the LED matrix);
 - `i2cdetect -y 5` reports 0c, 2f, and 51 as UU (the RTC).


Cheers,
-- 
Cyril Brulebois -- Debian Consultant @ DEBAMAX -- https://debamax.com/

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

[-- Attachment #2: Type: text/plain, Size: 176 bytes --]

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2022-01-02  6:34 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-31 11:51 [PATCH v3] ARM: dts: bcm2711-rpi-cm4-io: Add rtc on a pinctrl-muxed i2c bus Uwe Kleine-König
2021-12-31 11:51 ` Uwe Kleine-König
2022-01-02  4:33 ` Cyril Brulebois
2022-01-02  4:33   ` Cyril Brulebois
2022-01-02  6:34   ` Cyril Brulebois [this message]
2022-01-02  6:34     ` Cyril Brulebois
2022-01-18 19:45 ` Jean-Michel Hautbois
2022-01-18 19:45   ` Jean-Michel Hautbois
2022-01-18 20:00   ` Florian Fainelli
2022-01-18 20:00     ` Florian Fainelli
2022-01-18 20:02     ` Jean-Michel Hautbois
2022-01-18 20:02       ` Jean-Michel Hautbois
2022-01-18 20:47     ` Laurent Pinchart
2022-01-18 20:47       ` Laurent Pinchart
2022-01-18 22:41       ` Uwe Kleine-König
2022-01-18 22:41         ` Uwe Kleine-König
2022-01-18 22:59         ` Laurent Pinchart
2022-01-18 22:59           ` Laurent Pinchart
2022-01-19  9:44           ` Dave Stevenson
2022-01-19  9:44             ` Dave Stevenson
2022-02-25  0:55             ` Florian Fainelli
2022-02-25  0:55               ` Florian Fainelli

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=20220102063418.acneigxran2a6cpr@debamax.com \
    --to=cyril@debamax.com \
    --cc=bcm-kernel-feedback-list@broadcom.com \
    --cc=dave.stevenson@raspberrypi.com \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-rpi-kernel@lists.infradead.org \
    --cc=maxime@cerno.tech \
    --cc=nsaenz@kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=stefan.wahren@i2se.com \
    --cc=uwe@kleine-koenig.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 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.