public inbox for linux-sunxi@lists.linux.dev
 help / color / mirror / Atom feed
* [PATCH 0/2] pwm: Manage owner assignment implicitly for drivers
@ 2023-08-03 14:06 Uwe Kleine-König
  2023-08-03 14:06 ` [PATCH 1/2] " Uwe Kleine-König
  0 siblings, 1 reply; 3+ messages in thread
From: Uwe Kleine-König @ 2023-08-03 14:06 UTC (permalink / raw)
  To: Thierry Reding
  Cc: Linus Walleij, Bartosz Golaszewski, Andy Shevchenko,
	Douglas Anderson, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec, David Airlie,
	Daniel Vetter, Pavel Machek, Lee Jones, Hector Martin, Sven Peter,
	Alyssa Rosenzweig, Nicolas Ferre, Alexandre Belloni,
	Claudiu Beznea, Ray Jui, Scott Branden,
	Broadcom internal kernel review list, Florian Fainelli,
	Alexander Shiyan, Benson Leung, Guenter Roeck, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam,
	NXP Linux Team, Paul Cercueil, Vladimir Zapolskiy, Kevin Hilman,
	Jerome Brunet, Martin Blumenstingl, Conor Dooley, Daire McNamara,
	Matthias Brugger, AngeloGioacchino Del Regno,
	Jonathan Neuschäfer, Heiko Stuebner, Krzysztof Kozlowski,
	Alim Akhtar, Palmer Dabbelt, Paul Walmsley, Michael Walle,
	Orson Zhai, Baolin Wang, Chunyan Zhang, Fabrice Gasnier,
	Maxime Coquelin, Alexandre Torgue, Chen-Yu Tsai, Samuel Holland,
	Hammer Hsieh, Jonathan Hunter, Nobuhiro Iwamatsu, Sean Anderson,
	Michal Simek, Johan Hovold, Alex Elder, Greg Kroah-Hartman,
	linux-pwm, linux-gpio, dri-devel, linux-leds, asahi,
	linux-arm-kernel, linux-rpi-kernel, chrome-platform, linux-mips,
	linux-amlogic, linux-riscv, linux-mediatek, linux-rockchip,
	linux-samsung-soc, linux-stm32, linux-sunxi, linux-tegra,
	greybus-dev, linux-staging

Hello,

while working on the pwm core I noticed that pwm-crc doesn't assign
.owner in its pwm_ops structure. This isn't a problem in practise though
as this driver can only be compiled built-in (up to now).

Still prevent future pwm drivers not assigning .owner by wrapping
pwmchip_add() in a macro that automates owner handling simplifying each
driver a (tiny) bit.

I also found that there is no hard reason to only compile pwm-crc as a
built-in on x86, so this limitation is lifted in the second patch.

Best regards
Uwe

Uwe Kleine-König (2):
  pwm: Manage owner assignment implicitly for drivers
  pwm: crc: Allow compilation as module and with COMPILE_TEST

 drivers/gpio/gpio-mvebu.c             |  1 -
 drivers/gpu/drm/bridge/ti-sn65dsi86.c |  1 -
 drivers/leds/rgb/leds-qcom-lpg.c      |  1 -
 drivers/pwm/Kconfig                   |  4 ++--
 drivers/pwm/core.c                    | 20 +++++++++++---------
 drivers/pwm/pwm-ab8500.c              |  1 -
 drivers/pwm/pwm-apple.c               |  1 -
 drivers/pwm/pwm-atmel-hlcdc.c         |  1 -
 drivers/pwm/pwm-atmel-tcb.c           |  1 -
 drivers/pwm/pwm-atmel.c               |  1 -
 drivers/pwm/pwm-bcm-iproc.c           |  1 -
 drivers/pwm/pwm-bcm-kona.c            |  1 -
 drivers/pwm/pwm-bcm2835.c             |  1 -
 drivers/pwm/pwm-berlin.c              |  1 -
 drivers/pwm/pwm-brcmstb.c             |  1 -
 drivers/pwm/pwm-clk.c                 |  1 -
 drivers/pwm/pwm-clps711x.c            |  1 -
 drivers/pwm/pwm-crc.c                 |  5 ++++-
 drivers/pwm/pwm-cros-ec.c             |  1 -
 drivers/pwm/pwm-dwc.c                 |  1 -
 drivers/pwm/pwm-ep93xx.c              |  1 -
 drivers/pwm/pwm-fsl-ftm.c             |  1 -
 drivers/pwm/pwm-hibvt.c               |  1 -
 drivers/pwm/pwm-img.c                 |  1 -
 drivers/pwm/pwm-imx-tpm.c             |  1 -
 drivers/pwm/pwm-imx1.c                |  1 -
 drivers/pwm/pwm-imx27.c               |  1 -
 drivers/pwm/pwm-intel-lgm.c           |  1 -
 drivers/pwm/pwm-iqs620a.c             |  1 -
 drivers/pwm/pwm-jz4740.c              |  1 -
 drivers/pwm/pwm-keembay.c             |  1 -
 drivers/pwm/pwm-lp3943.c              |  1 -
 drivers/pwm/pwm-lpc18xx-sct.c         |  1 -
 drivers/pwm/pwm-lpc32xx.c             |  1 -
 drivers/pwm/pwm-lpss.c                |  1 -
 drivers/pwm/pwm-mediatek.c            |  1 -
 drivers/pwm/pwm-meson.c               |  1 -
 drivers/pwm/pwm-microchip-core.c      |  1 -
 drivers/pwm/pwm-mtk-disp.c            |  1 -
 drivers/pwm/pwm-mxs.c                 |  1 -
 drivers/pwm/pwm-ntxec.c               |  1 -
 drivers/pwm/pwm-omap-dmtimer.c        |  1 -
 drivers/pwm/pwm-pca9685.c             |  1 -
 drivers/pwm/pwm-pxa.c                 |  1 -
 drivers/pwm/pwm-raspberrypi-poe.c     |  1 -
 drivers/pwm/pwm-rcar.c                |  1 -
 drivers/pwm/pwm-renesas-tpu.c         |  1 -
 drivers/pwm/pwm-rockchip.c            |  1 -
 drivers/pwm/pwm-rz-mtu3.c             |  1 -
 drivers/pwm/pwm-samsung.c             |  1 -
 drivers/pwm/pwm-sifive.c              |  1 -
 drivers/pwm/pwm-sl28cpld.c            |  1 -
 drivers/pwm/pwm-spear.c               |  1 -
 drivers/pwm/pwm-sprd.c                |  1 -
 drivers/pwm/pwm-sti.c                 |  1 -
 drivers/pwm/pwm-stm32-lp.c            |  1 -
 drivers/pwm/pwm-stm32.c               |  1 -
 drivers/pwm/pwm-stmpe.c               |  1 -
 drivers/pwm/pwm-sun4i.c               |  1 -
 drivers/pwm/pwm-sunplus.c             |  1 -
 drivers/pwm/pwm-tegra.c               |  1 -
 drivers/pwm/pwm-tiecap.c              |  1 -
 drivers/pwm/pwm-tiehrpwm.c            |  1 -
 drivers/pwm/pwm-twl-led.c             |  2 --
 drivers/pwm/pwm-twl.c                 |  2 --
 drivers/pwm/pwm-visconti.c            |  1 -
 drivers/pwm/pwm-vt8500.c              |  1 -
 drivers/pwm/pwm-xilinx.c              |  1 -
 drivers/staging/greybus/pwm.c         |  1 -
 include/linux/pwm.h                   |  8 +++++---
 70 files changed, 22 insertions(+), 83 deletions(-)


base-commit: 3ccb179aa40d931eb00ef8910d7b812a95659563
-- 
2.39.2


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-08-03 21:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-03 14:06 [PATCH 0/2] pwm: Manage owner assignment implicitly for drivers Uwe Kleine-König
2023-08-03 14:06 ` [PATCH 1/2] " Uwe Kleine-König
2023-08-03 21:53   ` Laurent Pinchart

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox