Changeset e5424e9 in mainline for uspace/drv/nic/e1k/e1k.c


Ignore:
Timestamp:
2014-07-18T08:50:36Z (11 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
ebc9c2c
Parents:
869d936
Message:

Defer connecting IRC service until actually needed. This allows the driver to be loaded even in its absence.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/nic/e1k/e1k.c

    r869d936 re5424e9  
    17561756        e1000_enable_interrupts(e1000);
    17571757       
    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        }
    17591766       
    17601767        e1000_clear_rx_ring(e1000);
     
    23752382        printf("%s: HelenOS E1000 network adapter driver\n", NAME);
    23762383       
    2377         if (irc_init() != EOK) {
    2378                 printf("%s: Failed connecting IRC service\n", NAME);
    2379                 return 1;
    2380         }
    2381        
    23822384        if (nic_driver_init(NAME) != EOK)
    23832385                return 1;
Note: See TracChangeset for help on using the changeset viewer.