Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 1 | Purpose: |
| 2 | Demonstrate the usage of the new open sourced rbu (Remote BIOS Update) driver |
| 3 | for updating BIOS images on Dell servers and desktops. |
| 4 | |
| 5 | Scope: |
| 6 | This document discusses the functionality of the rbu driver only. |
Matt LaPlante | 3f6dee9 | 2006-10-03 22:45:33 +0200 | [diff] [blame] | 7 | It does not cover the support needed from applications to enable the BIOS to |
Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 8 | update itself with the image downloaded in to the memory. |
| 9 | |
| 10 | Overview: |
| 11 | This driver works with Dell OpenManage or Dell Update Packages for updating |
| 12 | the BIOS on Dell servers (starting from servers sold since 1999), desktops |
| 13 | and notebooks (starting from those sold in 2005). |
| 14 | Please go to http://support.dell.com register and you can find info on |
| 15 | OpenManage and Dell Update packages (DUP). |
Abhay Salunke | e61c0e3 | 2005-09-16 19:28:04 -0700 | [diff] [blame] | 16 | Libsmbios can also be used to update BIOS on Dell systems go to |
| 17 | http://linux.dell.com/libsmbios/ for details. |
Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 18 | |
Matt LaPlante | 2fe0ae7 | 2006-10-03 22:50:39 +0200 | [diff] [blame] | 19 | Dell_RBU driver supports BIOS update using the monolithic image and packetized |
| 20 | image methods. In case of monolithic the driver allocates a contiguous chunk |
Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 21 | of physical pages having the BIOS image. In case of packetized the app |
| 22 | using the driver breaks the image in to packets of fixed sizes and the driver |
| 23 | would place each packet in contiguous physical memory. The driver also |
| 24 | maintains a link list of packets for reading them back. |
| 25 | If the dell_rbu driver is unloaded all the allocated memory is freed. |
| 26 | |
Abhay Salunke | e61c0e3 | 2005-09-16 19:28:04 -0700 | [diff] [blame] | 27 | The rbu driver needs to have an application (as mentioned above)which will |
| 28 | inform the BIOS to enable the update in the next system reboot. |
Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 29 | |
| 30 | The user should not unload the rbu driver after downloading the BIOS image |
| 31 | or updating. |
| 32 | |
| 33 | The driver load creates the following directories under the /sys file system. |
| 34 | /sys/class/firmware/dell_rbu/loading |
| 35 | /sys/class/firmware/dell_rbu/data |
| 36 | /sys/devices/platform/dell_rbu/image_type |
| 37 | /sys/devices/platform/dell_rbu/data |
Abhay Salunke | ad6ce87 | 2005-10-11 08:29:02 -0700 | [diff] [blame] | 38 | /sys/devices/platform/dell_rbu/packet_size |
Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 39 | |
| 40 | The driver supports two types of update mechanism; monolithic and packetized. |
| 41 | These update mechanism depends upon the BIOS currently running on the system. |
| 42 | Most of the Dell systems support a monolithic update where the BIOS image is |
| 43 | copied to a single contiguous block of physical memory. |
Matt LaPlante | 6c28f2c | 2006-10-03 22:46:31 +0200 | [diff] [blame] | 44 | In case of packet mechanism the single memory can be broken in smaller chunks |
Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 45 | of contiguous memory and the BIOS image is scattered in these packets. |
| 46 | |
| 47 | By default the driver uses monolithic memory for the update type. This can be |
Abhay Salunke | e61c0e3 | 2005-09-16 19:28:04 -0700 | [diff] [blame] | 48 | changed to packets during the driver load time by specifying the load |
Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 49 | parameter image_type=packet. This can also be changed later as below |
| 50 | echo packet > /sys/devices/platform/dell_rbu/image_type |
Abhay Salunke | ad6ce87 | 2005-10-11 08:29:02 -0700 | [diff] [blame] | 51 | |
| 52 | In packet update mode the packet size has to be given before any packets can |
| 53 | be downloaded. It is done as below |
| 54 | echo XXXX > /sys/devices/platform/dell_rbu/packet_size |
Matt LaPlante | 992caac | 2006-10-03 22:52:05 +0200 | [diff] [blame] | 55 | In the packet update mechanism, the user needs to create a new file having |
Abhay Salunke | ad6ce87 | 2005-10-11 08:29:02 -0700 | [diff] [blame] | 56 | packets of data arranged back to back. It can be done as follows |
| 57 | The user creates packets header, gets the chunk of the BIOS image and |
Matt LaPlante | a2ffd27 | 2006-10-03 22:49:15 +0200 | [diff] [blame] | 58 | places it next to the packetheader; now, the packetheader + BIOS image chunk |
| 59 | added together should match the specified packet_size. This makes one |
Abhay Salunke | ad6ce87 | 2005-10-11 08:29:02 -0700 | [diff] [blame] | 60 | packet, the user needs to create more such packets out of the entire BIOS |
| 61 | image file and then arrange all these packets back to back in to one single |
| 62 | file. |
| 63 | This file is then copied to /sys/class/firmware/dell_rbu/data. |
| 64 | Once this file gets to the driver, the driver extracts packet_size data from |
Lucas De Marchi | 25985ed | 2011-03-30 22:57:33 -0300 | [diff] [blame] | 65 | the file and spreads it across the physical memory in contiguous packet_sized |
Abhay Salunke | ad6ce87 | 2005-10-11 08:29:02 -0700 | [diff] [blame] | 66 | space. |
| 67 | This method makes sure that all the packets get to the driver in a single operation. |
| 68 | |
| 69 | In monolithic update the user simply get the BIOS image (.hdr file) and copies |
| 70 | to the data file as is without any change to the BIOS image itself. |
Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 71 | |
| 72 | Do the steps below to download the BIOS image. |
| 73 | 1) echo 1 > /sys/class/firmware/dell_rbu/loading |
| 74 | 2) cp bios_image.hdr /sys/class/firmware/dell_rbu/data |
| 75 | 3) echo 0 > /sys/class/firmware/dell_rbu/loading |
| 76 | |
| 77 | The /sys/class/firmware/dell_rbu/ entries will remain till the following is |
| 78 | done. |
Masanori Kobayasi | 1b68bfc | 2009-06-04 21:12:29 +0900 | [diff] [blame] | 79 | echo -1 > /sys/class/firmware/dell_rbu/loading |
Abhay Salunke | ad6ce87 | 2005-10-11 08:29:02 -0700 | [diff] [blame] | 80 | Until this step is completed the driver cannot be unloaded. |
Masanori Kobayasi | 1b68bfc | 2009-06-04 21:12:29 +0900 | [diff] [blame] | 81 | Also echoing either mono, packet or init in to image_type will free up the |
Abhay Salunke | ad6ce87 | 2005-10-11 08:29:02 -0700 | [diff] [blame] | 82 | memory allocated by the driver. |
| 83 | |
Frederik Schwarzer | 0211a9c | 2008-12-29 22:14:56 +0100 | [diff] [blame] | 84 | If a user by accident executes steps 1 and 3 above without executing step 2; |
| 85 | it will make the /sys/class/firmware/dell_rbu/ entries disappear. |
Abhay Salunke | e61c0e3 | 2005-09-16 19:28:04 -0700 | [diff] [blame] | 86 | The entries can be recreated by doing the following |
| 87 | echo init > /sys/devices/platform/dell_rbu/image_type |
| 88 | NOTE: echoing init in image_type does not change it original value. |
Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 89 | |
| 90 | Also the driver provides /sys/devices/platform/dell_rbu/data readonly file to |
Abhay Salunke | ad6ce87 | 2005-10-11 08:29:02 -0700 | [diff] [blame] | 91 | read back the image downloaded. |
Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 92 | |
| 93 | NOTE: |
Abhay Salunke | ad6ce87 | 2005-10-11 08:29:02 -0700 | [diff] [blame] | 94 | This driver requires a patch for firmware_class.c which has the modified |
| 95 | request_firmware_nowait function. |
Matt LaPlante | 992caac | 2006-10-03 22:52:05 +0200 | [diff] [blame] | 96 | Also after updating the BIOS image a user mode application needs to execute |
| 97 | code which sends the BIOS update request to the BIOS. So on the next reboot |
| 98 | the BIOS knows about the new image downloaded and it updates itself. |
| 99 | Also don't unload the rbu driver if the image has to be updated. |
Abhay Salunke | 6c54c28 | 2005-09-06 15:17:14 -0700 | [diff] [blame] | 100 | |