LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH 1/2] dt-bindings: Add bindings for Capella cm3323 Ambient Light Sensor
@ 2021-07-28 11:00 Siddharth Manthan
2021-07-28 11:00 ` [PATCH 2/2] drivers: iio: light: cm3323: Add device tree support Siddharth Manthan
2021-08-02 21:34 ` [PATCH 1/2] dt-bindings: Add bindings for Capella cm3323 Ambient Light Sensor Rob Herring
0 siblings, 2 replies; 5+ messages in thread
From: Siddharth Manthan @ 2021-07-28 11:00 UTC (permalink / raw)
To: jic23
Cc: robh+dt, nikita, linux-iio, linux-kernel, devicetree, ktsai,
lars, Siddharth Manthan
Update trivial-devices.yaml with Capella cm3323 Ambient Light Sensor
description.
Signed-off-by: Siddharth Manthan <siddharth.manthan@gmail.com>
---
This patch was previously sent using outlook email provider. Unfortunately
I had no knowledge of outlook being banned from mailing lists. I am
resending these patches using gmail. Please ignore the previous patches.
Documentation/devicetree/bindings/trivial-devices.yaml | 2 ++
1 file changed, 2 insertions(+)
diff --git a/Documentation/devicetree/bindings/trivial-devices.yaml b/Documentation/devicetree/bindings/trivial-devices.yaml
index 919a4bf03a5a..39fb27561a7b 100644
--- a/Documentation/devicetree/bindings/trivial-devices.yaml
+++ b/Documentation/devicetree/bindings/trivial-devices.yaml
@@ -61,6 +61,8 @@ properties:
- capella,cm32181
# CM3232: Ambient Light Sensor
- capella,cm3232
+ # CM3323: Ambient Light Sensor
+ - capella,cm3323
# High-Precision Digital Thermometer
- dallas,ds1631
# Total-Elapsed-Time Recorder with Alarm
--
2.31.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH 2/2] drivers: iio: light: cm3323: Add device tree support
2021-07-28 11:00 [PATCH 1/2] dt-bindings: Add bindings for Capella cm3323 Ambient Light Sensor Siddharth Manthan
@ 2021-07-28 11:00 ` Siddharth Manthan
2021-08-02 21:34 ` [PATCH 1/2] dt-bindings: Add bindings for Capella cm3323 Ambient Light Sensor Rob Herring
1 sibling, 0 replies; 5+ messages in thread
From: Siddharth Manthan @ 2021-07-28 11:00 UTC (permalink / raw)
To: jic23
Cc: robh+dt, nikita, linux-iio, linux-kernel, devicetree, ktsai,
lars, Siddharth Manthan
Add Device Tree support for Capella cm3323 Ambient Light Sensor
Signed-off-by: Siddharth Manthan <siddharth.manthan@gmail.com>
---
drivers/iio/light/cm3323.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/drivers/iio/light/cm3323.c b/drivers/iio/light/cm3323.c
index 6d1b0ffd144b..fd9a8c27de2e 100644
--- a/drivers/iio/light/cm3323.c
+++ b/drivers/iio/light/cm3323.c
@@ -256,9 +256,16 @@ static const struct i2c_device_id cm3323_id[] = {
};
MODULE_DEVICE_TABLE(i2c, cm3323_id);
+static const struct of_device_id cm3323_of_match[] = {
+ { .compatible = "capella,cm3323", },
+ { /* sentinel */ }
+};
+MODULE_DEVICE_TABLE(of, cm3323_of_match);
+
static struct i2c_driver cm3323_driver = {
.driver = {
.name = CM3323_DRV_NAME,
+ .of_match_table = cm3323_of_match,
},
.probe = cm3323_probe,
.id_table = cm3323_id,
--
2.31.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH 1/2] dt-bindings: Add bindings for Capella cm3323 Ambient Light Sensor
2021-07-28 11:00 [PATCH 1/2] dt-bindings: Add bindings for Capella cm3323 Ambient Light Sensor Siddharth Manthan
2021-07-28 11:00 ` [PATCH 2/2] drivers: iio: light: cm3323: Add device tree support Siddharth Manthan
@ 2021-08-02 21:34 ` Rob Herring
2021-08-08 14:28 ` Jonathan Cameron
1 sibling, 1 reply; 5+ messages in thread
From: Rob Herring @ 2021-08-02 21:34 UTC (permalink / raw)
To: Siddharth Manthan
Cc: linux-kernel, nikita, devicetree, robh+dt, linux-iio, ktsai, jic23, lars
On Wed, 28 Jul 2021 16:30:47 +0530, Siddharth Manthan wrote:
> Update trivial-devices.yaml with Capella cm3323 Ambient Light Sensor
> description.
>
> Signed-off-by: Siddharth Manthan <siddharth.manthan@gmail.com>
> ---
> This patch was previously sent using outlook email provider. Unfortunately
> I had no knowledge of outlook being banned from mailing lists. I am
> resending these patches using gmail. Please ignore the previous patches.
>
> Documentation/devicetree/bindings/trivial-devices.yaml | 2 ++
> 1 file changed, 2 insertions(+)
>
Acked-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 1/2] dt-bindings: Add bindings for Capella cm3323 Ambient Light Sensor
2021-08-02 21:34 ` [PATCH 1/2] dt-bindings: Add bindings for Capella cm3323 Ambient Light Sensor Rob Herring
@ 2021-08-08 14:28 ` Jonathan Cameron
0 siblings, 0 replies; 5+ messages in thread
From: Jonathan Cameron @ 2021-08-08 14:28 UTC (permalink / raw)
To: Rob Herring
Cc: Siddharth Manthan, linux-kernel, nikita, devicetree, robh+dt,
linux-iio, ktsai, lars
On Mon, 2 Aug 2021 15:34:16 -0600
Rob Herring <robh@kernel.org> wrote:
> On Wed, 28 Jul 2021 16:30:47 +0530, Siddharth Manthan wrote:
> > Update trivial-devices.yaml with Capella cm3323 Ambient Light Sensor
> > description.
> >
> > Signed-off-by: Siddharth Manthan <siddharth.manthan@gmail.com>
> > ---
> > This patch was previously sent using outlook email provider. Unfortunately
> > I had no knowledge of outlook being banned from mailing lists. I am
> > resending these patches using gmail. Please ignore the previous patches.
> >
> > Documentation/devicetree/bindings/trivial-devices.yaml | 2 ++
> > 1 file changed, 2 insertions(+)
> >
>
> Acked-by: Rob Herring <robh@kernel.org>
Seems we have two versions of this series, only one of which made it to the archive.
Anyhow, I've tweaked the message for patch 2 to remove implication that
the of_device_id table is 'necessary' for dt based probing rather than nice
to have.
Applied to the togreg branch of iio.git and pushed out as testing for
0-day to see if it can find anything we missed before I make a mess of linux-next.
Thanks,
Jonathan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 2/2] drivers: iio: light: cm3323: Add device tree support
[not found] ` <SG2PR02MB38141E2560616F0514CF9A768FEA9@SG2PR02MB3814.apcprd02.prod.outlook.com>
@ 2021-07-28 17:56 ` Jonathan Cameron
0 siblings, 0 replies; 5+ messages in thread
From: Jonathan Cameron @ 2021-07-28 17:56 UTC (permalink / raw)
To: Siddharth Manthan
Cc: robh+dt, ktsai, lars, devicetree, linux-kernel, linux-iio, nikita
On Wed, 28 Jul 2021 17:52:16 +0530
Siddharth Manthan <siddharth_manthan@outlook.com> wrote:
> Add Device Tree support for Capella cm3323 Ambient Light Sensor
>
> Signed-off-by: Siddharth Manthan <siddharth_manthan@outlook.com>
It 'should' have worked without the explicit of_device_id table,
via the fallback that I2C has to use the i2c_device_id table.
I'm fine with making it explicit though as that route doesn't
use the vendor ID at all, so we 'might' get a clash.
I'll change the patch title when applying to something like
iio:light:cm3323: Add of_device_id table
Note also drop the drivers bit as we don't normally have that for
IIO devices.
Jonathan
> ---
> drivers/iio/light/cm3323.c | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/drivers/iio/light/cm3323.c b/drivers/iio/light/cm3323.c
> index 6d1b0ffd1..fd9a8c27d 100644
> --- a/drivers/iio/light/cm3323.c
> +++ b/drivers/iio/light/cm3323.c
> @@ -256,9 +256,16 @@ static const struct i2c_device_id cm3323_id[] = {
> };
> MODULE_DEVICE_TABLE(i2c, cm3323_id);
>
> +static const struct of_device_id cm3323_of_match[] = {
> + { .compatible = "capella,cm3323", },
> + { /* sentinel */ }
> +};
> +MODULE_DEVICE_TABLE(of, cm3323_of_match);
> +
> static struct i2c_driver cm3323_driver = {
> .driver = {
> .name = CM3323_DRV_NAME,
> + .of_match_table = cm3323_of_match,
> },
> .probe = cm3323_probe,
> .id_table = cm3323_id,
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2021-08-08 14:25 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-28 11:00 [PATCH 1/2] dt-bindings: Add bindings for Capella cm3323 Ambient Light Sensor Siddharth Manthan
2021-07-28 11:00 ` [PATCH 2/2] drivers: iio: light: cm3323: Add device tree support Siddharth Manthan
2021-08-02 21:34 ` [PATCH 1/2] dt-bindings: Add bindings for Capella cm3323 Ambient Light Sensor Rob Herring
2021-08-08 14:28 ` Jonathan Cameron
[not found] <20210728122216.22849-1-siddharth_manthan@outlook.com>
[not found] ` <SG2PR02MB38141E2560616F0514CF9A768FEA9@SG2PR02MB3814.apcprd02.prod.outlook.com>
2021-07-28 17:56 ` [PATCH 2/2] drivers: iio: light: cm3323: Add device tree support Jonathan Cameron
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).