Skip to contentSkip to conversation

dt: Update I2C trivial devices list

PATCH In review Ben Gamari 3 participants 8 messages Dec 17, 2013 – Nov 19, 2014 6 messages not in the archive

Subsystems (2)
lore
Share & tools
lore

Ben Gamari

author
#0 lore raw

PATCH 1/1 dt: Update I2C trivial devices list

---
 Documentation/devicetree/bindings/i2c/trivial-devices.txt | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)
Documentation/devicetree/bindings/i2c/trivial-devices.txt +6 -3
index b1cb341..0e68085 100644
@@ -1,6 +1,9 @@
 This is a list of trivial i2c devices that have simple device tree
 bindings, consisting only of a compatible field, an address and
-possibly an interrupt line.
+possibly an interrupt line. The compatible field is used to lookup the
+modalias of the driver which will handle the device. The compatible
+string may begin with a manufacturer prefix (separated from the
+modalias by a comma) which will be stripped off during lookup.
 
 If a device needs more specific bindings, such as properties to
 describe some aspect of it, there needs to be a specific binding
@@ -9,10 +12,10 @@ document for it just like any other devices.
 
 Compatible		Vendor / Chip
 ==========		=============
+ad,adt7411		I2C Digital 8-channel 10-bit ADC and temperature sensor
 ad,ad7414		SMBus/I2C Digital Temperature Sensor in 6-Pin SOT with SMBus Alert and Over Temperature Pin
 ad,adm9240		ADM9240:  Complete System Hardware Monitor for uProcessor-Based Systems
-adi,adt7461		+/-1C TDM Extended Temp Range I.C
-adt7461			+/-1C TDM Extended Temp Range I.C
+adi,adt7461		+/-1C SMBus digital thermometer
 at,24c08		i2c serial eeprom  (24cxx)
 atmel,24c02		i2c serial eeprom  (24cxx)
 atmel,at97sc3204t	i2c trusted platform module (TPM)
Signature · 1 line
1.8.3.2

A message that is not in the archive (sent off-list or not yet received): 1387239151-19226-1-git-send-email-bgamari.foss-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org

#2 lore raw

Documentation/devicetree/bindings/i2c/trivial-devices.txt line 6

Quoted 9 lines · Ben Gamari
Documentation/devicetree/bindings/i2c/trivial-devices.txt +4 -1
 
 This is a list of trivial i2c devices that have simple device tree
 bindings, consisting only of a compatible field, an address and
-possibly an interrupt line.
+possibly an interrupt line. The compatible field is used to lookup the
+modalias of the driver which will handle the device. The compatible
+string may begin with a manufacturer prefix (separated from the
+modalias by a comma) which will be stripped off during lookup.

This part of the patch described Linux-specific behaviour, whereas DT bindings should be OS-agnostic.

BTW, you didn't CC the DT binding maintainers.

A message that is not in the archive (sent off-list or not yet received): [email protected]

author
#4 lore raw
Quoted 4 lines · Stephen Warren
Quoted 1 line · Ben Gamari
Documentation/devicetree/bindings/i2c/trivial-devices.txt +0 -0
Quoted 11 lines

Documentation/devicetree/bindings/i2c/trivial-devices.txt line 6

Quoted 7 lines

This is a list of trivial i2c devices that have simple device tree bindings, consisting only of a compatible field, an address and

Documentation/devicetree/bindings/i2c/trivial-devices.txt +4 -1
-possibly an interrupt line.
+possibly an interrupt line. The compatible field is used to lookup the
+modalias of the driver which will handle the device. The compatible
+string may begin with a manufacturer prefix (separated from the
+modalias by a comma) which will be stripped off during lookup.

This part of the patch described Linux-specific behaviour, whereas DT bindings should be OS-agnostic.

I see your point but it would be nice to have language like this somewhere. One of the biggest challenges in diving in to writing a devicetree is figuring out details like this.

Quoted 2 lines

BTW, you didn't CC the DT binding maintainers.

Very true. Fixed.

Cheers,

- Ben

A message that is not in the archive (sent off-list or not yet received): [email protected]

#6 lore raw
Quoted 17 lines · Ben Gamari
Quoted 4 lines · Stephen Warren
Quoted 1 line · Ben Gamari
Documentation/devicetree/bindings/i2c/trivial-devices.txt +0 -0
Quoted 11 lines

Documentation/devicetree/bindings/i2c/trivial-devices.txt line 6

Quoted 7 lines

This is a list of trivial i2c devices that have simple device tree bindings, consisting only of a compatible field, an address and

Documentation/devicetree/bindings/i2c/trivial-devices.txt +4 -1
-possibly an interrupt line.
+possibly an interrupt line. The compatible field is used to lookup the
+modalias of the driver which will handle the device. The compatible
+string may begin with a manufacturer prefix (separated from the
+modalias by a comma) which will be stripped off during lookup.

