linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Javier Martinez Canillas <javierm@redhat.com>
To: linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org
Cc: "Javier Martinez Canillas" <javierm@redhat.com>,
	"Heiko Stübner" <heiko@sntech.de>,
	"James (Qian) Wang" <james.qian.wang@arm.com>,
	"Alexey Brodkin" <abrodkin@synopsys.com>,
	"Alison Wang" <alison.wang@nxp.com>,
	"Anitha Chrisanthus" <anitha.chrisanthus@intel.com>,
	"Boris Brezillon" <bbrezillon@kernel.org>,
	"Brian Starkey" <brian.starkey@arm.com>,
	"Chen-Yu Tsai" <wens@csie.org>,
	"Chun-Kuang Hu" <chunkuang.hu@kernel.org>,
	"Deepak Rawat" <drawat.floss@gmail.com>,
	"Edmund Dea" <edmund.j.dea@intel.com>,
	"Hyun Kwon" <hyun.kwon@xilinx.com>,
	"Inki Dae" <inki.dae@samsung.com>,
	"Joel Stanley" <joel@jms.id.au>,
	"Joonyoung Shim" <jy0922.shim@samsung.com>,
	"Jyri Sarha" <jyri.sarha@iki.fi>,
	"Kieran Bingham" <kieran.bingham+renesas@ideasonboard.com>,
	"Laurent Pinchart" <laurent.pinchart@ideasonboard.com>,
	"Laurentiu Palcu" <laurentiu.palcu@oss.nxp.com>,
	"Linus Walleij" <linus.walleij@linaro.org>,
	"Liviu Dudau" <liviu.dudau@arm.com>,
	"Lucas Stach" <l.stach@pengutronix.de>,
	"Marek Vasut" <marex@denx.de>,
	"Maxime Ripard" <mripard@kernel.org>,
	"Neil Armstrong" <narmstrong@baylibre.com>,
	"Oleksandr Andrushchenko" <oleksandr_andrushchenko@epam.com>,
	"Patrik Jakobsson" <patrik.r.jakobsson@gmail.com>,
	"Paul Cercueil" <paul@crapouillou.net>,
	"Philipp Zabel" <p.zabel@pengutronix.de>,
	"Philippe Cornu" <philippe.cornu@foss.st.com>,
	"Rob Clark" <robdclark@gmail.com>,
	"Russell King" <linux@armlinux.org.uk>,
	"Sam Ravnborg" <sam@ravnborg.org>,
	"Sandy Huang" <hjc@rock-chips.com>, "Sean Paul" <sean@poorly.run>,
	"Stefan Agner" <stefan@agner.ch>,
	"Thierry Reding" <thierry.reding@gmail.com>,
	"Thomas Zimmermann" <tzimmermann@suse.de>,
	"Tian Tao" <tiantao6@hisilicon.com>,
	"Tomi Valkeinen" <tomba@kernel.org>,
	"Xinliang Liu" <xinliang.liu@linaro.org>,
	"Yannick Fertre" <yannick.fertre@foss.st.com>
Subject: [PATCH v2 00/37] drm: Make drivers to honour the nomodeset parameter
Date: Fri, 17 Dec 2021 01:37:15 +0100	[thread overview]
Message-ID: <20211217003752.3946210-1-javierm@redhat.com> (raw)

The nomodeset kernel command line parameter is used to prevent the KMS/DRM
drivers to be registered/probed. But only a few drivers implement support
for this and most DRM drivers just ignore it.

This patch series is a v2 to make DRM drivers to honour nomodeset. It is
posted as separate patches to make easier for drivers maintainers to ack
or pick them independently at their own pace.

The drm_module_{pci,platform}_driver() helper macros are added, which are
just wrappers around module_{pci,platform}_driver() but adding a check for
drm_firmware_drivers_only() and returning -ENODEV if that is true.

PCI and platform DRM drivers are then modified in the following patches to
make use of those macros.

