Re: [patch 2.6.12-rc3] modifications in firmware_class.c to support nohotplug

From: Dmitry Torokhov
Date: Fri Jun 10 2005 - 14:58:57 EST


On 6/10/05, Abhay_Salunke@xxxxxxxx <Abhay_Salunke@xxxxxxxx> wrote:
> I tired to do the following
> 1. echo 0 > /sys/class/firmware/timeout
> 2. modify the firmware.agent by commenting echo -1 when file is not
> present as below.
>
> if [ -f "$FIRMWARE_DIR/$FIRMWARE" ]; then
> echo 1 > $SYSFS/$DEVPATH/loading
> cp "$FIRMWARE_DIR/$FIRMWARE" $SYSFS/$DEVPATH/data
> echo 0 > $SYSFS/$DEVPATH/loading
> else
> # echo -1 > $SYSFS/$DEVPATH/loading
> Fi
> 3. load the dell_rbu driver : see dell_rbu code snipped below
>
> device_initialize(&rbu_device);
>
> strncpy(rbu_device.bus_id,"dell_rbu", BUS_ID_SIZE);
>

I think if you add:

kobject_set_name(&rbu_device.kobj, "%s", rbu_device.bus_id,"dell_rbu");

it will work much better. Also, are you initializing rbu_device with
all 0 to begin with?

--
Dmitry
-
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/