History

fbcon: call fbcon_fb_(un)registered directly

With commit 6104c37094e729f3d4ce65797002112735d49cd1 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Aug 1 17:32:07 2017 +0200 fbcon: Make fbcon a built-time depency for fbdev we have a static dependency between fbcon and fbdev, and we can replace the indirection through the notifier chain with a function call. v2: Sam Ravnborg noticed that mach-pxa/am200epd.c has a notifier too, and listens to this. ... Looking at the code it seems to wait for some fb to show up, so that it can get the framebuffer base address from the fb_info struct. I suspect his is some firmware fbdev. Then it uses that information to let the real fbdev driver (metronomefb.c by the looks) get at the framebuffer memory. This doesn't looke like it's easy to fix (except by deleting the entire thing, seems untouched since 2008, we might be able to get away with that), so let's just stuff a few #ifdef into fb.h and fbmem.c and cry over them for a bit.

Daniel Vetter committed 7 years ago

Commit 97b67981 parent 1f4ed2f5 files · +40 −22Browse files

Showing the changes to include/linux (2 of 5 files). Show all

Unified · Split

2 files
  1. include/linux/fb.h +5 −2
  2. include/linux/fbcon.h +4 −0
include/linux/fb.h+5−2
@@ -136,10 +136,13 @@ struct fb_cursor_user { · 135 unmodified lines
136136 #define FB_EVENT_RESUME 0x03
137137 /* An entry from the modelist was removed */
138138 #define FB_EVENT_MODE_DELETE 0x04
139−/* A driver registered itself */
139+
140+#ifdef CONFIG_GUMSTIX_AM200EPD
141+/* only used by mach-pxa/am200epd.c */
140142 #define FB_EVENT_FB_REGISTERED 0x05
141−/* A driver unregistered itself */
142143 #define FB_EVENT_FB_UNREGISTERED 0x06
144+#endif
145+
143146 /* CONSOLE-SPECIFIC: get console to framebuffer mapping */
144147 #define FB_EVENT_GET_CONSOLE_MAP 0x07
145148 /* CONSOLE-SPECIFIC: set console to framebuffer mapping */
include/linux/fbcon.h+4−0
@@ -4,9 +4,13 @@ · 3 unmodified lines
44 #ifdef CONFIG_FRAMEBUFFER_CONSOLE
55 void __init fb_console_init(void);
66 void __exit fb_console_exit(void);
7+int fbcon_fb_registered(struct fb_info *info);
8+void fbcon_fb_unregistered(struct fb_info *info);
79 #else
810 static inline void fb_console_init(void) {}
911 static inline void fb_console_exit(void) {}
12+static inline int fbcon_fb_registered(struct fb_info *info) { return 0; }
13+static inline void fbcon_fb_unregistered(struct fb_info *info) {}
1014 #endif
1115
1216 #endif /* _LINUX_FBCON_H */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t