Contents
The EEPROM contents is built from PDRs (whatever that means). On the N810, the contents of some of the PDRs are loaded via wlan-cal. In EEPROM, the structure is as follows, wlan-cal loads each PDR record contents through different sysfs files.
__le32 unknown; u16 pad; __le16 wraplen; __le32 arm_opcode; u8 data[wraplen]; u8 pdrdata[variable];
The PDR data is built from records:
__le16 record_len; /* in 16-bit words! */ __le16 record_type; u8 record_data[2*record_len];
The last record has bogus data and a record type of zero (PDR_END). The known record types are:
numeric value |
type |
0x0000 |
PDR_END |
0x0001 |
PDR_MANUFACTURING_PART_NUMBER |
0x0002 |
PDR_PDA_VERSION |
0x0003 |
PDR_NIC_SERIAL_NUMBER |
0x0101 |
PDR_MAC_ADDRESS |
0x0103 |
PDR_REGULATORY_DOMAIN_LIST |
0x0107 |
PDR_TEMPERATURE_TYPE |
0x0402 |
PDR_PRISM_PCI_IDENTIFIER |
0x1000 |
PDR_COUNTRY_INFORMATION |
0x1001 |
PDR_INTERFACE_LIST |
0x1002 |
PDR_HARDWARE_PLATFORM_COMPONENT_ID |
0x1003 |
PDR_OEM_NAME |
0x1004 |
PDR_PRODUCT_NAME |
0x1005 |
PDR_UTF8_OEM_NAME |
0x1006 |
PDR_UTF8_PRODUCT_NAME |
0x1007 |
PDR_COUNTRY_LIST |
0x1008 |
PDR_DEFAULT_COUNTRY |
0x1100 |
PDR_ANTENNA_GAIN |
0x1901 |
PDR_PRISM_INDIGO_PA_CALIBRATION_DATA |
0x1902 |
PDR_RSSI_LINEAR_APPROXIMATION |
0x1903 |
PDR_PRISM_PA_CAL_OUTPUT_POWER_LIMITS |
0x1904 |
PDR_PRISM_PA_CAL_CURVE_DATA |
0x1905 |
PDR_RSSI_LINEAR_APPROXIMATION_DUAL_BAND |
0x1906 |
PDR_PRISM_ZIF_TX_IQ_CALIBRATION |
0x1907 |
PDR_REGULATORY_POWER_LIMITS |
0x1908 |
PDR_RSSI_LINEAR_APPROXIMATION_EXTENDED |
0x1909 |
PDR_RADIATED_TRANSMISSION_CORRECTION |
0x190a |
PDR_PRISM_TX_IQ_CALIBRATION |
0x8000 |
PDR_BASEBAND_REGISTERS |
0x8001 |
PDR_PER_CHANNEL_BASEBAND_REGISTERS |
Used on my N810 are the following.
PDR_MANUFACTURING_PART_NUMBER
six times 0x58
PDR_NIC_SERIAL_NUMBER
0x31, 0x30, 0x34, 0x00
PDR_MAC_ADDRESS
6 bytes, hardcoded is bogus data
PDR_INTERFACE_LIST
Built from any count of such structures:
__le16 role; __le16 if_id; __le16 variant; __le16 btm_compat; __le16 top_compat;
PDR_HARDWARE_PLATFORM_COMPONENT_ID
Hardcoded to 0x03, 0x20, 0x00, 0x43
PDR_RSSI_LINEAR_APPROXIMATION_EXTENDED
Starts with the following fields:
u8 pdr_revision; /* 1 */ u8 xcvr_bmp; /* transceiver bitmap? */
and then any count of such structures:
__le16 freq; /* in MHz */ __le16 rssiA; __le16 rssiB; __le16 rssiLNA;
PDR_PRISM_PA_CAL_CURVE_DATA
Starts with the following fields:
u8 pdr_revision; /* 3 (PHASER) */ u8 xcvr_bmp; /* transceiver bitmap? */ u8 ppc; /* points per channel */ u8 pad;
and then any count of such structures:
__le16 freq; /* in MHz */ __le16 ladder; u8 rate_set_mask; u8 rate_set_size; struct { __le16 rf_power; __le16 pa_detector; __le16 pcv; } curve_data[ppc]; /* ppc from above */
PDR_PRISM_PA_CAL_OUTPUT_POWER_LIMITS
Starts with the following fields:
u8 pdr_revision; /* 1 (PHASER) */ u8 xcvr_bmp; /* transceiver bitmap? */ u8 pa_lvls; /* # of PA levels */ u8 pad;
and then any count of such structures:
__le16 frequency; /* in MHz */ u8 rate_set_mask; u8 rate_set_size; __le16 limit_barker; __le16 limit_bpsk; __le16 limit_qpsk; __le16 limit_16qam; __le16 limit_64qam;
PDR_PRISM_ZIF_TX_IQ_CALIBRATION
Any number of the following structure:
__le16 frequency; /* in MHz */ __le16 param1; __le16 param2; __le16 param3; __le16 param4;
PDR_ANTENNA_GAIN
Hardcoded at 0x08, 0x08, 0x08, 0x08.