All of lore.kernel.org
 help / color / mirror / Atom feed
From: Abel Vesa <abel.vesa@nxp.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v3 01/22] usb: Rename SPL_USB_SUPPORT to SPL_USB_STORAGE
Date: Wed, 30 Jan 2019 13:39:51 +0000	[thread overview]
Message-ID: <1548855578-12529-2-git-send-email-abel.vesa@nxp.com> (raw)
In-Reply-To: <1548855578-12529-1-git-send-email-abel.vesa@nxp.com>

Since there is the SPL_USB_HOST_SUPPORT for enabling USB support in SPL,
makes more sense to rename the SPL_USB_SUPPORT as SPL_USB_STORAGE.
Everything that is not part of the usb storage support in SPL is now
build under SPL_USB_HOST_SUPPORT.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
---
 arch/arm/include/asm/arch-am33xx/spl.h    | 2 +-
 arch/arm/mach-omap2/boot-common.c         | 2 +-
 common/Makefile                           | 5 +++--
 common/spl/Kconfig                        | 4 ++--
 common/spl/Makefile                       | 2 +-
 common/spl/spl_usb.c                      | 4 ----
 configs/am43xx_evm_usbhost_boot_defconfig | 2 +-
 configs/am43xx_hs_evm_defconfig           | 2 +-
 8 files changed, 10 insertions(+), 13 deletions(-)

diff --git a/arch/arm/include/asm/arch-am33xx/spl.h b/arch/arm/include/asm/arch-am33xx/spl.h
index 0bf8c17..f3910c2 100644
--- a/arch/arm/include/asm/arch-am33xx/spl.h
+++ b/arch/arm/include/asm/arch-am33xx/spl.h
@@ -62,7 +62,7 @@
 #define BOOT_DEVICE_CPGMAC	0x47
 
 #define MMC_BOOT_DEVICES_START	BOOT_DEVICE_MMC1
-#ifdef CONFIG_SPL_USB_SUPPORT
+#ifdef CONFIG_SPL_USB_STORAGE
 #define MMC_BOOT_DEVICES_END	BOOT_DEVICE_USB
 #else
 #define MMC_BOOT_DEVICES_END	BOOT_DEVICE_MMC2
diff --git a/arch/arm/mach-omap2/boot-common.c b/arch/arm/mach-omap2/boot-common.c
index 2db1922..c8b8ac6 100644
--- a/arch/arm/mach-omap2/boot-common.c
+++ b/arch/arm/mach-omap2/boot-common.c
@@ -93,7 +93,7 @@ void save_omap_boot_params(void)
 			sys_boot_device = 1;
 			break;
 #endif
-#if defined(BOOT_DEVICE_USB) && !defined(CONFIG_SPL_USB_SUPPORT)
+#if defined(BOOT_DEVICE_USB) && !defined(CONFIG_SPL_USB_STORAGE)
 		case BOOT_DEVICE_USB:
 			sys_boot_device = 1;
 			break;
diff --git a/common/Makefile b/common/Makefile
index ad390d0..8c92feb 100644
--- a/common/Makefile
+++ b/common/Makefile
@@ -75,8 +75,9 @@ obj-$(CONFIG_SPL_NET_SUPPORT) += miiphyutil.o
 obj-$(CONFIG_$(SPL_TPL_)OF_LIBFDT) += fdt_support.o
 
 ifdef CONFIG_SPL_USB_HOST_SUPPORT
-obj-$(CONFIG_SPL_USB_SUPPORT) += usb.o usb_hub.o
-obj-$(CONFIG_USB_STORAGE) += usb_storage.o
+obj-y += usb.o
+obj-y += usb_hub.o
+obj-$(CONFIG_SPL_USB_STORAGE) += usb_storage.o
 else
 obj-$(CONFIG_USB_MUSB_HOST) += usb.o
 endif