For drivers that have custom module init/exit, the check is added to these
functions instead. Since the drm_*_module_driver() macros are only for the
default case when the init/exit just register/unregister the driver type.

In v1 all KMS/DRM drivers were included but v2 only includes KMS drivers,
and only the the PCI and platform DRM drivers. A follow-up series might
do the same for rendering-only and USB/SPI/I2C drivers, but it will need
more discussion to agree if that's desirable.

I've built tested with 'make allmodconfig && make M=drivers/gpu/drm' but I
don't have hardware to test the drivers, so review/testing is appreciated.

Best regards,
Javier

Changes in v2:
- Add drm_module_{pci,platform}_driver() macros and put the check there
  (Thomas Zimmermann).
- Use the drm_module_*_driver() macros if possible (Thomas Zimmermann).
- Leave the DRM drivers that don't set the DRIVER_MODESET driver feature
  (Lucas Stach).
- Leave USB/SPI/I2C drivers and only include PCI and platform ones
  (Noralf Trønnes).
- Add collected Reviewed-by tags

Javier Martinez Canillas (37):
  drm: Add drm_module_{pci,platform}_driver() helper macros
  drm/hisilicon/hibmc: Use drm_module_pci_driver() to register the
    driver
  drm/komeda: Use drm_module_platform_driver() to register the driver
  drm/arm/hdlcd: Use drm_module_platform_driver() to register the driver
  drm/malidp: Use drm_module_platform_driver() to register the driver
  drm/aspeed: Use drm_module_platform_driver() to register the driver
  drm/atmel-hlcdc: Use drm_module_platform_driver() to register the
    driver
  drm/fsl-dcu: Use drm_module_platform_driver() to register the driver
  drm/hisilicon/kirin: Use drm_module_platform_driver() to register the
    driver
  drm/imx/dcss: Use drm_module_platform_driver() to register the driver
  drm/kmb: Use drm_module_platform_driver() to register the driver
  drm/meson: Use drm_module_platform_driver() to register the driver
  drm: mxsfb: Use drm_module_platform_driver() to register the driver
  drm/shmobile: Use drm_module_platform_driver() to register the driver
  drm/stm: Use drm_module_platform_driver() to register the driver
  drm/sun4i: Use drm_module_platform_driver() to register the driver
  drm/tidss: Use drm_module_platform_driver() to register the driver
  drm/arc: Use drm_module_platform_driver() to register the driver
  drm/tve200: Use drm_module_platform_driver() to register the driver
  drm/xlnx: Use drm_module_platform_driver() to register the driver
  drm/armada: Add support for the nomodeset kernel parameter
  drm/exynos: Add support for the nomodeset kernel parameter
  drm/gma500: Add support for the nomodeset kernel parameter
  drm/hyperv: Add support for the nomodeset kernel parameter
  drm/imx: Add support for the nomodeset kernel parameter
  drm/ingenic: Add support for the nomodeset kernel parameter
  drm/mcde: Add support for the nomodeset kernel parameter
  drm/mediatek: Add support for the nomodeset kernel parameter
  drm/msm: Add support for the nomodeset kernel parameter
  drm/omap: Add support for the nomodeset kernel parameter
  drm: rcar-du: Add support for the nomodeset kernel parameter
  drm/rockchip: Add support for the nomodeset kernel parameter
  drm/sprd: Add support for the nomodeset kernel parameter
  drm/sti: Add support for the nomodeset kernel parameter
  drm/tegra: Add support for the nomodeset kernel parameter
  drm/tilcdc: Add support for the nomodeset kernel parameter
  drm/xen: Add support for the nomodeset kernel parameter

 .../gpu/drm/arm/display/komeda/komeda_drv.c   |  3 +-
 drivers/gpu/drm/arm/hdlcd_drv.c               |  2 +-
 drivers/gpu/drm/arm/malidp_drv.c              |  2 +-
 drivers/gpu/drm/armada/armada_drv.c           |  3 ++
 drivers/gpu/drm/aspeed/aspeed_gfx_drv.c       |  2 +-
 drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c  |  2 +-
 drivers/gpu/drm/exynos/exynos_drm_drv.c       |  3 ++
 drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c     |  2 +-
 drivers/gpu/drm/gma500/psb_drv.c              |  3 ++
 .../gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c   |  2 +-
 .../gpu/drm/hisilicon/kirin/kirin_drm_drv.c   |  2 +-
 drivers/gpu/drm/hyperv/hyperv_drm_drv.c       |  3 ++
 drivers/gpu/drm/imx/dcss/dcss-drv.c           |  2 +-
 drivers/gpu/drm/imx/imx-drm-core.c            |  3 ++
 drivers/gpu/drm/ingenic/ingenic-drm-drv.c     |  3 ++
 drivers/gpu/drm/kmb/kmb_drv.c                 |  2 +-
 drivers/gpu/drm/mcde/mcde_drv.c               |  3 ++
 drivers/gpu/drm/mediatek/mtk_drm_drv.c        |  3 ++
 drivers/gpu/drm/meson/meson_drv.c             |  2 +-
 drivers/gpu/drm/msm/msm_drv.c                 |  3 ++
 drivers/gpu/drm/mxsfb/mxsfb_drv.c             |  2 +-
 drivers/gpu/drm/omapdrm/omap_drv.c            |  3 ++
 drivers/gpu/drm/rcar-du/rcar_du_drv.c         |  3 ++
 drivers/gpu/drm/rockchip/rockchip_drm_drv.c   |  3 ++
 drivers/gpu/drm/shmobile/shmob_drm_drv.c      |  2 +-
 drivers/gpu/drm/sprd/sprd_drm.c               |  3 ++
 drivers/gpu/drm/sti/sti_drv.c                 |  3 ++
 drivers/gpu/drm/stm/drv.c                     |  2 +-
 drivers/gpu/drm/sun4i/sun4i_drv.c             |  2 +-
 drivers/gpu/drm/tegra/drm.c                   |  3 ++
 drivers/gpu/drm/tidss/tidss_drv.c             |  2 +-
 drivers/gpu/drm/tilcdc/tilcdc_drv.c           |  3 ++
 drivers/gpu/drm/tiny/arcpgu.c                 |  2 +-
 drivers/gpu/drm/tve200/tve200_drv.c           |  2 +-
 drivers/gpu/drm/xen/xen_drm_front.c           |  3 ++
 drivers/gpu/drm/xlnx/zynqmp_dpsub.c           |  2 +-
 include/drm/drm_drv.h                         | 50 +++++++++++++++++++
 37 files changed, 121 insertions(+), 19 deletions(-)

