Changes in uspace/drv/nic/rtl8139/driver.c [5cd3d67:e86b8f0] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/nic/rtl8139/driver.c
r5cd3d67 re86b8f0 55 55 /** Global mutex for work with shared irq structure */ 56 56 FIBRIL_MUTEX_INITIALIZE(irq_reg_lock); 57 58 57 /** Lock interrupt structure mutex */ 59 #define RTL8139_IRQ_STRUCT_LOCK() \ 60 fibril_mutex_lock(&irq_reg_lock) 61 58 #define RTL8139_IRQ_STRUCT_LOCK() fibril_mutex_lock(&irq_reg_lock) 62 59 /** Unlock interrupt structure mutex */ 63 #define RTL8139_IRQ_STRUCT_UNLOCK() \ 64 fibril_mutex_unlock(&irq_reg_lock) 60 #define RTL8139_IRQ_STRUCT_UNLOCK() fibril_mutex_unlock(&irq_reg_lock) 65 61 66 62 /** PCI clock frequency in kHz */ 67 #define RTL8139_PCI_FREQ_KHZ 68 69 #define RTL8139_AUTONEG_CAPS (ETH_AUTONEG_10BASE_T_HALF |\70 ETH_AUTONEG_10BASE_T_FULL | ETH_AUTONEG_100BASE_TX_HALF |\71 63 #define RTL8139_PCI_FREQ_KHZ 33000 64 65 #define RTL8139_AUTONEG_CAPS (ETH_AUTONEG_10BASE_T_HALF \ 66 | ETH_AUTONEG_10BASE_T_FULL | ETH_AUTONEG_100BASE_TX_HALF \ 67 | ETH_AUTONEG_100BASE_TX_FULL | ETH_AUTONEG_PAUSE_SYMETRIC) 72 68 73 69 /** Lock transmitter and receiver data 74 * 75 * This function shall be called whenever 76 * both transmitter and receiver locking 77 * to force safe lock ordering (deadlock prevention) 78 * 79 * @param rtl8139 RTL8139 private data 80 * 70 * This function shall be called whenever both transmitter and receiver locking 71 * to force safe lock ordering (deadlock prevention) 72 * 73 * @param rtl8139 RTL8139 private data 81 74 */ 82 75 inline static void rtl8139_lock_all(rtl8139_t *rtl8139) … … 89 82 /** Unlock transmitter and receiver data 90 83 * 91 * @param rtl8139 RTL8139 private data 92 * 84 * @param rtl8139 RTL8139 private data 93 85 */ 94 86 inline static void rtl8139_unlock_all(rtl8139_t *rtl8139) … … 465 457 pio_write_32(tsd, tsd_value); 466 458 return; 467 459 468 460 err_busy_no_inc: 469 461 err_size: … … 521 513 * 522 514 * @return The frame list node (not connected) 523 *524 515 */ 525 516 static nic_frame_t *rtl8139_read_frame(nic_t *nic_data, … … 1224 1215 ddf_msg(LVL_DEBUG, "The device is initialized"); 1225 1216 return ret; 1226 1217 1227 1218 failed: 1228 1219 ddf_msg(LVL_ERROR, "The device initialization failed"); … … 1351 1342 1352 1343 return EOK; 1353 1344 1354 1345 err_fun_bind: 1355 1346 ddf_fun_unbind(fun);
Note:
See TracChangeset
for help on using the changeset viewer.