diff mbox

[v3,1/3] fb.h: Provide alternate screen_base pointer

Message ID 1444202414-21271-1-git-send-email-lars1.svensson@sonymobile.com (mailing list archive)
State New, archived
Headers show

Commit Message

Lars Svensson Oct. 7, 2015, 7:20 a.m. UTC
Some drivers use member screen_base of struct fb_info to store non-
__iomem pointers, creating the need for ugly __force typecasts to
avoid sparse warnings. This adds an alternate pointer without the
__iomem qualifyer for this use.

Signed-off-by: Lars Svensson <lars1.svensson@sonymobile.com>
---
Patch v3: bugfix in fbtft-bus.c:fbtft_write_vmem16_bus9() in
a separate commit.
---
 include/linux/fb.h | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

Comments

Dan Carpenter Oct. 7, 2015, 7:42 a.m. UTC | #1
Thanks!

I feel like this series is definitely the right thing, but I wonder how
we're going to merge it...  Anyway that's above my pay grade.

regards,
dan carpenter

--
To unsubscribe from this list: send the line "unsubscribe linux-fbdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/include/linux/fb.h b/include/linux/fb.h
index bc9afa7..41a3b11 100644
--- a/include/linux/fb.h
+++ b/include/linux/fb.h
@@ -483,7 +483,10 @@  struct fb_info {
 #ifdef CONFIG_FB_TILEBLITTING
 	struct fb_tile_ops *tileops;    /* Tile Blitting */
 #endif
-	char __iomem *screen_base;	/* Virtual address */
+	union {
+		char __iomem *screen_base;	/* Virtual address */
+		char *screen_buffer;
+	};
 	unsigned long screen_size;	/* Amount of ioremapped VRAM or 0 */ 
 	void *pseudo_palette;		/* Fake palette of 16 colors */ 
 #define FBINFO_STATE_RUNNING	0