Commit 65a9be15 authored by Meelis Roos's avatar Meelis Roos Committed by David S. Miller

[SPARC64]: BUG on positive addresses in vga.h

parent 3d06d03d
...@@ -13,18 +13,16 @@ ...@@ -13,18 +13,16 @@
static inline void scr_writew(u16 val, u16 *addr) static inline void scr_writew(u16 val, u16 *addr)
{ {
if ((long) addr < 0) BUG_ON((long) addr >= 0);
*addr = val; *addr = val;
else
writew(val, (unsigned long) addr);
} }
static inline u16 scr_readw(const u16 *addr) static inline u16 scr_readw(const u16 *addr)
{ {
if ((long) addr < 0) BUG_ON((long) addr >= 0);
return *addr; return *addr;
else
return readw((unsigned long) addr);
} }
#define VGA_MAP_MEM(x) (x) #define VGA_MAP_MEM(x) (x)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment