Skip to contentSkip to conversation

Rename reset to sysreset

PATCH New Stephen Warren 3 participants 5 messages May 12, 2016 – May 23, 2016

Subsystems (5)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Rename reset to sysreset

From: Stephen Warren <[email protected]>

The current reset API implements a method to reset the entire system. In the near future, I'd like to introduce code that implements the device tree reset bindings; i.e. the equivalent of the Linux kernel's reset API. This controls resets to individual HW blocks or external chips with reset signals. It doesn't make sense to merge the two APIs into one since they have different semantic purposes. Resolve the naming conflict by renaming the existing reset API to sysreset instead, so the new reset API can be called just reset.

---
 arch/arm/lib/Makefile                              |  2 +-
 arch/arm/mach-rockchip/rk3036/reset_rk3036.c       | 20 +++---
 arch/arm/mach-rockchip/rk3288/reset_rk3288.c       | 20 +++---
 arch/arm/mach-snapdragon/reset.c                   | 18 ++---
 arch/sandbox/cpu/state.c                           |  4 +-
 arch/sandbox/include/asm/state.h                   |  6 +-
 configs/chromebook_jerry_defconfig                 |  2 +-
 configs/dragonboard410c_defconfig                  |  2 +-
 configs/evb-rk3036_defconfig                       |  2 +-
 configs/firefly-rk3288_defconfig                   |  2 +-
 configs/kylin-rk3036_defconfig                     |  2 +-
 configs/rock2_defconfig                            |  2 +-
 configs/sandbox_defconfig                          |  2 +-
 drivers/clk/clk_rk3036.c                           |  2 +-
 drivers/clk/clk_rk3288.c                           |  2 +-
 drivers/misc/Kconfig                               | 10 +--
 drivers/misc/Makefile                              |  4 +-
 drivers/misc/{reset-uclass.c => sysreset-uclass.c} | 32 ++++-----
 .../misc/{reset_sandbox.c => sysreset_sandbox.c}   | 61 +++++++++--------
 include/dm/uclass-id.h                             |  2 +-
 include/{reset.h => sysreset.h}                    | 42 ++++++------
 test/dm/Makefile                                   |  2 +-
 test/dm/{reset.c => sysreset.c}                    | 80 +++++++++++-----------
 23 files changed, 161 insertions(+), 160 deletions(-)
 rename drivers/misc/{reset-uclass.c => sysreset-uclass.c} (55%)
 rename drivers/misc/{reset_sandbox.c => sysreset_sandbox.c} (46%)
 rename include/{reset.h => sysreset.h} (47%)
 rename test/dm/{reset.c => sysreset.c} (16%)
arch/arm/lib/Makefile +1 -1
index 7a0fb5862e1b..b535dbef49a2 100644
@@ -46,7 +46,7 @@ obj-y	+= interrupts_64.o
 else
 obj-y	+= interrupts.o
 endif
-ifndef CONFIG_RESET
+ifndef CONFIG_SYSRESET
 obj-y	+= reset.o
 endif
 
arch/arm/mach-rockchip/rk3036/reset_rk3036.c +10 -10
index fefb568f7aef..b3d211323992 100644
@@ -7,24 +7,24 @@
 #include <common.h>
 #include <dm.h>
 #include <errno.h>
-#include <reset.h>
+#include <sysreset.h>
 #include <asm/io.h>
 #include <asm/arch/clock.h>
 #include <asm/arch/cru_rk3036.h>
 #include <asm/arch/hardware.h>
 #include <linux/err.h>
 
