All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] ARM: stm32: Define I2C EEPROM bus and address on DHCOM
@ 2020-04-27 10:26 Marek Vasut
  2020-04-27 10:26 ` [PATCH 2/2] ARM: stm32: Hog GPIO PF7 high on DHCOM to unlock SPI NOR nWP Marek Vasut
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Marek Vasut @ 2020-04-27 10:26 UTC (permalink / raw)
  To: u-boot

Define I2C EEPROM bus and address, so that the 'eeprom' command uses
the correct ones and does not generate the following error:
    eeprom_rw_block: Cannot find udev for a bus 0

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Patrick Delaunay <patrick.delaunay@st.com>
Cc: Patrice Chotard <patrice.chotard@st.com>
---
 configs/stm32mp15_dhcom_basic_defconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/configs/stm32mp15_dhcom_basic_defconfig b/configs/stm32mp15_dhcom_basic_defconfig
index f830feb306..28824cf813 100644
--- a/configs/stm32mp15_dhcom_basic_defconfig
+++ b/configs/stm32mp15_dhcom_basic_defconfig
@@ -76,6 +76,8 @@ CONFIG_LED_GPIO=y
 CONFIG_DM_MAILBOX=y
 CONFIG_STM32_IPCC=y
 CONFIG_I2C_EEPROM=y
+CONFIG_SYS_I2C_EEPROM_ADDR=0x50
+CONFIG_SYS_I2C_EEPROM_BUS=3
 CONFIG_DM_MMC=y
 CONFIG_SUPPORT_EMMC_BOOT=y
 CONFIG_STM32_SDMMC2=y
-- 
2.25.1

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

* [PATCH 2/2] ARM: stm32: Hog GPIO PF7 high on DHCOM to unlock SPI NOR nWP
  2020-04-27 10:26 [PATCH 1/2] ARM: stm32: Define I2C EEPROM bus and address on DHCOM Marek Vasut
@ 2020-04-27 10:26 ` Marek Vasut
  2020-04-28  8:42   ` Patrick DELAUNAY
  2020-05-14  9:38   ` Patrick DELAUNAY
  2020-04-27 13:39 ` [PATCH 1/2] ARM: stm32: Define I2C EEPROM bus and address on DHCOM Patrick DELAUNAY
  2020-05-14  9:37 ` Patrick DELAUNAY
  2 siblings, 2 replies; 6+ messages in thread
From: Marek Vasut @ 2020-04-27 10:26 UTC (permalink / raw)
  To: u-boot

The SPI NOR nWP line is connected to GPIO PF7 on the SoM,
pull the GPIO line high by default to clear SPI NOR WP.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Patrick Delaunay <patrick.delaunay@st.com>
Cc: Patrice Chotard <patrice.chotard@st.com>
---
 arch/arm/dts/stm32mp15xx-dhcom-u-boot.dtsi | 9 +++++++++
 configs/stm32mp15_dhcom_basic_defconfig    | 1 +
 2 files changed, 10 insertions(+)

diff --git a/arch/arm/dts/stm32mp15xx-dhcom-u-boot.dtsi b/arch/arm/dts/stm32mp15xx-dhcom-u-boot.dtsi
index b57f3d520c..26bd6418c1 100644
--- a/arch/arm/dts/stm32mp15xx-dhcom-u-boot.dtsi
+++ b/arch/arm/dts/stm32mp15xx-dhcom-u-boot.dtsi
@@ -45,6 +45,15 @@
 	};
 };
 
+&gpiof {
+	snor-nwp {
+		gpio-hog;
+		gpios = <7 0>;
+		output-high;
+		line-name = "spi-nor-nwp";
+	};
+};
+
 &i2c4 {
 	u-boot,dm-pre-reloc;
 };
diff --git a/configs/stm32mp15_dhcom_basic_defconfig b/configs/stm32mp15_dhcom_basic_defconfig
index 28824cf813..40afef2ece 100644
--- a/configs/stm32mp15_dhcom_basic_defconfig
+++ b/configs/stm32mp15_dhcom_basic_defconfig
@@ -67,6 +67,7 @@ CONFIG_SPL_BLOCK_CACHE=y
 CONFIG_DFU_MMC=y
 CONFIG_DFU_RAM=y
 CONFIG_DFU_VIRT=y
+CONFIG_GPIO_HOG=y
 CONFIG_DM_HWSPINLOCK=y
 CONFIG_HWSPINLOCK_STM32=y
 CONFIG_DM_I2C=y
-- 
2.25.1

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

* [PATCH 1/2] ARM: stm32: Define I2C EEPROM bus and address on DHCOM
  2020-04-27 10:26 [PATCH 1/2] ARM: stm32: Define I2C EEPROM bus and address on DHCOM Marek Vasut
  2020-04-27 10:26 ` [PATCH 2/2] ARM: stm32: Hog GPIO PF7 high on DHCOM to unlock SPI NOR nWP Marek Vasut
@ 2020-04-27 13:39 ` Patrick DELAUNAY
  2020-05-14  9:37 ` Patrick DELAUNAY
  2 siblings, 0 replies; 6+ messages in thread
From: Patrick DELAUNAY @ 2020-04-27 13:39 UTC (permalink / raw)
  To: u-boot

Dear Marek,

> From: Marek Vasut <marex@denx.de>
> Sent: lundi 27 avril 2020 12:27
> 
> Define I2C EEPROM bus and address, so that the 'eeprom' command uses the
> correct ones and does not generate the following error:
>     eeprom_rw_block: Cannot find udev for a bus 0
> 
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Patrick Delaunay <patrick.delaunay@st.com>
> Cc: Patrice Chotard <patrice.chotard@st.com>
> ---
>  configs/stm32mp15_dhcom_basic_defconfig | 2 ++
>  1 file changed, 2 insertions(+)
> 

Reviewed-by: Patrick Delaunay <patrick.delaunay@st.com>

Thanks

Patrick

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

* [PATCH 2/2] ARM: stm32: Hog GPIO PF7 high on DHCOM to unlock SPI NOR nWP
  2020-04-27 10:26 ` [PATCH 2/2] ARM: stm32: Hog GPIO PF7 high on DHCOM to unlock SPI NOR nWP Marek Vasut
