File README.dump_fw changed (mode: 100644) (index 8778f6f..c5208c9) |
|
1 |
|
This package contains two utilities, dump_fw and hfwget. If placed at |
|
2 |
|
the root of a wl_lkm source tree, both utilities will be built with |
|
3 |
|
the following command. |
|
4 |
|
|
|
5 |
|
make -f dump_fw.mk |
|
6 |
|
|
|
7 |
|
In any other location only hfwget will be built. |
|
8 |
|
|
|
9 |
|
|
1 |
10 |
dump_fw |
dump_fw |
2 |
11 |
------- |
------- |
3 |
12 |
|
|
|
... |
... |
the firmware for Hermes I AP+STA and Hermes II AP+STA respectively. |
14 |
23 |
|
|
15 |
24 |
To use the programs just do: |
To use the programs just do: |
16 |
25 |
|
|
17 |
|
./dump_h1_fw root |
|
|
26 |
|
./dump_h1_fw <root> |
18 |
27 |
|
|
19 |
|
Which will produce root_ap.fw and root_sta.fw, with root replaced by |
|
20 |
|
whatever you specified. |
|
|
28 |
|
Which will produce <root>_ap_fw.bin and <root>_sta_fw.bin. |
21 |
29 |
|
|
22 |
30 |
If you want to use the wl_lkm_714 source tree instead, you can. See |
If you want to use the wl_lkm_714 source tree instead, you can. See |
23 |
31 |
instructions in dump_fw.mk |
instructions in dump_fw.mk |
|
... |
... |
instructions in dump_fw.mk |
25 |
33 |
KNOWN BUGS |
KNOWN BUGS |
26 |
34 |
---------- |
---------- |
27 |
35 |
|
|
28 |
|
1. Compatibility information offset present, but data not output. |
|
|
36 |
|
N/A |
29 |
37 |
|
|
30 |
38 |
|
|
|
39 |
|
|
31 |
40 |
hfwget |
hfwget |
32 |
41 |
------ |
------ |
33 |
42 |
|
|
34 |
|
Program to dump Lucent tertiary and Variant 2 FW images from windows |
|
35 |
|
drivers (WLLUC48.SYS, WLLUC48B.SYS). Should work with Agere |
|
36 |
|
(WLAGS48B.SYS) and Dell (WLDEL48B.SYS) drivers, and probably |
|
37 |
|
others. The firmware images are intended to be used with the |
|
|
43 |
|
Program to dump Lucent Station and AP images from Windows and Apple |
|
44 |
|
drivers. The firmware images are intended to be used with the |
38 |
45 |
orinoco_cs and hermes_dld Linux driver. |
orinoco_cs and hermes_dld Linux driver. |
39 |
46 |
|
|
|
47 |
|
Windows drivers: |
|
48 |
|
WLLUC48.SYS (old Lucent) |
|
49 |
|
WLLUC48B.SYS (Lucent) |
|
50 |
|
WLAGS48B.SYS (Agere) |
|
51 |
|
WLDEL48B.SYS (Dell) |
|
52 |
|
|
|
53 |
|
Apple Powerbook G3 AirPort firmware: |
|
54 |
|
AppleAirPort.kext/Contents/PlugIns/AppleAirPortFW.kext |
|
55 |
|
AppleAirPort.kext/Contents/PlugIns/AppleAirPortFWAP.kext |
|
56 |
|
|
40 |
57 |
Compiled when building dump_fw above. Alternatively, extract into any |
Compiled when building dump_fw above. Alternatively, extract into any |
41 |
58 |
directory and run: |
directory and run: |
42 |
59 |
|
|
|
... |
... |
make -f dump_fw.mk hfwget |
45 |
62 |
This will generate hfwget which will dump the firmware images it can |
This will generate hfwget which will dump the firmware images it can |
46 |
63 |
locate in the specified file. Just do: |
locate in the specified file. Just do: |
47 |
64 |
|
|
48 |
|
./hfwget <path to driver> |
|
|
65 |
|
./hfwget <path to file> <rootname> |
49 |
66 |
|
|
50 |
67 |
Which will output any of: |
Which will output any of: |
51 |
|
R02xxxxx.hfw Variant 2 firmware for RAM download |
|
52 |
|
T02xxxxx.hfw Tertiary firmware |
|
53 |
|
guess000.hfw Variant 2 firmware from Dell/old Lucent drivers. |
|
|
68 |
|
<rootname>_sta_fw.bin Station firmware for RAM download |
|
69 |
|
<rootname>_ap_fw.bin AP firmware for RAM download |
|
70 |
|
|
|
71 |
|
For the Airport, you need to specify the path to the firmware image |
|
72 |
|
(AppleAirPort.kext/Contents/PlugIns/AppleAirPortFW.kext/Contents/MacOS/AppleAirPortFW) |
54 |
73 |
|
|
55 |
74 |
KNOWN BUGS |
KNOWN BUGS |
56 |
75 |
---------- |
---------- |
57 |
|
1. Will only work on a little endian machine. |
|
58 |
76 |
|
|
59 |
|
2. Compatibility information offset present, but data not output. |
|
|
77 |
|
N/A |
60 |
78 |
|
|
61 |
79 |
|
|
62 |
80 |
Enjoy, |
Enjoy, |
63 |
81 |
|
|
64 |
82 |
Dave Kilroy |
Dave Kilroy |
65 |
|
September 2007. |
|
|
83 |
|
October 2008. |
File dump_fw.c changed (mode: 100644) (index 561dd2a..9b099a3) |
24 |
24 |
* .. |
* .. |
25 |
25 |
* pda_n |
* pda_n |
26 |
26 |
* pda_term |
* pda_term |
|
27 |
|
* pri_1 |
|
28 |
|
* .. |
|
29 |
|
* pri_n |
|
30 |
|
* pri_term |
|
31 |
|
* compat_1 |
|
32 |
|
* .. |
|
33 |
|
* compat_n |
|
34 |
|
* compat_term |
27 |
35 |
* |
* |
28 |
36 |
* Where Block_n is: |
* Where Block_n is: |
29 |
37 |
* addr [4] NIC address to program data |
* addr [4] NIC address to program data |
|
34 |
42 |
* 0xFFFFFFFF [4] BLOCK_END identifier |
* 0xFFFFFFFF [4] BLOCK_END identifier |
35 |
43 |
* 0x0000 [2] zero length |
* 0x0000 [2] zero length |
36 |
44 |
* |
* |
37 |
|
* pda_n is: |
|
38 |
|
* id [4] PDA identifier |
|
39 |
|
* addr [4] Address to program PDA |
|
|
45 |
|
* pda_n and pri_n are: |
|
46 |
|
* id [4] (Primary) PDA identifier |
|
47 |
|
* addr [4] Address to program (Primary) PDA |
40 |
48 |
* len [4] Number of bytes to program |
* len [4] Number of bytes to program |
41 |
49 |
* |
* |
42 |
|
* pda_term |
|
|
50 |
|
* pda_term and pri_n are: |
43 |
51 |
* 0x00000000 [4] PDI_END |
* 0x00000000 [4] PDI_END |
44 |
52 |
* 0x00000000 [4] |
* 0x00000000 [4] |
45 |
53 |
* 0x00000000 [4] |
* 0x00000000 [4] |
46 |
54 |
* |
* |
|
55 |
|
* compat_n is: |
|
56 |
|
* size [2] Length of LTV - ((n_bytes/2) - 1) |
|
57 |
|
* code [2] LTV code - 0xFD21 (FW compatibility range) |
|
58 |
|
* 0xFD22 (Modem I/F compatibility range) |
|
59 |
|
* 0xFD23 (Controller I/F compatibility range) |
|
60 |
|
* role [2] Who this restriction applies to? |
|
61 |
|
* 0x00 - 'Supplier' |
|
62 |
|
* 0x01 - 'Actor' |
|
63 |
|
* id [2] |
|
64 |
|
* spec_1 Specifications |
|
65 |
|
* ... |
|
66 |
|
* spec_20 |
|
67 |
|
* |
|
68 |
|
* spec_n is: |
|
69 |
|
* variant [2] |
|
70 |
|
* bottom [2] |
|
71 |
|
* top [2] |
|
72 |
|
* |
47 |
73 |
* There is more information available in the driver. In particular |
* There is more information available in the driver. In particular |
48 |
74 |
* whether the block is supposed to be programmed to NV or volatile, |
* whether the block is supposed to be programmed to NV or volatile, |
49 |
75 |
* and various flags. |
* and various flags. |
|
... |
... |
terminate: |
289 |
315 |
return; |
return; |
290 |
316 |
} |
} |
291 |
317 |
|
|
|
318 |
|
void dump_compat(FILE *f, CFG_RANGE20_STRCT *c) |
|
319 |
|
{ |
|
320 |
|
#if __wl_lkm < 718 |
|
321 |
|
#define VARIANT_STRUCT variant |
|
322 |
|
#define VARIANT_NO number |
|
323 |
|
#else |
|
324 |
|
#define VARIANT_STRUCT var_rec |
|
325 |
|
#define VARIANT_NO variant |
|
326 |
|
#endif |
|
327 |
|
u8 hdr[sizeof(c->id) + sizeof(c->typ) + sizeof(c->role) + sizeof(c->id)]; |
|
328 |
|
u8 spec[sizeof(c->VARIANT_STRUCT[0])]; |
|
329 |
|
u16 *len = (u16*) &hdr[0]; |
|
330 |
|
u16 *typ = (u16*) &hdr[sizeof(c->len)]; |
|
331 |
|
u16 *role = (u16*) &hdr[sizeof(c->len) + sizeof(c->typ)]; |
|
332 |
|
u16 *id = (u16*) &hdr[sizeof(c->len) + sizeof(c->typ) + sizeof(c->role)]; |
|
333 |
|
u16 *variant = (u16*) &spec[0]; |
|
334 |
|
u16 *bottom = (u16*) &spec[sizeof(c->VARIANT_STRUCT[0].VARIANT_NO)]; |
|
335 |
|
u16 *top = (u16*) &spec[sizeof(c->VARIANT_STRUCT[0].VARIANT_NO) + sizeof(c->VARIANT_STRUCT[0].bottom)]; |
|
336 |
|
int i; |
|
337 |
|
|
|
338 |
|
while(c->len) |
|
339 |
|
{ |
|
340 |
|
*len = host_to_le16(c->len); |
|
341 |
|
*typ = host_to_le16(c->typ); |
|
342 |
|
*role = host_to_le16(c->role); |
|
343 |
|
*id = host_to_le16(c->id); |
|
344 |
|
fwrite(&hdr, 1, sizeof(hdr), f); |
|
345 |
|
|
|
346 |
|
for (i = 0; i < sizeof(c->VARIANT_STRUCT)/sizeof(c->VARIANT_STRUCT[0]); i++) |
|
347 |
|
{ |
|
348 |
|
*variant = host_to_le16(c->VARIANT_STRUCT[i].VARIANT_NO); |
|
349 |
|
*bottom = host_to_le16(c->VARIANT_STRUCT[i].bottom); |
|
350 |
|
*top = host_to_le16(c->VARIANT_STRUCT[i].top); |
|
351 |
|
fwrite(&spec, 1, sizeof(spec), f); |
|
352 |
|
} |
|
353 |
|
|
|
354 |
|
c++; |
|
355 |
|
} |
|
356 |
|
|
|
357 |
|
/* sentinel */ |
|
358 |
|
memset(&hdr[0], 0, sizeof(hdr)); |
|
359 |
|
memset(&spec[0], 0, sizeof(spec)); |
|
360 |
|
fwrite(&hdr, 1, sizeof(hdr), f); |
|
361 |
|
for (i = 0; i < sizeof(c->VARIANT_STRUCT)/sizeof(c->VARIANT_STRUCT[0]); i++) |
|
362 |
|
{ |
|
363 |
|
fwrite(&spec, 1, sizeof(spec), f); |
|
364 |
|
} |
|
365 |
|
|
|
366 |
|
return; |
|
367 |
|
} |
|
368 |
|
|
292 |
369 |
void dump_image(FILE* f, memimage *image) |
void dump_image(FILE* f, memimage *image) |
293 |
370 |
{ |
{ |
294 |
371 |
u32 image_header[6]; |
u32 image_header[6]; |
|
... |
... |
void dump_image(FILE* f, memimage *image) |
332 |
409 |
dump_blocks(f, image); |
dump_blocks(f, image); |
333 |
410 |
dump_pdr(f, image->pdaplug); |
dump_pdr(f, image->pdaplug); |
334 |
411 |
dump_pdr(f, image->priplug); |
dump_pdr(f, image->priplug); |
335 |
|
/* compat info not written */ |
|
|
412 |
|
dump_compat(f, image->compat); |
336 |
413 |
|
|
337 |
414 |
return; |
return; |
338 |
415 |
} |
} |
File dump_fw.mk changed (mode: 100644) (index 352bd0a..b397f2c) |
7 |
7 |
# - include/hcf/hcfcfg.h line 775 should be commented out |
# - include/hcf/hcfcfg.h line 775 should be commented out |
8 |
8 |
# - select the appropriate DIR_FW and LKM_CFLAGS values below |
# - select the appropriate DIR_FW and LKM_CFLAGS values below |
9 |
9 |
|
|
10 |
|
LIB := ../lib |
|
11 |
|
|
|
12 |
10 |
DIR_HCF := hcf |
DIR_HCF := hcf |
13 |
11 |
DIR_DHF := dhf |
DIR_DHF := dhf |
14 |
12 |
# 714 firmware is in |
# 714 firmware is in |
|
... |
... |
DIR_FW := firmware |
18 |
16 |
DIR_CONFIG := include/hcf |
DIR_CONFIG := include/hcf |
19 |
17 |
DIR_WIRELESS := include/wireless |
DIR_WIRELESS := include/wireless |
20 |
18 |
|
|
21 |
|
CONFIG_HEADERS := $(DIR_CONFIG)/debug.h $(DIR_CONFIG)/hcfcfg.h |
|
22 |
|
HCF_HEADERS := $(DIR_HCF)/hcf.h $(DIR_HCF)/mdd.h $(DIR_HCF)/hcfdef.h |
|
23 |
|
MMD_HEADERS := $(MMD_DIR)/mmd.h |
|
24 |
|
WIRELESS_HEADERS := $(DIR_WIRELESS)/wl_enc.h $(DIR_WIRELESS)/wl_if.h $(DIR_WIRELESS)/wl_internal.h $(DIR_WIRELESS)/wl_version.h |
|
25 |
|
|
|
26 |
19 |
OBJS := dump_fw.o |
OBJS := dump_fw.o |
27 |
20 |
|
|
28 |
21 |
CFLAGS := -O3 -Wall -Wstrict-prototypes -pipe |
CFLAGS := -O3 -Wall -Wstrict-prototypes -pipe |
|
... |
... |
hfwget : hfwget.c |
69 |
62 |
gcc $(CFLAGS) $^ -o $@ |
gcc $(CFLAGS) $^ -o $@ |
70 |
63 |
|
|
71 |
64 |
clean : |
clean : |
72 |
|
rm $(OBJS) $(H1_OBJS) $(H2_OBJS) dump_h1_fw dump_h2_fw |
|
|
65 |
|
rm $(TARGETS) $(OBJS) $(H1_OBJS) $(H2_OBJS) |