Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
7457affc
Commit
7457affc
authored
Oct 30, 2004
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Plain Diff
Merge
bk://bk.arm.linux.org.uk/linux-2.6-rmk
into ppc970.osdl.org:/home/torvalds/v2.6/linux
parents
06170b11
35d8faae
Changes
29
Hide whitespace changes
Inline
Side-by-side
Showing
29 changed files
with
250 additions
and
161 deletions
+250
-161
arch/arm/common/amba.c
arch/arm/common/amba.c
+1
-1
arch/arm/mach-ebsa110/io.c
arch/arm/mach-ebsa110/io.c
+30
-28
arch/arm/mach-s3c2410/dma.c
arch/arm/mach-s3c2410/dma.c
+3
-3
arch/arm/mm/ioremap.c
arch/arm/mm/ioremap.c
+3
-3
drivers/mmc/mmci.c
drivers/mmc/mmci.c
+6
-6
drivers/mmc/mmci.h
drivers/mmc/mmci.h
+1
-1
drivers/net/arm/etherh.c
drivers/net/arm/etherh.c
+125
-40
drivers/serial/amba-pl011.c
drivers/serial/amba-pl011.c
+1
-1
include/asm-arm/arch-clps711x/io.h
include/asm-arm/arch-clps711x/io.h
+3
-3
include/asm-arm/arch-ebsa110/io.h
include/asm-arm/arch-ebsa110/io.h
+7
-7
include/asm-arm/arch-ebsa285/io.h
include/asm-arm/arch-ebsa285/io.h
+11
-9
include/asm-arm/arch-epxa10db/io.h
include/asm-arm/arch-epxa10db/io.h
+1
-1
include/asm-arm/arch-h720x/io.h
include/asm-arm/arch-h720x/io.h
+2
-2
include/asm-arm/arch-imx/io.h
include/asm-arm/arch-imx/io.h
+2
-2
include/asm-arm/arch-integrator/io.h
include/asm-arm/arch-integrator/io.h
+3
-3
include/asm-arm/arch-iop3xx/io.h
include/asm-arm/arch-iop3xx/io.h
+3
-3
include/asm-arm/arch-ixp2000/io.h
include/asm-arm/arch-ixp2000/io.h
+1
-1
include/asm-arm/arch-ixp4xx/io.h
include/asm-arm/arch-ixp4xx/io.h
+5
-5
include/asm-arm/arch-l7200/io.h
include/asm-arm/arch-l7200/io.h
+3
-3
include/asm-arm/arch-lh7a40x/io.h
include/asm-arm/arch-lh7a40x/io.h
+3
-3
include/asm-arm/arch-omap/io.h
include/asm-arm/arch-omap/io.h
+3
-3
include/asm-arm/arch-pxa/io.h
include/asm-arm/arch-pxa/io.h
+3
-3
include/asm-arm/arch-rpc/io.h
include/asm-arm/arch-rpc/io.h
+1
-1
include/asm-arm/arch-s3c2410/dma.h
include/asm-arm/arch-s3c2410/dma.h
+1
-1
include/asm-arm/arch-sa1100/io.h
include/asm-arm/arch-sa1100/io.h
+3
-3
include/asm-arm/arch-shark/io.h
include/asm-arm/arch-shark/io.h
+1
-1
include/asm-arm/arch-versatile/io.h
include/asm-arm/arch-versatile/io.h
+3
-3
include/asm-arm/hardware/amba_clcd.h
include/asm-arm/hardware/amba_clcd.h
+1
-1
include/asm-arm/io.h
include/asm-arm/io.h
+20
-20
No files found.
arch/arm/common/amba.c
View file @
7457affc
...
...
@@ -194,7 +194,7 @@ amba_attr(resource, "\t%08lx\t%08lx\t%08lx\n",
int
amba_device_register
(
struct
amba_device
*
dev
,
struct
resource
*
parent
)
{
u32
pid
,
cid
;
void
*
tmp
;
void
__iomem
*
tmp
;
int
i
,
ret
;
dev
->
dev
.
release
=
amba_device_release
;
...
...
arch/arm/mach-ebsa110/io.c
View file @
7457affc
...
...
@@ -27,9 +27,9 @@
#include <asm/io.h>
#include <asm/page.h>
static
u32
__isamem_convert_addr
(
void
*
addr
)
static
void
__iomem
*
__isamem_convert_addr
(
void
__iomem
*
addr
)
{
u32
ret
,
a
=
(
u32
)
addr
;
u32
ret
,
a
=
(
u32
__force
)
addr
;
/*
* The PCMCIA controller is wired up as follows:
...
...
@@ -53,41 +53,43 @@ static u32 __isamem_convert_addr(void *addr)
ret
+=
0xe8000000
;
if
((
a
&
0x20000
)
==
(
a
&
0x40000
)
>>
1
)
return
ret
;
return
(
void
__iomem
*
)
ret
;
BUG
();
return
0
;
return
NULL
;
}
/*
* read[bwl] and write[bwl]
*/
u8
__readb
(
void
*
addr
)
u8
__readb
(
void
__iomem
*
addr
)
{
u32
ret
,
a
=
__isamem_convert_addr
(
addr
);
void
__iomem
*
a
=
__isamem_convert_addr
(
addr
);
u32
ret
;
if
((
int
)
addr
&
1
)
if
((
unsigned
long
)
addr
&
1
)
ret
=
__raw_readl
(
a
);
else
ret
=
__raw_readb
(
a
);
return
ret
;
}
u16
__readw
(
void
*
addr
)
u16
__readw
(
void
__iomem
*
addr
)
{
u32
a
=
__isamem_convert_addr
(
addr
);
void
__iomem
*
a
=
__isamem_convert_addr
(
addr
);
if
((
int
)
addr
&
1
)
if
((
unsigned
long
)
addr
&
1
)
BUG
();
return
__raw_readw
(
a
);
}
u32
__readl
(
void
*
addr
)
u32
__readl
(
void
__iomem
*
addr
)
{
u32
ret
,
a
=
__isamem_convert_addr
(
addr
);
void
__iomem
*
a
=
__isamem_convert_addr
(
addr
);
u32
ret
;
if
((
int
)
addr
&
3
)
if
((
unsigned
long
)
addr
&
3
)
BUG
();
ret
=
__raw_readw
(
a
);
...
...
@@ -99,31 +101,31 @@ EXPORT_SYMBOL(__readb);
EXPORT_SYMBOL
(
__readw
);
EXPORT_SYMBOL
(
__readl
);
void
__writeb
(
u8
val
,
void
*
addr
)
void
__writeb
(
u8
val
,
void
__iomem
*
addr
)
{
u32
a
=
__isamem_convert_addr
(
addr
);
void
__iomem
*
a
=
__isamem_convert_addr
(
addr
);
if
((
int
)
addr
&
1
)
if
((
unsigned
long
)
addr
&
1
)
__raw_writel
(
val
,
a
);
else
__raw_writeb
(
val
,
a
);
}
void
__writew
(
u16
val
,
void
*
addr
)
void
__writew
(
u16
val
,
void
__iomem
*
addr
)
{
u32
a
=
__isamem_convert_addr
(
addr
);
void
__iomem
*
a
=
__isamem_convert_addr
(
addr
);
if
((
int
)
addr
&
1
)
if
((
unsigned
long
)
addr
&
1
)
BUG
();
__raw_writew
(
val
,
a
);
}
void
__writel
(
u32
val
,
void
*
addr
)
void
__writel
(
u32
val
,
void
__iomem
*
addr
)
{
u32
a
=
__isamem_convert_addr
(
addr
);
void
__iomem
*
a
=
__isamem_convert_addr
(
addr
);
if
((
int
)
addr
&
3
)
if
((
unsigned
long
)
addr
&
3
)
BUG
();
__raw_writew
(
val
,
a
);
...
...
@@ -153,7 +155,7 @@ u8 __inb8(unsigned int port)
if
(
SUPERIO_PORT
(
port
))
ret
=
__raw_readb
(
ISAIO_BASE
+
(
port
<<
2
));
else
{
u32
a
=
ISAIO_BASE
+
((
port
&
~
1
)
<<
1
);
void
__iomem
*
a
=
ISAIO_BASE
+
((
port
&
~
1
)
<<
1
);
/*
* Shame nothing else does
...
...
@@ -180,7 +182,7 @@ u8 __inb16(unsigned int port)
if
(
SUPERIO_PORT
(
port
))
ret
=
__raw_readb
(
ISAIO_BASE
+
(
port
<<
2
));
else
{
u32
a
=
ISAIO_BASE
+
((
port
&
~
1
)
<<
1
);
void
__iomem
*
a
=
ISAIO_BASE
+
((
port
&
~
1
)
<<
1
);
/*
* Shame nothing else does
...
...
@@ -200,7 +202,7 @@ u16 __inw(unsigned int port)
if
(
SUPERIO_PORT
(
port
))
ret
=
__raw_readw
(
ISAIO_BASE
+
(
port
<<
2
));
else
{
u32
a
=
ISAIO_BASE
+
((
port
&
~
1
)
<<
1
);
void
__iomem
*
a
=
ISAIO_BASE
+
((
port
&
~
1
)
<<
1
);
/*
* Shame nothing else does
...
...
@@ -218,7 +220,7 @@ u16 __inw(unsigned int port)
*/
u32
__inl
(
unsigned
int
port
)
{
u32
a
;
void
__iomem
*
a
;
if
(
SUPERIO_PORT
(
port
)
||
port
&
3
)
BUG
();
...
...
@@ -241,7 +243,7 @@ void __outb8(u8 val, unsigned int port)
if
(
SUPERIO_PORT
(
port
))
__raw_writeb
(
val
,
ISAIO_BASE
+
(
port
<<
2
));
else
{
u32
a
=
ISAIO_BASE
+
((
port
&
~
1
)
<<
1
);
void
__iomem
*
a
=
ISAIO_BASE
+
((
port
&
~
1
)
<<
1
);
/*
* Shame nothing else does
...
...
@@ -261,7 +263,7 @@ void __outb16(u8 val, unsigned int port)
if
(
SUPERIO_PORT
(
port
))
__raw_writeb
(
val
,
ISAIO_BASE
+
(
port
<<
2
));
else
{
u32
a
=
ISAIO_BASE
+
((
port
&
~
1
)
<<
1
);
void
__iomem
*
a
=
ISAIO_BASE
+
((
port
&
~
1
)
<<
1
);
/*
* Shame nothing else does
...
...
arch/arm/mach-s3c2410/dma.c
View file @
7457affc
...
...
@@ -52,7 +52,7 @@
#include <asm/arch/map.h>
/* io map for dma */
static
void
*
dma_base
;
static
void
__iomem
*
dma_base
;
/* dma channel state information */
s3c2410_dma_chan_t
s3c2410_chans
[
S3C2410_DMA_CHANNELS
];
...
...
@@ -1065,7 +1065,7 @@ static int __init s3c2410_init_dma(void)
/* dma channel irqs are in order.. */
cp
->
number
=
channel
;
cp
->
irq
=
channel
+
IRQ_DMA0
;
cp
->
regs
=
(
unsigned
long
)
dma_base
+
(
channel
*
0x40
);
cp
->
regs
=
dma_base
+
(
channel
*
0x40
);
/* point current stats somewhere */
cp
->
stats
=
&
cp
->
stats_store
;
...
...
@@ -1075,7 +1075,7 @@ static int __init s3c2410_init_dma(void)
cp
->
load_timeout
=
1
<<
18
;
printk
(
"DMA channel %d at %
08lx
, irq %d
\n
"
,
printk
(
"DMA channel %d at %
p
, irq %d
\n
"
,
cp
->
number
,
cp
->
regs
,
cp
->
irq
);
}
...
...
arch/arm/mm/ioremap.c
View file @
7457affc
...
...
@@ -130,7 +130,7 @@ remap_area_pages(unsigned long start, unsigned long phys_addr,
* 'flags' are the extra L_PTE_ flags that you want to specify for this
* mapping. See include/asm-arm/proc-armv/pgtable.h for more information.
*/
void
*
void
__iomem
*
__ioremap
(
unsigned
long
phys_addr
,
size_t
size
,
unsigned
long
flags
,
unsigned
long
align
)
{
...
...
@@ -161,11 +161,11 @@ __ioremap(unsigned long phys_addr, size_t size, unsigned long flags,
vfree
(
addr
);
return
NULL
;
}
return
(
void
*
)
(
offset
+
(
char
*
)
addr
);
return
(
void
__iomem
*
)
(
offset
+
(
char
*
)
addr
);
}
EXPORT_SYMBOL
(
__ioremap
);
void
__iounmap
(
void
*
addr
)
void
__iounmap
(
void
__iomem
*
addr
)
{
vfree
((
void
*
)
(
PAGE_MASK
&
(
unsigned
long
)
addr
));
}
...
...
drivers/mmc/mmci.c
View file @
7457affc
...
...
@@ -69,7 +69,7 @@ static void mmci_stop_data(struct mmci_host *host)
static
void
mmci_start_data
(
struct
mmci_host
*
host
,
struct
mmc_data
*
data
)
{
unsigned
int
datactrl
,
timeout
,
irqmask
;
void
*
base
;
void
__iomem
*
base
;
DBG
(
host
,
"blksz %04x blks %04x flags %08x
\n
"
,
1
<<
data
->
blksz_bits
,
data
->
blocks
,
data
->
flags
);
...
...
@@ -108,7 +108,7 @@ static void mmci_start_data(struct mmci_host *host, struct mmc_data *data)
static
void
mmci_start_command
(
struct
mmci_host
*
host
,
struct
mmc_command
*
cmd
,
u32
c
)
{
void
*
base
=
host
->
base
;
void
__iomem
*
base
=
host
->
base
;
DBG
(
host
,
"op %02x arg %08x flags %08x
\n
"
,
cmd
->
opcode
,
cmd
->
arg
,
cmd
->
flags
);
...
...
@@ -169,7 +169,7 @@ static void
mmci_cmd_irq
(
struct
mmci_host
*
host
,
struct
mmc_command
*
cmd
,
unsigned
int
status
)
{
void
*
base
=
host
->
base
;
void
__iomem
*
base
=
host
->
base
;
host
->
cmd
=
NULL
;
...
...
@@ -193,7 +193,7 @@ mmci_cmd_irq(struct mmci_host *host, struct mmc_command *cmd,
static
int
mmci_pio_read
(
struct
mmci_host
*
host
,
char
*
buffer
,
unsigned
int
remain
)
{
void
*
base
=
host
->
base
;
void
__iomem
*
base
=
host
->
base
;
char
*
ptr
=
buffer
;
u32
status
;
...
...
@@ -222,7 +222,7 @@ static int mmci_pio_read(struct mmci_host *host, char *buffer, unsigned int rema
static
int
mmci_pio_write
(
struct
mmci_host
*
host
,
char
*
buffer
,
unsigned
int
remain
,
u32
status
)
{
void
*
base
=
host
->
base
;
void
__iomem
*
base
=
host
->
base
;
char
*
ptr
=
buffer
;
do
{
...
...
@@ -251,7 +251,7 @@ static int mmci_pio_write(struct mmci_host *host, char *buffer, unsigned int rem
static
irqreturn_t
mmci_pio_irq
(
int
irq
,
void
*
dev_id
,
struct
pt_regs
*
regs
)
{
struct
mmci_host
*
host
=
dev_id
;
void
*
base
=
host
->
base
;
void
__iomem
*
base
=
host
->
base
;
u32
status
;
status
=
readl
(
base
+
MMCISTATUS
);
...
...
drivers/mmc/mmci.h
View file @
7457affc
...
...
@@ -120,7 +120,7 @@
struct
clk
;
struct
mmci_host
{
void
*
base
;
void
__iomem
*
base
;
struct
mmc_request
*
mrq
;
struct
mmc_command
*
cmd
;
struct
mmc_data
*
data
;
...
...
drivers/net/arm/etherh.c
View file @
7457affc
...
...
@@ -40,6 +40,7 @@
#include <linux/errno.h>
#include <linux/netdevice.h>
#include <linux/etherdevice.h>
#include <linux/ethtool.h>
#include <linux/skbuff.h>
#include <linux/delay.h>
#include <linux/device.h>
...
...
@@ -56,14 +57,19 @@
#define NET_DEBUG 0
#define DEBUG_INIT 2
#define DRV_NAME "etherh"
#define DRV_VERSION "1.11"
static
unsigned
int
net_debug
=
NET_DEBUG
;
struct
etherh_priv
{
void
*
ioc_fast
;
void
*
memc
;
void
__iomem
*
ioc_fast
;
void
__iomem
*
memc
;
void
__iomem
*
dma_base
;
unsigned
int
id
;
void
*
ctrl_port
;
void
__iomem
*
ctrl_port
;
unsigned
char
ctrl
;
u32
supported
;
};
struct
etherh_data
{
...
...
@@ -72,11 +78,7 @@ struct etherh_data {
unsigned
long
ctrlport_offset
;
int
ctrl_ioc
;
const
char
name
[
16
];
/*
* netdev flags and port
*/
unsigned
short
flags
;
unsigned
char
if_port
;
u32
supported
;
unsigned
char
tx_start_page
;
unsigned
char
stop_page
;
};
...
...
@@ -86,7 +88,7 @@ MODULE_DESCRIPTION("EtherH/EtherM driver");
MODULE_LICENSE
(
"GPL"
);
static
char
version
[]
__initdata
=
"EtherH/EtherM Driver (c) 2002
Russell King v1.09
\n
"
;
"EtherH/EtherM Driver (c) 2002
-2004 Russell King "
DRV_VERSION
"
\n
"
;
#define ETHERH500_DATAPORT 0x800
/* MEMC */
#define ETHERH500_NS8390 0x000
/* MEMC */
...
...
@@ -166,7 +168,8 @@ static void
etherh_setif
(
struct
net_device
*
dev
)
{
struct
ei_device
*
ei_local
=
netdev_priv
(
dev
);
unsigned
long
addr
,
flags
;
unsigned
long
flags
;
void
__iomem
*
addr
;
local_irq_save
(
flags
);
...
...
@@ -174,7 +177,7 @@ etherh_setif(struct net_device *dev)
switch
(
etherh_priv
(
dev
)
->
id
)
{
case
PROD_I3_ETHERLAN600
:
case
PROD_I3_ETHERLAN600A
:
addr
=
dev
->
base_addr
+
EN0_RCNTHI
;
addr
=
(
void
*
)
dev
->
base_addr
+
EN0_RCNTHI
;
switch
(
dev
->
if_port
)
{
case
IF_PORT_10BASE2
:
...
...
@@ -209,17 +212,19 @@ static int
etherh_getifstat
(
struct
net_device
*
dev
)
{
struct
ei_device
*
ei_local
=
netdev_priv
(
dev
);
void
__iomem
*
addr
;
int
stat
=
0
;
switch
(
etherh_priv
(
dev
)
->
id
)
{
case
PROD_I3_ETHERLAN600
:
case
PROD_I3_ETHERLAN600A
:
addr
=
(
void
*
)
dev
->
base_addr
+
EN0_RCNTHI
;
switch
(
dev
->
if_port
)
{
case
IF_PORT_10BASE2
:
stat
=
1
;
break
;
case
IF_PORT_10BASET
:
stat
=
readb
(
dev
->
base_addr
+
EN0_RCNTHI
)
&
4
;
stat
=
readb
(
addr
)
&
4
;
break
;
}
break
;
...
...
@@ -276,8 +281,9 @@ static void
etherh_reset
(
struct
net_device
*
dev
)
{
struct
ei_device
*
ei_local
=
netdev_priv
(
dev
);
void
__iomem
*
addr
=
(
void
*
)
dev
->
base_addr
;
writeb
(
E8390_NODMA
+
E8390_PAGE0
+
E8390_STOP
,
dev
->
base_
addr
);
writeb
(
E8390_NODMA
+
E8390_PAGE0
+
E8390_STOP
,
addr
);
/*
* See if we need to change the interface type.
...
...
@@ -303,8 +309,8 @@ static void
etherh_block_output
(
struct
net_device
*
dev
,
int
count
,
const
unsigned
char
*
buf
,
int
start_page
)
{
struct
ei_device
*
ei_local
=
netdev_priv
(
dev
);
unsigned
int
addr
,
dma_addr
;
unsigned
long
dma_start
;
void
__iomem
*
dma_base
,
*
addr
;
if
(
ei_local
->
dmaing
)
{
printk
(
KERN_ERR
"%s: DMAing conflict in etherh_block_input: "
...
...
@@ -321,8 +327,8 @@ etherh_block_output (struct net_device *dev, int count, const unsigned char *buf
ei_local
->
dmaing
=
1
;
addr
=
dev
->
base_addr
;
dma_
addr
=
dev
->
mem_start
;
addr
=
(
void
*
)
dev
->
base_addr
;
dma_
base
=
etherh_priv
(
dev
)
->
dma_base
;
count
=
(
count
+
1
)
&
~
1
;
writeb
(
E8390_NODMA
|
E8390_PAGE0
|
E8390_START
,
addr
+
E8390_CMD
);
...
...
@@ -343,9 +349,9 @@ etherh_block_output (struct net_device *dev, int count, const unsigned char *buf
writeb
(
E8390_RWRITE
|
E8390_START
,
addr
+
E8390_CMD
);
if
(
ei_local
->
word16
)
writesw
(
dma_
addr
,
buf
,
count
>>
1
);
writesw
(
dma_
base
,
buf
,
count
>>
1
);
else
writesb
(
dma_
addr
,
buf
,
count
);
writesb
(
dma_
base
,
buf
,
count
);
dma_start
=
jiffies
;
...
...
@@ -369,8 +375,8 @@ static void
etherh_block_input
(
struct
net_device
*
dev
,
int
count
,
struct
sk_buff
*
skb
,
int
ring_offset
)
{
struct
ei_device
*
ei_local
=
netdev_priv
(
dev
);
unsigned
int
addr
,
dma_addr
;
unsigned
char
*
buf
;
void
__iomem
*
dma_base
,
*
addr
;
if
(
ei_local
->
dmaing
)
{
printk
(
KERN_ERR
"%s: DMAing conflict in etherh_block_input: "
...
...
@@ -381,8 +387,8 @@ etherh_block_input (struct net_device *dev, int count, struct sk_buff *skb, int
ei_local
->
dmaing
=
1
;
addr
=
dev
->
base_addr
;
dma_
addr
=
dev
->
mem_start
;
addr
=
(
void
*
)
dev
->
base_addr
;
dma_
base
=
etherh_priv
(
dev
)
->
dma_base
;
buf
=
skb
->
data
;
writeb
(
E8390_NODMA
|
E8390_PAGE0
|
E8390_START
,
addr
+
E8390_CMD
);
...
...
@@ -393,11 +399,11 @@ etherh_block_input (struct net_device *dev, int count, struct sk_buff *skb, int
writeb
(
E8390_RREAD
|
E8390_START
,
addr
+
E8390_CMD
);
if
(
ei_local
->
word16
)
{
readsw
(
dma_
addr
,
buf
,
count
>>
1
);
readsw
(
dma_
base
,
buf
,
count
>>
1
);
if
(
count
&
1
)
buf
[
count
-
1
]
=
readb
(
dma_
addr
);
buf
[
count
-
1
]
=
readb
(
dma_
base
);
}
else
readsb
(
dma_
addr
,
buf
,
count
);
readsb
(
dma_
base
,
buf
,
count
);
writeb
(
ENISR_RDC
,
addr
+
EN0_ISR
);
ei_local
->
dmaing
=
0
;
...
...
@@ -410,7 +416,7 @@ static void
etherh_get_header
(
struct
net_device
*
dev
,
struct
e8390_pkt_hdr
*
hdr
,
int
ring_page
)
{
struct
ei_device
*
ei_local
=
netdev_priv
(
dev
);
unsigned
int
addr
,
dma_
addr
;
void
__iomem
*
dma_base
,
*
addr
;
if
(
ei_local
->
dmaing
)
{
printk
(
KERN_ERR
"%s: DMAing conflict in etherh_get_header: "
...
...
@@ -421,8 +427,8 @@ etherh_get_header (struct net_device *dev, struct e8390_pkt_hdr *hdr, int ring_p
ei_local
->
dmaing
=
1
;
addr
=
dev
->
base_addr
;
dma_
addr
=
dev
->
mem_start
;
addr
=
(
void
*
)
dev
->
base_addr
;
dma_
base
=
etherh_priv
(
dev
)
->
dma_base
;
writeb
(
E8390_NODMA
|
E8390_PAGE0
|
E8390_START
,
addr
+
E8390_CMD
);
writeb
(
sizeof
(
*
hdr
),
addr
+
EN0_RCNTLO
);
...
...
@@ -432,9 +438,9 @@ etherh_get_header (struct net_device *dev, struct e8390_pkt_hdr *hdr, int ring_p
writeb
(
E8390_RREAD
|
E8390_START
,
addr
+
E8390_CMD
);
if
(
ei_local
->
word16
)
readsw
(
dma_
addr
,
hdr
,
sizeof
(
*
hdr
)
>>
1
);
readsw
(
dma_
base
,
hdr
,
sizeof
(
*
hdr
)
>>
1
);
else
readsb
(
dma_
addr
,
hdr
,
sizeof
(
*
hdr
));
readsb
(
dma_
base
,
hdr
,
sizeof
(
*
hdr
));
writeb
(
ENISR_RDC
,
addr
+
EN0_ISR
);
ei_local
->
dmaing
=
0
;
...
...
@@ -522,16 +528,30 @@ static int __init etherh_addr(char *addr, struct expansion_card *ec)
struct
in_chunk_dir
cd
;
char
*
s
;
if
(
ecard_readchunk
(
&
cd
,
ec
,
0xf5
,
0
)
&&
(
s
=
strchr
(
cd
.
d
.
string
,
'('
)))
{
if
(
!
ecard_readchunk
(
&
cd
,
ec
,
0xf5
,
0
))
{
printk
(
KERN_ERR
"%s: unable to read podule description string
\n
"
,
ec
->
dev
.
bus_id
);
goto
no_addr
;
}
s
=
strchr
(
cd
.
d
.
string
,
'('
);
if
(
s
)
{
int
i
;
for
(
i
=
0
;
i
<
6
;
i
++
)
{
addr
[
i
]
=
simple_strtoul
(
s
+
1
,
&
s
,
0x10
);
if
(
*
s
!=
(
i
==
5
?
')'
:
':'
))
break
;
}
if
(
i
==
6
)
return
0
;
}
printk
(
KERN_ERR
"%s: unable to parse MAC address: %s
\n
"
,
ec
->
dev
.
bus_id
,
cd
.
d
.
string
);
no_addr:
return
-
ENODEV
;
}
...
...
@@ -556,6 +576,62 @@ static int __init etherm_addr(char *addr)
return
0
;
}
static
void
etherh_get_drvinfo
(
struct
net_device
*
dev
,
struct
ethtool_drvinfo
*
info
)
{
strlcpy
(
info
->
driver
,
DRV_NAME
,
sizeof
(
info
->
driver
));
strlcpy
(
info
->
version
,
DRV_VERSION
,
sizeof
(
info
->
version
));
strlcpy
(
info
->
bus_info
,
dev
->
class_dev
.
dev
->
bus_id
,
sizeof
(
info
->
bus_info
));
}
static
int
etherh_get_settings
(
struct
net_device
*
dev
,
struct
ethtool_cmd
*
cmd
)
{
cmd
->
supported
=
etherh_priv
(
dev
)
->
supported
;
cmd
->
speed
=
SPEED_10
;
cmd
->
duplex
=
DUPLEX_HALF
;
cmd
->
port
=
dev
->
if_port
==
IF_PORT_10BASET
?
PORT_TP
:
PORT_BNC
;
cmd
->
autoneg
=
dev
->
flags
&
IFF_AUTOMEDIA
?
AUTONEG_ENABLE
:
AUTONEG_DISABLE
;
return
0
;
}
static
int
etherh_set_settings
(
struct
net_device
*
dev
,
struct
ethtool_cmd
*
cmd
)
{
switch
(
cmd
->
autoneg
)
{
case
AUTONEG_ENABLE
:
dev
->
flags
|=
IFF_AUTOMEDIA
;
break
;
case
AUTONEG_DISABLE
:
switch
(
cmd
->
port
)
{
case
PORT_TP
:
dev
->
if_port
=
IF_PORT_10BASET
;
break
;
case
PORT_BNC
:
dev
->
if_port
=
IF_PORT_10BASE2
;
break
;
default:
return
-
EINVAL
;
}
dev
->
flags
&=
~
IFF_AUTOMEDIA
;
break
;
default:
return
-
EINVAL
;
}
etherh_setif
(
dev
);
return
0
;
}
static
struct
ethtool_ops
etherh_ethtool_ops
=
{
.
get_settings
=
etherh_get_settings
,
.
set_settings
=
etherh_set_settings
,
.
get_drvinfo
=
etherh_get_drvinfo
,
};
static
u32
etherh_regoffsets
[
16
];
static
u32
etherm_regoffsets
[
16
];
...
...
@@ -587,10 +663,21 @@ etherh_probe(struct expansion_card *ec, const struct ecard_id *id)
dev
->
stop
=
etherh_close
;
dev
->
set_config
=
etherh_set_config
;
dev
->
irq
=
ec
->
irq
;
dev
->
if_port
=
data
->
if_port
;
dev
->
flags
|=
data
->
flags
;
dev
->
ethtool_ops
=
&
etherh_ethtool_ops
;
if
(
data
->
supported
&
SUPPORTED_Autoneg
)
dev
->
flags
|=
IFF_AUTOMEDIA
;
if
(
data
->
supported
&
SUPPORTED_TP
)
{
dev
->
flags
|=
IFF_PORTSEL
;
dev
->
if_port
=
IF_PORT_10BASET
;
}
else
if
(
data
->
supported
&
SUPPORTED_BNC
)
{
dev
->
flags
|=
IFF_PORTSEL
;
dev
->
if_port
=
IF_PORT_10BASE2
;
}
else
dev
->
if_port
=
IF_PORT_UNKNOWN
;
eh
=
etherh_priv
(
dev
);
eh
->
supported
=
data
->
supported
;
eh
->
ctrl
=
0
;
eh
->
id
=
ec
->
cid
.
product
;
eh
->
memc
=
ioremap
(
ecard_resource_start
(
ec
,
ECARD_RES_MEMC
),
PAGE_SIZE
);
...
...
@@ -610,7 +697,7 @@ etherh_probe(struct expansion_card *ec, const struct ecard_id *id)
}
dev
->
base_addr
=
(
unsigned
long
)
eh
->
memc
+
data
->
ns8390_offset
;
dev
->
mem_start
=
(
unsigned
long
)
eh
->
memc
+
data
->
dataport_offset
;
eh
->
dma_base
=
eh
->
memc
+
data
->
dataport_offset
;
eh
->
ctrl_port
+=
data
->
ctrlport_offset
;
/*
...
...
@@ -701,7 +788,7 @@ static struct etherh_data etherm_data = {
.
dataport_offset
=
ETHERM_NS8390
+
ETHERM_DATAPORT
,
.
ctrlport_offset
=
ETHERM_NS8390
+
ETHERM_CTRLPORT
,
.
name
=
"ANT EtherM"
,
.
if_port
=
IF_PORT_UNKNOWN
,
.
supported
=
SUPPORTED_10baseT_Half
,
.
tx_start_page
=
ETHERM_TX_START_PAGE
,
.
stop_page
=
ETHERM_STOP_PAGE
,
};
...
...
@@ -712,7 +799,7 @@ static struct etherh_data etherlan500_data = {
.
ctrlport_offset
=
ETHERH500_CTRLPORT
,
.
ctrl_ioc
=
1
,
.
name
=
"i3 EtherH 500"
,
.
if_port
=
IF_PORT_UNKNOWN
,
.
supported
=
SUPPORTED_10baseT_Half
,
.
tx_start_page
=
ETHERH_TX_START_PAGE
,
.
stop_page
=
ETHERH_STOP_PAGE
,
};
...
...
@@ -722,8 +809,7 @@ static struct etherh_data etherlan600_data = {
.
dataport_offset
=
ETHERH600_NS8390
+
ETHERH600_DATAPORT
,
.
ctrlport_offset
=
ETHERH600_NS8390
+
ETHERH600_CTRLPORT
,
.
name
=
"i3 EtherH 600"
,
.
flags
=
IFF_PORTSEL
|
IFF_AUTOMEDIA
,
.
if_port
=
IF_PORT_10BASET
,
.
supported
=
SUPPORTED_10baseT_Half
|
SUPPORTED_TP
|
SUPPORTED_BNC
|
SUPPORTED_Autoneg
,
.
tx_start_page
=
ETHERH_TX_START_PAGE
,
.
stop_page
=
ETHERH_STOP_PAGE
,
};
...
...
@@ -733,8 +819,7 @@ static struct etherh_data etherlan600a_data = {
.
dataport_offset
=
ETHERH600_NS8390
+
ETHERH600_DATAPORT
,
.
ctrlport_offset
=
ETHERH600_NS8390
+
ETHERH600_CTRLPORT
,
.
name
=
"i3 EtherH 600A"
,
.
flags
=
IFF_PORTSEL
|
IFF_AUTOMEDIA
,
.
if_port
=
IF_PORT_10BASET
,
.
supported
=
SUPPORTED_10baseT_Half
|
SUPPORTED_TP
|
SUPPORTED_BNC
|
SUPPORTED_Autoneg
,
.
tx_start_page
=
ETHERH_TX_START_PAGE
,
.
stop_page
=
ETHERH_STOP_PAGE
,
};
...
...
@@ -752,7 +837,7 @@ static struct ecard_driver etherh_driver = {
.
remove
=
__devexit_p
(
etherh_remove
),
.
id_table
=
etherh_ids
,
.
drv
=
{
.
name
=
"etherh"
,
.
name
=
DRV_NAME
,
},
};
...
...
drivers/serial/amba-pl011.c
View file @
7457affc
...
...
@@ -745,7 +745,7 @@ static struct uart_driver amba_reg = {
static
int
pl011_probe
(
struct
amba_device
*
dev
,
void
*
id
)
{
struct
uart_amba_port
*
uap
;
void
*
base
;
void
__iomem
*
base
;
int
i
,
ret
;
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
amba_ports
);
i
++
)
...
...
include/asm-arm/arch-clps711x/io.h
View file @
7457affc
...
...
@@ -22,9 +22,9 @@
#define IO_SPACE_LIMIT 0xffffffff
#define __io(a) ((a))
#define __mem_pci(a) (
(unsigned long)(a)
)
#define __mem_isa(a) (
(unsigned long)(a)
)
#define __io(a) ((
void __iomem *)(
a))
#define __mem_pci(a) (
a
)
#define __mem_isa(a) (
a
)
/*
* We don't support ins[lb]/outs[lb]. Make them fault.
...
...
include/asm-arm/arch-ebsa110/io.h
View file @
7457affc
...
...
@@ -27,13 +27,13 @@ void __outw(u16 val, unsigned int port);
u32
__inl
(
unsigned
int
port
);
void
__outl
(
u32
val
,
unsigned
int
port
);
u8
__readb
(
void
*
addr
);
u16
__readw
(
void
*
addr
);
u32
__readl
(
void
*
addr
);
u8
__readb
(
void
__iomem
*
addr
);
u16
__readw
(
void
__iomem
*
addr
);
u32
__readl
(
void
__iomem
*
addr
);
void
__writeb
(
u8
val
,
void
*
addr
);
void
__writew
(
u16
val
,
void
*
addr
);
void
__writel
(
u32
val
,
void
*
addr
);
void
__writeb
(
u8
val
,
void
__iomem
*
addr
);
void
__writew
(
u16
val
,
void
__iomem
*
addr
);
void
__writel
(
u32
val
,
void
__iomem
*
addr
);
/*
* Argh, someone forgot the IOCS16 line. We therefore have to handle
...
...
@@ -64,7 +64,7 @@ void __writel(u32 val, void *addr);
#define writew(v,b) __writew(v,b)
#define writel(v,b) __writel(v,b)
#define __arch_ioremap(cookie,sz,c,a) ((void *)(cookie))
#define __arch_ioremap(cookie,sz,c,a) ((void
__iomem
*)(cookie))
#define __arch_iounmap(cookie) do { } while (0)
extern
void
insb
(
unsigned
int
port
,
void
*
buf
,
int
sz
);
...
...
include/asm-arm/arch-ebsa285/io.h
View file @
7457affc
...
...
@@ -19,25 +19,27 @@
/*
* Translation of various region addresses to virtual addresses
*/
#define __io(a) (
PCIO_BASE + (a
))
#define __io(a) (
(void __iomem *)(PCIO_BASE + (a)
))
#if 1
#define __mem_pci(a) (
(unsigned long)(a)
)
#define __mem_isa(a) (
PCIMEM_BASE + (unsigned long)(a)
)
#define __mem_pci(a) (
a
)
#define __mem_isa(a) (
(a) + PCIMEM_BASE
)
#else
static
inline
unsigned
long
___mem_pci
(
unsigned
long
a
)
static
inline
void
__iomem
*
___mem_pci
(
void
__iomem
*
p
)
{
unsigned
long
a
=
(
unsigned
long
)
p
;
BUG_ON
(
a
<=
0xc0000000
||
a
>=
0xe0000000
);
return
a
;
return
p
;
}
static
inline
unsigned
long
___mem_isa
(
unsigned
long
a
)
static
inline
void
__iomem
*
___mem_isa
(
void
__iomem
*
p
)
{
unsigned
long
a
=
(
unsigned
long
)
p
;
BUG_ON
(
a
>=
16
*
1048576
);
return
PCIMEM_BASE
+
a
;
return
p
+
PCIMEM_BASE
;
}
#define __mem_pci(a) ___mem_pci(
(unsigned long)(a)
)
#define __mem_isa(a) ___mem_isa(
(unsigned long)(a)
)
#define __mem_pci(a) ___mem_pci(
a
)
#define __mem_isa(a) ___mem_isa(
a
)
#endif
#endif
include/asm-arm/arch-epxa10db/io.h
View file @
7457affc
...
...
@@ -33,7 +33,7 @@
#define insw __arch_readsw
#define insl __arch_readsl*/
#define __io(a) (
a
)
#define __io(a) (
(void __iomem *)(a)
)
#define __mem_pci(a) (a)
#endif
include/asm-arm/arch-h720x/io.h
View file @
7457affc
...
...
@@ -18,7 +18,7 @@
#define IO_SPACE_LIMIT 0xffffffff
#define __io(a)
(a
)
#define __mem_pci(a)
(a)
#define __io(a)
((void __iomem *)(a)
)
#define __mem_pci(a)
(a)
#endif
include/asm-arm/arch-imx/io.h
View file @
7457affc
...
...
@@ -22,7 +22,7 @@
#define IO_SPACE_LIMIT 0xffffffff
#define __io(a)
(a
)
#define __mem_pci(a)
(a)
#define __io(a)
((void __iomem *)(a)
)
#define __mem_pci(a)
(a)
#endif
include/asm-arm/arch-integrator/io.h
View file @
7457affc
...
...
@@ -22,8 +22,8 @@
#define IO_SPACE_LIMIT 0xffff
#define __io(a) (
PCI_IO_VADDR + (a
))
#define __mem_pci(a) (
(unsigned long)(a)
)
#define __mem_isa(a) (
PCI_MEMORY_VADDR + (unsigned long)(a)
)
#define __io(a) (
(void __iomem *)(PCI_IO_VADDR + (a)
))
#define __mem_pci(a) (
a
)
#define __mem_isa(a) (
(a) + PCI_MEMORY_VADDR
)
#endif
include/asm-arm/arch-iop3xx/io.h
View file @
7457affc
...
...
@@ -13,8 +13,8 @@
#define IO_SPACE_LIMIT 0xffffffff
#define __io(p) ((p))
#define __mem_pci(a) (
(unsigned long)(a)
)
#define __mem_isa(a) (
(unsigned long)(a)
)
#define __io(p) ((
void __iomem *)(
p))
#define __mem_pci(a) (
a
)
#define __mem_isa(a) (
a
)
#endif
include/asm-arm/arch-ixp2000/io.h
View file @
7457affc
...
...
@@ -16,7 +16,7 @@
#define __ASM_ARM_ARCH_IO_H
#define IO_SPACE_LIMIT 0xffffffff
#define __mem_pci(a) (
(unsigned long)(a)
)
#define __mem_pci(a) (
a
)
/*
* Pick up VMALLOC_END
...
...
include/asm-arm/arch-ixp4xx/io.h
View file @
7457affc
...
...
@@ -46,7 +46,7 @@ extern int ixp4xx_pci_write(u32 addr, u32 cmd, u32 data);
*/
#ifndef CONFIG_IXP4XX_INDIRECT_PCI
#define __mem_pci(a) (
(unsigned long)(a)
)
#define __mem_pci(a) (
a
)
#else
...
...
@@ -58,10 +58,10 @@ extern int ixp4xx_pci_write(u32 addr, u32 cmd, u32 data);
* access registers. If something outside of PCI is ioremap'd, we
* fallback to the default.
*/
static
inline
void
*
static
inline
void
__iomem
*
__ixp4xx_ioremap
(
unsigned
long
addr
,
size_t
size
,
unsigned
long
flags
,
unsigned
long
align
)
{
extern
void
*
__ioremap
(
unsigned
long
,
size_t
,
unsigned
long
,
unsigned
long
);
extern
void
__iomem
*
__ioremap
(
unsigned
long
,
size_t
,
unsigned
long
,
unsigned
long
);
if
((
addr
<
0x48000000
)
||
(
addr
>
0x4fffffff
))
return
__ioremap
(
addr
,
size
,
flags
,
align
);
...
...
@@ -69,9 +69,9 @@ __ixp4xx_ioremap(unsigned long addr, size_t size, unsigned long flags, unsigned
}
static
inline
void
__ixp4xx_iounmap
(
void
*
addr
)
__ixp4xx_iounmap
(
void
__iomem
*
addr
)
{
extern
void
__iounmap
(
void
*
addr
);
extern
void
__iounmap
(
void
__iomem
*
addr
);
if
((
u32
)
addr
>=
VMALLOC_START
)
__iounmap
(
addr
);
...
...
include/asm-arm/arch-l7200/io.h
View file @
7457affc
...
...
@@ -17,9 +17,9 @@
/*
* There are not real ISA nor PCI buses, so we fake it.
*/
#define __io_pci(a)
(PCIO_BASE + (a
))
#define __mem_pci(a)
((unsigned long)(a)
)
#define __mem_isa(a)
((unsigned long)(a)
)
#define __io_pci(a)
((void __iomem *)(PCIO_BASE + (a)
))
#define __mem_pci(a)
(a
)
#define __mem_isa(a)
(a
)
#define __ioaddr(p) __io_pci(p)
...
...
include/asm-arm/arch-lh7a40x/io.h
View file @
7457affc
...
...
@@ -14,8 +14,8 @@
#define IO_SPACE_LIMIT 0xffffffff
/* No ISA or PCI bus on this machine. */
#define __io(a) (
a
)
#define __mem_pci(a) (
(unsigned long)(a)
)
#define __mem_isa(a) (
(unsigned long)(a)
)
#define __io(a) (
(void __iomem *)(a)
)
#define __mem_pci(a) (
a
)
#define __mem_isa(a) (
a
)
#endif
/* __ASM_ARCH_IO_H */
include/asm-arm/arch-omap/io.h
View file @
7457affc
...
...
@@ -40,9 +40,9 @@
* We don't actually have real ISA nor PCI buses, but there is so many
* drivers out there that might just work if we fake them...
*/
#define __io(a) (
PCIO_BASE + (a
))
#define __mem_pci(a) (
(unsigned long)(a)
)
#define __mem_isa(a) (
(unsigned long)(a)
)
#define __io(a) (
(void __iomem *)(PCIO_BASE + (a)
))
#define __mem_pci(a) (
a
)
#define __mem_isa(a) (
a
)
/*
* ----------------------------------------------------------------------------
...
...
include/asm-arm/arch-pxa/io.h
View file @
7457affc
...
...
@@ -12,8 +12,8 @@
* We don't actually have real ISA nor PCI buses, but there is so many
* drivers out there that might just work if we fake them...
*/
#define __io(a) (
a
)
#define __mem_pci(a) (
(unsigned long)(a)
)
#define __mem_isa(a) (
(unsigned long)(a)
)
#define __io(a) (
(void __iomem *)(a)
)
#define __mem_pci(a) (
a
)
#define __mem_isa(a) (
a
)
#endif
include/asm-arm/arch-rpc/io.h
View file @
7457affc
...
...
@@ -250,6 +250,6 @@ DECLARE_IO(int,l,"")
/*
* 1:1 mapping for ioremapped regions.
*/
#define __mem_pci(x) (
(unsigned long)(x)
)
#define __mem_pci(x) (
x
)
#endif
include/asm-arm/arch-s3c2410/dma.h
View file @
7457affc
...
...
@@ -198,7 +198,7 @@ struct s3c2410_dma_chan_s {
unsigned
int
flags
;
/* channel flags */
/* channel's hardware position and configuration */
unsigned
long
regs
;
/* channels registers */
void
__iomem
*
regs
;
/* channels registers */
unsigned
int
irq
;
/* channel irq */
unsigned
long
addr_reg
;
/* data address register */
unsigned
long
dcon
;
/* default value of DCON */
...
...
include/asm-arm/arch-sa1100/io.h
View file @
7457affc
...
...
@@ -16,8 +16,8 @@
* We don't actually have real ISA nor PCI buses, but there is so many
* drivers out there that might just work if we fake them...
*/
#define __io(a) (
PCIO_BASE + (a
))
#define __mem_pci(a) (
(unsigned long)(a)
)
#define __mem_isa(a) (
(unsigned long)(a)
)
#define __io(a) (
(void __iomem *)(PCIO_BASE + (a)
))
#define __mem_pci(a) (
a
)
#define __mem_isa(a) (
a
)
#endif
include/asm-arm/arch-shark/io.h
View file @
7457affc
...
...
@@ -170,7 +170,7 @@ DECLARE_IO(long,l,"")
addr; \
})
#define __mem_pci(addr)
addr
#define __mem_pci(addr)
(addr)
#define inb(p) (__builtin_constant_p((p)) ? __inbc(p) : __inb(p))
#define inw(p) (__builtin_constant_p((p)) ? __inwc(p) : __inw(p))
...
...
include/asm-arm/arch-versatile/io.h
View file @
7457affc
...
...
@@ -22,8 +22,8 @@
#define IO_SPACE_LIMIT 0xffff
#define __io(a) ((a))
#define __mem_pci(a) (
(unsigned long)(a)
)
#define __mem_isa(a) (
(unsigned long)(a)
)
#define __io(a) ((
void __iomem *)(
a))
#define __mem_pci(a) (
a
)
#define __mem_isa(a) (
a
)
#endif
include/asm-arm/hardware/amba_clcd.h
View file @
7457affc
...
...
@@ -141,7 +141,7 @@ struct clcd_fb {
struct
clcd_panel
*
panel
;
struct
clcd_board
*
board
;
void
*
board_data
;
void
*
regs
;
void
__iomem
*
regs
;
u32
clcd_cntl
;
u32
cmap
[
16
];
};
...
...
include/asm-arm/io.h
View file @
7457affc
...
...
@@ -39,21 +39,21 @@
* Generic IO read/write. These perform native-endian accesses. Note
* that some architectures will want to re-define __raw_{read,write}w.
*/
extern
void
__raw_writesb
(
unsigned
int
addr
,
const
void
*
data
,
int
bytelen
);
extern
void
__raw_writesw
(
unsigned
int
addr
,
const
void
*
data
,
int
wordlen
);
extern
void
__raw_writesl
(
unsigned
int
addr
,
const
void
*
data
,
int
longlen
);
extern
void
__raw_writesb
(
void
__iomem
*
addr
,
const
void
*
data
,
int
bytelen
);
extern
void
__raw_writesw
(
void
__iomem
*
addr
,
const
void
*
data
,
int
wordlen
);
extern
void
__raw_writesl
(
void
__iomem
*
addr
,
const
void
*
data
,
int
longlen
);
extern
void
__raw_readsb
(
unsigned
int
addr
,
void
*
data
,
int
bytelen
);
extern
void
__raw_readsw
(
unsigned
int
addr
,
void
*
data
,
int
wordlen
);
extern
void
__raw_readsl
(
unsigned
int
addr
,
void
*
data
,
int
longlen
);
extern
void
__raw_readsb
(
void
__iomem
*
addr
,
void
*
data
,
int
bytelen
);
extern
void
__raw_readsw
(
void
__iomem
*
addr
,
void
*
data
,
int
wordlen
);
extern
void
__raw_readsl
(
void
__iomem
*
addr
,
void
*
data
,
int
longlen
);
#define __raw_writeb(v,a) (*(volatile unsigned char *)(a) = (v))
#define __raw_writew(v,a) (*(volatile unsigned short *)(a) = (v))
#define __raw_writel(v,a) (*(volatile unsigned int *)(a) = (v))
#define __raw_writeb(v,a) (*(volatile unsigned char
__force
*)(a) = (v))
#define __raw_writew(v,a) (*(volatile unsigned short
__force
*)(a) = (v))
#define __raw_writel(v,a) (*(volatile unsigned int
__force
*)(a) = (v))
#define __raw_readb(a) (*(volatile unsigned char *)(a))
#define __raw_readw(a) (*(volatile unsigned short *)(a))
#define __raw_readl(a) (*(volatile unsigned int *)(a))
#define __raw_readb(a) (*(volatile unsigned char
__force
*)(a))
#define __raw_readw(a) (*(volatile unsigned short
__force
*)(a))
#define __raw_readl(a) (*(volatile unsigned int
__force
*)(a))
/*
* Bad read/write accesses...
...
...
@@ -156,17 +156,17 @@ extern void _memset_io(void __iomem *, int, size_t);
#define readw_relaxed(addr) readw(addr)
#define readl_relaxed(addr) readl(addr)
#define readsb(p,d,l) __raw_readsb(
(unsigned int)
__mem_pci(p),d,l)
#define readsw(p,d,l) __raw_readsw(
(unsigned int)
__mem_pci(p),d,l)
#define readsl(p,d,l) __raw_readsl(
(unsigned int)
__mem_pci(p),d,l)
#define readsb(p,d,l) __raw_readsb(__mem_pci(p),d,l)
#define readsw(p,d,l) __raw_readsw(__mem_pci(p),d,l)
#define readsl(p,d,l) __raw_readsl(__mem_pci(p),d,l)
#define writeb(v,c) __raw_writeb(v,__mem_pci(c))
#define writew(v,c) __raw_writew(cpu_to_le16(v),__mem_pci(c))
#define writel(v,c) __raw_writel(cpu_to_le32(v),__mem_pci(c))
#define writesb(p,d,l) __raw_writesb(
(unsigned int)
__mem_pci(p),d,l)
#define writesw(p,d,l) __raw_writesw(
(unsigned int)
__mem_pci(p),d,l)
#define writesl(p,d,l) __raw_writesl(
(unsigned int)
__mem_pci(p),d,l)
#define writesb(p,d,l) __raw_writesb(__mem_pci(p),d,l)
#define writesw(p,d,l) __raw_writesw(__mem_pci(p),d,l)
#define writesl(p,d,l) __raw_writesl(__mem_pci(p),d,l)
#define memset_io(c,v,l) _memset_io(__mem_pci(c),(v),(l))
#define memcpy_fromio(a,c,l) _memcpy_fromio((a),__mem_pci(c),(l))
...
...
@@ -268,8 +268,8 @@ isa_check_signature(unsigned long io_addr, const unsigned char *signature,
* ioremap takes a PCI memory address, as specified in
* Documentation/IO-mapping.txt.
*/
extern
void
*
__ioremap
(
unsigned
long
,
size_t
,
unsigned
long
,
unsigned
long
);
extern
void
__iounmap
(
void
*
addr
);
extern
void
__iomem
*
__ioremap
(
unsigned
long
,
size_t
,
unsigned
long
,
unsigned
long
);
extern
void
__iounmap
(
void
__iomem
*
addr
);
#ifndef __arch_ioremap
#define ioremap(cookie,size) __ioremap(cookie,size,0,1)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment