blob: 0fdb6aa2704c506ada0f893e6649e97ce25000ff [file] [log] [blame]
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -03001=============================================================
2Usage of the new open sourced rbu (Remote BIOS Update) driver
3=============================================================
4
5Purpose
6=======
7
8Document demonstrating the use of the Dell Remote BIOS Update driver.
Abhay Salunke6c54c282005-09-06 15:17:14 -07009for updating BIOS images on Dell servers and desktops.
10
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030011Scope
12=====
13
Abhay Salunke6c54c282005-09-06 15:17:14 -070014This document discusses the functionality of the rbu driver only.
Matt LaPlante3f6dee92006-10-03 22:45:33 +020015It does not cover the support needed from applications to enable the BIOS to
Abhay Salunke6c54c282005-09-06 15:17:14 -070016update itself with the image downloaded in to the memory.
17
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030018Overview
19========
20
Abhay Salunke6c54c282005-09-06 15:17:14 -070021This driver works with Dell OpenManage or Dell Update Packages for updating
22the BIOS on Dell servers (starting from servers sold since 1999), desktops
23and notebooks (starting from those sold in 2005).
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030024
Abhay Salunke6c54c282005-09-06 15:17:14 -070025Please go to http://support.dell.com register and you can find info on
26OpenManage and Dell Update packages (DUP).
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030027
Abhay Salunkee61c0e32005-09-16 19:28:04 -070028Libsmbios can also be used to update BIOS on Dell systems go to
29http://linux.dell.com/libsmbios/ for details.
Abhay Salunke6c54c282005-09-06 15:17:14 -070030
Matt LaPlante2fe0ae72006-10-03 22:50:39 +020031Dell_RBU driver supports BIOS update using the monolithic image and packetized
32image methods. In case of monolithic the driver allocates a contiguous chunk
Abhay Salunke6c54c282005-09-06 15:17:14 -070033of physical pages having the BIOS image. In case of packetized the app
34using the driver breaks the image in to packets of fixed sizes and the driver
35would place each packet in contiguous physical memory. The driver also
36maintains a link list of packets for reading them back.
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030037
Abhay Salunke6c54c282005-09-06 15:17:14 -070038If the dell_rbu driver is unloaded all the allocated memory is freed.
39
Abhay Salunkee61c0e32005-09-16 19:28:04 -070040The rbu driver needs to have an application (as mentioned above)which will
41inform the BIOS to enable the update in the next system reboot.
Abhay Salunke6c54c282005-09-06 15:17:14 -070042
43The user should not unload the rbu driver after downloading the BIOS image
44or updating.
45
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030046The driver load creates the following directories under the /sys file system::
47
48 /sys/class/firmware/dell_rbu/loading
49 /sys/class/firmware/dell_rbu/data
50 /sys/devices/platform/dell_rbu/image_type
51 /sys/devices/platform/dell_rbu/data
52 /sys/devices/platform/dell_rbu/packet_size
Abhay Salunke6c54c282005-09-06 15:17:14 -070053
54The driver supports two types of update mechanism; monolithic and packetized.
55These update mechanism depends upon the BIOS currently running on the system.
56Most of the Dell systems support a monolithic update where the BIOS image is
57copied to a single contiguous block of physical memory.
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030058
Matt LaPlante6c28f2c2006-10-03 22:46:31 +020059In case of packet mechanism the single memory can be broken in smaller chunks
Abhay Salunke6c54c282005-09-06 15:17:14 -070060of contiguous memory and the BIOS image is scattered in these packets.
61
62By default the driver uses monolithic memory for the update type. This can be
Abhay Salunkee61c0e32005-09-16 19:28:04 -070063changed to packets during the driver load time by specifying the load
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030064parameter image_type=packet. This can also be changed later as below::
65
66 echo packet > /sys/devices/platform/dell_rbu/image_type
Abhay Salunkead6ce872005-10-11 08:29:02 -070067
68In packet update mode the packet size has to be given before any packets can
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030069be downloaded. It is done as below::
70
71 echo XXXX > /sys/devices/platform/dell_rbu/packet_size
72
Matt LaPlante992caac2006-10-03 22:52:05 +020073In the packet update mechanism, the user needs to create a new file having
Abhay Salunkead6ce872005-10-11 08:29:02 -070074packets of data arranged back to back. It can be done as follows
75The user creates packets header, gets the chunk of the BIOS image and
Matt LaPlantea2ffd272006-10-03 22:49:15 +020076places it next to the packetheader; now, the packetheader + BIOS image chunk
77added together should match the specified packet_size. This makes one
Abhay Salunkead6ce872005-10-11 08:29:02 -070078packet, the user needs to create more such packets out of the entire BIOS
79image file and then arrange all these packets back to back in to one single
80file.
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030081
Abhay Salunkead6ce872005-10-11 08:29:02 -070082This file is then copied to /sys/class/firmware/dell_rbu/data.
83Once this file gets to the driver, the driver extracts packet_size data from
Lucas De Marchi25985ed2011-03-30 22:57:33 -030084the file and spreads it across the physical memory in contiguous packet_sized
Abhay Salunkead6ce872005-10-11 08:29:02 -070085space.
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030086
Abhay Salunkead6ce872005-10-11 08:29:02 -070087This method makes sure that all the packets get to the driver in a single operation.
88
89In monolithic update the user simply get the BIOS image (.hdr file) and copies
90to the data file as is without any change to the BIOS image itself.
Abhay Salunke6c54c282005-09-06 15:17:14 -070091
92Do the steps below to download the BIOS image.
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -030093
Abhay Salunke6c54c282005-09-06 15:17:14 -0700941) echo 1 > /sys/class/firmware/dell_rbu/loading
952) cp bios_image.hdr /sys/class/firmware/dell_rbu/data
963) echo 0 > /sys/class/firmware/dell_rbu/loading
97
98The /sys/class/firmware/dell_rbu/ entries will remain till the following is
99done.
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -0300100
101::
102
103 echo -1 > /sys/class/firmware/dell_rbu/loading
104
Abhay Salunkead6ce872005-10-11 08:29:02 -0700105Until this step is completed the driver cannot be unloaded.
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -0300106
Masanori Kobayasi1b68bfc2009-06-04 21:12:29 +0900107Also echoing either mono, packet or init in to image_type will free up the
Abhay Salunkead6ce872005-10-11 08:29:02 -0700108memory allocated by the driver.
109
Frederik Schwarzer0211a9c2008-12-29 22:14:56 +0100110If a user by accident executes steps 1 and 3 above without executing step 2;
111it will make the /sys/class/firmware/dell_rbu/ entries disappear.
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -0300112
113The entries can be recreated by doing the following::
114
115 echo init > /sys/devices/platform/dell_rbu/image_type
116
117.. note:: echoing init in image_type does not change it original value.
Abhay Salunke6c54c282005-09-06 15:17:14 -0700118
119Also the driver provides /sys/devices/platform/dell_rbu/data readonly file to
Abhay Salunkead6ce872005-10-11 08:29:02 -0700120read back the image downloaded.
Abhay Salunke6c54c282005-09-06 15:17:14 -0700121
Mauro Carvalho Chehab58ef0e52017-05-17 14:25:05 -0300122.. note::
123
124 This driver requires a patch for firmware_class.c which has the modified
125 request_firmware_nowait function.
126
127 Also after updating the BIOS image a user mode application needs to execute
128 code which sends the BIOS update request to the BIOS. So on the next reboot
129 the BIOS knows about the new image downloaded and it updates itself.
130 Also don't unload the rbu driver if the image has to be updated.
Abhay Salunke6c54c282005-09-06 15:17:14 -0700131