-int rk3036_reset_request(struct udevice *dev, enum reset_t type)
+int rk3036_sysreset_request(struct udevice *dev, enum sysreset_t type)
 {
 	struct rk3036_cru *cru = rockchip_get_cru();
 
 	if (IS_ERR(cru))
 		return PTR_ERR(cru);
 	switch (type) {
-	case RESET_WARM:
+	case SYSRESET_WARM:
 		writel(0xeca8, &cru->cru_glb_srst_snd_value);
 		break;
-	case RESET_COLD:
+	case SYSRESET_COLD:
 		writel(0xfdb9, &cru->cru_glb_srst_fst_value);
 		break;
 	default:
@@ -34,12 +34,12 @@ int rk3036_reset_request(struct udevice *dev, enum reset_t type)
 	return -EINPROGRESS;
 }
 
-static struct reset_ops rk3036_reset = {
-	.request	= rk3036_reset_request,
+static struct sysreset_ops rk3036_sysreset = {
+	.request	= rk3036_sysreset_request,
 };
 
-U_BOOT_DRIVER(reset_rk3036) = {
-	.name	= "rk3036_reset",
-	.id	= UCLASS_RESET,
-	.ops	= &rk3036_reset,
+U_BOOT_DRIVER(sysreset_rk3036) = {
+	.name	= "rk3036_sysreset",
+	.id	= UCLASS_SYSRESET,
+	.ops	= &rk3036_sysreset,
 };
arch/arm/mach-rockchip/rk3288/reset_rk3288.c +10 -10
index bf7540a5d24d..0aad1c216013 100644
@@ -7,25 +7,25 @@
 #include <common.h>
 #include <dm.h>
 #include <errno.h>
-#include <reset.h>
+#include <sysreset.h>
 #include <asm/io.h>
 #include <asm/arch/clock.h>
 #include <asm/arch/cru_rk3288.h>
 #include <asm/arch/hardware.h>
 #include <linux/err.h>
 
-int rk3288_reset_request(struct udevice *dev, enum reset_t type)
+int rk3288_sysreset_request(struct udevice *dev, enum sysreset_t type)
 {
 	struct rk3288_cru *cru = rockchip_get_cru();
 
 	if (IS_ERR(cru))
 		return PTR_ERR(cru);
 	switch (type) {
-	case RESET_WARM:
+	case SYSRESET_WARM:
 		rk_clrreg(&cru->cru_mode_con, 0xffff);
 		writel(0xeca8, &cru->cru_glb_srst_snd_value);
 		break;
-	case RESET_COLD:
+	case SYSRESET_COLD:
 		rk_clrreg(&cru->cru_mode_con, 0xffff);
 		writel(0xfdb9, &cru->cru_glb_srst_fst_value);
 		break;
@@ -36,12 +36,12 @@ int rk3288_reset_request(struct udevice *dev, enum reset_t type)
 	return -EINPROGRESS;
 }
 
-static struct reset_ops rk3288_reset = {
-	.request	= rk3288_reset_request,
+static struct sysreset_ops rk3288_sysreset = {
+	.request	= rk3288_sysreset_request,
 };
 
-U_BOOT_DRIVER(reset_rk3288) = {
-	.name	= "rk3288_reset",
-	.id	= UCLASS_RESET,
-	.ops	= &rk3288_reset,
+U_BOOT_DRIVER(sysreset_rk3288) = {
+	.name	= "rk3288_sysreset",
+	.id	= UCLASS_SYSRESET,
+	.ops	= &rk3288_sysreset,
 };
arch/arm/mach-snapdragon/reset.c +9 -9
index 2627eec18154..a6cabfb8b012 100644
@@ -9,12 +9,12 @@
 #include <common.h>
 #include <dm.h>
 #include <errno.h>
-#include <reset.h>
+#include <sysreset.h>
 #include <asm/io.h>
 
 DECLARE_GLOBAL_DATA_PTR;
 
-static int msm_reset_request(struct udevice *dev, enum reset_t type)
+static int msm_sysreset_request(struct udevice *dev, enum sysreset_t type)
 {
 	phys_addr_t addr = dev_get_addr(dev);
 	if (!addr)
@@ -23,18 +23,18 @@ static int msm_reset_request(struct udevice *dev, enum reset_t type)
 	return -EINPROGRESS;
 }
 
-static struct reset_ops msm_reset_ops = {
-	.request	= msm_reset_request,
+static struct sysreset_ops msm_sysreset_ops = {
+	.request	= msm_sysreset_request,
 };
 
-static const struct udevice_id msm_reset_ids[] = {
+static const struct udevice_id msm_sysreset_ids[] = {
 	{ .compatible = "qcom,pshold" },
 	{ }
 };
 
 U_BOOT_DRIVER(msm_reset) = {
-	.name		= "msm_reset",
-	.id		= UCLASS_RESET,
-	.of_match	= msm_reset_ids,
-	.ops		= &msm_reset_ops,
+	.name		= "msm_sysreset",
+	.id		= UCLASS_SYSRESET,
+	.of_match	= msm_sysreset_ids,
+	.ops		= &msm_sysreset_ops,
 };
arch/sandbox/cpu/state.c +2 -2
index d2a7dc9b450f..2b4dbd341ff3 100644
@@ -360,8 +360,8 @@ int state_init(void)
 	assert(state->ram_buf);
 
 	/* No reset yet, so mark it as such. Always allow power reset */
-	state->last_reset = RESET_COUNT;
-	state->reset_allowed[RESET_POWER] = true;
+	state->last_sysreset = SYSRESET_COUNT;
+	state->sysreset_allowed[SYSRESET_POWER] = true;
 
 	/*
 	 * Example of how to use GPIOs:
arch/sandbox/include/asm/state.h +3 -3
index 11856c2fede6..149f28d8732f 100644
@@ -7,7 +7,7 @@
 #define __SANDBOX_STATE_H
 
 #include <config.h>
-#include <reset.h>
+#include <sysreset.h>
 #include <stdbool.h>
 #include <linux/stringify.h>
 
@@ -60,8 +60,8 @@ struct sandbox_state {
 	bool write_state;		/* Write sandbox state on exit */
 	bool ignore_missing_state_on_read;	/* No error if state missing */
 	bool show_lcd;			/* Show LCD on start-up */
-	enum reset_t last_reset;	/* Last reset type */
-	bool reset_allowed[RESET_COUNT];	/* Allowed reset types */
+	enum sysreset_t last_sysreset;	/* Last system reset type */
+	bool sysreset_allowed[SYSRESET_COUNT];	/* Allowed system reset types */
 	enum state_terminal_raw term_raw;	/* Terminal raw/cooked */
 	bool skip_delays;		/* Ignore any time delays (for test) */
 	bool show_test_output;		/* Don't suppress stdout in tests */
configs/chromebook_jerry_defconfig +1 -1
index 25ead92778cc..d5bc5153b1b1 100644
@@ -47,7 +47,7 @@ CONFIG_CMD_CROS_EC=y
 CONFIG_CROS_EC=y
 CONFIG_CROS_EC_SPI=y
 CONFIG_PWRSEQ=y
-CONFIG_RESET=y
+CONFIG_SYSRESET=y
 CONFIG_DM_MMC=y
 CONFIG_ROCKCHIP_DWMMC=y
 CONFIG_PINCTRL=y
configs/dragonboard410c_defconfig +1 -1
index 2566ded58a44..37c5ea7761c9 100644
@@ -23,7 +23,7 @@ CONFIG_MSM_GPIO=y
 CONFIG_PM8916_GPIO=y
 CONFIG_LED=y
 CONFIG_LED_GPIO=y
-CONFIG_RESET=y
+CONFIG_SYSRESET=y
 CONFIG_DM_MMC=y
 CONFIG_MSM_SDHCI=y
 CONFIG_DM_PMIC=y
configs/evb-rk3036_defconfig +1 -1
index 4dd458624342..9894fffcca20 100644
@@ -28,7 +28,7 @@ CONFIG_CLK=y
 CONFIG_ROCKCHIP_GPIO=y
 CONFIG_SYS_I2C_ROCKCHIP=y
 CONFIG_LED=y
-CONFIG_RESET=y
+CONFIG_SYSRESET=y
 CONFIG_DM_MMC=y
 CONFIG_ROCKCHIP_DWMMC=y
 CONFIG_PINCTRL=y
configs/firefly-rk3288_defconfig +1 -1
index 0995f9b329fe..0cbc5398488d 100644
@@ -40,7 +40,7 @@ CONFIG_ROCKCHIP_GPIO=y
 CONFIG_SYS_I2C_ROCKCHIP=y
 CONFIG_LED=y
 CONFIG_LED_GPIO=y
-CONFIG_RESET=y
+CONFIG_SYSRESET=y
 CONFIG_DM_MMC=y
 CONFIG_ROCKCHIP_DWMMC=y
 CONFIG_PINCTRL=y
configs/kylin-rk3036_defconfig +1 -1
index 50fbe654bf63..0ff6c6b9a4ac 100644
@@ -28,7 +28,7 @@ CONFIG_CLK=y
 CONFIG_ROCKCHIP_GPIO=y
 CONFIG_SYS_I2C_ROCKCHIP=y
 CONFIG_LED=y
-CONFIG_RESET=y
+CONFIG_SYSRESET=y
 CONFIG_DM_MMC=y
 CONFIG_ROCKCHIP_DWMMC=y
 CONFIG_PINCTRL=y
configs/rock2_defconfig +1 -1
index fd32fb521eb6..3e16b805caa8 100644
@@ -38,7 +38,7 @@ CONFIG_CLK=y
 CONFIG_SPL_CLK=y
 CONFIG_ROCKCHIP_GPIO=y
 CONFIG_SYS_I2C_ROCKCHIP=y
-CONFIG_RESET=y
+CONFIG_SYSRESET=y
 CONFIG_DM_MMC=y
 CONFIG_ROCKCHIP_DWMMC=y
 CONFIG_PINCTRL=y
configs/sandbox_defconfig +1 -1
index afdf4a3ba715..9ad570c7fc49 100644
@@ -95,7 +95,7 @@ CONFIG_CROS_EC_SANDBOX=y
 CONFIG_CROS_EC_SPI=y
 CONFIG_PWRSEQ=y
 CONFIG_SPL_PWRSEQ=y
-CONFIG_RESET=y
+CONFIG_SYSRESET=y
 CONFIG_DM_MMC=y
 CONFIG_SPI_FLASH_SANDBOX=y
 CONFIG_SPI_FLASH=y
drivers/clk/clk_rk3036.c +1 -1
index bd5f22a753a4..7ec65bdff029 100644
@@ -407,7 +407,7 @@ static int rk3036_clk_bind(struct udevice *dev)
 	}
 
 	/* The reset driver does not have a device node, so bind it here */
-	ret = device_bind_driver(gd->dm_root, "rk3036_reset", "reset", &dev);
+	ret = device_bind_driver(gd->dm_root, "rk3036_sysreset", "reset", &dev);
 	if (ret)
 		debug("Warning: No RK3036 reset driver: ret=%d\n", ret);
 
drivers/clk/clk_rk3288.c +1 -1
index 2a85e93a6cc3..e763a1c8e91f 100644
@@ -877,7 +877,7 @@ static int rk3288_clk_bind(struct udevice *dev)
 	}
 
 	/* The reset driver does not have a device node, so bind it here */
-	ret = device_bind_driver(gd->dm_root, "rk3288_reset", "reset", &dev);
+	ret = device_bind_driver(gd->dm_root, "rk3288_sysreset", "reset", &dev);
 	if (ret)
 		debug("Warning: No RK3288 reset driver: ret=%d\n", ret);
 
drivers/misc/Kconfig +5 -5
index af8667f030c5..48f23e61cf8e 100644
@@ -121,13 +121,13 @@ config PCA9551_I2C_ADDR
 	help
 	  The I2C address of the PCA9551 LED controller.
 
-config RESET
-	bool "Enable support for reset drivers"
+config SYSRESET
+	bool "Enable support for system reset drivers"
 	depends on DM
 	help
-	  Enable reset drivers which can be used to reset the CPU or board.
-	  Each driver can provide a reset method which will be called to
-	  effect a reset. The uclass will try all available drivers when
+	  Enable system reset drivers which can be used to reset the CPU or
+	  board. Each driver can provide a reset method which will be called
+	  to effect a reset. The uclass will try all available drivers when
 	  reset_walk() is called.
 
 config WINBOND_W83627
drivers/misc/Makefile +2 -2
index 5969d3444413..59c73415139c 100644
@@ -27,7 +27,7 @@ obj-$(CONFIG_MXS_OCOTP) += mxs_ocotp.o
 obj-$(CONFIG_NS87308) += ns87308.o
 obj-$(CONFIG_PDSP188x) += pdsp188x.o
 obj-$(CONFIG_$(SPL_)PWRSEQ) += pwrseq-uclass.o
-obj-$(CONFIG_SANDBOX) += reset_sandbox.o
+obj-$(CONFIG_SANDBOX) += sysreset_sandbox.o
 ifdef CONFIG_DM_I2C
 obj-$(CONFIG_SANDBOX) += i2c_eeprom_emul.o
 endif
@@ -40,6 +40,6 @@ obj-$(CONFIG_TWL4030_LED) += twl4030_led.o
 obj-$(CONFIG_FSL_IFC) += fsl_ifc.o
 obj-$(CONFIG_FSL_SEC_MON) += fsl_sec_mon.o
 obj-$(CONFIG_PCA9551_LED) += pca9551_led.o
-obj-$(CONFIG_RESET) += reset-uclass.o
+obj-$(CONFIG_SYSRESET) += sysreset-uclass.o
 obj-$(CONFIG_FSL_DEVICE_DISABLE) += fsl_devdis.o
 obj-$(CONFIG_WINBOND_W83627) += winbond_w83627.o
drivers/misc/sysreset-uclass.c renamed from drivers/misc/reset-uclass.c +16 -16
similarity index 55%
rename from drivers/misc/reset-uclass.c
rename to drivers/misc/sysreset-uclass.c
index fdb5c6fcff34..e41efcaca602 100644
@@ -6,7 +6,7 @@
  */
 
 #include <common.h>
-#include <reset.h>
+#include <sysreset.h>
 #include <dm.h>
 #include <errno.h>
 #include <regmap.h>
@@ -15,9 +15,9 @@
 #include <dm/root.h>
 #include <linux/err.h>
 
-int reset_request(struct udevice *dev, enum reset_t type)
+int sysreset_request(struct udevice *dev, enum sysreset_t type)
 {
-	struct reset_ops *ops = reset_get_ops(dev);
+	struct sysreset_ops *ops = sysreset_get_ops(dev);
 
 	if (!ops->request)
 		return -ENOSYS;
@@ -25,16 +25,16 @@ int reset_request(struct udevice *dev, enum reset_t type)
 	return ops->request(dev, type);
 }
 
-int reset_walk(enum reset_t type)
+int sysreset_walk(enum sysreset_t type)
 {
 	struct udevice *dev;
 	int ret = -ENOSYS;
 
-	while (ret != -EINPROGRESS && type < RESET_COUNT) {
-		for (uclass_first_device(UCLASS_RESET, &dev);
+	while (ret != -EINPROGRESS && type < SYSRESET_COUNT) {
+		for (uclass_first_device(UCLASS_SYSRESET, &dev);
 		     dev;
 		     uclass_next_device(&dev)) {
-			ret = reset_request(dev, type);
+			ret = sysreset_request(dev, type);
 			if (ret == -EINPROGRESS)
 				break;
 		}
@@ -44,38 +44,38 @@ int reset_walk(enum reset_t type)
 	return ret;
 }
 
-void reset_walk_halt(enum reset_t type)
+void sysreset_walk_halt(enum sysreset_t type)
 {
 	int ret;
 
-	ret = reset_walk(type);
+	ret = sysreset_walk(type);
 
 	/* Wait for the reset to take effect */
 	if (ret == -EINPROGRESS)
 		mdelay(100);
 
 	/* Still no reset? Give up */
-	printf("Reset not supported on this platform\n");
+	printf("System reset not supported on this platform\n");
 	hang();
 }
 
 /**
- * reset_cpu() - calls reset_walk(RESET_WARM)
+ * reset_cpu() - calls sysreset_walk(SYSRESET_WARM)
  */
 void reset_cpu(ulong addr)
 {
-	reset_walk_halt(RESET_WARM);
+	sysreset_walk_halt(SYSRESET_WARM);
 }
 
 
 int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
 {
-	reset_walk_halt(RESET_WARM);
+	sysreset_walk_halt(SYSRESET_WARM);
 
 	return 0;
 }
 
-UCLASS_DRIVER(reset) = {
-	.id		= UCLASS_RESET,
-	.name		= "reset",
+UCLASS_DRIVER(sysreset) = {
+	.id		= UCLASS_SYSRESET,
+	.name		= "sysreset",
 };
drivers/misc/sysreset_sandbox.c renamed from drivers/misc/reset_sandbox.c +31 -30

118 lines not on this page · raw message

include/dm/uclass-id.h +1 -1
index cbf9b2ca2351..45ae9650e3dd 100644
@@ -61,7 +61,6 @@ enum uclass_id {
 	UCLASS_PWM,		/* Pulse-width modulator */
 	UCLASS_PWRSEQ,		/* Power sequence device */
 	UCLASS_REGULATOR,	/* Regulator device */
-	UCLASS_RESET,		/* Reset device */
 	UCLASS_REMOTEPROC,	/* Remote Processor device */
 	UCLASS_RTC,		/* Real time clock device */
 	UCLASS_SERIAL,		/* Serial UART */
@@ -70,6 +69,7 @@ enum uclass_id {
 	UCLASS_SPI_FLASH,	/* SPI flash */
 	UCLASS_SPI_GENERIC,	/* Generic SPI flash target */
 	UCLASS_SYSCON,		/* System configuration device */
+	UCLASS_SYSRESET,	/* System reset device */
 	UCLASS_THERMAL,		/* Thermal sensor */
 	UCLASS_TIMER,		/* Timer device */
 	UCLASS_TPM,		/* Trusted Platform Module TIS interface */
include/sysreset.h renamed from include/reset.h +21 -21

83 lines not on this page · raw message

test/dm/Makefile +1 -1
index 9a11ae0a147a..fd781e82cfe8 100644
@@ -26,7 +26,7 @@ obj-$(CONFIG_DM_PCI) += pci.o
 obj-$(CONFIG_RAM) += ram.o
 obj-y += regmap.o
 obj-$(CONFIG_REMOTEPROC) += remoteproc.o
-obj-$(CONFIG_RESET) += reset.o
+obj-$(CONFIG_SYSRESET) += sysreset.o
 obj-$(CONFIG_DM_RTC) += rtc.o
 obj-$(CONFIG_DM_SPI_FLASH) += sf.o
 obj-$(CONFIG_DM_SPI) += spi.o
test/dm/sysreset.c renamed from test/dm/reset.c +40 -40

109 lines not on this page · raw message

Signature · 1 line
2.8.2
#1 lore raw

PATCH 1/1 Rename reset to sysreset

Dear Stephen,

Quoted 9 lines · In message <[email protected]> you wrote:

The current reset API implements a method to reset the entire system. In the near future, I'd like to introduce code that implements the device tree reset bindings; i.e. the equivalent of the Linux kernel's reset API. This controls resets to individual HW blocks or external chips with reset signals. It doesn't make sense to merge the two APIs into one since they have different semantic purposes. Resolve the naming conflict by renaming the existing reset API to sysreset instead, so the new reset API can be called just reset.

What about the "reset" command? This cannot be easily renamed (not without breaking backward compatibility). Do you feel this is an issue, or can we just ignore that here?

Best regards,

Wolfgang Denk

Signature · 4 lines
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
What's the sound a name makes when it's dropped?
#2 lore raw

PATCH 1/1 Rename reset to sysreset

Quoted 13 lines · Wolfgang Denk

Dear Stephen,

Quoted 9 lines · In message <[email protected]> you wrote:

The current reset API implements a method to reset the entire system. In the near future, I'd like to introduce code that implements the device tree reset bindings; i.e. the equivalent of the Linux kernel's reset API. This controls resets to individual HW blocks or external chips with reset signals. It doesn't make sense to merge the two APIs into one since they have different semantic purposes. Resolve the naming conflict by renaming the existing reset API to sysreset instead, so the new reset API can be called just reset.

Quoted 3 lines

What about the "reset" command? This cannot be easily renamed (not without breaking backward compatibility). Do you feel this is an issue, or can we just ignore that here?

As you say, it's best not to change the cmdline syntax to avoid compatibility issues. I think we can ignore this; in the context of a bootloader command-line, I'd expect "reset" to do a system reset, and any debug commands related to any new reset subsystem (if there end up being any) to get some other name that's a bit less of a "land grab" for a common name.

#3 lore raw

PATCH 1/1 Rename reset to sysreset

In reply to Stephen Warren
Quoted 31 lines · Stephen Warren

The current reset API implements a method to reset the entire system. In the near future, I'd like to introduce code that implements the device tree reset bindings; i.e. the equivalent of the Linux kernel's reset API. This controls resets to individual HW blocks or external chips with reset signals. It doesn't make sense to merge the two APIs into one since they have different semantic purposes. Resolve the naming conflict by renaming the existing reset API to sysreset instead, so the new reset API can be called just reset.

---
 arch/arm/lib/Makefile                              |  2 +-
 arch/arm/mach-rockchip/rk3036/reset_rk3036.c       | 20 +++---
 arch/arm/mach-rockchip/rk3288/reset_rk3288.c       | 20 +++---
 arch/arm/mach-snapdragon/reset.c                   | 18 ++---
 arch/sandbox/cpu/state.c                           |  4 +-
 arch/sandbox/include/asm/state.h                   |  6 +-
 configs/chromebook_jerry_defconfig                 |  2 +-
 configs/dragonboard410c_defconfig                  |  2 +-
 configs/evb-rk3036_defconfig                       |  2 +-
 configs/firefly-rk3288_defconfig                   |  2 +-
 configs/kylin-rk3036_defconfig                     |  2 +-
 configs/rock2_defconfig                            |  2 +-
 configs/sandbox_defconfig                          |  2 +-
 drivers/clk/clk_rk3036.c                           |  2 +-
 drivers/clk/clk_rk3288.c                           |  2 +-
 drivers/misc/Kconfig                               | 10 +--
 drivers/misc/Makefile                              |  4 +-
 drivers/misc/{reset-uclass.c => sysreset-uclass.c} | 32 ++++-----
 .../misc/{reset_sandbox.c => sysreset_sandbox.c}   | 61 +++++++++--------
 include/dm/uclass-id.h                             |  2 +-
Quoted 8 lines
 include/{reset.h => sysreset.h}                    | 42 ++++++------
 test/dm/Makefile                                   |  2 +-
 test/dm/{reset.c => sysreset.c}                    | 80 +++++++++++-----------
 23 files changed, 161 insertions(+), 160 deletions(-)
 rename drivers/misc/{reset-uclass.c => sysreset-uclass.c} (55%)
 rename drivers/misc/{reset_sandbox.c => sysreset_sandbox.c} (46%)
 rename include/{reset.h => sysreset.h} (47%)
 rename test/dm/{reset.c => sysreset.c} (16%)
#4 lore raw

PATCH 1/1 Rename reset to sysreset

Quoted 41 lines · Simon Glass
Quoted 31 lines · Stephen Warren

The current reset API implements a method to reset the entire system. In the near future, I'd like to introduce code that implements the device tree reset bindings; i.e. the equivalent of the Linux kernel's reset API. This controls resets to individual HW blocks or external chips with reset signals. It doesn't make sense to merge the two APIs into one since they have different semantic purposes. Resolve the naming conflict by renaming the existing reset API to sysreset instead, so the new reset API can be called just reset.

---
 arch/arm/lib/Makefile                              |  2 +-
 arch/arm/mach-rockchip/rk3036/reset_rk3036.c       | 20 +++---
 arch/arm/mach-rockchip/rk3288/reset_rk3288.c       | 20 +++---
 arch/arm/mach-snapdragon/reset.c                   | 18 ++---
 arch/sandbox/cpu/state.c                           |  4 +-
 arch/sandbox/include/asm/state.h                   |  6 +-
 configs/chromebook_jerry_defconfig                 |  2 +-
 configs/dragonboard410c_defconfig                  |  2 +-
 configs/evb-rk3036_defconfig                       |  2 +-
 configs/firefly-rk3288_defconfig                   |  2 +-
 configs/kylin-rk3036_defconfig                     |  2 +-
 configs/rock2_defconfig                            |  2 +-
 configs/sandbox_defconfig                          |  2 +-
 drivers/clk/clk_rk3036.c                           |  2 +-
 drivers/clk/clk_rk3288.c                           |  2 +-
 drivers/misc/Kconfig                               | 10 +--
 drivers/misc/Makefile                              |  4 +-
 drivers/misc/{reset-uclass.c => sysreset-uclass.c} | 32 ++++-----
 .../misc/{reset_sandbox.c => sysreset_sandbox.c}   | 61 +++++++++--------
 include/dm/uclass-id.h                             |  2 +-
Quoted 8 lines
 include/{reset.h => sysreset.h}                    | 42 ++++++------
 test/dm/Makefile                                   |  2 +-
 test/dm/{reset.c => sysreset.c}                    | 80 +++++++++++-----------
 23 files changed, 161 insertions(+), 160 deletions(-)
 rename drivers/misc/{reset-uclass.c => sysreset-uclass.c} (55%)
 rename drivers/misc/{reset_sandbox.c => sysreset_sandbox.c} (46%)
 rename include/{reset.h => sysreset.h} (47%)
 rename test/dm/{reset.c => sysreset.c} (16%)
Quoted 1 line

Applied to u-boot-dm, thanks!