Skip to content

Commit

Permalink
Revert "fbdev: Prevent probing generic drivers if a FB is already reg…
Browse files Browse the repository at this point in the history
…istered"

This reverts commit fb561bf.

With

commit 27599aa
Author: Thomas Zimmermann <tzimmermann@suse.de>
Date:   Tue Jan 25 10:12:18 2022 +0100

    fbdev: Hot-unplug firmware fb devices on forced removal

this should be fixed properly and we can remove this somewhat hackish
check here (e.g. this won't catch drm drivers if fbdev emulation isn't
enabled).

Cc: Thomas Zimmermann <tzimmermann@suse.de>
Cc: Zack Rusin <zackr@vmware.com>
Cc: Javier Martinez Canillas <javierm@redhat.com>
Cc: Zack Rusin <zackr@vmware.com>
Cc: Hans de Goede <hdegoede@redhat.com>
Cc: Ilya Trukhanov <lahvuun@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
Cc: Peter Jones <pjones@redhat.com>
Cc: linux-fbdev@vger.kernel.org

Cover-changes: 3
- Rebase on top of latest drm-misc-next branch.

Cover-changes: 2
- Drop RFC prefix since patches were already reviewed by Daniel Vetter.
- Add Daniel Reviewed-by tags to the patches.
  • Loading branch information
danvet authored and martinezjavier committed Apr 28, 2022
1 parent 035babf commit 3641bcc
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 22 deletions.
11 changes: 0 additions & 11 deletions drivers/video/fbdev/efifb.c
Original file line number Diff line number Diff line change
Expand Up @@ -351,17 +351,6 @@ static int efifb_probe(struct platform_device *dev)
char *option = NULL;
efi_memory_desc_t md;

/*
* Generic drivers must not be registered if a framebuffer exists.
* If a native driver was probed, the display hardware was already
* taken and attempting to use the system framebuffer is dangerous.
*/
if (num_registered_fb > 0) {
dev_err(&dev->dev,
"efifb: a framebuffer is already registered\n");
return -EINVAL;
}

if (screen_info.orig_video_isVGA != VIDEO_TYPE_EFI || pci_dev_disabled)
return -ENODEV;

Expand Down
11 changes: 0 additions & 11 deletions drivers/video/fbdev/simplefb.c
Original file line number Diff line number Diff line change
Expand Up @@ -413,17 +413,6 @@ static int simplefb_probe(struct platform_device *pdev)
struct simplefb_par *par;
struct resource *res, *mem;

/*
* Generic drivers must not be registered if a framebuffer exists.
* If a native driver was probed, the display hardware was already
* taken and attempting to use the system framebuffer is dangerous.
*/
if (num_registered_fb > 0) {
dev_err(&pdev->dev,
"simplefb: a framebuffer is already registered\n");
return -EINVAL;
}

if (fb_get_options("simplefb", NULL))
return -ENODEV;

Expand Down

0 comments on commit 3641bcc

Please sign in to comment.