Changeset ec52752 in mainline


Ignore:
Timestamp:
2012-02-12T19:16:29Z (13 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
2507d1fc
Parents:
bd8c6537
Message:

Modify the E1000 driver to work with the new IRQ code constraints.

File:
1 edited

Legend:

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

    rbd8c6537 rec52752  
    229229static void e1000_send_frame(nic_t *, void *, size_t);
    230230
     231/** PIO ranges used in the IRQ code. */
     232irq_pio_range_t e1000_irq_pio_ranges[] = {
     233        {
     234                .base = 0,
     235                .size = PAGE_SIZE,      /* XXX */
     236        }
     237};
     238
    231239/** Commands to deal with interrupt
    232240 *
     
    257265/** Interrupt code definition */
    258266irq_code_t e1000_irq_code = {
     267        .rangecount = sizeof(e1000_irq_pio_ranges) /
     268            sizeof(irq_pio_range_t),
     269        .ranges = e1000_irq_pio_ranges,
    259270        .cmdcount = sizeof(e1000_irq_commands) / sizeof(irq_cmd_t),
    260271        .cmds = e1000_irq_commands
     
    12641275        fibril_mutex_lock(&irq_reg_mutex);
    12651276       
    1266         e1000_irq_code.cmds[0].addr = e1000->reg_base_virt + E1000_ICR;
    1267         e1000_irq_code.cmds[2].addr = e1000->reg_base_virt + E1000_IMC;
     1277        e1000_irq_code.ranges[0].base = (uintptr_t) e1000->reg_base_phys;
     1278        e1000_irq_code.cmds[0].addr = e1000->reg_base_phys + E1000_ICR;
     1279        e1000_irq_code.cmds[2].addr = e1000->reg_base_phys + E1000_IMC;
    12681280       
    12691281        int rc = register_interrupt_handler(nic_get_ddf_dev(nic),
Note: See TracChangeset for help on using the changeset viewer.