Re: [PATCH RFC] modpost: Support I2C Aliases from OF tables

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Aug 6, 2019 at 12:48 AM Javier Martinez Canillas
<javierm@xxxxxxxxxx> wrote:
> On 8/1/19 4:17 AM, Masahiro Yamada wrote:
> So I think that we should either:
>
> a) take Kieran's patch or b) remove the i2c_of_match_device_sysfs() fallback
> for OF and require an I2C device table for sysfs instantiation and matching.
>
> > If a driver supports DT and devices are instantiated via DT,
> > in which situation is this useful?
>
> Is useful if you don't have all the I2C devices described in the DT. For example
> a daughterboard with an I2C device is connected to a board through an expansion
> slot or an I2C device connected directly to I2C pins exposed in a machine.
>
> In these cases your I2C devices won't be static so users might want to use the
> sysfs user-space interface to instantiate the I2C devices, i.e:
>
>  # echo eeprom 0x50 > /sys/bus/i2c/devices/i2c-3/new_device
>
> as explained in https://github.com/torvalds/linux/blob/master/Documentation/i2c/instantiating-devices#L207

Does this actually work with DT names, too? E.g.

# echo atmel,24c02 > /sys/bus/i2c/devices/i2c-3/new_device

Still leaves us with legacy names for backwards compatibility.

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds



[Index of Archives]     [Linux&nblp;USB Development]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite Secrets]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux