From: David Lechner
Date: Fri Sep 16 2016 - 16:06:17 EST

On 09/15/2016 03:00 PM, Wolfram Sang wrote:
On Mon, Sep 05, 2016 at 03:40:11PM -0500, David Lechner wrote:
I'm working on getting LEGO MINDSTORMS[1] support in the Linux kernel.

They have a system of modular sensors that are hot-plugable, some of which use
I2C communications. Unfortunately, these don't necessary follow standard I2C
conventions, but they do have a well-defined register layout, so they are
easy to detect.

This set of patches addresses the hot-plugability of the sensors.



For a review, I'd need users of this functionality. In this case, a
master driver and probably a sensor driver.

Work in progress drivers:


Can any regular I2C master
talk to these devices if they support talking to addresses 0x00-0x7f?

Yes. I've tested this with the SoC I2C on Raspberry Pi. There are several 3rd party LEGO MINDSTORMS compatible addon boards for RPi that use the SoC I2C with LEGO sensors, which is part of my motivation for this patchset.

My first impression is that using a class is not the proper approach
because classes were used to limit access to devices, not to extend.
However, I'd need to see more code to check if that holds true.

I'm certainly open to other suggestions. This just seemed like the obvious way to me.