Changeset e5424e9 in mainline for uspace/drv/nic
- Timestamp:
- 2014-07-18T08:50:36Z (11 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- ebc9c2c
- Parents:
- 869d936
- Location:
- uspace/drv/nic
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/nic/e1k/e1k.c
r869d936 re5424e9 1756 1756 e1000_enable_interrupts(e1000); 1757 1757 1758 irc_enable_interrupt(e1000->irq); 1758 int rc = irc_enable_interrupt(e1000->irq); 1759 if (rc != EOK) { 1760 e1000_disable_interrupts(e1000); 1761 fibril_mutex_unlock(&e1000->ctrl_lock); 1762 fibril_mutex_unlock(&e1000->tx_lock); 1763 fibril_mutex_unlock(&e1000->rx_lock); 1764 return rc; 1765 } 1759 1766 1760 1767 e1000_clear_rx_ring(e1000); … … 2375 2382 printf("%s: HelenOS E1000 network adapter driver\n", NAME); 2376 2383 2377 if (irc_init() != EOK) {2378 printf("%s: Failed connecting IRC service\n", NAME);2379 return 1;2380 }2381 2382 2384 if (nic_driver_init(NAME) != EOK) 2383 2385 return 1; -
uspace/drv/nic/ne2k/ne2k.c
r869d936 re5424e9 257 257 if (!ne2k->up) { 258 258 int rc = ne2k_up(ne2k); 259 if (rc != EOK) 260 return rc; 261 262 rc = irc_enable_interrupt(ne2k->irq); 259 263 if (rc != EOK) { 264 ne2k_down(ne2k); 260 265 return rc; 261 266 } 262 263 irc_enable_interrupt(ne2k->irq);264 267 } 265 268 return EOK; … … 270 273 ne2k_t *ne2k = (ne2k_t *) nic_get_specific(nic_data); 271 274 272 irc_disable_interrupt(ne2k->irq);275 (void) irc_disable_interrupt(ne2k->irq); 273 276 ne2k->receive_configuration = RCR_AB | RCR_AM; 274 277 ne2k_down(ne2k); … … 440 443 printf("%s: HelenOS NE 2000 network adapter driver\n", NAME); 441 444 442 if (irc_init() != EOK) {443 printf("%s: Failed connecting IRC service\n", NAME);444 return 1;445 }446 447 445 nic_driver_init(NAME); 448 446 nic_driver_implement(&ne2k_driver_ops, &ne2k_dev_ops, &ne2k_nic_iface); -
uspace/drv/nic/rtl8139/driver.c
r869d936 re5424e9 956 956 rtl8139->int_mask = RTL_DEFAULT_INTERRUPTS; 957 957 rtl8139_hw_int_enable(rtl8139); 958 irc_enable_interrupt(rtl8139->irq); 958 959 int rc = irc_enable_interrupt(rtl8139->irq); 960 if (rc != EOK) { 961 rtl8139_on_stopped(nic_data); 962 return rc; 963 } 959 964 960 965 ddf_msg(LVL_DEBUG, "Device activated, interrupt %d registered", rtl8139->irq); … … 2170 2175 printf("%s: HelenOS RTL8139 network adapter driver\n", NAME); 2171 2176 2172 if (irc_init() != EOK) {2173 printf("%s: Failed connecting IRC service\n", NAME);2174 return 1;2175 }2176 2177 2177 int rc = nic_driver_init(NAME); 2178 2178 if (rc != EOK)
Note:
See TracChangeset
for help on using the changeset viewer.