diff options
author | Jaswinder Singh Rajput <jaswinderrajput@gmail.com> | 2009-01-07 15:59:17 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-01-07 15:59:17 -0500 |
commit | 9ac32e1bc0518b01b47dd34a733dce8634a38ed3 (patch) | |
tree | 4316ea3a959cab393289c67364ee63f06e34543c | |
parent | 92dc8cc317844e5681f5d8990896720ed2b21cc8 (diff) |
firmware: convert e100 driver to request_firmware()
Thanks to David Woodhouse for help.
Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/e100.c | 299 | ||||
-rw-r--r-- | firmware/Makefile | 2 | ||||
-rw-r--r-- | firmware/WHENCE | 12 | ||||
-rw-r--r-- | firmware/e100/d101m_ucode.bin.ihex | 38 | ||||
-rw-r--r-- | firmware/e100/d101s_ucode.bin.ihex | 38 | ||||
-rw-r--r-- | firmware/e100/d102e_ucode.bin.ihex | 38 |
6 files changed, 225 insertions, 202 deletions
diff --git a/drivers/net/e100.c b/drivers/net/e100.c index 134b2d60b479..86bb876fb123 100644 --- a/drivers/net/e100.c +++ b/drivers/net/e100.c | |||
@@ -161,6 +161,7 @@ | |||
161 | #include <linux/skbuff.h> | 161 | #include <linux/skbuff.h> |
162 | #include <linux/ethtool.h> | 162 | #include <linux/ethtool.h> |
163 | #include <linux/string.h> | 163 | #include <linux/string.h> |
164 | #include <linux/firmware.h> | ||
164 | #include <asm/unaligned.h> | 165 | #include <asm/unaligned.h> |
165 | 166 | ||
166 | 167 | ||
@@ -174,10 +175,17 @@ | |||
174 | #define E100_WATCHDOG_PERIOD (2 * HZ) | 175 | #define E100_WATCHDOG_PERIOD (2 * HZ) |
175 | #define E100_NAPI_WEIGHT 16 | 176 | #define E100_NAPI_WEIGHT 16 |
176 | 177 | ||
178 | #define FIRMWARE_D101M "e100/d101m_ucode.bin" | ||
179 | #define FIRMWARE_D101S "e100/d101s_ucode.bin" | ||
180 | #define FIRMWARE_D102E "e100/d102e_ucode.bin" | ||
181 | |||
177 | MODULE_DESCRIPTION(DRV_DESCRIPTION); | 182 | MODULE_DESCRIPTION(DRV_DESCRIPTION); |
178 | MODULE_AUTHOR(DRV_COPYRIGHT); | 183 | MODULE_AUTHOR(DRV_COPYRIGHT); |
179 | MODULE_LICENSE("GPL"); | 184 | MODULE_LICENSE("GPL"); |
180 | MODULE_VERSION(DRV_VERSION); | 185 | MODULE_VERSION(DRV_VERSION); |
186 | MODULE_FIRMWARE(FIRMWARE_D101M); | ||
187 | MODULE_FIRMWARE(FIRMWARE_D101S); | ||
188 | MODULE_FIRMWARE(FIRMWARE_D102E); | ||
181 | 189 | ||
182 | static int debug = 3; | 190 | static int debug = 3; |
183 | static int eeprom_bad_csum_allow = 0; | 191 | static int eeprom_bad_csum_allow = 0; |
@@ -1049,178 +1057,6 @@ static void e100_configure(struct nic *nic, struct cb *cb, struct sk_buff *skb) | |||
1049 | c[16], c[17], c[18], c[19], c[20], c[21], c[22], c[23]); | 1057 | c[16], c[17], c[18], c[19], c[20], c[21], c[22], c[23]); |
1050 | } | 1058 | } |
1051 | 1059 | ||
1052 | /********************************************************/ | ||
1053 | /* Micro code for 8086:1229 Rev 8 */ | ||
1054 | /********************************************************/ | ||
1055 | |||
1056 | /* Parameter values for the D101M B-step */ | ||
1057 | #define D101M_CPUSAVER_TIMER_DWORD 78 | ||
1058 | #define D101M_CPUSAVER_BUNDLE_DWORD 65 | ||
1059 | #define D101M_CPUSAVER_MIN_SIZE_DWORD 126 | ||
1060 | |||
1061 | #define D101M_B_RCVBUNDLE_UCODE \ | ||
1062 | {\ | ||
1063 | 0x00550215, 0xFFFF0437, 0xFFFFFFFF, 0x06A70789, 0xFFFFFFFF, 0x0558FFFF, \ | ||
1064 | 0x000C0001, 0x00101312, 0x000C0008, 0x00380216, \ | ||
1065 | 0x0010009C, 0x00204056, 0x002380CC, 0x00380056, \ | ||
1066 | 0x0010009C, 0x00244C0B, 0x00000800, 0x00124818, \ | ||
1067 | 0x00380438, 0x00000000, 0x00140000, 0x00380555, \ | ||
1068 | 0x00308000, 0x00100662, 0x00100561, 0x000E0408, \ | ||
1069 | 0x00134861, 0x000C0002, 0x00103093, 0x00308000, \ | ||
1070 | 0x00100624, 0x00100561, 0x000E0408, 0x00100861, \ | ||
1071 | 0x000C007E, 0x00222C21, 0x000C0002, 0x00103093, \ | ||
1072 | 0x00380C7A, 0x00080000, 0x00103090, 0x00380C7A, \ | ||
1073 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1074 | 0x0010009C, 0x00244C2D, 0x00010004, 0x00041000, \ | ||
1075 | 0x003A0437, 0x00044010, 0x0038078A, 0x00000000, \ | ||
1076 | 0x00100099, 0x00206C7A, 0x0010009C, 0x00244C48, \ | ||
1077 | 0x00130824, 0x000C0001, 0x00101213, 0x00260C75, \ | ||
1078 | 0x00041000, 0x00010004, 0x00130826, 0x000C0006, \ | ||
1079 | 0x002206A8, 0x0013C926, 0x00101313, 0x003806A8, \ | ||
1080 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1081 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1082 | 0x00080600, 0x00101B10, 0x00050004, 0x00100826, \ | ||
1083 | 0x00101210, 0x00380C34, 0x00000000, 0x00000000, \ | ||
1084 | 0x0021155B, 0x00100099, 0x00206559, 0x0010009C, \ | ||
1085 | 0x00244559, 0x00130836, 0x000C0000, 0x00220C62, \ | ||
1086 | 0x000C0001, 0x00101B13, 0x00229C0E, 0x00210C0E, \ | ||
1087 | 0x00226C0E, 0x00216C0E, 0x0022FC0E, 0x00215C0E, \ | ||
1088 | 0x00214C0E, 0x00380555, 0x00010004, 0x00041000, \ | ||
1089 | 0x00278C67, 0x00040800, 0x00018100, 0x003A0437, \ | ||
1090 | 0x00130826, 0x000C0001, 0x00220559, 0x00101313, \ | ||
1091 | 0x00380559, 0x00000000, 0x00000000, 0x00000000, \ | ||
1092 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1093 | 0x00000000, 0x00130831, 0x0010090B, 0x00124813, \ | ||
1094 | 0x000CFF80, 0x002606AB, 0x00041000, 0x00010004, \ | ||
1095 | 0x003806A8, 0x00000000, 0x00000000, 0x00000000, \ | ||
1096 | } | ||
1097 | |||
1098 | /********************************************************/ | ||
1099 | /* Micro code for 8086:1229 Rev 9 */ | ||
1100 | /********************************************************/ | ||
1101 | |||
1102 | /* Parameter values for the D101S */ | ||
1103 | #define D101S_CPUSAVER_TIMER_DWORD 78 | ||
1104 | #define D101S_CPUSAVER_BUNDLE_DWORD 67 | ||
1105 | #define D101S_CPUSAVER_MIN_SIZE_DWORD 128 | ||
1106 | |||
1107 | #define D101S_RCVBUNDLE_UCODE \ | ||
1108 | {\ | ||
1109 | 0x00550242, 0xFFFF047E, 0xFFFFFFFF, 0x06FF0818, 0xFFFFFFFF, 0x05A6FFFF, \ | ||
1110 | 0x000C0001, 0x00101312, 0x000C0008, 0x00380243, \ | ||
1111 | 0x0010009C, 0x00204056, 0x002380D0, 0x00380056, \ | ||
1112 | 0x0010009C, 0x00244F8B, 0x00000800, 0x00124818, \ | ||
1113 | 0x0038047F, 0x00000000, 0x00140000, 0x003805A3, \ | ||
1114 | 0x00308000, 0x00100610, 0x00100561, 0x000E0408, \ | ||
1115 | 0x00134861, 0x000C0002, 0x00103093, 0x00308000, \ | ||
1116 | 0x00100624, 0x00100561, 0x000E0408, 0x00100861, \ | ||
1117 | 0x000C007E, 0x00222FA1, 0x000C0002, 0x00103093, \ | ||
1118 | 0x00380F90, 0x00080000, 0x00103090, 0x00380F90, \ | ||
1119 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1120 | 0x0010009C, 0x00244FAD, 0x00010004, 0x00041000, \ | ||
1121 | 0x003A047E, 0x00044010, 0x00380819, 0x00000000, \ | ||
1122 | 0x00100099, 0x00206FFD, 0x0010009A, 0x0020AFFD, \ | ||
1123 | 0x0010009C, 0x00244FC8, 0x00130824, 0x000C0001, \ | ||
1124 | 0x00101213, 0x00260FF7, 0x00041000, 0x00010004, \ | ||
1125 | 0x00130826, 0x000C0006, 0x00220700, 0x0013C926, \ | ||
1126 | 0x00101313, 0x00380700, 0x00000000, 0x00000000, \ | ||
1127 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1128 | 0x00080600, 0x00101B10, 0x00050004, 0x00100826, \ | ||
1129 | 0x00101210, 0x00380FB6, 0x00000000, 0x00000000, \ | ||
1130 | 0x002115A9, 0x00100099, 0x002065A7, 0x0010009A, \ | ||
1131 | 0x0020A5A7, 0x0010009C, 0x002445A7, 0x00130836, \ | ||
1132 | 0x000C0000, 0x00220FE4, 0x000C0001, 0x00101B13, \ | ||
1133 | 0x00229F8E, 0x00210F8E, 0x00226F8E, 0x00216F8E, \ | ||
1134 | 0x0022FF8E, 0x00215F8E, 0x00214F8E, 0x003805A3, \ | ||
1135 | 0x00010004, 0x00041000, 0x00278FE9, 0x00040800, \ | ||
1136 | 0x00018100, 0x003A047E, 0x00130826, 0x000C0001, \ | ||
1137 | 0x002205A7, 0x00101313, 0x003805A7, 0x00000000, \ | ||
1138 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1139 | 0x00000000, 0x00000000, 0x00000000, 0x00130831, \ | ||
1140 | 0x0010090B, 0x00124813, 0x000CFF80, 0x00260703, \ | ||
1141 | 0x00041000, 0x00010004, 0x00380700 \ | ||
1142 | } | ||
1143 | |||
1144 | /********************************************************/ | ||
1145 | /* Micro code for the 8086:1229 Rev F/10 */ | ||
1146 | /********************************************************/ | ||
1147 | |||
1148 | /* Parameter values for the D102 E-step */ | ||
1149 | #define D102_E_CPUSAVER_TIMER_DWORD 42 | ||
1150 | #define D102_E_CPUSAVER_BUNDLE_DWORD 54 | ||
1151 | #define D102_E_CPUSAVER_MIN_SIZE_DWORD 46 | ||
1152 | |||
1153 | #define D102_E_RCVBUNDLE_UCODE \ | ||
1154 | {\ | ||
1155 | 0x007D028F, 0x0E4204F9, 0x14ED0C85, 0x14FA14E9, 0x0EF70E36, 0x1FFF1FFF, \ | ||
1156 | 0x00E014B9, 0x00000000, 0x00000000, 0x00000000, \ | ||
1157 | 0x00E014BD, 0x00000000, 0x00000000, 0x00000000, \ | ||
1158 | 0x00E014D5, 0x00000000, 0x00000000, 0x00000000, \ | ||
1159 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1160 | 0x00E014C1, 0x00000000, 0x00000000, 0x00000000, \ | ||
1161 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1162 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1163 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1164 | 0x00E014C8, 0x00000000, 0x00000000, 0x00000000, \ | ||
1165 | 0x00200600, 0x00E014EE, 0x00000000, 0x00000000, \ | ||
1166 | 0x0030FF80, 0x00940E46, 0x00038200, 0x00102000, \ | ||
1167 | 0x00E00E43, 0x00000000, 0x00000000, 0x00000000, \ | ||
1168 | 0x00300006, 0x00E014FB, 0x00000000, 0x00000000, \ | ||
1169 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1170 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1171 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1172 | 0x00906E41, 0x00800E3C, 0x00E00E39, 0x00000000, \ | ||
1173 | 0x00906EFD, 0x00900EFD, 0x00E00EF8, 0x00000000, \ | ||
1174 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1175 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1176 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1177 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1178 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1179 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1180 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1181 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1182 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1183 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1184 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1185 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1186 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1187 | 0x00000000, 0x00000000, 0x00000000, 0x00000000, \ | ||
1188 | } | ||
1189 | |||
1190 | static void e100_setup_ucode(struct nic *nic, struct cb *cb, struct sk_buff *skb) | ||
1191 | { | ||
1192 | /* *INDENT-OFF* */ | ||
1193 | static struct { | ||
1194 | u32 ucode[UCODE_SIZE + 1]; | ||
1195 | u8 mac; | ||
1196 | u8 timer_dword; | ||
1197 | u8 bundle_dword; | ||
1198 | u8 min_size_dword; | ||
1199 | } ucode_opts[] = { | ||
1200 | { D101M_B_RCVBUNDLE_UCODE, | ||
1201 | mac_82559_D101M, | ||
1202 | D101M_CPUSAVER_TIMER_DWORD, | ||
1203 | D101M_CPUSAVER_BUNDLE_DWORD, | ||
1204 | D101M_CPUSAVER_MIN_SIZE_DWORD }, | ||
1205 | { D101S_RCVBUNDLE_UCODE, | ||
1206 | mac_82559_D101S, | ||
1207 | D101S_CPUSAVER_TIMER_DWORD, | ||
1208 | D101S_CPUSAVER_BUNDLE_DWORD, | ||
1209 | D101S_CPUSAVER_MIN_SIZE_DWORD }, | ||
1210 | { D102_E_RCVBUNDLE_UCODE, | ||
1211 | mac_82551_F, | ||
1212 | D102_E_CPUSAVER_TIMER_DWORD, | ||
1213 | D102_E_CPUSAVER_BUNDLE_DWORD, | ||
1214 | D102_E_CPUSAVER_MIN_SIZE_DWORD }, | ||
1215 | { D102_E_RCVBUNDLE_UCODE, | ||
1216 | mac_82551_10, | ||
1217 | D102_E_CPUSAVER_TIMER_DWORD, | ||
1218 | D102_E_CPUSAVER_BUNDLE_DWORD, | ||
1219 | D102_E_CPUSAVER_MIN_SIZE_DWORD }, | ||
1220 | { {0}, 0, 0, 0, 0} | ||
1221 | }, *opts; | ||
1222 | /* *INDENT-ON* */ | ||
1223 | |||
1224 | /************************************************************************* | 1060 | /************************************************************************* |
1225 | * CPUSaver parameters | 1061 | * CPUSaver parameters |
1226 | * | 1062 | * |
@@ -1280,42 +1116,101 @@ static void e100_setup_ucode(struct nic *nic, struct cb *cb, struct sk_buff *skb | |||
1280 | #define BUNDLEMAX (u16)6 | 1116 | #define BUNDLEMAX (u16)6 |
1281 | #define INTDELAY (u16)1536 /* 0x600 */ | 1117 | #define INTDELAY (u16)1536 /* 0x600 */ |
1282 | 1118 | ||
1119 | /* Initialize firmware */ | ||
1120 | static const struct firmware *e100_request_firmware(struct nic *nic) | ||
1121 | { | ||
1122 | const char *fw_name; | ||
1123 | const struct firmware *fw; | ||
1124 | u8 timer, bundle, min_size; | ||
1125 | int err; | ||
1126 | |||
1283 | /* do not load u-code for ICH devices */ | 1127 | /* do not load u-code for ICH devices */ |
1284 | if (nic->flags & ich) | 1128 | if (nic->flags & ich) |
1285 | goto noloaducode; | 1129 | return NULL; |
1286 | 1130 | ||
1287 | /* Search for ucode match against h/w revision */ | 1131 | /* Search for ucode match against h/w revision */ |
1288 | for (opts = ucode_opts; opts->mac; opts++) { | 1132 | if (nic->mac == mac_82559_D101M) |
1289 | int i; | 1133 | fw_name = FIRMWARE_D101M; |
1290 | u32 *ucode = opts->ucode; | 1134 | else if (nic->mac == mac_82559_D101S) |
1291 | if (nic->mac != opts->mac) | 1135 | fw_name = FIRMWARE_D101S; |
1292 | continue; | 1136 | else if (nic->mac == mac_82551_F || nic->mac == mac_82551_10) |
1293 | 1137 | fw_name = FIRMWARE_D102E; | |
1294 | /* Insert user-tunable settings */ | 1138 | else /* No ucode on other devices */ |
1295 | ucode[opts->timer_dword] &= 0xFFFF0000; | 1139 | return NULL; |
1296 | ucode[opts->timer_dword] |= INTDELAY; | 1140 | |
1297 | ucode[opts->bundle_dword] &= 0xFFFF0000; | 1141 | err = request_firmware(&fw, fw_name, &nic->pdev->dev); |
1298 | ucode[opts->bundle_dword] |= BUNDLEMAX; | 1142 | if (err) { |
1299 | ucode[opts->min_size_dword] &= 0xFFFF0000; | 1143 | DPRINTK(PROBE, ERR, "Failed to load firmware \"%s\": %d\n", |
1300 | ucode[opts->min_size_dword] |= (BUNDLESMALL) ? 0xFFFF : 0xFF80; | 1144 | fw_name, err); |
1301 | 1145 | return ERR_PTR(err); | |
1302 | for (i = 0; i < UCODE_SIZE; i++) | 1146 | } |
1303 | cb->u.ucode[i] = cpu_to_le32(ucode[i]); | 1147 | /* Firmware should be precisely UCODE_SIZE (words) plus three bytes |
1304 | cb->command = cpu_to_le16(cb_ucode | cb_el); | 1148 | indicating the offsets for BUNDLESMALL, BUNDLEMAX, INTDELAY */ |
1305 | return; | 1149 | if (fw->size != UCODE_SIZE * 4 + 3) { |
1306 | } | 1150 | DPRINTK(PROBE, ERR, "Firmware \"%s\" has wrong size %zu\n", |
1307 | 1151 | fw_name, fw->size); | |
1308 | noloaducode: | 1152 | release_firmware(fw); |
1309 | cb->command = cpu_to_le16(cb_nop | cb_el); | 1153 | return ERR_PTR(-EINVAL); |
1310 | } | 1154 | } |
1311 | 1155 | ||
1312 | static inline int e100_exec_cb_wait(struct nic *nic, struct sk_buff *skb, | 1156 | /* Read timer, bundle and min_size from end of firmware blob */ |
1313 | void (*cb_prepare)(struct nic *, struct cb *, struct sk_buff *)) | 1157 | timer = fw->data[UCODE_SIZE * 4]; |
1314 | { | 1158 | bundle = fw->data[UCODE_SIZE * 4 + 1]; |
1159 | min_size = fw->data[UCODE_SIZE * 4 + 2]; | ||
1160 | |||
1161 | if (timer >= UCODE_SIZE || bundle >= UCODE_SIZE || | ||
1162 | min_size >= UCODE_SIZE) { | ||
1163 | DPRINTK(PROBE, ERR, | ||
1164 | "\"%s\" has bogus offset values (0x%x,0x%x,0x%x)\n", | ||
1165 | fw_name, timer, bundle, min_size); | ||
1166 | release_firmware(fw); | ||
1167 | return ERR_PTR(-EINVAL); | ||
1168 | } | ||
1169 | /* OK, firmware is validated and ready to use... */ | ||
1170 | return fw; | ||
1171 | } | ||
1172 | |||
1173 | static void e100_setup_ucode(struct nic *nic, struct cb *cb, | ||
1174 | struct sk_buff *skb) | ||
1175 | { | ||
1176 | const struct firmware *fw = (void *)skb; | ||
1177 | u8 timer, bundle, min_size; | ||
1178 | |||
1179 | /* It's not a real skb; we just abused the fact that e100_exec_cb | ||
1180 | will pass it through to here... */ | ||
1181 | cb->skb = NULL; | ||
1182 | |||
1183 | /* firmware is stored as little endian already */ | ||
1184 | memcpy(cb->u.ucode, fw->data, UCODE_SIZE * 4); | ||
1185 | |||
1186 | /* Read timer, bundle and min_size from end of firmware blob */ | ||
1187 | timer = fw->data[UCODE_SIZE * 4]; | ||
1188 | bundle = fw->data[UCODE_SIZE * 4 + 1]; | ||
1189 | min_size = fw->data[UCODE_SIZE * 4 + 2]; | ||
1190 | |||
1191 | /* Insert user-tunable settings in cb->u.ucode */ | ||
1192 | cb->u.ucode[timer] &= cpu_to_le32(0xFFFF0000); | ||
1193 | cb->u.ucode[timer] |= cpu_to_le32(INTDELAY); | ||
1194 | cb->u.ucode[bundle] &= cpu_to_le32(0xFFFF0000); | ||
1195 | cb->u.ucode[bundle] |= cpu_to_le32(BUNDLEMAX); | ||
1196 | cb->u.ucode[min_size] &= cpu_to_le32(0xFFFF0000); | ||
1197 | cb->u.ucode[min_size] |= cpu_to_le32((BUNDLESMALL) ? 0xFFFF : 0xFF80); | ||
1198 | |||
1199 | cb->command = cpu_to_le16(cb_ucode | cb_el); | ||
1200 | } | ||
1201 | |||
1202 | static inline int e100_load_ucode_wait(struct nic *nic) | ||
1203 | { | ||
1204 | const struct firmware *fw; | ||
1315 | int err = 0, counter = 50; | 1205 | int err = 0, counter = 50; |
1316 | struct cb *cb = nic->cb_to_clean; | 1206 | struct cb *cb = nic->cb_to_clean; |
1317 | 1207 | ||
1318 | if ((err = e100_exec_cb(nic, NULL, e100_setup_ucode))) | 1208 | fw = e100_request_firmware(nic); |
1209 | /* If it's NULL, then no ucode is required */ | ||
1210 | if (!fw || IS_ERR(fw)) | ||
1211 | return PTR_ERR(fw); | ||
1212 | |||
1213 | if ((err = e100_exec_cb(nic, (void *)fw, e100_setup_ucode))) | ||
1319 | DPRINTK(PROBE,ERR, "ucode cmd failed with error %d\n", err); | 1214 | DPRINTK(PROBE,ERR, "ucode cmd failed with error %d\n", err); |
1320 | 1215 | ||
1321 | /* must restart cuc */ | 1216 | /* must restart cuc */ |
@@ -1435,7 +1330,7 @@ static int e100_hw_init(struct nic *nic) | |||
1435 | return err; | 1330 | return err; |
1436 | if ((err = e100_exec_cmd(nic, ruc_load_base, 0))) | 1331 | if ((err = e100_exec_cmd(nic, ruc_load_base, 0))) |
1437 | return err; | 1332 | return err; |
1438 | if ((err = e100_exec_cb_wait(nic, NULL, e100_setup_ucode))) | 1333 | if ((err = e100_load_ucode_wait(nic))) |
1439 | return err; | 1334 | return err; |
1440 | if ((err = e100_exec_cb(nic, NULL, e100_configure))) | 1335 | if ((err = e100_exec_cb(nic, NULL, e100_configure))) |
1441 | return err; | 1336 | return err; |
diff --git a/firmware/Makefile b/firmware/Makefile index d872b7942a30..aae5129fa892 100644 --- a/firmware/Makefile +++ b/firmware/Makefile | |||
@@ -37,6 +37,8 @@ fw-shipped-$(CONFIG_CHELSIO_T3) += cxgb3/t3b_psram-1.1.0.bin \ | |||
37 | cxgb3/t3c_psram-1.1.0.bin \ | 37 | cxgb3/t3c_psram-1.1.0.bin \ |
38 | cxgb3/t3fw-7.0.0.bin | 38 | cxgb3/t3fw-7.0.0.bin |
39 | fw-shipped-$(CONFIG_DVB_TTUSB_BUDGET) += ttusb-budget/dspbootcode.bin | 39 | fw-shipped-$(CONFIG_DVB_TTUSB_BUDGET) += ttusb-budget/dspbootcode.bin |
40 | fw-shipped-$(CONFIG_E100) += e100/d101m_ucode.bin e100/d101s_ucode.bin \ | ||
41 | e100/d102e_ucode.bin | ||
40 | fw-shipped-$(CONFIG_SMCTR) += tr_smctr.bin | 42 | fw-shipped-$(CONFIG_SMCTR) += tr_smctr.bin |
41 | fw-shipped-$(CONFIG_SND_KORG1212) += korg/k1212.dsp | 43 | fw-shipped-$(CONFIG_SND_KORG1212) += korg/k1212.dsp |
42 | fw-shipped-$(CONFIG_SND_MAESTRO3) += ess/maestro3_assp_kernel.fw \ | 44 | fw-shipped-$(CONFIG_SND_MAESTRO3) += ess/maestro3_assp_kernel.fw \ |
diff --git a/firmware/WHENCE b/firmware/WHENCE index 1bb2cf4b1735..8b5651347791 100644 --- a/firmware/WHENCE +++ b/firmware/WHENCE | |||
@@ -360,6 +360,18 @@ License: GPLv2 or OpenIB.org BSD license, no source visible | |||
360 | 360 | ||
361 | -------------------------------------------------------------------------- | 361 | -------------------------------------------------------------------------- |
362 | 362 | ||
363 | Driver: e100 -- Intel PRO/100 Ethernet NIC | ||
364 | |||
365 | File: e100/d101m_ucode.bin | ||
366 | File: e100/d101s_ucode.bin | ||
367 | File: e100/d102e_ucode.bin | ||
368 | |||
369 | Licence: Unknown | ||
370 | |||
371 | Found in hex form in kernel source. | ||
372 | |||
373 | -------------------------------------------------------------------------- | ||
374 | |||
363 | Driver: acenic -- Alteon AceNIC Gigabit Ethernet card | 375 | Driver: acenic -- Alteon AceNIC Gigabit Ethernet card |
364 | 376 | ||
365 | File: acenic/tg1.bin | 377 | File: acenic/tg1.bin |
diff --git a/firmware/e100/d101m_ucode.bin.ihex b/firmware/e100/d101m_ucode.bin.ihex new file mode 100644 index 000000000000..12971ed458a6 --- /dev/null +++ b/firmware/e100/d101m_ucode.bin.ihex | |||
@@ -0,0 +1,38 @@ | |||
1 | :10000000150255003704FFFFFFFFFFFF8907A70612 | ||
2 | :10001000FFFFFFFFFFFF580501000C001213100047 | ||
3 | :1000200008000C00160238009C001000564020000A | ||
4 | :10003000CC802300560038009C0010000B4C24009C | ||
5 | :1000400000080000184812003804380000000000C2 | ||
6 | :1000500000001400550538000080300062061000D2 | ||
7 | :100060006105100008040E006148130002000C0036 | ||
8 | :10007000933010000080300024061000610510004D | ||
9 | :1000800008040E00610810007E000C00212C2200E4 | ||
10 | :1000900002000C00933010007A0C380000000800B9 | ||
11 | :1000A000903010007A0C38000000000000000000C2 | ||
12 | :1000B00000000000000000009C0010002D4C2400F7 | ||
13 | :1000C000040001000010040037043A00104004004E | ||
14 | :1000D0008A07380000000000990010007A6C2000A8 | ||
15 | :1000E0009C001000484C24002408130001000C0060 | ||
16 | :1000F00013121000750C260000100400040001000B | ||
17 | :100100002608130006000C00A806220026C91300CA | ||
18 | :1001100013131000A80638000000000000000000C3 | ||
19 | :1001200000000000000000000000000000000000CF | ||
20 | :10013000000000000000000000060800101B100076 | ||
21 | :10014000040005002608100010121000340C3800BE | ||
22 | :1001500000000000000000005B1521009900100065 | ||
23 | :10016000596520009C0010005945240036081300F2 | ||
24 | :1001700000000C00620C220001000C00131B100098 | ||
25 | :100180000E9C22000E0C21000E6C22000E6C210031 | ||
26 | :100190000EFC22000E5C21000E4C2100550538009B | ||
27 | :1001A0000400010000100400678C27000008040010 | ||
28 | :1001B0000081010037043A002608130001000C00FA | ||
29 | :1001C00059052200131310005905380000000000E3 | ||
30 | :1001D000000000000000000000000000000000001F | ||
31 | :1001E00000000000000000000000000031081300C3 | ||
32 | :1001F0000B0910001348120080FF0C00AB0626000C | ||
33 | :100200000010040004000100A806380000000000EF | ||
34 | :0B02100000000000000000004E417ED6 | ||
35 | :00000001FF | ||
36 | /********************************************************/ | ||
37 | /* Micro code for 8086:1229 Rev 8 */ | ||
38 | /********************************************************/ | ||
diff --git a/firmware/e100/d101s_ucode.bin.ihex b/firmware/e100/d101s_ucode.bin.ihex new file mode 100644 index 000000000000..102c7feb666e --- /dev/null +++ b/firmware/e100/d101s_ucode.bin.ihex | |||
@@ -0,0 +1,38 @@ | |||
1 | :10000000420255007E04FFFFFFFFFFFF1808FF06B6 | ||
2 | :10001000FFFFFFFFFFFFA60501000C0012131000F9 | ||
3 | :1000200008000C00430238009C00100056402000DD | ||
4 | :10003000D0802300560038009C0010008B4F240015 | ||
5 | :1000400000080000184812007F043800000000007B | ||
6 | :1000500000001400A30538000080300010061000D6 | ||
7 | :100060006105100008040E006148130002000C0036 | ||
8 | :10007000933010000080300024061000610510004D | ||
9 | :1000800008040E00610810007E000C00A12F220061 | ||
10 | :1000900002000C0093301000900F380000000800A0 | ||
11 | :1000A00090301000900F38000000000000000000A9 | ||
12 | :1000B00000000000000000009C001000AD4F240074 | ||
13 | :1000C00004000100001004007E043A001040040007 | ||
14 | :1000D000190838000000000099001000FD6F200092 | ||
15 | :1000E0009A001000FDAF20009C001000C84F2400B3 | ||
16 | :1000F0002408130001000C0013121000F70F260053 | ||
17 | :1001000000100400040001002608130006000C0083 | ||
18 | :100110000007220026C9130013131000000738003F | ||
19 | :1001200000000000000000000000000000000000CF | ||
20 | :10013000000000000000000000060800101B100076 | ||
21 | :10014000040005002608100010121000B60F380039 | ||
22 | :100150000000000000000000A91521009900100017 | ||
23 | :10016000A76520009A001000A7A520009C001000A1 | ||
24 | :10017000A74524003608130000000C00E40F2200FD | ||
25 | :1001800001000C00131B10008E9F22008E0F210017 | ||
26 | :100190008E6F22008E6F21008EFF22008E5F210065 | ||
27 | :1001A0008E4F2100A3053800040001000010040058 | ||
28 | :1001B000E98F270000080400008101007E043A0056 | ||
29 | :1001C0002608130001000C00A705220013131000DD | ||
30 | :1001D000A70538000000000000000000000000003B | ||
31 | :1001E000000000000000000000000000000000000F | ||
32 | :1001F00000000000310813000B0910001348120022 | ||
33 | :1002000080FF0C000307260000100400040001001A | ||
34 | :0B02100000073800000000004E438093 | ||
35 | :00000001FF | ||
36 | /********************************************************/ | ||
37 | /* Micro code for 8086:1229 Rev 9 */ | ||
38 | /********************************************************/ | ||
diff --git a/firmware/e100/d102e_ucode.bin.ihex b/firmware/e100/d102e_ucode.bin.ihex new file mode 100644 index 000000000000..9e806da854de --- /dev/null +++ b/firmware/e100/d102e_ucode.bin.ihex | |||
@@ -0,0 +1,38 @@ | |||
1 | :100000008F027D00F904420E850CED14E914FA14F8 | ||
2 | :10001000360EF70EFF1FFF1FB914E00000000000AE | ||
3 | :100020000000000000000000BD14E000000000001F | ||
4 | :100030000000000000000000D514E00000000000F7 | ||
5 | :1000400000000000000000000000000000000000B0 | ||
6 | :100050000000000000000000C114E00000000000EB | ||
7 | :100060000000000000000000000000000000000090 | ||
8 | :100070000000000000000000000000000000000080 | ||
9 | :100080000000000000000000000000000000000070 | ||
10 | :100090000000000000000000C814E00000000000A4 | ||
11 | :1000A000000000000000000000062000EE14E00048 | ||
12 | :1000B000000000000000000080FF3000460E9400A9 | ||
13 | :1000C0000082030000201000430EE000000000004A | ||
14 | :1000D000000000000000000006003000FB14E000FB | ||
15 | :1000E0000000000000000000000000000000000010 | ||
16 | :1000F0000000000000000000000000000000000000 | ||
17 | :1001000000000000000000000000000000000000EF | ||
18 | :100110000000000000000000416E90003C0E8000D6 | ||
19 | :10012000390EE00000000000FD6E9000FD0E900012 | ||
20 | :10013000F80EE000000000000000000000000000D9 | ||
21 | :1001400000000000000000000000000000000000AF | ||
22 | :10015000000000000000000000000000000000009F | ||
23 | :10016000000000000000000000000000000000008F | ||
24 | :10017000000000000000000000000000000000007F | ||
25 | :10018000000000000000000000000000000000006F | ||
26 | :10019000000000000000000000000000000000005F | ||
27 | :1001A000000000000000000000000000000000004F | ||
28 | :1001B000000000000000000000000000000000003F | ||
29 | :1001C000000000000000000000000000000000002F | ||
30 | :1001D000000000000000000000000000000000001F | ||
31 | :1001E000000000000000000000000000000000000F | ||
32 | :1001F00000000000000000000000000000000000FF | ||
33 | :1002000000000000000000000000000000000000EE | ||
34 | :0B02100000000000000000002A362E55 | ||
35 | :00000001FF | ||
36 | /********************************************************/ | ||
37 | /* Micro code for the 8086:1229 Rev F/10 */ | ||
38 | /********************************************************/ | ||