Re: [PATCH 1/2] i2c: Add possibility for user-defined (i2c-)devicesfor bus-drivers.

From: Alexander Holler
Date: Wed Nov 14 2012 - 18:34:44 EST


Am 14.11.2012 20:22, schrieb till@xxxxxxxxxxx:
Hi,

i have seen i2c chips going nuts because some probing actually affected the chips state. So i fully agree with Jean here.

I'm fully aware of that.

I2C just isn't meant to be used for hot plugging. And so isn't the i2c-tiny-usb. It's more a hacking and testing device and is e.g. very convenient to test i2c client drivers or to test some new i2c hardware. But i have never had a need for this before user land was available. And once it is you can really do any magic you want using e.g. udev and sysfs.

So I conclude you don't accept my patch too.

Also if you really need some chip to be available at boot time, then usb isn't for you. Usb can take pretty long to enumerate etc and you can never be sure when exactly a device shows up on the usb bus. You'd thus additionally need some means of blocking the entire boot process if you want to enforce that. E.g. the kernel can wait for boot disks to appear for exactly this reason. But it wouldn't make much sense to delay the boot for less cruicial things. Boot time is a critical thing and only the most important things are supposed to have a negative impact on that.

Some people are booting from USB, including the small server this mail goes through. I wonder why you consider the boot time a critical thing. This device isn't meant for some industrial (embedded) application. And most people are booting only seldom their desktop (not to speak about servers).


If you wan't an i2c device to be available at boot time, then you might consider to connect it to some non-volatile i2c bus. I am pretty sure the raspberry pi has one.

I don't have a Rasberry Pi and I don't need one.

Sorry, but think all of you have the impression I'm a dumb kid, playing with some silly hardware. How does that come? I might be even older than you. ;)

Anyway, if someone of you is curious why I've undergone all the pain trying to submit a simple patch, here you can find a first draft:

http://ahsoftware.de/usb-rtc/

Regards,

Alexander
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/