diff options
author | Aaro Koskinen <aaro.koskinen@iki.fi> | 2011-09-13 23:49:33 +0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-09-16 22:16:48 +0400 |
commit | c44fa627c7b351cb359b7bd373756776b907ecd5 (patch) | |
tree | 0df5300ac4eae6985555bcf3c0f54de280510b51 /drivers/staging/xgifb/vgatypes.h | |
parent | 4b4954621ff57e168ebd77b7d2682308d13b4e7f (diff) | |
download | linux-c44fa627c7b351cb359b7bd373756776b907ecd5.tar.xz |
staging: xgifb: vb_init: use readl()/writel() to access iomapped memory
Use readl() and writel() in FB memory test instead of direct pointer
access, and also add iomem annotations for the FB memory.
The patch eliminates the following sparse warnings:
drivers/staging/xgifb/XGI_main_26.c:2113:69: warning: incorrect type in assignment (different address spaces)
drivers/staging/xgifb/XGI_main_26.c:2113:69: expected unsigned char *static [addressable] [toplevel] [assigned] pjVideoMemoryAddress
drivers/staging/xgifb/XGI_main_26.c:2113:69: got void [noderef] <asn:2>*
drivers/staging/xgifb/XGI_main_26.c:2399:30: warning: incorrect type in assignment (different address spaces)
drivers/staging/xgifb/XGI_main_26.c:2399:30: expected char [noderef] <asn:2>*screen_base
drivers/staging/xgifb/XGI_main_26.c:2399:30: got char *[addressable] [toplevel] [assigned] video_vbase
drivers/staging/xgifb/XGI_main_26.c:2430:31: warning: incorrect type in argument 1 (different address spaces)
drivers/staging/xgifb/XGI_main_26.c:2430:31: expected void volatile [noderef] <asn:2>*addr
drivers/staging/xgifb/XGI_main_26.c:2430:31: got char *[addressable] [toplevel] [assigned] video_vbase
drivers/staging/xgifb/XGI_main_26.c:2454:31: warning: incorrect type in argument 1 (different address spaces)
drivers/staging/xgifb/XGI_main_26.c:2454:31: expected void volatile [noderef] <asn:2>*addr
drivers/staging/xgifb/XGI_main_26.c:2454:31: got char *[addressable] [toplev
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/xgifb/vgatypes.h')
-rw-r--r-- | drivers/staging/xgifb/vgatypes.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/xgifb/vgatypes.h b/drivers/staging/xgifb/vgatypes.h index 7f911f1ac32d..76e2d81cbd51 100644 --- a/drivers/staging/xgifb/vgatypes.h +++ b/drivers/staging/xgifb/vgatypes.h @@ -53,7 +53,7 @@ struct xgi_hw_device_info { unsigned char *pjVirtualRomBase; /* ROM image */ - unsigned char *pjVideoMemoryAddress;/* base virtual memory address */ + void __iomem *pjVideoMemoryAddress;/* base virtual memory address */ /* of Linear VGA memory */ unsigned long ulVideoMemorySize; /* size, in bytes, of the |