mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-06 22:42:10 +00:00
[PATCH] cs89x0: make {read,write}reg use {read,write}word
Make readreg/writereg use readword/writeword. Signed-off-by: Lennert Buytenhek <buytenh@wantstofly.org> Cc: dmitry pervushin <dpervushin@ru.mvista.com> Cc: <dsaxena@plexity.net> Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
0d5affcfe2
commit
3eaa5e7dcc
1 changed files with 6 additions and 6 deletions
|
@ -351,17 +351,17 @@ writeword(unsigned long base_addr, int portno, int value)
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
readreg(struct net_device *dev, int portno)
|
readreg(struct net_device *dev, int regno)
|
||||||
{
|
{
|
||||||
outw(portno, dev->base_addr + ADD_PORT);
|
writeword(dev->base_addr, ADD_PORT, regno);
|
||||||
return inw(dev->base_addr + DATA_PORT);
|
return readword(dev->base_addr, DATA_PORT);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
writereg(struct net_device *dev, int portno, int value)
|
writereg(struct net_device *dev, int regno, int value)
|
||||||
{
|
{
|
||||||
outw(portno, dev->base_addr + ADD_PORT);
|
writeword(dev->base_addr, ADD_PORT, regno);
|
||||||
outw(value, dev->base_addr + DATA_PORT);
|
writeword(dev->base_addr, DATA_PORT, value);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int __init
|
static int __init
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue