diff --git a/drivers/net/cs89x0.c b/drivers/net/cs89x0.c index 04fca31f1733a79ee1466a2fc11d2f9295de534e..221f92e45ec73f797379209afccbb3ace3a1c255 100644 --- a/drivers/net/cs89x0.c +++ b/drivers/net/cs89x0.c @@ -339,29 +339,29 @@ struct net_device * __init cs89x0_probe(int unit) #endif static int -readreg(struct net_device *dev, int portno) +readword(unsigned long base_addr, int portno) { - outw(portno, dev->base_addr + ADD_PORT); - return inw(dev->base_addr + DATA_PORT); + return inw(base_addr + portno); } static void -writereg(struct net_device *dev, int portno, int value) +writeword(unsigned long base_addr, int portno, int value) { - outw(portno, dev->base_addr + ADD_PORT); - outw(value, dev->base_addr + DATA_PORT); + outw(value, base_addr + portno); } static int -readword(unsigned long base_addr, int portno) +readreg(struct net_device *dev, int portno) { - return inw(base_addr + portno); + outw(portno, dev->base_addr + ADD_PORT); + return inw(dev->base_addr + DATA_PORT); } static void -writeword(unsigned long base_addr, int portno, int value) +writereg(struct net_device *dev, int portno, int value) { - outw(value, base_addr + portno); + outw(portno, dev->base_addr + ADD_PORT); + outw(value, dev->base_addr + DATA_PORT); } static int __init