@ 2020-04-28  8:42   ` Patrick DELAUNAY
  2020-05-14  9:38   ` Patrick DELAUNAY
  1 sibling, 0 replies; 6+ messages in thread
From: Patrick DELAUNAY @ 2020-04-28  8:42 UTC (permalink / raw)
  To: u-boot

Dear Marek,

> From: Marek Vasut <marex@denx.de>
> Sent: lundi 27 avril 2020 12:27
> 
> The SPI NOR nWP line is connected to GPIO PF7 on the SoM, pull the GPIO line
> high by default to clear SPI NOR WP.
> 
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Patrick Delaunay <patrick.delaunay@st.com>
> Cc: Patrice Chotard <patrice.chotard@st.com>
> ---
>  arch/arm/dts/stm32mp15xx-dhcom-u-boot.dtsi | 9 +++++++++
>  configs/stm32mp15_dhcom_basic_defconfig    | 1 +
>  2 files changed, 10 insertions(+)
> 

Reviewed-by: Patrick Delaunay <patrick.delaunay@st.com>

Thanks

Patrick

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

* [PATCH 1/2] ARM: stm32: Define I2C EEPROM bus and address on DHCOM
  2020-04-27 10:26 [PATCH 1/2] ARM: stm32: Define I2C EEPROM bus and address on DHCOM Marek Vasut
  2020-04-27 10:26 ` [PATCH 2/2] ARM: stm32: Hog GPIO PF7 high on DHCOM to unlock SPI NOR nWP Marek Vasut
  2020-04-27 13:39 ` [PATCH 1/2] ARM: stm32: Define I2C EEPROM bus and address on DHCOM Patrick DELAUNAY
@ 2020-05-14  9:37 ` Patrick DELAUNAY
  2 siblings, 0 replies; 6+ messages in thread
From: Patrick DELAUNAY @ 2020-05-14  9:37 UTC (permalink / raw)
  To: u-boot

Hi,

> From: Marek Vasut <marex@denx.de>
> Sent: lundi 27 avril 2020 12:27
> 
> Define I2C EEPROM bus and address, so that the 'eeprom' command uses the
> correct ones and does not generate the following error:
>     eeprom_rw_block: Cannot find udev for a bus 0
> 
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Patrick Delaunay <patrick.delaunay@st.com>
> Cc: Patrice Chotard <patrice.chotard@st.com>
> ---
>  configs/stm32mp15_dhcom_basic_defconfig | 2 ++
>  1 file changed, 2 insertions(+)
> 

Applied to u-boot-stm/master, thanks!

Regards

Patrick

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

* [PATCH 2/2] ARM: stm32: Hog GPIO PF7 high on DHCOM to unlock SPI NOR nWP
  2020-04-27 10:26 ` [PATCH 2/2] ARM: stm32: Hog GPIO PF7 high on DHCOM to unlock SPI NOR nWP Marek Vasut
  2020-04-28  8:42   ` Patrick DELAUNAY
@ 2020-05-14  9:38   ` Patrick DELAUNAY
  1 sibling, 0 replies; 6+ messages in thread
From: Patrick DELAUNAY @ 2020-05-14  9:38 UTC (permalink / raw)
  To: u-boot

Hi

> From: Marek Vasut <marex@denx.de>
> Sent: lundi 27 avril 2020 12:27
> 
> The SPI NOR nWP line is connected to GPIO PF7 on the SoM, pull the GPIO line
> high by default to clear SPI NOR WP.
> 
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Patrick Delaunay <patrick.delaunay@st.com>
> Cc: Patrice Chotard <patrice.chotard@st.com>
> ---
>  arch/arm/dts/stm32mp15xx-dhcom-u-boot.dtsi | 9 +++++++++
>  configs/stm32mp15_dhcom_basic_defconfig    | 1 +
>  2 files changed, 10 insertions(+)
> 
Applied to u-boot-stm/master, thanks!

Regards

Patrick

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

end of thread, other threads:[~2020-05-14  9:38 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-27 10:26 [PATCH 1/2] ARM: stm32: Define I2C EEPROM bus and address on DHCOM Marek Vasut
2020-04-27 10:26 ` [PATCH 2/2] ARM: stm32: Hog GPIO PF7 high on DHCOM to unlock SPI NOR nWP Marek Vasut
2020-04-28  8:42   ` Patrick DELAUNAY
2020-05-14  9:38   ` Patrick DELAUNAY
2020-04-27 13:39 ` [PATCH 1/2] ARM: stm32: Define I2C EEPROM bus and address on DHCOM Patrick DELAUNAY
2020-05-14  9:37 ` Patrick DELAUNAY

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.