[lkml]   [2017]   [Dec]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 2/2] iio: accel: bmc150: Check for a second ACPI device for BOSC0200
On Sat, Dec 02, 2017 at 12:19:27PM +0000, Jonathan Cameron wrote:
> On Wed, 29 Nov 2017 22:31:12 +0000
> Jeremy Cline <> wrote:
> > Some BOSC0200 acpi_device-s describe two accelerometers in a single ACPI
> > device. Check for a companion device and handle a second i2c_client
> > if it is present.
> + Mika and Wolfram - please cc them on anything odd and i2c / ACPI related.
> (I like to share the pain)
> My usual question, just out of curiosity as we have to cope with this
> fun anyway. Are you actually allowed to do this under the ACPI spec
> or not? I would assume an acpi device is supposed to be just that A
> device... I fall asleep every time I try to read that spec ;)

Yes, it is allowed. Typically you have an ACPI device and it can have
multiple I2cSerialBus() connections.

Linux ACPI/I2C core then picks the first one and creates i2c_client from
that but the additional connections need to be created by the driver in

BTW, there is a function i2c_new_secondary_device() that is supposed to
be used for this but it does not have ACPI support yet (maybe it is good
time to add it now, with this patch series?)

 \ /
  Last update: 2017-12-04 10:59    [W:0.062 / U:0.636 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site