Changeset 7afcb26 in rtems


Ignore:
Timestamp:
04/10/12 19:12:23 (12 years ago)
Author:
Daniel Hellstrom <daniel@…>
Branches:
4.11, 5, master
Children:
abe87b9, dc62a48c
Parents:
e230fb4
git-author:
Daniel Hellstrom <daniel@…> (04/10/12 19:12:23)
git-committer:
Gedare Bloom <gedare@…> (04/10/12 19:12:23)
Message:

PR2052: LEON3: fix open_eth interrupt initialization bug

Fixed a bug where the vector number is used to clean and unmask
the IRQ at the IRQ controller, the irq number must be used.

Signed-off-by: Daniel Hellstrom <daniel@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/sparc/leon3/leon_open_eth/leon_open_eth.c

    re230fb4 r7afcb26  
    4848      iobar = amba_ahb_get_membar(amba_conf.ahbslv, i, 0);
    4949      base_addr = amba_iobar_start(LEON3_IO_AREA, iobar);
    50       eth_irq = amba_irq(conf) + 0x10;
     50      eth_irq = amba_irq(conf);
    5151      device_found = 1;
    5252      break;
     
    6262    *(volatile int *) base_addr = 0;
    6363    leon_open_eth_configuration.base_address = base_addr;
    64     leon_open_eth_configuration.vector = eth_irq;
     64    leon_open_eth_configuration.vector = eth_irq + 0x10;
    6565    leon_open_eth_configuration.txd_count = TDA_COUNT;
    6666    leon_open_eth_configuration.rxd_count = RDA_COUNT;
     
    6868    if (LEON3_Timer_Regs->scaler_reload >= 49) leon_open_eth_configuration.en100MHz = 1;
    6969    if (rtems_open_eth_driver_attach( config, &leon_open_eth_configuration )) {
    70       LEON_Clear_interrupt(leon_open_eth_configuration.vector);
    71       LEON_Unmask_interrupt(leon_open_eth_configuration.vector);
     70      LEON_Clear_interrupt(eth_irq);
     71      LEON_Unmask_interrupt(eth_irq);
    7272    }
    7373  }
Note: See TracChangeset for help on using the changeset viewer.