diff options
| author | Tom Rini <[email protected]> | 2024-12-14 09:34:27 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2024-12-14 09:34:27 -0600 |
| commit | 8aab7730c1c26192b0e4218fbf2f6009f955cb88 (patch) | |
| tree | a83a5ea79c6eea5ca85dd3a4a60c876501498b4c /drivers | |
| parent | d229e0bd0d591801bc3e5df664a7ab888d9672fe (diff) | |
| parent | 8f71d37838ba0b0bfa047f5133877092ee9d1110 (diff) | |
Merge patch series "Hyperflash Boot fixes for J7200/J721E"
Anurag Dutta <[email protected]> says:
Hi All,
In u-boot, hbmc is broken and has been removed from j7200
configs. This series re-enables the hbmc driver and introduces a series
of hyperflash boot fixes. At present, in u-boot, the parent device (fss)
gets registered as a syscon device. This is done because the MMIO
mux driver in u-boot did not support the mux functionality when the
parent device is not a syscon. In this series, we make relevant changes
in the hbmc driver as well as dts' so that we can use the reg-mux driver for
selecting the appropriate state of the mux.
Test logs:
1) j721e-idk-gw hyperflash boot test: https://gist.github.com/anuragdutta731/50aae6fec707a3ffad6d985de6757fe4
2) j7200-evm hyperflash boot test: https://gist.github.com/anuragdutta731/c3a4d60f8bfd9c425d6c44b36eb7322b
Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'drivers')
| -rw-r--r-- | drivers/Makefile | 1 | ||||
| -rw-r--r-- | drivers/mtd/Kconfig | 2 | ||||
| -rw-r--r-- | drivers/mtd/hbmc-am654.c | 10 |
3 files changed, 9 insertions, 4 deletions
diff --git a/drivers/Makefile b/drivers/Makefile index 9440af1b09b..0e1f58c515b 100644 --- a/drivers/Makefile +++ b/drivers/Makefile @@ -21,6 +21,7 @@ obj-$(CONFIG_$(PHASE_)INPUT) += input/ obj-$(CONFIG_$(PHASE_)LED) += led/ obj-$(CONFIG_$(PHASE_)MMC) += mmc/ obj-y += mtd/ +obj-$(CONFIG_MULTIPLEXER) += mux/ obj-$(CONFIG_$(PHASE_)ETH) += net/ obj-$(CONFIG_$(PHASE_)PCH) += pch/ obj-$(CONFIG_$(PHASE_)PCI) += pci/ diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig index 3764e2567c1..678bbde89e6 100644 --- a/drivers/mtd/Kconfig +++ b/drivers/mtd/Kconfig @@ -202,7 +202,7 @@ config RENESAS_RPC_HF config HBMC_AM654 bool "HyperBus controller driver for AM65x SoC" - depends on SYSCON + depends on MULTIPLEXER && MUX_MMIO help This is the driver for HyperBus controller on TI's AM65x and other SoCs diff --git a/drivers/mtd/hbmc-am654.c b/drivers/mtd/hbmc-am654.c index 599beda30d5..98988a8e24d 100644 --- a/drivers/mtd/hbmc-am654.c +++ b/drivers/mtd/hbmc-am654.c @@ -5,8 +5,8 @@ #include <asm/io.h> #include <dm.h> +#include <mux.h> #include <regmap.h> -#include <syscon.h> #include <dm/device_compat.h> #define FSS_SYSC_REG 0x4 @@ -52,9 +52,13 @@ static int am654_hyperbus_calibrate(struct udevice *dev) static int am654_select_hbmc(struct udevice *dev) { - struct regmap *regmap = syscon_get_regmap(dev_get_parent(dev)); + struct mux_control *mux_ctl; + int ret; - return regmap_update_bits(regmap, FSS_SYSC_REG, 0x2, 0x2); + ret = mux_get_by_index(dev, 0, &mux_ctl); + if (!ret) + ret = mux_control_select(mux_ctl, 1); + return ret; } static int am654_hbmc_bind(struct udevice *dev) |
