mirror of
https://github.com/torvalds/linux.git
synced 2024-11-15 08:31:55 +00:00
d1aae06630
Let's use a wrapper struct for the auxiliary_device made in
jh7110_reset_controller_register() so that we can stop casting iomem
pointers. The casts trip up tools like sparse, and make for some awkward
casts that are largely unnecessary. While we're here, change the
allocation from devm and actually free the auxiliary_device memory in
the release function. This avoids any use after free problems where the
parent device driver is unbound from the device but the
auxiliuary_device is still in use accessing devm freed memory.
Cc: Tommaso Merciai <tomm.merciai@gmail.com>
Cc: Emil Renner Berthing <emil.renner.berthing@canonical.com>
Cc: Hal Feng <hal.feng@starfivetech.com>
Cc: Conor Dooley <conor.dooley@microchip.com>
Cc: Xingyu Wu <xingyu.wu@starfivetech.com>
Reviewed-by: Conor Dooley <conor.dooley@microchip.com>
Fixes:
|
||
---|---|---|
.. | ||
hisilicon | ||
starfive | ||
sti | ||
tegra | ||
core.c | ||
Kconfig | ||
Makefile | ||
reset-a10sr.c | ||
reset-ath79.c | ||
reset-axs10x.c | ||
reset-bcm6345.c | ||
reset-berlin.c | ||
reset-brcmstb-rescal.c | ||
reset-brcmstb.c | ||
reset-hsdk.c | ||
reset-imx7.c | ||
reset-intel-gw.c | ||
reset-k210.c | ||
reset-lantiq.c | ||
reset-lpc18xx.c | ||
reset-meson-audio-arb.c | ||
reset-meson.c | ||
reset-microchip-sparx5.c | ||
reset-mpfs.c | ||
reset-npcm.c | ||
reset-oxnas.c | ||
reset-pistachio.c | ||
reset-qcom-aoss.c | ||
reset-qcom-pdc.c | ||
reset-raspberrypi.c | ||
reset-rzg2l-usbphy-ctrl.c | ||
reset-scmi.c | ||
reset-simple.c | ||
reset-socfpga.c | ||
reset-sunplus.c | ||
reset-sunxi.c | ||
reset-ti-sci.c | ||
reset-ti-syscon.c | ||
reset-tn48m.c | ||
reset-tps380x.c | ||
reset-uniphier-glue.c | ||
reset-uniphier.c | ||
reset-zynq.c | ||
reset-zynqmp.c |