This part of the patch described Linux-specific behaviour, whereas DT bindings should be OS-agnostic.

Quoted 3 lines

I see your point but it would be nice to have language like this somewhere. One of the biggest challenges in diving in to writing a devicetree is figuring out details like this.

What about putting this into a seperate paragraph prefixed with "Current Linux specific implementation:"?

author
#7 lore raw
Quoted 18 lines · Wolfram Sang
Quoted 17 lines · Ben Gamari
Quoted 15 lines · Stephen Warren

Documentation/devicetree/bindings/i2c/trivial-devices.txt

Quoted 9 lines · Ben Gamari
Documentation/devicetree/bindings/i2c/trivial-devices.txt +4 -1
 
 This is a list of trivial i2c devices that have simple device tree
 bindings, consisting only of a compatible field, an address and
-possibly an interrupt line.
+possibly an interrupt line. The compatible field is used to lookup the
+modalias of the driver which will handle the device. The compatible
+string may begin with a manufacturer prefix (separated from the
+modalias by a comma) which will be stripped off during lookup.

This part of the patch described Linux-specific behaviour, whereas DT bindings should be OS-agnostic.

Quoted 7 lines
Quoted 3 lines

I see your point but it would be nice to have language like this somewhere. One of the biggest challenges in diving in to writing a devicetree is figuring out details like this.

What about putting this into a seperate paragraph prefixed with "Current Linux specific implementation:"?

This would address my concern quite nicely.

Cheers,

- Ben

A message that is not in the archive (sent off-list or not yet received): [email protected]

#9 lore raw
Quoted 20 lines · Ben Gamari
Quoted 18 lines · Wolfram Sang
Quoted 17 lines · Ben Gamari
Quoted 15 lines · Stephen Warren

Documentation/devicetree/bindings/i2c/trivial-devices.txt

Quoted 9 lines · Ben Gamari
Documentation/devicetree/bindings/i2c/trivial-devices.txt +4 -1
 
 This is a list of trivial i2c devices that have simple device tree
 bindings, consisting only of a compatible field, an address and
-possibly an interrupt line.
+possibly an interrupt line. The compatible field is used to lookup the
+modalias of the driver which will handle the device. The compatible
+string may begin with a manufacturer prefix (separated from the
+modalias by a comma) which will be stripped off during lookup.

This part of the patch described Linux-specific behaviour, whereas DT bindings should be OS-agnostic.

Quoted 8 lines
Quoted 7 lines
Quoted 3 lines

I see your point but it would be nice to have language like this somewhere. One of the biggest challenges in diving in to writing a devicetree is figuring out details like this.

What about putting this into a seperate paragraph prefixed with "Current Linux specific implementation:"?

This would address my concern quite nicely.

The text should go into Documentation/ not the DT binding.

A message that is not in the archive (sent off-list or not yet received): [email protected]

author
#11 lore raw
Quoted 9 lines · Stephen Warren
Quoted 5 lines · Ben Gamari
Quoted 3 lines · Wolfram Sang

What about putting this into a seperate paragraph prefixed with "Current Linux specific implementation:"?

This would address my concern quite nicely.

The text should go into Documentation/ not the DT binding.

The problem here is that as it stands DT is quite daunting to pick up. My needs are pretty minimal yet I had to spend many hours sifting through source, blogs, and Documentation/* to get something that more or less worked. The bindings are generally well-documented, but there is no "start here" document in the tree giving conventions and an overview of how Linux in particular uses DT.

The closest thing I know of is Documentation/devicetree/usage-model.txt. Perhaps this is where the language Wolfram suggested should be placed.

Cheers,

- Ben

A message that is not in the archive (sent off-list or not yet received): [email protected]

#13 lore raw
Quoted 18 lines · Ben Gamari
Quoted 9 lines · Stephen Warren
Quoted 5 lines · Ben Gamari
Quoted 3 lines · Wolfram Sang

What about putting this into a seperate paragraph prefixed with "Current Linux specific implementation:"?

This would address my concern quite nicely.

The text should go into Documentation/ not the DT binding.

The problem here is that as it stands DT is quite daunting to pick up. My needs are pretty minimal yet I had to spend many hours sifting through source, blogs, and Documentation/* to get something that more or less worked. The bindings are generally well-documented, but there is no "start here" document in the tree giving conventions and an overview of how Linux in particular uses DT.

Quoted 2 lines

The closest thing I know of is Documentation/devicetree/usage-model.txt. Perhaps this is where the language Wolfram suggested should be placed.

I appreciate your effort to improve documentation on how to get started. Sadly, I don't know where the best place would be and I am too busy to look it up. If you are interested, I'll happily apply the outcome, otherwise we sadly have to wait until someone else comes up.