Commit 0ba2fa8c authored by Thomas Zimmermann's avatar Thomas Zimmermann

fbdev: Add support for the nomodeset kernel parameter

Support the kernel's nomodeset parameter for all PCI-based fbdev
drivers that use aperture helpers to remove other, hardware-agnostic
graphics drivers.

The parameter is a simple way of using the firmware-provided scanout
buffer if the hardware's native driver is broken. The same effect
could be achieved with per-driver options, but the importance of the
graphics output for many users makes a single, unified approach
worthwhile.

With nomodeset specified, the fbdev driver module will not load. This
unifies behavior with similar DRM drivers. In DRM helpers, modules
first check the nomodeset parameter before registering the PCI
driver. As fbdev has no such module helpers, we have to modify each
driver individually.

The name 'nomodeset' is slightly misleading, but has been chosen for
historical reasons. Several drivers implemented it before it became a
general option for DRM. So keeping the existing name was preferred over
introducing a new one.

v2:
	* print a warning if a driver does not init (Helge)
	* wrap video_firmware_drivers_only() in helper
Signed-off-by: default avatarThomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: default avatarJavier Martinez Canillas <javierm@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20221111133024.9897-3-tzimmermann@suse.de
parent 9a758d87
...@@ -6,6 +6,7 @@ config FB_SM750 ...@@ -6,6 +6,7 @@ config FB_SM750
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
Frame buffer driver for the Silicon Motion SM750 chip Frame buffer driver for the Silicon Motion SM750 chip
with 2D accelearion and dual head support. with 2D accelearion and dual head support.
......
...@@ -1168,6 +1168,9 @@ static int __init lynxfb_init(void) ...@@ -1168,6 +1168,9 @@ static int __init lynxfb_init(void)
{ {
char *option; char *option;
if (fb_modesetting_disabled("sm750fb"))
return -ENODEV;
#ifdef MODULE #ifdef MODULE
option = g_option; option = g_option;
#else #else
......
...@@ -227,6 +227,7 @@ config FB_CIRRUS ...@@ -227,6 +227,7 @@ config FB_CIRRUS
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
This enables support for Cirrus Logic GD542x/543x based boards on This enables support for Cirrus Logic GD542x/543x based boards on
Amiga: SD64, Piccolo, Picasso II/II+, Picasso IV, or EGS Spectrum. Amiga: SD64, Piccolo, Picasso II/II+, Picasso IV, or EGS Spectrum.
...@@ -245,6 +246,7 @@ config FB_PM2 ...@@ -245,6 +246,7 @@ config FB_PM2
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
This is the frame buffer device driver for cards based on This is the frame buffer device driver for cards based on
the 3D Labs Permedia, Permedia 2 and Permedia 2V chips. the 3D Labs Permedia, Permedia 2 and Permedia 2V chips.
...@@ -340,6 +342,7 @@ config FB_CYBER2000 ...@@ -340,6 +342,7 @@ config FB_CYBER2000
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
This enables support for the Integraphics CyberPro 20x0 and 5000 This enables support for the Integraphics CyberPro 20x0 and 5000
VGA chips used in the Rebel.com Netwinder and other machines. VGA chips used in the Rebel.com Netwinder and other machines.
...@@ -504,6 +507,7 @@ config FB_CT65550 ...@@ -504,6 +507,7 @@ config FB_CT65550
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
This is the frame buffer device driver for the Chips & Technologies This is the frame buffer device driver for the Chips & Technologies
65550 graphics chip in PowerBooks. 65550 graphics chip in PowerBooks.
...@@ -514,6 +518,7 @@ config FB_ASILIANT ...@@ -514,6 +518,7 @@ config FB_ASILIANT
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
This is the frame buffer device driver for the Asiliant 69030 chipset This is the frame buffer device driver for the Asiliant 69030 chipset
...@@ -522,6 +527,7 @@ config FB_IMSTT ...@@ -522,6 +527,7 @@ config FB_IMSTT
depends on (FB = y) && PCI depends on (FB = y) && PCI
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select FB_MACMODES if PPC_PMAC select FB_MACMODES if PPC_PMAC
select VIDEO_NOMODESET
help help
The IMS Twin Turbo is a PCI-based frame buffer card bundled with The IMS Twin Turbo is a PCI-based frame buffer card bundled with
many Macintosh and compatible computers. many Macintosh and compatible computers.
...@@ -585,6 +591,7 @@ config FB_TGA ...@@ -585,6 +591,7 @@ config FB_TGA
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select BITREVERSE select BITREVERSE
select VIDEO_NOMODESET
help help
This is the frame buffer device driver for generic TGA and SFB+ This is the frame buffer device driver for generic TGA and SFB+
graphic cards. These include DEC ZLXp-E1, -E2 and -E3 PCI cards, graphic cards. These include DEC ZLXp-E1, -E2 and -E3 PCI cards,
...@@ -777,6 +784,7 @@ config FB_XVR500 ...@@ -777,6 +784,7 @@ config FB_XVR500
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
This is the framebuffer device for the Sun XVR-500 and similar This is the framebuffer device for the Sun XVR-500 and similar
graphics cards based upon the 3DLABS Wildcat chipset. The driver graphics cards based upon the 3DLABS Wildcat chipset. The driver
...@@ -790,6 +798,7 @@ config FB_XVR2500 ...@@ -790,6 +798,7 @@ config FB_XVR2500
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
This is the framebuffer device for the Sun XVR-2500 and similar This is the framebuffer device for the Sun XVR-2500 and similar
graphics cards based upon the 3DLABS Wildcat chipset. The driver graphics cards based upon the 3DLABS Wildcat chipset. The driver
...@@ -816,6 +825,7 @@ config FB_PVR2 ...@@ -816,6 +825,7 @@ config FB_PVR2
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
Say Y here if you have a PowerVR 2 card in your box. If you plan to Say Y here if you have a PowerVR 2 card in your box. If you plan to
run linux on your Dreamcast, you will have to say Y here. run linux on your Dreamcast, you will have to say Y here.
...@@ -881,6 +891,7 @@ config FB_NVIDIA ...@@ -881,6 +891,7 @@ config FB_NVIDIA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select BITREVERSE select BITREVERSE
select VGASTATE select VGASTATE
select VIDEO_NOMODESET
help help
This driver supports graphics boards with the nVidia chips, TNT This driver supports graphics boards with the nVidia chips, TNT
and newer. For very old chipsets, such as the RIVA128, then use and newer. For very old chipsets, such as the RIVA128, then use
...@@ -928,6 +939,7 @@ config FB_RIVA ...@@ -928,6 +939,7 @@ config FB_RIVA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select BITREVERSE select BITREVERSE
select VGASTATE select VGASTATE
select VIDEO_NOMODESET
help help
This driver supports graphics boards with the nVidia Riva/Geforce This driver supports graphics boards with the nVidia Riva/Geforce
chips. chips.
...@@ -972,6 +984,7 @@ config FB_I740 ...@@ -972,6 +984,7 @@ config FB_I740
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VGASTATE select VGASTATE
select VIDEO_NOMODESET
select FB_DDC select FB_DDC
help help
This driver supports graphics cards based on Intel740 chip. This driver supports graphics cards based on Intel740 chip.
...@@ -984,6 +997,7 @@ config FB_I810 ...@@ -984,6 +997,7 @@ config FB_I810
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VGASTATE select VGASTATE
select VIDEO_NOMODESET
help help
This driver supports the on-board graphics built in to the Intel 810 This driver supports the on-board graphics built in to the Intel 810
and 815 chipsets. Say Y if you have and plan to use such a board. and 815 chipsets. Say Y if you have and plan to use such a board.
...@@ -1034,6 +1048,7 @@ config FB_LE80578 ...@@ -1034,6 +1048,7 @@ config FB_LE80578
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
This driver supports the LE80578 (Vermilion Range) chipset This driver supports the LE80578 (Vermilion Range) chipset
...@@ -1051,6 +1066,7 @@ config FB_INTEL ...@@ -1051,6 +1066,7 @@ config FB_INTEL
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select BOOT_VESA_SUPPORT if FB_INTEL = y select BOOT_VESA_SUPPORT if FB_INTEL = y
select VIDEO_NOMODESET
depends on !DRM_I915 depends on !DRM_I915
help help
This driver supports the on-board graphics built in to the Intel This driver supports the on-board graphics built in to the Intel
...@@ -1088,6 +1104,7 @@ config FB_MATROX ...@@ -1088,6 +1104,7 @@ config FB_MATROX
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select FB_TILEBLITTING select FB_TILEBLITTING
select FB_MACMODES if PPC_PMAC select FB_MACMODES if PPC_PMAC
select VIDEO_NOMODESET
help help
Say Y here if you have a Matrox Millennium, Matrox Millennium II, Say Y here if you have a Matrox Millennium, Matrox Millennium II,
Matrox Mystique, Matrox Mystique 220, Matrox Productiva G100, Matrox Matrox Mystique, Matrox Mystique 220, Matrox Productiva G100, Matrox
...@@ -1208,6 +1225,7 @@ config FB_RADEON ...@@ -1208,6 +1225,7 @@ config FB_RADEON
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select FB_MACMODES if PPC select FB_MACMODES if PPC
select VIDEO_NOMODESET
help help
Choose this option if you want to use an ATI Radeon graphics card as Choose this option if you want to use an ATI Radeon graphics card as
a framebuffer device. There are both PCI and AGP versions. You a framebuffer device. There are both PCI and AGP versions. You
...@@ -1247,6 +1265,7 @@ config FB_ATY128 ...@@ -1247,6 +1265,7 @@ config FB_ATY128
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select FB_BACKLIGHT if FB_ATY128_BACKLIGHT select FB_BACKLIGHT if FB_ATY128_BACKLIGHT
select FB_MACMODES if PPC_PMAC select FB_MACMODES if PPC_PMAC
select VIDEO_NOMODESET
help help
This driver supports graphics boards with the ATI Rage128 chips. This driver supports graphics boards with the ATI Rage128 chips.
Say Y if you have such a graphics board and read Say Y if you have such a graphics board and read
...@@ -1271,6 +1290,7 @@ config FB_ATY ...@@ -1271,6 +1290,7 @@ config FB_ATY
select FB_BACKLIGHT if FB_ATY_BACKLIGHT select FB_BACKLIGHT if FB_ATY_BACKLIGHT
select FB_MACMODES if PPC select FB_MACMODES if PPC
select FB_ATY_CT if SPARC64 && PCI select FB_ATY_CT if SPARC64 && PCI
select VIDEO_NOMODESET
help help
This driver supports graphics boards with the ATI Mach64 chips. This driver supports graphics boards with the ATI Mach64 chips.
Say Y if you have such a graphics board. Say Y if you have such a graphics board.
...@@ -1321,6 +1341,7 @@ config FB_S3 ...@@ -1321,6 +1341,7 @@ config FB_S3
select FB_TILEBLITTING select FB_TILEBLITTING
select FB_SVGALIB select FB_SVGALIB
select VGASTATE select VGASTATE
select VIDEO_NOMODESET
select FONT_8x16 if FRAMEBUFFER_CONSOLE select FONT_8x16 if FRAMEBUFFER_CONSOLE
help help
Driver for graphics boards with S3 Trio / S3 Virge chip. Driver for graphics boards with S3 Trio / S3 Virge chip.
...@@ -1341,6 +1362,7 @@ config FB_SAVAGE ...@@ -1341,6 +1362,7 @@ config FB_SAVAGE
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VGASTATE select VGASTATE
select VIDEO_NOMODESET
help help
This driver supports notebooks and computers with S3 Savage PCI/AGP This driver supports notebooks and computers with S3 Savage PCI/AGP
chips. chips.
...@@ -1379,6 +1401,7 @@ config FB_SIS ...@@ -1379,6 +1401,7 @@ config FB_SIS
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select BOOT_VESA_SUPPORT if FB_SIS = y select BOOT_VESA_SUPPORT if FB_SIS = y
select FB_SIS_300 if !FB_SIS_315 select FB_SIS_300 if !FB_SIS_315
select VIDEO_NOMODESET
help help
This is the frame buffer device driver for the SiS 300, 315, 330 This is the frame buffer device driver for the SiS 300, 315, 330
and 340 series as well as XGI V3XT, V5, V8, Z7 graphics chipsets. and 340 series as well as XGI V3XT, V5, V8, Z7 graphics chipsets.
...@@ -1408,6 +1431,7 @@ config FB_VIA ...@@ -1408,6 +1431,7 @@ config FB_VIA
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select I2C_ALGOBIT select I2C_ALGOBIT
select VIDEO_NOMODESET
help help
This is the frame buffer device driver for Graphics chips of VIA This is the frame buffer device driver for Graphics chips of VIA
UniChrome (Pro) Family (CLE266,PM800/CN400,P4M800CE/P4M800Pro/ UniChrome (Pro) Family (CLE266,PM800/CN400,P4M800CE/P4M800Pro/
...@@ -1447,6 +1471,7 @@ config FB_NEOMAGIC ...@@ -1447,6 +1471,7 @@ config FB_NEOMAGIC
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VGASTATE select VGASTATE
select VIDEO_NOMODESET
help help
This driver supports notebooks with NeoMagic PCI chips. This driver supports notebooks with NeoMagic PCI chips.
Say Y if you have such a graphics card. Say Y if you have such a graphics card.
...@@ -1460,6 +1485,7 @@ config FB_KYRO ...@@ -1460,6 +1485,7 @@ config FB_KYRO
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
Say Y here if you have a STG4000 / Kyro / PowerVR 3 based Say Y here if you have a STG4000 / Kyro / PowerVR 3 based
graphics board. graphics board.
...@@ -1474,6 +1500,7 @@ config FB_3DFX ...@@ -1474,6 +1500,7 @@ config FB_3DFX
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_MODE_HELPERS select FB_MODE_HELPERS
select VIDEO_NOMODESET
help help
This driver supports graphics boards with the 3Dfx Banshee, This driver supports graphics boards with the 3Dfx Banshee,
Voodoo3 or VSA-100 (aka Voodoo4/5) chips. Say Y if you have Voodoo3 or VSA-100 (aka Voodoo4/5) chips. Say Y if you have
...@@ -1503,6 +1530,7 @@ config FB_VOODOO1 ...@@ -1503,6 +1530,7 @@ config FB_VOODOO1
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
Say Y here if you have a 3Dfx Voodoo Graphics (Voodoo1/sst1) or Say Y here if you have a 3Dfx Voodoo Graphics (Voodoo1/sst1) or
Voodoo2 (cvg) based graphics card. Voodoo2 (cvg) based graphics card.
...@@ -1524,6 +1552,7 @@ config FB_VT8623 ...@@ -1524,6 +1552,7 @@ config FB_VT8623
select FB_TILEBLITTING select FB_TILEBLITTING
select FB_SVGALIB select FB_SVGALIB
select VGASTATE select VGASTATE
select VIDEO_NOMODESET
select FONT_8x16 if FRAMEBUFFER_CONSOLE select FONT_8x16 if FRAMEBUFFER_CONSOLE
help help
Driver for CastleRock integrated graphics core in the Driver for CastleRock integrated graphics core in the
...@@ -1537,6 +1566,7 @@ config FB_TRIDENT ...@@ -1537,6 +1566,7 @@ config FB_TRIDENT
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select FB_DDC select FB_DDC
select FB_MODE_HELPERS select FB_MODE_HELPERS
select VIDEO_NOMODESET
help help
This is the frame buffer device driver for Trident PCI/AGP chipsets. This is the frame buffer device driver for Trident PCI/AGP chipsets.
Supported chipset families are TGUI 9440/96XX, 3DImage, Blade3D Supported chipset families are TGUI 9440/96XX, 3DImage, Blade3D
...@@ -1560,6 +1590,7 @@ config FB_ARK ...@@ -1560,6 +1590,7 @@ config FB_ARK
select FB_TILEBLITTING select FB_TILEBLITTING
select FB_SVGALIB select FB_SVGALIB
select VGASTATE select VGASTATE
select VIDEO_NOMODESET
select FONT_8x16 if FRAMEBUFFER_CONSOLE select FONT_8x16 if FRAMEBUFFER_CONSOLE
help help
Driver for PCI graphics boards with ARK 2000PV chip Driver for PCI graphics boards with ARK 2000PV chip
...@@ -1571,6 +1602,7 @@ config FB_PM3 ...@@ -1571,6 +1602,7 @@ config FB_PM3
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
This is the frame buffer device driver for the 3DLabs Permedia3 This is the frame buffer device driver for the 3DLabs Permedia3
chipset, used in Formac ProFormance III, 3DLabs Oxygen VX1 & chipset, used in Formac ProFormance III, 3DLabs Oxygen VX1 &
...@@ -1583,6 +1615,7 @@ config FB_CARMINE ...@@ -1583,6 +1615,7 @@ config FB_CARMINE
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
This is the frame buffer device driver for the Fujitsu Carmine chip. This is the frame buffer device driver for the Fujitsu Carmine chip.
The driver provides two independent frame buffer devices. The driver provides two independent frame buffer devices.
...@@ -1961,6 +1994,7 @@ config FB_IBM_GXT4500 ...@@ -1961,6 +1994,7 @@ config FB_IBM_GXT4500
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
Say Y here to enable support for the IBM GXT4000P/6000P and Say Y here to enable support for the IBM GXT4000P/6000P and
GXT4500P/6500P display adaptor based on Raster Engine RC1000, GXT4500P/6500P display adaptor based on Raster Engine RC1000,
...@@ -2101,6 +2135,7 @@ config FB_MB862XX ...@@ -2101,6 +2135,7 @@ config FB_MB862XX
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
Frame buffer driver for Fujitsu Carmine/Coral-P(A)/Lime controllers. Frame buffer driver for Fujitsu Carmine/Coral-P(A)/Lime controllers.
...@@ -2188,6 +2223,7 @@ config FB_HYPERV ...@@ -2188,6 +2223,7 @@ config FB_HYPERV
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select FB_DEFERRED_IO select FB_DEFERRED_IO
select DMA_CMA if HAVE_DMA_CONTIGUOUS && CMA select DMA_CMA if HAVE_DMA_CONTIGUOUS && CMA
select VIDEO_NOMODESET
help help
This framebuffer driver supports Microsoft Hyper-V Synthetic Video. This framebuffer driver supports Microsoft Hyper-V Synthetic Video.
...@@ -2230,6 +2266,7 @@ config FB_SM712 ...@@ -2230,6 +2266,7 @@ config FB_SM712
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
Frame buffer driver for the Silicon Motion SM710, SM712, SM721 Frame buffer driver for the Silicon Motion SM710, SM712, SM721
and SM722 chips. and SM722 chips.
......
...@@ -1187,7 +1187,12 @@ static int __init arkfb_init(void) ...@@ -1187,7 +1187,12 @@ static int __init arkfb_init(void)
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("arkfb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("arkfb", &option)) if (fb_get_options("arkfb", &option))
return -ENODEV; return -ENODEV;
......
...@@ -616,6 +616,9 @@ static struct pci_driver asiliantfb_driver = { ...@@ -616,6 +616,9 @@ static struct pci_driver asiliantfb_driver = {
static int __init asiliantfb_init(void) static int __init asiliantfb_init(void)
{ {
if (fb_modesetting_disabled("asiliantfb"))
return -ENODEV;
if (fb_get_options("asiliantfb", NULL)) if (fb_get_options("asiliantfb", NULL))
return -ENODEV; return -ENODEV;
......
...@@ -2503,7 +2503,12 @@ static int aty128fb_init(void) ...@@ -2503,7 +2503,12 @@ static int aty128fb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("aty128fb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("aty128fb", &option)) if (fb_get_options("aty128fb", &option))
return -ENODEV; return -ENODEV;
aty128fb_setup(option); aty128fb_setup(option);
......
...@@ -3965,7 +3965,12 @@ static int __init atyfb_init(void) ...@@ -3965,7 +3965,12 @@ static int __init atyfb_init(void)
int err1 = 1, err2 = 1; int err1 = 1, err2 = 1;
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("atyfb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("atyfb", &option)) if (fb_get_options("atyfb", &option))
return -ENODEV; return -ENODEV;
atyfb_setup(option); atyfb_setup(option);
......
...@@ -2607,7 +2607,12 @@ static int __init radeonfb_init (void) ...@@ -2607,7 +2607,12 @@ static int __init radeonfb_init (void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("radeonfb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("radeonfb", &option)) if (fb_get_options("radeonfb", &option))
return -ENODEV; return -ENODEV;
radeonfb_setup(option); radeonfb_setup(option);
......
...@@ -773,6 +773,9 @@ static struct pci_driver carmine_pci_driver = { ...@@ -773,6 +773,9 @@ static struct pci_driver carmine_pci_driver = {
static int __init carminefb_init(void) static int __init carminefb_init(void)
{ {
if (fb_modesetting_disabled("carminefb"))
return -ENODEV;
if (!(fb_displays & if (!(fb_displays &
(CARMINE_USE_DISPLAY0 | CARMINE_USE_DISPLAY1))) { (CARMINE_USE_DISPLAY0 | CARMINE_USE_DISPLAY1))) {
printk(KERN_ERR "If you disable both displays than you don't " printk(KERN_ERR "If you disable both displays than you don't "
......
...@@ -506,6 +506,9 @@ static struct pci_driver chipsfb_driver = { ...@@ -506,6 +506,9 @@ static struct pci_driver chipsfb_driver = {
int __init chips_init(void) int __init chips_init(void)
{ {
if (fb_modesetting_disabled("chipsfb"))
return -ENODEV;
if (fb_get_options("chipsfb", NULL)) if (fb_get_options("chipsfb", NULL))
return -ENODEV; return -ENODEV;
......
...@@ -2359,7 +2359,12 @@ static int __init cirrusfb_init(void) ...@@ -2359,7 +2359,12 @@ static int __init cirrusfb_init(void)
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("cirrusfb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("cirrusfb", &option)) if (fb_get_options("cirrusfb", &option))
return -ENODEV; return -ENODEV;
cirrusfb_setup(option); cirrusfb_setup(option);
......
...@@ -40,6 +40,7 @@ ...@@ -40,6 +40,7 @@
#include <asm/fb.h> #include <asm/fb.h>
#include <video/nomodeset.h>
#include <video/vga.h> #include <video/vga.h>
/* /*
...@@ -1844,4 +1845,18 @@ int fb_new_modelist(struct fb_info *info) ...@@ -1844,4 +1845,18 @@ int fb_new_modelist(struct fb_info *info)
return 0; return 0;
} }
#if defined(CONFIG_VIDEO_NOMODESET)
bool fb_modesetting_disabled(const char *drvname)
{
bool fwonly = video_firmware_drivers_only();
if (fwonly)
pr_warn("Driver %s not loading because of nomodeset parameter\n",
drvname);
return fwonly;
}
EXPORT_SYMBOL(fb_modesetting_disabled);
#endif
MODULE_LICENSE("GPL"); MODULE_LICENSE("GPL");
...@@ -48,7 +48,6 @@ ...@@ -48,7 +48,6 @@
#include <linux/i2c.h> #include <linux/i2c.h>
#include <linux/i2c-algo-bit.h> #include <linux/i2c-algo-bit.h>
#ifdef __arm__ #ifdef __arm__
#include <asm/mach-types.h> #include <asm/mach-types.h>
#endif #endif
...@@ -1876,7 +1875,12 @@ static int __init cyber2000fb_init(void) ...@@ -1876,7 +1875,12 @@ static int __init cyber2000fb_init(void)
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("CyberPro"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("cyber2000fb", &option)) if (fb_get_options("cyber2000fb", &option))
return -ENODEV; return -ENODEV;
cyber2000fb_setup(option); cyber2000fb_setup(option);
......
...@@ -15,6 +15,7 @@ config FB_GEODE_LX ...@@ -15,6 +15,7 @@ config FB_GEODE_LX
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
Framebuffer driver for the display controller integrated into the Framebuffer driver for the display controller integrated into the
AMD Geode LX processors. AMD Geode LX processors.
...@@ -30,6 +31,7 @@ config FB_GEODE_GX ...@@ -30,6 +31,7 @@ config FB_GEODE_GX
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
Framebuffer driver for the display controller integrated into the Framebuffer driver for the display controller integrated into the
AMD Geode GX processors. AMD Geode GX processors.
...@@ -45,6 +47,7 @@ config FB_GEODE_GX1 ...@@ -45,6 +47,7 @@ config FB_GEODE_GX1
select FB_CFB_FILLRECT select FB_CFB_FILLRECT
select FB_CFB_COPYAREA select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT select FB_CFB_IMAGEBLIT
select VIDEO_NOMODESET
help help
Framebuffer driver for the display controller integrated into the Framebuffer driver for the display controller integrated into the
AMD Geode GX1 processor. AMD Geode GX1 processor.
......
...@@ -446,7 +446,12 @@ static int __init gx1fb_init(void) ...@@ -446,7 +446,12 @@ static int __init gx1fb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("gx1fb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("gx1fb", &option)) if (fb_get_options("gx1fb", &option))
return -ENODEV; return -ENODEV;
gx1fb_setup(option); gx1fb_setup(option);
......
...@@ -511,7 +511,12 @@ static int __init gxfb_init(void) ...@@ -511,7 +511,12 @@ static int __init gxfb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("gxfb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("gxfb", &option)) if (fb_get_options("gxfb", &option))
return -ENODEV; return -ENODEV;
......
...@@ -647,7 +647,12 @@ static int __init lxfb_init(void) ...@@ -647,7 +647,12 @@ static int __init lxfb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("lxfb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("lxfb", &option)) if (fb_get_options("lxfb", &option))
return -ENODEV; return -ENODEV;
......
...@@ -779,6 +779,9 @@ static struct pci_driver gxt4500_driver = { ...@@ -779,6 +779,9 @@ static struct pci_driver gxt4500_driver = {
static int gxt4500_init(void) static int gxt4500_init(void)
{ {
if (fb_modesetting_disabled("gxt4500"))
return -ENODEV;
#ifndef MODULE #ifndef MODULE
if (fb_get_options("gxt4500", &mode_option)) if (fb_get_options("gxt4500", &mode_option))
return -ENODEV; return -ENODEV;
......
...@@ -59,7 +59,6 @@ ...@@ -59,7 +59,6 @@
#include <linux/hyperv.h> #include <linux/hyperv.h>
/* Hyper-V Synthetic Video Protocol definitions and structures */ /* Hyper-V Synthetic Video Protocol definitions and structures */
#define MAX_VMBUS_PKT_SIZE 0x4000 #define MAX_VMBUS_PKT_SIZE 0x4000
...@@ -1363,6 +1362,9 @@ static int __init hvfb_drv_init(void) ...@@ -1363,6 +1362,9 @@ static int __init hvfb_drv_init(void)
{ {
int ret; int ret;
if (fb_modesetting_disabled("hyper_fb"))
return -ENODEV;
ret = vmbus_driver_register(&hvfb_drv); ret = vmbus_driver_register(&hvfb_drv);
if (ret != 0) if (ret != 0)
return ret; return ret;
......
...@@ -1285,7 +1285,12 @@ static int __init i740fb_init(void) ...@@ -1285,7 +1285,12 @@ static int __init i740fb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("i740fb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("i740fb", &option)) if (fb_get_options("i740fb", &option))
return -ENODEV; return -ENODEV;
i740fb_setup(option); i740fb_setup(option);
......
...@@ -2143,6 +2143,9 @@ static int i810fb_init(void) ...@@ -2143,6 +2143,9 @@ static int i810fb_init(void)
{ {
char *option = NULL; char *option = NULL;
if (fb_modesetting_disabled("i810fb"))
return -ENODEV;
if (fb_get_options("i810fb", &option)) if (fb_get_options("i810fb", &option))
return -ENODEV; return -ENODEV;
i810fb_setup(option); i810fb_setup(option);
...@@ -2159,6 +2162,9 @@ static int i810fb_init(void) ...@@ -2159,6 +2162,9 @@ static int i810fb_init(void)
static int i810fb_init(void) static int i810fb_init(void)
{ {
if (fb_modesetting_disabled("i810fb"))
return -ENODEV;
hsync1 *= 1000; hsync1 *= 1000;
hsync2 *= 1000; hsync2 *= 1000;
......
...@@ -1617,7 +1617,12 @@ static int __init imsttfb_init(void) ...@@ -1617,7 +1617,12 @@ static int __init imsttfb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("imsttfb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("imsttfb", &option)) if (fb_get_options("imsttfb", &option))
return -ENODEV; return -ENODEV;
......
...@@ -389,6 +389,9 @@ static int __init intelfb_init(void) ...@@ -389,6 +389,9 @@ static int __init intelfb_init(void)
if (idonly) if (idonly)
return -ENODEV; return -ENODEV;
if (fb_modesetting_disabled("intelfb"))
return -ENODEV;
#ifndef MODULE #ifndef MODULE
if (fb_get_options("intelfb", &option)) if (fb_get_options("intelfb", &option))
return -ENODEV; return -ENODEV;
......
...@@ -789,7 +789,12 @@ static int __init kyrofb_init(void) ...@@ -789,7 +789,12 @@ static int __init kyrofb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("kyrofb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("kyrofb", &option)) if (fb_get_options("kyrofb", &option))
return -ENODEV; return -ENODEV;
kyrofb_setup(option); kyrofb_setup(option);
......
...@@ -2314,6 +2314,9 @@ static void __init matroxfb_init_params(void) { ...@@ -2314,6 +2314,9 @@ static void __init matroxfb_init_params(void) {
static int __init matrox_init(void) { static int __init matrox_init(void) {
int err; int err;
if (fb_modesetting_disabled("matroxfb"))
return -ENODEV;
matroxfb_init_params(); matroxfb_init_params();
err = pci_register_driver(&matroxfb_driver); err = pci_register_driver(&matroxfb_driver);
dev = -1; /* accept all new devices... */ dev = -1; /* accept all new devices... */
......
...@@ -1181,6 +1181,9 @@ static int mb862xxfb_init(void) ...@@ -1181,6 +1181,9 @@ static int mb862xxfb_init(void)
{ {
int ret = -ENODEV; int ret = -ENODEV;
if (fb_modesetting_disabled(DRV_NAME))
return -ENODEV;
#if defined(CONFIG_FB_MB862XX_LIME) #if defined(CONFIG_FB_MB862XX_LIME)
ret = platform_driver_register(&of_platform_mb862xxfb_driver); ret = platform_driver_register(&of_platform_mb862xxfb_driver);
#endif #endif
......
...@@ -2209,7 +2209,12 @@ static int __init neofb_init(void) ...@@ -2209,7 +2209,12 @@ static int __init neofb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("neofb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("neofb", &option)) if (fb_get_options("neofb", &option))
return -ENODEV; return -ENODEV;
neofb_setup(option); neofb_setup(option);
......
...@@ -1521,7 +1521,12 @@ static int nvidiafb_init(void) ...@@ -1521,7 +1521,12 @@ static int nvidiafb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("nvidiafb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("nvidiafb", &option)) if (fb_get_options("nvidiafb", &option))
return -ENODEV; return -ENODEV;
nvidiafb_setup(option); nvidiafb_setup(option);
......
...@@ -1799,7 +1799,12 @@ static int __init pm2fb_init(void) ...@@ -1799,7 +1799,12 @@ static int __init pm2fb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("pm2fb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("pm2fb", &option)) if (fb_get_options("pm2fb", &option))
return -ENODEV; return -ENODEV;
pm2fb_setup(option); pm2fb_setup(option);
......
...@@ -1540,7 +1540,12 @@ static int __init pm3fb_init(void) ...@@ -1540,7 +1540,12 @@ static int __init pm3fb_init(void)
*/ */
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("pm3fb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("pm3fb", &option)) if (fb_get_options("pm3fb", &option))
return -ENODEV; return -ENODEV;
pm3fb_setup(option); pm3fb_setup(option);
......
...@@ -1082,7 +1082,12 @@ static int __init pvr2fb_init(void) ...@@ -1082,7 +1082,12 @@ static int __init pvr2fb_init(void)
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("pvr2fb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("pvr2fb", &option)) if (fb_get_options("pvr2fb", &option))
return -ENODEV; return -ENODEV;
pvr2fb_setup(option); pvr2fb_setup(option);
......
...@@ -2165,7 +2165,12 @@ static int rivafb_init(void) ...@@ -2165,7 +2165,12 @@ static int rivafb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("rivafb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("rivafb", &option)) if (fb_get_options("rivafb", &option))
return -ENODEV; return -ENODEV;
rivafb_setup(option); rivafb_setup(option);
......
...@@ -1558,7 +1558,12 @@ static int __init s3fb_init(void) ...@@ -1558,7 +1558,12 @@ static int __init s3fb_init(void)
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("s3fb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("s3fb", &option)) if (fb_get_options("s3fb", &option))
return -ENODEV; return -ENODEV;
s3fb_setup(option); s3fb_setup(option);
......
...@@ -2556,6 +2556,9 @@ static int __init savagefb_init(void) ...@@ -2556,6 +2556,9 @@ static int __init savagefb_init(void)
DBG("savagefb_init"); DBG("savagefb_init");
if (fb_modesetting_disabled("savagefb"))
return -ENODEV;
if (fb_get_options("savagefb", &option)) if (fb_get_options("savagefb", &option))
return -ENODEV; return -ENODEV;
......
...@@ -6588,7 +6588,12 @@ static int __init sisfb_init(void) ...@@ -6588,7 +6588,12 @@ static int __init sisfb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *options = NULL; char *options = NULL;
#endif
if (fb_modesetting_disabled("sisfb"))
return -ENODEV;
#ifndef MODULE
if(fb_get_options("sisfb", &options)) if(fb_get_options("sisfb", &options))
return -ENODEV; return -ENODEV;
......
...@@ -987,7 +987,12 @@ static int __init xxxfb_init(void) ...@@ -987,7 +987,12 @@ static int __init xxxfb_init(void)
*/ */
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("xxxfb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("xxxfb", &option)) if (fb_get_options("xxxfb", &option))
return -ENODEV; return -ENODEV;
xxxfb_setup(option); xxxfb_setup(option);
......
...@@ -1756,6 +1756,9 @@ static int __init sm712fb_init(void) ...@@ -1756,6 +1756,9 @@ static int __init sm712fb_init(void)
{ {
char *option = NULL; char *option = NULL;
if (fb_modesetting_disabled("sm712fb"))
return -ENODEV;
if (fb_get_options("sm712fb", &option)) if (fb_get_options("sm712fb", &option))
return -ENODEV; return -ENODEV;
if (option && *option) if (option && *option)
......
...@@ -1503,6 +1503,9 @@ static int sstfb_init(void) ...@@ -1503,6 +1503,9 @@ static int sstfb_init(void)
{ {
char *option = NULL; char *option = NULL;
if (fb_modesetting_disabled("sstfb"))
return -ENODEV;
if (fb_get_options("sstfb", &option)) if (fb_get_options("sstfb", &option))
return -ENODEV; return -ENODEV;
sstfb_setup(option); sstfb_setup(option);
......
...@@ -247,6 +247,9 @@ static struct pci_driver s3d_driver = { ...@@ -247,6 +247,9 @@ static struct pci_driver s3d_driver = {
static int __init s3d_init(void) static int __init s3d_init(void)
{ {
if (fb_modesetting_disabled("s3d"))
return -ENODEV;
if (fb_get_options("s3d", NULL)) if (fb_get_options("s3d", NULL))
return -ENODEV; return -ENODEV;
......
...@@ -430,6 +430,9 @@ static struct pci_driver e3d_driver = { ...@@ -430,6 +430,9 @@ static struct pci_driver e3d_driver = {
static int __init e3d_init(void) static int __init e3d_init(void)
{ {
if (fb_modesetting_disabled("e3d"))
return -ENODEV;
if (fb_get_options("e3d", NULL)) if (fb_get_options("e3d", NULL))
return -ENODEV; return -ENODEV;
......
...@@ -1632,7 +1632,12 @@ static int __init tdfxfb_init(void) ...@@ -1632,7 +1632,12 @@ static int __init tdfxfb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("tdfxfb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("tdfxfb", &option)) if (fb_get_options("tdfxfb", &option))
return -ENODEV; return -ENODEV;
......
...@@ -1597,7 +1597,12 @@ static int tgafb_init(void) ...@@ -1597,7 +1597,12 @@ static int tgafb_init(void)
int status; int status;
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("tgafb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("tgafb", &option)) if (fb_get_options("tgafb", &option))
return -ENODEV; return -ENODEV;
tgafb_setup(option); tgafb_setup(option);
......
...@@ -1811,7 +1811,12 @@ static int __init tridentfb_init(void) ...@@ -1811,7 +1811,12 @@ static int __init tridentfb_init(void)
{ {
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("tridentfb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("tridentfb", &option)) if (fb_get_options("tridentfb", &option))
return -ENODEV; return -ENODEV;
tridentfb_setup(option); tridentfb_setup(option);
......
...@@ -1057,7 +1057,12 @@ static int __init vmlfb_init(void) ...@@ -1057,7 +1057,12 @@ static int __init vmlfb_init(void)
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("vmlfb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options(MODULE_NAME, &option)) if (fb_get_options(MODULE_NAME, &option))
return -ENODEV; return -ENODEV;
#endif #endif
......
...@@ -725,6 +725,9 @@ static int __init via_core_init(void) ...@@ -725,6 +725,9 @@ static int __init via_core_init(void)
{ {
int ret; int ret;
if (fb_modesetting_disabled("viafb"))
return -ENODEV;
ret = viafb_init(); ret = viafb_init();
if (ret) if (ret)
return ret; return ret;
......
...@@ -920,7 +920,12 @@ static int __init vt8623fb_init(void) ...@@ -920,7 +920,12 @@ static int __init vt8623fb_init(void)
#ifndef MODULE #ifndef MODULE
char *option = NULL; char *option = NULL;
#endif
if (fb_modesetting_disabled("vt8623fb"))
return -ENODEV;
#ifndef MODULE
if (fb_get_options("vt8623fb", &option)) if (fb_get_options("vt8623fb", &option))
return -ENODEV; return -ENODEV;
......
...@@ -804,6 +804,15 @@ extern int fb_find_mode(struct fb_var_screeninfo *var, ...@@ -804,6 +804,15 @@ extern int fb_find_mode(struct fb_var_screeninfo *var,
const struct fb_videomode *default_mode, const struct fb_videomode *default_mode,
unsigned int default_bpp); unsigned int default_bpp);
#if defined(CONFIG_VIDEO_NOMODESET)
bool fb_modesetting_disabled(const char *drvname);
#else
bool fb_modesetting_disabled(const char *drvname)
{
return false;
}
#endif
/* Convenience logging macros */ /* Convenience logging macros */
#define fb_err(fb_info, fmt, ...) \ #define fb_err(fb_info, fmt, ...) \
pr_err("fb%d: " fmt, (fb_info)->node, ##__VA_ARGS__) pr_err("fb%d: " fmt, (fb_info)->node, ##__VA_ARGS__)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment