diff mbox series

[10/10] am335x: add support for cape detect functionality

Message ID 20210218132938.2168-11-kory.maincent@bootlin.com
State Superseded
Delegated to: Tom Rini
Headers show
Series Add support for extension boards detection and DT overlays application | expand

Commit Message

Kory Maincent Feb. 18, 2021, 1:29 p.m. UTC
Update the Kconfig and the board file to make the am335x board compatible
with cape detection.

Signed-off-by: Kory Maincent <kory.maincent@bootlin.com>
---
 arch/arm/mach-omap2/am33xx/Kconfig | 1 +
 board/ti/am335x/board.c            | 1 +
 include/configs/am335x_evm.h       | 2 ++
 3 files changed, 4 insertions(+)

Comments

Tom Rini Feb. 19, 2021, 4:55 p.m. UTC | #1
On Thu, Feb 18, 2021 at 02:29:38PM +0100, Kory Maincent wrote:

> Update the Kconfig and the board file to make the am335x board compatible
> with cape detection.
> 
> Signed-off-by: Kory Maincent <kory.maincent@bootlin.com>
> ---
>  arch/arm/mach-omap2/am33xx/Kconfig | 1 +
>  board/ti/am335x/board.c            | 1 +
>  include/configs/am335x_evm.h       | 2 ++
>  3 files changed, 4 insertions(+)
[snip]
> +#define CONFIG_CAPE_EEPROM_BUS_NUM	2

You can't add new CONFIG options like that outside of Kconfig.
diff mbox series

Patch

diff --git a/arch/arm/mach-omap2/am33xx/Kconfig b/arch/arm/mach-omap2/am33xx/Kconfig
index 9a98e8a0a9..11e54cd293 100644
--- a/arch/arm/mach-omap2/am33xx/Kconfig
+++ b/arch/arm/mach-omap2/am33xx/Kconfig
@@ -34,6 +34,7 @@  config TARGET_AM335X_EVM
 	select DM_GPIO
 	select DM_SERIAL
 	select TI_I2C_BOARD_DETECT
+	select SUPPORT_EXTENSION_SCAN
 	imply CMD_DM
 	imply SPL_DM
 	imply SPL_DM_SEQ_ALIAS
diff --git a/board/ti/am335x/board.c b/board/ti/am335x/board.c
index 56cdda856c..eb5cbd3b30 100644
--- a/board/ti/am335x/board.c
+++ b/board/ti/am335x/board.c
@@ -43,6 +43,7 @@ 
 #include <env_internal.h>
 #include <watchdog.h>
 #include "../common/board_detect.h"
+#include "../common/cape_detect.h"
 #include "board.h"
 
 DECLARE_GLOBAL_DATA_PTR;
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
index 5af90d932d..65835e094d 100644
--- a/include/configs/am335x_evm.h
+++ b/include/configs/am335x_evm.h
@@ -188,6 +188,8 @@ 
 #define CONFIG_SYS_I2C_EEPROM_ADDR	0x50	/* Main EEPROM */
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN	2
 
+#define CONFIG_CAPE_EEPROM_BUS_NUM	2
+
 /* PMIC support */
 #define CONFIG_POWER_TPS65217
 #define CONFIG_POWER_TPS65910