mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-06 01:49:46 +00:00
Fixup c91c9f257d ("fbdev: Allow client to request a particular /dev/fbN node")
We lost a line in the forward port, which meant that it always used
/dev/fb0, and complained that the sysfs nodes already existed.
Fixes: c91c9f257d ("fbdev: Allow client to request a particular /dev/fbN node")
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
This commit is contained in:
committed by
Dom Cobley
parent
192c0d1084
commit
9e5f95529b
@@ -446,6 +446,7 @@ static int do_register_framebuffer(struct fb_info *fb_info)
|
||||
if (num_registered_fb == FB_MAX)
|
||||
return -ENXIO;
|
||||
|
||||
i = fb_info->node;
|
||||
if (!fb_info->custom_fb_num || fb_info->node >= FB_MAX || registered_fb[fb_info->node]) {
|
||||
for (i = min_dynamic_fb ; i < FB_MAX; i++)
|
||||
if (!registered_fb[i])
|
||||
@@ -463,6 +464,7 @@ static int do_register_framebuffer(struct fb_info *fb_info)
|
||||
if (err < 0)
|
||||
return err;
|
||||
|
||||
fb_info->node = i;
|
||||
refcount_set(&fb_info->count, 1);
|
||||
mutex_init(&fb_info->lock);
|
||||
mutex_init(&fb_info->mm_lock);
|
||||
|
||||
Reference in New Issue
Block a user