diff --git a/common/spl/Kconfig b/common/spl/Kconfig
index 54b0dc3..8b0627e 100644
--- a/common/spl/Kconfig
+++ b/common/spl/Kconfig
@@ -766,9 +766,9 @@ config SPL_USB_HOST_SUPPORT
 	  device can be attached. This option enables the drivers in
 	  drivers/usb/host as part of an SPL build.
 
-config SPL_USB_SUPPORT
+config SPL_USB_STORAGE
 	bool "Support loading from USB"
-	depends on SPL_USB_HOST_SUPPORT
+	depends on SPL_USB_HOST_SUPPORT && !(BLK && !DM_USB)
 	help
 	  Enable support for USB devices in SPL. This allows use of USB
 	  devices such as hard drives and flash drivers for loading U-Boot.
diff --git a/common/spl/Makefile b/common/spl/Makefile
index 6f8d759..a3980ce 100644
--- a/common/spl/Makefile
+++ b/common/spl/Makefile
@@ -22,7 +22,7 @@ obj-$(CONFIG_$(SPL_TPL_)NET_SUPPORT) += spl_net.o
 obj-$(CONFIG_$(SPL_TPL_)MMC_SUPPORT) += spl_mmc.o
 obj-$(CONFIG_$(SPL_TPL_)ATF) += spl_atf.o
 obj-$(CONFIG_$(SPL_TPL_)OPTEE) += spl_optee.o
-obj-$(CONFIG_$(SPL_TPL_)USB_SUPPORT) += spl_usb.o
+obj-$(CONFIG_$(SPL_TPL_)USB_STORAGE) += spl_usb.o
 obj-$(CONFIG_$(SPL_TPL_)FAT_SUPPORT) += spl_fat.o
 obj-$(CONFIG_$(SPL_TPL_)EXT_SUPPORT) += spl_ext.o
 obj-$(CONFIG_$(SPL_TPL_)SATA_SUPPORT) += spl_sata.o
diff --git a/common/spl/spl_usb.c b/common/spl/spl_usb.c
index c8d8231..e29d579 100644
--- a/common/spl/spl_usb.c
+++ b/common/spl/spl_usb.c
@@ -15,9 +15,7 @@
 #include <usb.h>
 #include <fat.h>
 
-#ifdef CONFIG_USB_STORAGE
 static int usb_stor_curr_dev = -1; /* current device */
-#endif
 
 static int spl_usb_load_image(struct spl_image_info *spl_image,
 			      struct spl_boot_device *bootdev)
@@ -34,13 +32,11 @@ static int spl_usb_load_image(struct spl_image_info *spl_image,
 		return err;
 	}
 
-#ifdef CONFIG_USB_STORAGE
 	/* try to recognize storage devices immediately */
 	usb_stor_curr_dev = usb_stor_scan(1);
 	stor_dev = blk_get_devnum_by_type(IF_TYPE_USB, usb_stor_curr_dev);
 	if (!stor_dev)
 		return -ENODEV;
-#endif
 
 	debug("boot mode - FAT\n");
 
diff --git a/configs/am43xx_evm_usbhost_boot_defconfig b/configs/am43xx_evm_usbhost_boot_defconfig
index 5131f19..5bd919b 100644
--- a/configs/am43xx_evm_usbhost_boot_defconfig
+++ b/configs/am43xx_evm_usbhost_boot_defconfig
@@ -14,7 +14,7 @@ CONFIG_VERSION_VARIABLE=y
 CONFIG_SPL_MTD_SUPPORT=y
 CONFIG_SPL_OS_BOOT=y
 CONFIG_SPL_USB_HOST_SUPPORT=y
-CONFIG_SPL_USB_SUPPORT=y
+CONFIG_SPL_USB_STORAGE=y
 CONFIG_CMD_SPL=y
 CONFIG_CMD_SPL_NAND_OFS=0x00100000
 CONFIG_CMD_SPL_WRITE_SIZE=0x40000
