diff options
author | Alex Landau <landau.alex@gmail.com> | 2007-07-12 08:11:48 +0400 |
---|---|---|
committer | Bryan Wu <bryan.wu@analog.com> | 2007-07-12 08:11:48 +0400 |
commit | f40d24d909ad99c802a6813ff32b6feb20ab8c71 (patch) | |
tree | 5404a10d8c894f82334965a4ea5af603ac334b6e /drivers/net/dm9000.c | |
parent | 9be343c5bcd1cf285c2150f363bc9dd7aab8b7fb (diff) | |
download | linux-f40d24d909ad99c802a6813ff32b6feb20ab8c71.tar.xz |
Blackfin arch: Port the dm9000 driver to Blackfin by using the correct low-level io routines
Signed-off-by: Alex Landau <landau.alex@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
Diffstat (limited to 'drivers/net/dm9000.c')
-rw-r--r-- | drivers/net/dm9000.c | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/drivers/net/dm9000.c b/drivers/net/dm9000.c index 264fa0e2e075..c3de81bf090a 100644 --- a/drivers/net/dm9000.c +++ b/drivers/net/dm9000.c @@ -104,6 +104,18 @@ #define PRINTK(args...) printk(KERN_DEBUG args) #endif +#ifdef CONFIG_BLACKFIN +#define readsb insb +#define readsw insw +#define readsl insl +#define writesb outsb +#define writesw outsw +#define writesl outsl +#define DM9000_IRQ_FLAGS (IRQF_SHARED | IRQF_TRIGGER_HIGH) +#else +#define DM9000_IRQ_FLAGS IRQF_SHARED +#endif + /* * Transmit timeout, default 5 seconds. */ @@ -431,6 +443,9 @@ dm9000_probe(struct platform_device *pdev) db->io_addr = (void __iomem *)base; db->io_data = (void __iomem *)(base + 4); + /* ensure at least we have a default set of IO routines */ + dm9000_set_io(db, 2); + } else { db->addr_res = platform_get_resource(pdev, IORESOURCE_MEM, 0); db->data_res = platform_get_resource(pdev, IORESOURCE_MEM, 1); @@ -614,7 +629,7 @@ dm9000_open(struct net_device *dev) PRINTK2("entering dm9000_open\n"); - if (request_irq(dev->irq, &dm9000_interrupt, IRQF_SHARED, dev->name, dev)) + if (request_irq(dev->irq, &dm9000_interrupt, DM9000_IRQ_FLAGS, dev->name, dev)) return -EAGAIN; /* Initialize DM9000 board */ |