-- 
2.33.1


             reply	other threads:[~2021-12-17  0:38 UTC|newest]

Thread overview: 52+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-17  0:37 Javier Martinez Canillas [this message]
2021-12-17  0:37 ` [PATCH v2 01/37] drm: Add drm_module_{pci,platform}_driver() helper macros Javier Martinez Canillas
2021-12-17 14:31   ` Thomas Zimmermann
2021-12-17  0:37 ` [PATCH v2 02/37] drm/hisilicon/hibmc: Use drm_module_pci_driver() to register the driver Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 03/37] drm/komeda: Use drm_module_platform_driver() " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 04/37] drm/arm/hdlcd: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 05/37] drm/malidp: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 06/37] drm/aspeed: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 07/37] drm/atmel-hlcdc: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 08/37] drm/fsl-dcu: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 09/37] drm/hisilicon/kirin: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 10/37] drm/imx/dcss: " Javier Martinez Canillas
2021-12-17 15:58   ` kernel test robot
2021-12-17  0:37 ` [PATCH v2 11/37] drm/kmb: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 12/37] drm/meson: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 13/37] drm: mxsfb: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 14/37] drm/shmobile: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 15/37] drm/stm: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 16/37] drm/sun4i: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 17/37] drm/tidss: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 18/37] drm/arc: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 19/37] drm/tve200: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 20/37] drm/xlnx: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 21/37] drm/armada: Add support for the nomodeset kernel parameter Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 22/37] drm/exynos: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 23/37] drm/gma500: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 24/37] drm/hyperv: " Javier Martinez Canillas
2021-12-20 17:10   ` Deepak Rawat
2021-12-17  0:37 ` [PATCH v2 25/37] drm/imx: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 26/37] drm/ingenic: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 27/37] drm/mcde: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 28/37] drm/mediatek: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 29/37] drm/msm: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 30/37] drm/omap: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 31/37] drm: rcar-du: " Javier Martinez Canillas
2022-01-28  9:13   ` Kieran Bingham
2022-01-28  9:33     ` Thomas Zimmermann
2022-01-28 10:34       ` Laurent Pinchart
2022-01-28 10:46         ` Thomas Zimmermann
2022-01-28 11:04           ` Laurent Pinchart
2022-01-28 11:26             ` Thomas Zimmermann
2022-01-28 11:36               ` Laurent Pinchart
2022-01-28 11:53                 ` Thomas Zimmermann
2022-01-28 11:09           ` Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 32/37] drm/rockchip: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 33/37] drm/sprd: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 34/37] drm/sti: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 35/37] drm/tegra: " Javier Martinez Canillas
2021-12-17  0:37 ` [PATCH v2 36/37] drm/tilcdc: " Javier Martinez Canillas
2021-12-17 13:30   ` Jyri Sarha
2021-12-17  0:37 ` [PATCH v2 37/37] drm/xen: " Javier Martinez Canillas
2022-01-27 18:29 ` [PATCH v2 00/37] drm: Make drivers to honour the nomodeset parameter Javier Martinez Canillas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20211217003752.3946210-1-javierm@redhat.com \
    --to=javierm@redhat.com \
    --cc=abrodkin@synopsys.com \
    --cc=alison.wang@nxp.com \
    --cc=anitha.chrisanthus@intel.com \
    --cc=bbrezillon@kernel.org \
    --cc=brian.starkey@arm.com \
    --cc=chunkuang.hu@kernel.org \
    --cc=drawat.floss@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=edmund.j.dea@intel.com \
    --cc=heiko@sntech.de \
    --cc=hjc@rock-chips.com \
    --cc=hyun.kwon@xilinx.com \
    --cc=inki.dae@samsung.com \
    --cc=james.qian.wang@arm.com \
    --cc=joel@jms.id.au \
    --cc=jy0922.shim@samsung.com \
    --cc=jyri.sarha@iki.fi \
    --cc=kieran.bingham+renesas@ideasonboard.com \
    --cc=l.stach@pengutronix.de \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=laurentiu.palcu@oss.nxp.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=liviu.dudau@arm.com \
    --cc=marex@denx.de \
    --cc=mripard@kernel.org \
    --cc=narmstrong@baylibre.com \
    --cc=oleksandr_andrushchenko@epam.com \
    --cc=p.zabel@pengutronix.de \
    --cc=patrik.r.jakobsson@gmail.com \
    --cc=paul@crapouillou.net \
    --cc=philippe.cornu@foss.st.com \
    --cc=robdclark@gmail.com \
    --cc=sam@ravnborg.org \
    --cc=sean@poorly.run \
    --cc=stefan@agner.ch \
    --cc=thierry.reding@gmail.com \
    --cc=tiantao6@hisilicon.com \
    --cc=tomba@kernel.org \
    --cc=tzimmermann@suse.de \
    --cc=wens@csie.org \
    --cc=xinliang.liu@linaro.org \
    --cc=yannick.fertre@foss.st.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).