diff --git a/configs/am43xx_hs_evm_defconfig b/configs/am43xx_hs_evm_defconfig
index 99e4ccb..c01fda9 100644
--- a/configs/am43xx_hs_evm_defconfig
+++ b/configs/am43xx_hs_evm_defconfig
@@ -24,7 +24,7 @@ CONFIG_SPL_MTD_SUPPORT=y
 CONFIG_SPL_NET_SUPPORT=y
 CONFIG_SPL_NET_VCI_STRING="AM43xx U-Boot SPL"
 CONFIG_SPL_USB_HOST_SUPPORT=y
-CONFIG_SPL_USB_SUPPORT=y
+CONFIG_SPL_USB_STORAGE=y
 CONFIG_SPL_USB_GADGET=y
 CONFIG_SPL_USB_ETHER=y
 # CONFIG_CMD_FLASH is not set
-- 
2.7.4

  reply	other threads:[~2019-01-30 13:39 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-30 13:39 [U-Boot] [PATCH v3 00/22] mx6sabre: Add DM and SPL FIT support Abel Vesa
2019-01-30 13:39 ` Abel Vesa [this message]
2019-01-30 13:39 ` [U-Boot] [PATCH v3 02/22] usb: ehci-mx6: Make regulator DM_REGULATOR dependent Abel Vesa
2019-01-30 13:39 ` [U-Boot] [PATCH v3 03/22] configs: imx6sabreauto: Add DM_MMC support Abel Vesa
2019-01-30 13:39 ` [U-Boot] [PATCH v3 04/22] configs: imx6sabreauto: Add DM_USB support Abel Vesa
2019-01-30 13:39 ` [U-Boot] [PATCH v3 05/22] mmc: fsl_esdhc: Fix DM_REGULATOR ifdefs for SPL builds Abel Vesa
2019-01-30 13:39 ` [U-Boot] [PATCH v3 06/22] board: mx6sabresd: Add board_fit_config_name_match to support FIT in SPL Abel Vesa
2019-01-30 13:39 ` [U-Boot] [PATCH v3 07/22] board: mx6sabreauto: " Abel Vesa
2019-01-30 13:39 ` [U-Boot] [PATCH v3 08/22] arm: dts: Add all the imx6[q|qp|dl] sabre[auto|sd] u-boot dts[i] files Abel Vesa
2019-01-30 13:39 ` [U-Boot] [PATCH v3 09/22] arm: dts: Update all the dts[i] files for imx6[q|qp|dl] sabre[auto|sd] Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 10/22] arm: imx: Add FIT SPL its Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 11/22] configs: mx6sabreauto: Add SPL FIT and DM support Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 12/22] configs: mx6sabresd: " Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 13/22] mx6sabreauto: Add DM_GPIO support Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 14/22] mx6sabresd: " Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 15/22] configs: mx6sabreauto: Add DM_SPI_FLASH necessary configs Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 16/22] configs: mx6sabresd: " Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 17/22] board: mx6sabreauto: Remove the non-DM code Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 18/22] board: mx6sabresd: Remove " Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 19/22] board: mx6sabresd: Remove the enet reset gpio handling Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 20/22] configs: mx6sabresd: Reduce size for SPL by disabling SPL_DOS and SPL_EFI Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 21/22] board: mx6sabreauto: Update README with the SPL DM FIT info Abel Vesa
2019-01-30 13:40 ` [U-Boot] [PATCH v3 22/22] board: mx6sabresd: " Abel Vesa
2019-01-30 18:58 ` [U-Boot] [PATCH v3 00/22] mx6sabre: Add DM and SPL FIT support Tom Rini
2019-01-31 12:59   ` Abel Vesa
2019-01-31 14:41     ` Tom Rini
2019-01-31 15:13       ` Abel Vesa
2019-01-31 15:45         ` Tom Rini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1548855578-12529-2-git-send-email-abel.vesa@nxp.com \
    --to=abel.vesa@nxp.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.