diff options
author | Helge Deller | 2006-03-22 15:19:46 -0700 |
---|---|---|
committer | Kyle McMartin | 2006-03-30 17:48:47 +0000 |
commit | 857600c77161fd36e30cd6bcca9a0a8676036323 (patch) | |
tree | bef75f9f9a2bebd9fc084b8a15064bdce1a45aef /drivers/video/sticore.h | |
parent | b8ce0aadcdebbaf5ec013c57e2a0803060817bcc (diff) |
[PARISC] Fix stifb with IOREMAP and a 64-bit kernel
Kill various warnings when built using ioremap.
Remove stifb_{read,write} functions, which are now obsolete (and stack abusers!)
Disable stifb mmap() functionality on a 64-bit kernel, it will crash the
machine.
Signed-off-by: Helge Deller <deller@parisc-linux.org>
Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
Diffstat (limited to 'drivers/video/sticore.h')
-rw-r--r-- | drivers/video/sticore.h | 37 |
1 files changed, 11 insertions, 26 deletions
diff --git a/drivers/video/sticore.h b/drivers/video/sticore.h index dc93336af557..1a9a60c74be3 100644 --- a/drivers/video/sticore.h +++ b/drivers/video/sticore.h @@ -34,36 +34,20 @@ * for them to fix it and steal their solution. prumpf */ -#define STI_WAIT 1 - -#include <asm/io.h> /* for USE_HPPA_IOREMAP */ - -#if USE_HPPA_IOREMAP +#include <asm/io.h> -#define STI_PTR(p) (p) -#define PTR_STI(p) (p) -static inline int STI_CALL( unsigned long func, - void *flags, void *inptr, void *outptr, void *glob_cfg ) -{ - int (*f)(void *,void *,void *,void *); - f = (void*)func; - return f(flags, inptr, outptr, glob_cfg); -} - -#else /* !USE_HPPA_IOREMAP */ +#define STI_WAIT 1 #define STI_PTR(p) ( virt_to_phys(p) ) -#define PTR_STI(p) ( phys_to_virt((long)p) ) -#define STI_CALL(func, flags, inptr, outptr, glob_cfg) \ - ({ \ - pdc_sti_call( func, (unsigned long)STI_PTR(flags), \ - (unsigned long)STI_PTR(inptr), \ - (unsigned long)STI_PTR(outptr), \ - (unsigned long)STI_PTR(glob_cfg)); \ +#define PTR_STI(p) ( phys_to_virt((unsigned long)p) ) +#define STI_CALL(func, flags, inptr, outptr, glob_cfg) \ + ({ \ + pdc_sti_call( func, STI_PTR(flags), \ + STI_PTR(inptr), \ + STI_PTR(outptr), \ + STI_PTR(glob_cfg)); \ }) -#endif /* USE_HPPA_IOREMAP */ - #define sti_onscreen_x(sti) (sti->glob_cfg->onscreen_x) #define sti_onscreen_y(sti) (sti->glob_cfg->onscreen_y) @@ -352,8 +336,9 @@ struct sti_struct { struct sti_conf_outptr outptr; /* configuration */ struct sti_conf_outptr_ext outptr_ext; - /* PCI data structures (pg. 17ff from sti.pdf) */ struct pci_dev *pd; + + /* PCI data structures (pg. 17ff from sti.pdf) */ u8 rm_entry[16]; /* pci region mapper array == pci config space offset */ /* pointer to the fb_info where this STI device is used */ |