Skip to content

Commit 2875b4b

Browse files
docularxupH5
authored andcommitted
reset: Create subdirectory for SpacemiT drivers
Create a dedicated subdirectory for SpacemiT reset drivers to allow for better organization as support for more SoCs is added. Move the existing K1 reset driver into this new directory and rename it to reset-spacemit-k1.c. Rename the Kconfig symbol to RESET_SPACEMIT_K1 and update its default from ARCH_SPACEMIT to SPACEMIT_K1_CCU. The reset driver depends on the clock driver to register reset devices as an auxiliary device, so the default should reflect this dependency. Also sort the drivers/reset/Kconfig entries alphabetically. Reviewed-by: Alex Elder <elder@riscstar.com> Signed-off-by: Guodong Xu <guodong@riscstar.com> Reviewed-by: Yixun Lan <dlan@kernel.org> Link: https://lore.kernel.org/spacemit/20260114092742-GYC7933267@gentoo.org/ [1] Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
1 parent 216e0a5 commit 2875b4b

5 files changed

Lines changed: 19 additions & 11 deletions

File tree

drivers/reset/Kconfig

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -299,15 +299,6 @@ config RESET_SOCFPGA
299299
This enables the reset driver for the SoCFPGA ARMv7 platforms. This
300300
driver gets initialized early during platform init calls.
301301

302-
config RESET_SPACEMIT
303-
tristate "SpacemiT reset driver"
304-
depends on ARCH_SPACEMIT || COMPILE_TEST
305-
select AUXILIARY_BUS
306-
default ARCH_SPACEMIT
307-
help
308-
This enables the reset controller driver for SpacemiT SoCs,
309-
including the K1.
310-
311302
config RESET_SUNPLUS
312303
bool "Sunplus SoCs Reset Driver" if COMPILE_TEST
313304
default ARCH_SUNPLUS
@@ -406,9 +397,10 @@ config RESET_ZYNQMP
406397
This enables the reset controller driver for Xilinx ZynqMP SoCs.
407398

408399
source "drivers/reset/amlogic/Kconfig"
400+
source "drivers/reset/hisilicon/Kconfig"
401+
source "drivers/reset/spacemit/Kconfig"
409402
source "drivers/reset/starfive/Kconfig"
410403
source "drivers/reset/sti/Kconfig"
411-
source "drivers/reset/hisilicon/Kconfig"
412404
source "drivers/reset/tegra/Kconfig"
413405

414406
endif

drivers/reset/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
obj-y += core.o
33
obj-y += amlogic/
44
obj-y += hisilicon/
5+
obj-y += spacemit/
56
obj-y += starfive/
67
obj-y += sti/
78
obj-y += tegra/
@@ -38,7 +39,6 @@ obj-$(CONFIG_RESET_RZV2H_USB2PHY) += reset-rzv2h-usb2phy.o
3839
obj-$(CONFIG_RESET_SCMI) += reset-scmi.o
3940
obj-$(CONFIG_RESET_SIMPLE) += reset-simple.o
4041
obj-$(CONFIG_RESET_SOCFPGA) += reset-socfpga.o
41-
obj-$(CONFIG_RESET_SPACEMIT) += reset-spacemit.o
4242
obj-$(CONFIG_RESET_SUNPLUS) += reset-sunplus.o
4343
obj-$(CONFIG_RESET_SUNXI) += reset-sunxi.o
4444
obj-$(CONFIG_RESET_TH1520) += reset-th1520.o

drivers/reset/spacemit/Kconfig

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# SPDX-License-Identifier: GPL-2.0-only
2+
3+
config RESET_SPACEMIT_K1
4+
tristate "SpacemiT K1 reset driver"
5+
depends on ARCH_SPACEMIT || COMPILE_TEST
6+
depends on SPACEMIT_K1_CCU
7+
select AUXILIARY_BUS
8+
default SPACEMIT_K1_CCU
9+
help
10+
Support for reset controller in SpacemiT K1 SoC.
11+
This driver works with the SpacemiT K1 clock controller
12+
unit (CCU) driver to provide reset control functionality
13+
for various peripherals and subsystems in the SoC.
14+

drivers/reset/spacemit/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# SPDX-License-Identifier: GPL-2.0
2+
obj-$(CONFIG_RESET_SPACEMIT_K1) += reset-spacemit-k1.o
File renamed without changes.

0 commit comments

Comments
 (0)