[PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
Due to how the Makefile logic is we currently get DM_SPI support in SPL enabled by having DM_SPI enabled for full U-Boot but not having CONFIG_SPL_DM_SPI set. Add this missing option to boards that were inadvertently making use of it. Cc: Adam Ford Cc: Akash Gajjar Cc: Anatolij Gustschin Cc: Andy Yan Cc: Anup Patel Cc: Atish Patra Cc: Bin Meng Cc: Chee Hong Ang Cc: Chin-Liang See Cc: Dalon Westergreen Cc: Dinh Nguyen Cc: Eugen Hristev Cc: Hannes Schmelzer Cc: Heiko Schocher Cc: Jagan Teki Cc: Klaus Goger Cc: Levin Du Cc: Ley Foon Tan Cc: Lokesh Vutla Cc: Luca Ceresoli Cc: Marek Vasut Cc: Michal Simek Cc: Mike Looijmans Cc: Nicolas Ferre Cc: Nikita Kiryanov Cc: Palmer Dabbelt Cc: Patrick Delaunay Cc: Paul Walmsley Cc: Pavel Machek Cc: Peter Robinson Cc: Philipp Tomsich Cc: Simon Glass Cc: Stefan Roese Cc: Suniel Mahesh Cc: Wolfgang Grandegger Signed-off-by: Tom Rini --- configs/am57xx_evm_defconfig | 1 + configs/am57xx_hs_evm_defconfig| 1 + configs/am57xx_hs_evm_usb_defconfig| 1 + configs/am65x_evm_a53_defconfig| 1 + configs/am65x_evm_r5_defconfig | 1 + configs/am65x_hs_evm_a53_defconfig | 1 + configs/am65x_hs_evm_r5_defconfig | 1 + configs/avnet_ultrazedev_cc_v1_0_ultrazedev_som_v1_0_defconfig | 1 + configs/axm_defconfig | 1 + configs/brppt1_spi_defconfig | 1 + configs/brsmarc1_defconfig | 1 + configs/chromebit_mickey_defconfig | 1 + configs/chromebook_bob_defconfig | 1 + configs/chromebook_coral_defconfig | 1 + configs/chromebook_jerry_defconfig | 1 + configs/chromebook_link64_defconfig| 1 + configs/chromebook_minnie_defconfig| 1 + configs/chromebook_samus_tpl_defconfig | 1 + configs/chromebook_speedy_defconfig| 1 + configs/cm_t43_defconfig | 1 + configs/da850evm_defconfig | 1 + configs/da850evm_nand_defconfig| 1 + configs/dra7xx_evm_defconfig | 1 + configs/dra7xx_hs_evm_defconfig| 1 + configs/dra7xx_hs_evm_usb_defconfig| 1 + configs/evb-px5_defconfig | 1 + configs/j721e_evm_a72_defconfig| 1 + configs/j721e_evm_r5_defconfig | 1 + configs/j721e_hs_evm_a72_defconfig | 1 + configs/j721e_hs_evm_r5_defconfig | 1 + configs/lion-rk3368_defconfig | 1 + configs/pinebook-pro-rk3399_defconfig | 1 + configs/puma-rk3399_defconfig | 1 + configs/qemu-x86_64_defconfig | 1 + configs/roc-pc-mezzanine-rk3399_defconfig | 1 + configs/roc-pc-rk3399_defconfig| 1 + configs/rockpro64-rk3399_defconfig | 1 + configs/sama5d27_wlsom1_ek_qspiflash_defconfig | 1 + configs/sama5d2_xplained_spiflash_defconfig| 1 + configs/sama5d3xek_spiflash_defconfig | 1 + configs/sama5d4_xplained_spiflash_defconfig| 1 + configs/sama5d4ek_spiflash_defconfig | 1 + configs/sifive_fu540_defconfig | 1 + configs/socfpga_agilex_defconfig | 1 + configs/socfpga_arria10_defconfig | 1 + configs/socfpga_arria5_defconfig | 1 + configs/socfpga_cyclone5_defconfig | 1 + configs/socfpga_dbm_soc1_defconfig | 1 + configs/socfpga_de0_nano_soc_defconfig | 1 + configs/socfpga_de10_nano_defconfig| 1 + configs/socfpga_de1_soc_defconfig | 1 + configs/socfpga_is1_defconfig | 1 + configs/socfpga_mcvevk_defconfig | 1 + configs/socfpga_sockit_defconfig | 1 + configs/socfpga_socrates_defconfig | 1 + configs/socfpga_sr1500_defconfig | 1 + configs/socfpga_stratix10_defconfig| 1 + configs/socfpga_vining_fpga_defconfig | 1 + configs/stm32mp15_
Re: [PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
On 6/10/20 10:16 PM, Tom Rini wrote: [...] > configs/socfpga_dbm_soc1_defconfig | 1 + > configs/socfpga_de0_nano_soc_defconfig | 1 + > configs/socfpga_de10_nano_defconfig| 1 + > configs/socfpga_de1_soc_defconfig | 1 + I don't think those de*_soc boards have a SPI NOR at all. And I'm also afraid that enabling this will make those boards overflow SPL size limits.
Re: [PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
On Wed, Jun 10, 2020 at 10:38:45PM +0200, Marek Vasut wrote: > On 6/10/20 10:16 PM, Tom Rini wrote: > [...] > > configs/socfpga_dbm_soc1_defconfig | 1 + > > configs/socfpga_de0_nano_soc_defconfig | 1 + > > configs/socfpga_de10_nano_defconfig| 1 + > > configs/socfpga_de1_soc_defconfig | 1 + > > I don't think those de*_soc boards have a SPI NOR at all. > And I'm also afraid that enabling this will make those boards overflow > SPL size limits. There is zero size change from this patch on any platform included in this patch. Today each of the boards you mention enables CONFIG_SPL_SPI_SUPPORT, CONFIG_SPL_SPI_FLASH_SUPPORT and then CONFIG_SPL_SPI_FLASH_TINY. That said, that means you aren't using SPL_DM_SPI for real, so I'll go take a look at what to change instead in the previous patch, thanks! -- Tom signature.asc Description: PGP signature
Re: [PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
On Wed, Jun 10, 2020 at 05:01:21PM -0400, Tom Rini wrote: > On Wed, Jun 10, 2020 at 10:38:45PM +0200, Marek Vasut wrote: > > On 6/10/20 10:16 PM, Tom Rini wrote: > > [...] > > > configs/socfpga_dbm_soc1_defconfig | 1 + > > > configs/socfpga_de0_nano_soc_defconfig | 1 + > > > configs/socfpga_de10_nano_defconfig| 1 + > > > configs/socfpga_de1_soc_defconfig | 1 + > > > > I don't think those de*_soc boards have a SPI NOR at all. > > And I'm also afraid that enabling this will make those boards overflow > > SPL size limits. > > There is zero size change from this patch on any platform included in > this patch. > > Today each of the boards you mention enables CONFIG_SPL_SPI_SUPPORT, > CONFIG_SPL_SPI_FLASH_SUPPORT and then CONFIG_SPL_SPI_FLASH_TINY. > > That said, that means you aren't using SPL_DM_SPI for real, so I'll go > take a look at what to change instead in the previous patch, thanks! Nope, check your platforms again. Based on looking over socfpga_de1_soc/spl/u-boot-spl.map it's not discarding a bunch of the DM SPI stuff as we're in fact building it today, and using the few functions that spi-mem-nodm.c provides from spi-mem.c instead. So this is correct for what's happening today. With Jagan's removal patches that I believe allow us to nuke drivers/spi/spi.c (and so the unconditional building of it) as it nukes the only platform that uses the only video driver that calls spi_set_wordlen() (spi_do_alloc_slave() is unused globally) we could then go ahead and do non-DM_SPI here, fully. -- Tom signature.asc Description: PGP signature
Re: [PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
On Wed, Jun 10, 2020 at 11:52:33PM +0200, Marek Vasut wrote: > On 6/10/20 11:48 PM, Tom Rini wrote: > > On Wed, Jun 10, 2020 at 05:01:21PM -0400, Tom Rini wrote: > >> On Wed, Jun 10, 2020 at 10:38:45PM +0200, Marek Vasut wrote: > >>> On 6/10/20 10:16 PM, Tom Rini wrote: > >>> [...] > configs/socfpga_dbm_soc1_defconfig | 1 + > configs/socfpga_de0_nano_soc_defconfig | 1 + > configs/socfpga_de10_nano_defconfig| 1 + > configs/socfpga_de1_soc_defconfig | 1 + > >>> > >>> I don't think those de*_soc boards have a SPI NOR at all. > >>> And I'm also afraid that enabling this will make those boards overflow > >>> SPL size limits. > >> > >> There is zero size change from this patch on any platform included in > >> this patch. > >> > >> Today each of the boards you mention enables CONFIG_SPL_SPI_SUPPORT, > >> CONFIG_SPL_SPI_FLASH_SUPPORT and then CONFIG_SPL_SPI_FLASH_TINY. > >> > >> That said, that means you aren't using SPL_DM_SPI for real, so I'll go > >> take a look at what to change instead in the previous patch, thanks! > > > > Nope, check your platforms again. Based on looking over > > socfpga_de1_soc/spl/u-boot-spl.map it's not discarding a bunch of the DM > > SPI stuff as we're in fact building it today, and using the few > > functions that spi-mem-nodm.c provides from spi-mem.c instead. So this > > is correct for what's happening today. > > Are you _sure_ the board has a SPI NOR on it at all ? I doubt all of > them do, so it seems some of those SPL DM SPI are copy-paste errors. I'm only as sure as what the board maintainer enabled. As they're on CC and see the answer is "Oh, I don't even have flash!" then they should go and fix that. My point is that it's not changing any platform sizes and is being explicit about what is implicit today based on the build logic in use. -- Tom signature.asc Description: PGP signature
Re: [PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
On 6/10/20 11:48 PM, Tom Rini wrote: > On Wed, Jun 10, 2020 at 05:01:21PM -0400, Tom Rini wrote: >> On Wed, Jun 10, 2020 at 10:38:45PM +0200, Marek Vasut wrote: >>> On 6/10/20 10:16 PM, Tom Rini wrote: >>> [...] configs/socfpga_dbm_soc1_defconfig | 1 + configs/socfpga_de0_nano_soc_defconfig | 1 + configs/socfpga_de10_nano_defconfig| 1 + configs/socfpga_de1_soc_defconfig | 1 + >>> >>> I don't think those de*_soc boards have a SPI NOR at all. >>> And I'm also afraid that enabling this will make those boards overflow >>> SPL size limits. >> >> There is zero size change from this patch on any platform included in >> this patch. >> >> Today each of the boards you mention enables CONFIG_SPL_SPI_SUPPORT, >> CONFIG_SPL_SPI_FLASH_SUPPORT and then CONFIG_SPL_SPI_FLASH_TINY. >> >> That said, that means you aren't using SPL_DM_SPI for real, so I'll go >> take a look at what to change instead in the previous patch, thanks! > > Nope, check your platforms again. Based on looking over > socfpga_de1_soc/spl/u-boot-spl.map it's not discarding a bunch of the DM > SPI stuff as we're in fact building it today, and using the few > functions that spi-mem-nodm.c provides from spi-mem.c instead. So this > is correct for what's happening today. Are you _sure_ the board has a SPI NOR on it at all ? I doubt all of them do, so it seems some of those SPL DM SPI are copy-paste errors.
Re: [PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
On Wed, Jun 10, 2020 at 3:17 PM Tom Rini wrote: > > Due to how the Makefile logic is we currently get DM_SPI support in SPL > enabled by having DM_SPI enabled for full U-Boot but not having > CONFIG_SPL_DM_SPI set. Add this missing option to boards that were > inadvertently making use of it. Not knowing exactly which patches to apply to see the Makefile changes in question, I'm just doing a code review instead of the test. > > Cc: Adam Ford [snip] Acked-by: Adam Ford #da850evm > Signed-off-by: Tom Rini > --- > configs/da850evm_defconfig | 1 + > configs/da850evm_nand_defconfig| 1 + The da850evm_defconfig is setup to boot from SPI Flash, so that board will need it. Thank you. The da850evm_nand_defconfig is set to boot from NAND via the NAND controller and not SPI, so it's probably not necessary, but I don't think it hurts anything. I may go through later and remove the CONFIG_SPL_DM_SPI from the nand version later. [snip] > diff --git a/configs/da850evm_defconfig b/configs/da850evm_defconfig > index 1a6a97ed161a..12768065f3ab 100644 > --- a/configs/da850evm_defconfig > +++ b/configs/da850evm_defconfig > @@ -12,6 +12,7 @@ CONFIG_ENV_OFFSET=0x8 > CONFIG_ENV_SECT_SIZE=0x1 > CONFIG_SYS_SPI_U_BOOT_OFFS=0x8000 > CONFIG_DM_GPIO=y > +CONFIG_SPL_DM_SPI=y Thank you, we'll need this. > CONFIG_SPL_SERIAL_SUPPORT=y > CONFIG_NR_DRAM_BANKS=1 > CONFIG_SPL=y > diff --git a/configs/da850evm_nand_defconfig b/configs/da850evm_nand_defconfig > index e805f2c10eda..13026fd1ea2c 100644 > --- a/configs/da850evm_nand_defconfig > +++ b/configs/da850evm_nand_defconfig > @@ -11,6 +11,7 @@ CONFIG_ENV_SIZE=0x2 > CONFIG_ENV_OFFSET=0x0 > CONFIG_SYS_SPI_U_BOOT_OFFS=0x8000 > CONFIG_DM_GPIO=y > +CONFIG_SPL_DM_SPI=y If you do a V2 for some reason and don't want to add this here in the future, I wouldn't object. If not, I'll do some testing later with this removed. > CONFIG_SPL_SERIAL_SUPPORT=y > CONFIG_SPL=y > CONFIG_SPL_SPI_FLASH_SUPPORT=y [snip] > -- > 2.17.1 >
Re: [PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
On Thu, Jun 11, 2020 at 05:38:15AM -0500, Adam Ford wrote: > On Wed, Jun 10, 2020 at 3:17 PM Tom Rini wrote: > > > > Due to how the Makefile logic is we currently get DM_SPI support in SPL > > enabled by having DM_SPI enabled for full U-Boot but not having > > CONFIG_SPL_DM_SPI set. Add this missing option to boards that were > > inadvertently making use of it. > > Not knowing exactly which patches to apply to see the Makefile changes > in question, I'm just doing a code review instead of the test. > > > > Cc: Adam Ford > [snip] > > Acked-by: Adam Ford #da850evm > > > Signed-off-by: Tom Rini > > --- > > > configs/da850evm_defconfig | 1 + > > configs/da850evm_nand_defconfig| 1 + > > The da850evm_defconfig is setup to boot from SPI Flash, so that board > will need it. Thank you. > > The da850evm_nand_defconfig is set to boot from NAND via the NAND > controller and not SPI, so it's probably not necessary, but I don't > think it hurts anything. I may go through later and remove the > CONFIG_SPL_DM_SPI from the nand version later. > > [snip] > > > diff --git a/configs/da850evm_defconfig b/configs/da850evm_defconfig > > index 1a6a97ed161a..12768065f3ab 100644 > > --- a/configs/da850evm_defconfig > > +++ b/configs/da850evm_defconfig > > @@ -12,6 +12,7 @@ CONFIG_ENV_OFFSET=0x8 > > CONFIG_ENV_SECT_SIZE=0x1 > > CONFIG_SYS_SPI_U_BOOT_OFFS=0x8000 > > CONFIG_DM_GPIO=y > > +CONFIG_SPL_DM_SPI=y > > Thank you, we'll need this. > > > CONFIG_SPL_SERIAL_SUPPORT=y > > CONFIG_NR_DRAM_BANKS=1 > > CONFIG_SPL=y > > diff --git a/configs/da850evm_nand_defconfig > > b/configs/da850evm_nand_defconfig > > index e805f2c10eda..13026fd1ea2c 100644 > > --- a/configs/da850evm_nand_defconfig > > +++ b/configs/da850evm_nand_defconfig > > @@ -11,6 +11,7 @@ CONFIG_ENV_SIZE=0x2 > > CONFIG_ENV_OFFSET=0x0 > > CONFIG_SYS_SPI_U_BOOT_OFFS=0x8000 > > CONFIG_DM_GPIO=y > > +CONFIG_SPL_DM_SPI=y > > If you do a V2 for some reason and don't want to add this here in the > future, I wouldn't object. If not, I'll do some testing later with > this removed. This is similar to the socfpga case Marek pointed out. Today, the platforms are building with SPI support enabled and are implicitly getting SPL_DM_SPI enabled too http://patchwork.ozlabs.org/project/uboot/patch/20200610201634.8457-30-tr...@konsulko.com/ is the Makefile patch but it's just dropping in to the DM or not-DM side based on SPL/TPL_DM and not just DM in main U-Boot. -- Tom signature.asc Description: PGP signature
RE: [PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
Dear Tom > From: Tom Rini > Sent: mercredi 10 juin 2020 22:17 > > Due to how the Makefile logic is we currently get DM_SPI support in SPL > enabled > by having DM_SPI enabled for full U-Boot but not having CONFIG_SPL_DM_SPI > set. Add this missing option to boards that were inadvertently making use of > it. > > Cc: Adam Ford > Cc: Akash Gajjar > Cc: Anatolij Gustschin > Cc: Andy Yan > Cc: Anup Patel > Cc: Atish Patra > Cc: Bin Meng > Cc: Chee Hong Ang > Cc: Chin-Liang See > Cc: Dalon Westergreen > Cc: Dinh Nguyen > Cc: Eugen Hristev > Cc: Hannes Schmelzer > Cc: Heiko Schocher > Cc: Jagan Teki > Cc: Klaus Goger > Cc: Levin Du > Cc: Ley Foon Tan > Cc: Lokesh Vutla > Cc: Luca Ceresoli > Cc: Marek Vasut > Cc: Michal Simek > Cc: Mike Looijmans > Cc: Nicolas Ferre > Cc: Nikita Kiryanov > Cc: Palmer Dabbelt > Cc: Patrick Delaunay > Cc: Paul Walmsley > Cc: Pavel Machek > Cc: Peter Robinson > Cc: Philipp Tomsich > Cc: Simon Glass > Cc: Stefan Roese > Cc: Suniel Mahesh > Cc: Wolfgang Grandegger > Signed-off-by: Tom Rini > --- > configs/am57xx_evm_defconfig | 1 + > configs/am57xx_hs_evm_defconfig| 1 + > configs/am57xx_hs_evm_usb_defconfig| 1 + > configs/am65x_evm_a53_defconfig| 1 + > configs/am65x_evm_r5_defconfig | 1 + > configs/am65x_hs_evm_a53_defconfig | 1 + > configs/am65x_hs_evm_r5_defconfig | 1 + > configs/avnet_ultrazedev_cc_v1_0_ultrazedev_som_v1_0_defconfig | 1 + > configs/axm_defconfig | 1 + > configs/brppt1_spi_defconfig | 1 + > configs/brsmarc1_defconfig | 1 + > configs/chromebit_mickey_defconfig | 1 + > configs/chromebook_bob_defconfig | 1 + > configs/chromebook_coral_defconfig | 1 + > configs/chromebook_jerry_defconfig | 1 + > configs/chromebook_link64_defconfig| 1 + > configs/chromebook_minnie_defconfig| 1 + > configs/chromebook_samus_tpl_defconfig | 1 + > configs/chromebook_speedy_defconfig| 1 + > configs/cm_t43_defconfig | 1 + > configs/da850evm_defconfig | 1 + > configs/da850evm_nand_defconfig| 1 + > configs/dra7xx_evm_defconfig | 1 + > configs/dra7xx_hs_evm_defconfig| 1 + > configs/dra7xx_hs_evm_usb_defconfig| 1 + > configs/evb-px5_defconfig | 1 + > configs/j721e_evm_a72_defconfig| 1 + > configs/j721e_evm_r5_defconfig | 1 + > configs/j721e_hs_evm_a72_defconfig | 1 + > configs/j721e_hs_evm_r5_defconfig | 1 + > configs/lion-rk3368_defconfig | 1 + > configs/pinebook-pro-rk3399_defconfig | 1 + > configs/puma-rk3399_defconfig | 1 + > configs/qemu-x86_64_defconfig | 1 + > configs/roc-pc-mezzanine-rk3399_defconfig | 1 + > configs/roc-pc-rk3399_defconfig| 1 + > configs/rockpro64-rk3399_defconfig | 1 + > configs/sama5d27_wlsom1_ek_qspiflash_defconfig | 1 + > configs/sama5d2_xplained_spiflash_defconfig| 1 + > configs/sama5d3xek_spiflash_defconfig | 1 + > configs/sama5d4_xplained_spiflash_defconfig| 1 + > configs/sama5d4ek_spiflash_defconfig | 1 + > configs/sifive_fu540_defconfig | 1 + > configs/socfpga_agilex_defconfig | 1 + > configs/socfpga_arria10_defconfig | 1 + > configs/socfpga_arria5_defconfig | 1 + > configs/socfpga_cyclone5_defconfig | 1 + > configs/socfpga_dbm_soc1_defconfig | 1 + > configs/socfpga_de0_nano_soc_defconfig | 1 + > configs/socfpga_de10_nano_defconfig| 1 + > configs/socfpga_de1_soc_defconfig | 1 + > configs/socfpga_is1_defconfig | 1 + > configs/socfpga_mcvevk_defconfig | 1 + > configs/socfpga_sockit_defconfig | 1 + > configs/socfpga_socrates_defconfi
Re: [PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
On Thu, Jun 11, 2020 at 9:09 PM Adam Ford wrote: > > On Thu, Jun 11, 2020 at 7:17 AM Tom Rini wrote: > > > > On Thu, Jun 11, 2020 at 05:38:15AM -0500, Adam Ford wrote: > > > On Wed, Jun 10, 2020 at 3:17 PM Tom Rini wrote: > > > > > > > > Due to how the Makefile logic is we currently get DM_SPI support in SPL > > > > enabled by having DM_SPI enabled for full U-Boot but not having > > > > CONFIG_SPL_DM_SPI set. Add this missing option to boards that were > > > > inadvertently making use of it. > > > > > > Not knowing exactly which patches to apply to see the Makefile changes > > > in question, I'm just doing a code review instead of the test. > > > > > > > > Cc: Adam Ford > > > [snip] > > > > > > Acked-by: Adam Ford #da850evm > > > > > Tested-by: Adam Ford #da850evm > > > > > Signed-off-by: Tom Rini > > > > --- > > > > > > > configs/da850evm_defconfig | 1 + > > > > configs/da850evm_nand_defconfig| 1 + > > > > > > The da850evm_defconfig is setup to boot from SPI Flash, so that board > > > will need it. Thank you. > > > > > > The da850evm_nand_defconfig is set to boot from NAND via the NAND > > > controller and not SPI, so it's probably not necessary, but I don't > > > think it hurts anything. I may go through later and remove the > > > CONFIG_SPL_DM_SPI from the nand version later. > > > > > > [snip] > > > > > > > diff --git a/configs/da850evm_defconfig b/configs/da850evm_defconfig > > > > index 1a6a97ed161a..12768065f3ab 100644 > > > > --- a/configs/da850evm_defconfig > > > > +++ b/configs/da850evm_defconfig > > > > @@ -12,6 +12,7 @@ CONFIG_ENV_OFFSET=0x8 > > > > CONFIG_ENV_SECT_SIZE=0x1 > > > > CONFIG_SYS_SPI_U_BOOT_OFFS=0x8000 > > > > CONFIG_DM_GPIO=y > > > > +CONFIG_SPL_DM_SPI=y > > > > > > Thank you, we'll need this. > > > > > > > CONFIG_SPL_SERIAL_SUPPORT=y > > > > CONFIG_NR_DRAM_BANKS=1 > > > > CONFIG_SPL=y > > > > diff --git a/configs/da850evm_nand_defconfig > > > > b/configs/da850evm_nand_defconfig > > > > index e805f2c10eda..13026fd1ea2c 100644 > > > > --- a/configs/da850evm_nand_defconfig > > > > +++ b/configs/da850evm_nand_defconfig > > > > @@ -11,6 +11,7 @@ CONFIG_ENV_SIZE=0x2 > > > > CONFIG_ENV_OFFSET=0x0 > > > > CONFIG_SYS_SPI_U_BOOT_OFFS=0x8000 > > > > CONFIG_DM_GPIO=y > > > > +CONFIG_SPL_DM_SPI=y I just sent a separate patch removing SPI from SPL from the nand defconfig since the system is booting from NAND to free up some space. I don't know how that plays into this patch for the nand version. If you need to apply your patch first, I can always rebase mine and re-submit later. adam > > > > > > If you do a V2 for some reason and don't want to add this here in the > > > future, I wouldn't object. If not, I'll do some testing later with > > > this removed. > > > > This is similar to the socfpga case Marek pointed out. Today, the > > platforms are building with SPI support enabled and are implicitly > > getting SPL_DM_SPI enabled too > > http://patchwork.ozlabs.org/project/uboot/patch/20200610201634.8457-30-tr...@konsulko.com/ > > is the Makefile patch but it's just dropping in to the DM or not-DM side > > based on SPL/TPL_DM and not just DM in main U-Boot. > > > > -- > > Tom
Re: [PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
On Thu, Jun 11, 2020 at 7:17 AM Tom Rini wrote: > > On Thu, Jun 11, 2020 at 05:38:15AM -0500, Adam Ford wrote: > > On Wed, Jun 10, 2020 at 3:17 PM Tom Rini wrote: > > > > > > Due to how the Makefile logic is we currently get DM_SPI support in SPL > > > enabled by having DM_SPI enabled for full U-Boot but not having > > > CONFIG_SPL_DM_SPI set. Add this missing option to boards that were > > > inadvertently making use of it. > > > > Not knowing exactly which patches to apply to see the Makefile changes > > in question, I'm just doing a code review instead of the test. > > > > > > Cc: Adam Ford > > [snip] > > > > Acked-by: Adam Ford #da850evm > > Tested-by: Adam Ford #da850evm > > > Signed-off-by: Tom Rini > > > --- > > > > > configs/da850evm_defconfig | 1 + > > > configs/da850evm_nand_defconfig| 1 + > > > > The da850evm_defconfig is setup to boot from SPI Flash, so that board > > will need it. Thank you. > > > > The da850evm_nand_defconfig is set to boot from NAND via the NAND > > controller and not SPI, so it's probably not necessary, but I don't > > think it hurts anything. I may go through later and remove the > > CONFIG_SPL_DM_SPI from the nand version later. > > > > [snip] > > > > > diff --git a/configs/da850evm_defconfig b/configs/da850evm_defconfig > > > index 1a6a97ed161a..12768065f3ab 100644 > > > --- a/configs/da850evm_defconfig > > > +++ b/configs/da850evm_defconfig > > > @@ -12,6 +12,7 @@ CONFIG_ENV_OFFSET=0x8 > > > CONFIG_ENV_SECT_SIZE=0x1 > > > CONFIG_SYS_SPI_U_BOOT_OFFS=0x8000 > > > CONFIG_DM_GPIO=y > > > +CONFIG_SPL_DM_SPI=y > > > > Thank you, we'll need this. > > > > > CONFIG_SPL_SERIAL_SUPPORT=y > > > CONFIG_NR_DRAM_BANKS=1 > > > CONFIG_SPL=y > > > diff --git a/configs/da850evm_nand_defconfig > > > b/configs/da850evm_nand_defconfig > > > index e805f2c10eda..13026fd1ea2c 100644 > > > --- a/configs/da850evm_nand_defconfig > > > +++ b/configs/da850evm_nand_defconfig > > > @@ -11,6 +11,7 @@ CONFIG_ENV_SIZE=0x2 > > > CONFIG_ENV_OFFSET=0x0 > > > CONFIG_SYS_SPI_U_BOOT_OFFS=0x8000 > > > CONFIG_DM_GPIO=y > > > +CONFIG_SPL_DM_SPI=y > > > > If you do a V2 for some reason and don't want to add this here in the > > future, I wouldn't object. If not, I'll do some testing later with > > this removed. > > This is similar to the socfpga case Marek pointed out. Today, the > platforms are building with SPI support enabled and are implicitly > getting SPL_DM_SPI enabled too > http://patchwork.ozlabs.org/project/uboot/patch/20200610201634.8457-30-tr...@konsulko.com/ > is the Makefile patch but it's just dropping in to the DM or not-DM side > based on SPL/TPL_DM and not just DM in main U-Boot. > > -- > Tom
Re: [PATCH 28/30] spi: Enable missing CONFIG_SPL_DM_SPI support
Hi Tom, On 10/06/20 22:16, Tom Rini wrote: > Due to how the Makefile logic is we currently get DM_SPI support in SPL > enabled by having DM_SPI enabled for full U-Boot but not having > CONFIG_SPL_DM_SPI set. Add this missing option to boards that were > inadvertently making use of it. > > Cc: Adam Ford > Cc: Akash Gajjar > Cc: Anatolij Gustschin > Cc: Andy Yan > Cc: Anup Patel > Cc: Atish Patra > Cc: Bin Meng > Cc: Chee Hong Ang > Cc: Chin-Liang See > Cc: Dalon Westergreen > Cc: Dinh Nguyen > Cc: Eugen Hristev > Cc: Hannes Schmelzer > Cc: Heiko Schocher > Cc: Jagan Teki > Cc: Klaus Goger > Cc: Levin Du > Cc: Ley Foon Tan > Cc: Lokesh Vutla > Cc: Luca Ceresoli > Cc: Marek Vasut > Cc: Michal Simek > Cc: Mike Looijmans > Cc: Nicolas Ferre > Cc: Nikita Kiryanov > Cc: Palmer Dabbelt > Cc: Patrick Delaunay > Cc: Paul Walmsley > Cc: Pavel Machek > Cc: Peter Robinson > Cc: Philipp Tomsich > Cc: Simon Glass > Cc: Stefan Roese > Cc: Suniel Mahesh > Cc: Wolfgang Grandegger > Signed-off-by: Tom Rini For the Avnet Ultrazed: > configs/avnet_ultrazedev_cc_v1_0_ultrazedev_som_v1_0_defconfig | 1 + Reviewed-by: Luca Ceresoli -- Luca