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
nexedi
linux
Commits
63f716b9
Commit
63f716b9
authored
Dec 29, 2005
by
Al Viro
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] sh: lvalues abuse in arch/sh/boards/renesas/rts7751r2d/io.c
Signed-off-by:
Al Viro
<
viro@zeniv.linux.org.uk
>
parent
6881761e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
12 deletions
+18
-12
arch/sh/boards/renesas/rts7751r2d/io.c
arch/sh/boards/renesas/rts7751r2d/io.c
+18
-12
No files found.
arch/sh/boards/renesas/rts7751r2d/io.c
View file @
63f716b9
...
...
@@ -216,24 +216,26 @@ void rts7751r2d_insb(unsigned long port, void *addr, unsigned long count)
{
volatile
__u8
*
bp
;
volatile
__u16
*
p
;
unsigned
char
*
s
=
addr
;
if
(
CHECK_AX88796L_PORT
(
port
))
{
p
=
(
volatile
unsigned
short
*
)
port88796l
(
port
,
0
);
while
(
count
--
)
*
((
unsigned
char
*
)
addr
)
++
=
*
p
&
0xff
;
while
(
count
--
)
*
s
++
=
*
p
&
0xff
;
}
else
if
(
PXSEG
(
port
))
while
(
count
--
)
*
((
unsigned
char
*
)
addr
)
++
=
*
(
volatile
unsigned
char
*
)
port
;
while
(
count
--
)
*
s
++
=
*
(
volatile
unsigned
char
*
)
port
;
else
if
(
CHECK_SH7751_PCIIO
(
port
)
||
shifted_port
(
port
))
{
bp
=
(
__u8
*
)
PCI_IOMAP
(
port
);
while
(
count
--
)
*
((
volatile
unsigned
char
*
)
addr
)
++
=
*
bp
;
while
(
count
--
)
*
s
++
=
*
bp
;
}
else
{
p
=
(
volatile
unsigned
short
*
)
port2adr
(
port
);
while
(
count
--
)
*
((
unsigned
char
*
)
addr
)
++
=
*
p
&
0xff
;
while
(
count
--
)
*
s
++
=
*
p
&
0xff
;
}
}
void
rts7751r2d_insw
(
unsigned
long
port
,
void
*
addr
,
unsigned
long
count
)
{
volatile
__u16
*
p
;
__u16
*
s
=
addr
;
if
(
CHECK_AX88796L_PORT
(
port
))
p
=
(
volatile
unsigned
short
*
)
port88796l
(
port
,
1
);
...
...
@@ -243,7 +245,7 @@ void rts7751r2d_insw(unsigned long port, void *addr, unsigned long count)
p
=
(
volatile
unsigned
short
*
)
PCI_IOMAP
(
port
);
else
p
=
(
volatile
unsigned
short
*
)
port2adr
(
port
);
while
(
count
--
)
*
((
__u16
*
)
addr
)
++
=
*
p
;
while
(
count
--
)
*
s
++
=
*
p
;
}
void
rts7751r2d_insl
(
unsigned
long
port
,
void
*
addr
,
unsigned
long
count
)
...
...
@@ -252,8 +254,9 @@ void rts7751r2d_insl(unsigned long port, void *addr, unsigned long count)
maybebadio
(
insl
,
port
);
else
if
(
CHECK_SH7751_PCIIO
(
port
)
||
shifted_port
(
port
))
{
volatile
__u32
*
p
=
(
__u32
*
)
PCI_IOMAP
(
port
);
__u32
*
s
=
addr
;
while
(
count
--
)
*
((
__u32
*
)
addr
)
++
=
*
p
;
while
(
count
--
)
*
s
++
=
*
p
;
}
else
maybebadio
(
insl
,
port
);
}
...
...
@@ -262,24 +265,26 @@ void rts7751r2d_outsb(unsigned long port, const void *addr, unsigned long count)
{
volatile
__u8
*
bp
;
volatile
__u16
*
p
;
const
__u8
*
s
=
addr
;
if
(
CHECK_AX88796L_PORT
(
port
))
{
p
=
(
volatile
unsigned
short
*
)
port88796l
(
port
,
0
);
while
(
count
--
)
*
p
=
*
((
unsigned
char
*
)
addr
)
++
;
while
(
count
--
)
*
p
=
*
s
++
;
}
else
if
(
PXSEG
(
port
))
while
(
count
--
)
*
(
volatile
unsigned
char
*
)
port
=
*
((
unsigned
char
*
)
addr
)
++
;
while
(
count
--
)
*
(
volatile
unsigned
char
*
)
port
=
*
s
++
;
else
if
(
CHECK_SH7751_PCIIO
(
port
)
||
shifted_port
(
port
))
{
bp
=
(
__u8
*
)
PCI_IOMAP
(
port
);
while
(
count
--
)
*
bp
=
*
((
volatile
unsigned
char
*
)
addr
)
++
;
while
(
count
--
)
*
bp
=
*
s
++
;
}
else
{
p
=
(
volatile
unsigned
short
*
)
port2adr
(
port
);
while
(
count
--
)
*
p
=
*
((
unsigned
char
*
)
addr
)
++
;
while
(
count
--
)
*
p
=
*
s
++
;
}
}
void
rts7751r2d_outsw
(
unsigned
long
port
,
const
void
*
addr
,
unsigned
long
count
)
{
volatile
__u16
*
p
;
const
__u16
*
s
=
addr
;
if
(
CHECK_AX88796L_PORT
(
port
))
p
=
(
volatile
unsigned
short
*
)
port88796l
(
port
,
1
);
...
...
@@ -289,7 +294,7 @@ void rts7751r2d_outsw(unsigned long port, const void *addr, unsigned long count)
p
=
(
volatile
unsigned
short
*
)
PCI_IOMAP
(
port
);
else
p
=
(
volatile
unsigned
short
*
)
port2adr
(
port
);
while
(
count
--
)
*
p
=
*
((
__u16
*
)
addr
)
++
;
while
(
count
--
)
*
p
=
*
s
++
;
}
void
rts7751r2d_outsl
(
unsigned
long
port
,
const
void
*
addr
,
unsigned
long
count
)
...
...
@@ -298,8 +303,9 @@ void rts7751r2d_outsl(unsigned long port, const void *addr, unsigned long count)
maybebadio
(
outsl
,
port
);
else
if
(
CHECK_SH7751_PCIIO
(
port
)
||
shifted_port
(
port
))
{
volatile
__u32
*
p
=
(
__u32
*
)
PCI_IOMAP
(
port
);
const
__u32
*
s
=
addr
;
while
(
count
--
)
*
p
=
*
((
__u32
*
)
addr
)
++
;
while
(
count
--
)
*
p
=
*
s
++
;
}
else
maybebadio
(
outsl
,
port
);
}
...
...
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