Skip to contentSkip to conversation

Enhancements and fixes for dell_rbu driver

PATCH New Abhay Salunke 1 participant 1 message Sep 16, 2005 Documentation

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Enhancements and fixes for dell_rbu driver

Please apply this patch which fixes as bug and usability issues in the dell_rbu driver and has some enhancements.

BUG fixes:
The driver used to allocate memory with spinlock held which has been fixed in this patch.
The driver was printing the entire buffer when it received a invalid entry in image_type. The fix is to only print a warning message and not the buffer.

Usability enhancements:
It is possible that due to user error the /sys/class/firmware/dell_rbu entries migh be missing, this can happen if the user does the following echo 1 > /sys/class/firmware/dell_rbu/loading
echo 0 > /sys/class/firmware/dell_rbu/loading
This will make the entries in /sys/class/firmware/ to disappear and the only way get them back was bby unloading and loading the driver.
This patch makes the user recreate these entries by echoing init in to image_type.

This patch has been tested with Libsmbios and Dell OpenManage.

Thanks
Abhay

Documentation/dell_rbu.txt +14 -6
diff -uprN linux-2.6.14-rc1.orig/Documentation/dell_rbu.txt linux-2.6.14-rc1.new/Documentation/dell_rbu.txt
@@ -13,6 +13,8 @@ the BIOS on Dell servers (starting from 
 and notebooks (starting from those sold in 2005).
 Please go to  http://support.dell.com register and you can find info on
 OpenManage and Dell Update packages (DUP).
+Libsmbios can also be used to update BIOS on Dell systems go to
+http://linux.dell.com/libsmbios/ for details.
 
 Dell_RBU driver supports BIOS update using the monilothic image and packetized
 image methods. In case of moniolithic the driver allocates a contiguous chunk
@@ -22,8 +24,8 @@ would place each packet in contiguous ph
 maintains a link list of packets for reading them back.
 If the dell_rbu driver is unloaded all the allocated memory is freed.
 
-The rbu driver needs to have an application which will inform the BIOS to
-enable the update in the next system reboot.
+The rbu driver needs to have an application (as mentioned above)which will 
+inform the BIOS to enable the update in the next system reboot.
 
 The user should not unload the rbu driver after downloading the BIOS image
 or updating.
@@ -42,9 +44,11 @@ In case of packet mechanism the single m
 of contiguous memory and the BIOS image is scattered in these packets.
 
 By default the driver uses monolithic memory for the update type. This can be
-changed to contiguous during the driver load time by specifying the load
+changed to packets during the driver load time by specifying the load
 parameter image_type=packet.  This can also be changed later as below
 echo packet > /sys/devices/platform/dell_rbu/image_type
+Also echoing either mono ,packet or init in to image_type will free up the 
+memory allocated by the driver.
 
 Do the steps below to download the BIOS image.
 1) echo 1 > /sys/class/firmware/dell_rbu/loading
@@ -52,10 +56,14 @@ Do the steps below to download the BIOS 
 3) echo 0 > /sys/class/firmware/dell_rbu/loading
 
 The /sys/class/firmware/dell_rbu/ entries will remain till the following is
-done.
-echo -1 > /sys/class/firmware/dell_rbu/loading
-
+done. 
+echo -1 > /sys/class/firmware/dell_rbu/loading.
 Until this step is completed the drivr cannot be unloaded.
+If an user by accident executes steps 1 and 3 above without executing step 2; 
+it will make the /sys/class/firmware/dell_rbu/ entries to disappear. 
+The entries can be recreated by doing the following
+echo init > /sys/devices/platform/dell_rbu/image_type
+NOTE: echoing init in image_type does not change it original value.
 
 Also the driver provides /sys/devices/platform/dell_rbu/data readonly file to
 read back the image downloaded. This is useful in case of packet update
drivers/firmware/dell_rbu.c +154 -97

476 lines not on this page · raw message