25 Oct, 2019
19 commits
-
Most boards currently use SPI_FLASH_MTD only in U-Boot proper, not in
SPL. They often rely on hacks in the board header files to include
this option conditionally. To be able to fix this, we previously
introduced a separate option SPL_SPI_FLASH_MTD.Therefore we can now adjust the Makefile and change the code in
sf_probe.c and sf_internal.h to use CONFIG_IS_ENABLED(SPI_FLASH_MTD).We also need to move all occurences of CONFIG_SPI_FLASH_MTD from the
header files to the according defconfigs. The affected boards are
socfpga, aristainetos, cm_fx6, display5, ventana, rcar-gen2, dh_imx6
and da850evm.We do this all in one patch to guarantee bisectibility.
This change was tested with buildman to make sure it does not
introduce any regressions by comparing the resulting binary sizes.Signed-off-by: Frieder Schrempf
Reviewed-by: Stefan Roese
Reviewed-by: Simon Goldschmidt
Acked-by: Lukasz Majewski
Reviewed-by: Heiko Schocher
Reviewed-by: Jagan Teki -
n25q* and mt25q* (both 256Mb and 512Mb) flashes support Flag status
register that indicates various errors that may be encountered during
erase/write operations. Therefore add USE_FSR flag wherever missing.Signed-off-by: Vignesh Raghavendra
Reviewed-by: Tudor Ambarus
Reviewed-by: Simon Goldschmidt
Reviewed-by: Jagan Teki -
mt25q* flashes support stateless 4 byte addressing opcodes. Add entries
for the same. These flashes have bit 6 set in 5th byte of READ ID
response when compared to n25q* variants.Signed-off-by: Vignesh Raghavendra
Reviewed-by: Tudor Ambarus
Tested-by: Simon Goldschmidt
Reviewed-by: Jagan Teki -
Per datasheets of n25q256* and n25q512* not all variants of n25q256* and
n25q512* support 4 Byte stateless addressing opcodes. Therefore drop
SPI_NOR_4B_OPCODES flag from these entriesSigned-off-by: Vignesh Raghavendra
Reviewed-by: Tudor Ambarus
Reviewed-by: Simon Goldschmidt
Tested-by: Simon Goldschmidt
Tested-by: Eugeniy Paltsev
Reviewed-by: Jagan Teki -
Disable and free clock when remove driver.
Signed-off-by: Ley Foon Tan
Acked-by: Marek Vasut
Reviewed-by: Jagan Teki -
U-Boot uses CONFIG_SPI_FLASH_USE_4K_SECTORS to enable 4K small sector
support. Use that instead of MTD_SPI_NOR_USE_4K_SECTORS.Reported-by: Eugeniy Paltsev
Signed-off-by: Vignesh Raghavendra
Reviewed-by: Jagan Teki -
Use dev_err() when reporting reason for erase/write failures so that
users can be made aware of the reason for failure.Signed-off-by: Vignesh Raghavendra
Reviewed-by: Jagan Teki -
As SPI_FLASH_MTD is used in SPL and U-Boot proper, we enable both,
now that a separate option for SPL was introduced.Signed-off-by: Frieder Schrempf
[jagan: drop unrelated change]
Signed-off-by: Jagan Teki
Reviewed-by: Lukasz Majewski
Reviewed-by: Jagan Teki -
To allow SPI_FLASH_MTD being enabled separately in SPL we add a new
option. The only user currently is the stm32mp15_basic board.Signed-off-by: Frieder Schrempf
Acked-by: Lukasz Majewski
Reviewed-by: Jagan Teki -
SoPine has winbond SPI-FLASH, so enable the same in defconfig
and add aliases for spi0 in -u-boot.dtsiSigned-off-by: Jagan Teki
-
SPI is available in Allwinner A64 SoC, so enable it
globally in Kconfig.- CONFIG_SPI
- CONFIG_DM_SPI
- CONFIG_DM_SPI_FLASHSigned-off-by: Jagan Teki
-
SPI_SUNXI driver is fully dm-aware and the Allwinner
architecture kconfig would have logic to enable the
DM_SPI. So, select default spi sunxi driver for
sunxi architecture.Signed-off-by: Jagan Teki
-
DM_SPI_FLASH should require spi flash interface code for dm
version, so imply SPI_FLASH core by default if any board
enabled DM_SPI_FLASH.This overcome the explicit enablement of CONFIG_SPI_FLASH on
respective boards when DM_SPI_FLASH being used.Acked-by: Vignesh Raghavendra
Signed-off-by: Jagan Teki -
If DM_SPI_FLASH enabled that means it is using sf command
for flash interface to access.SPI_FLASH can be used via sf command and board/driver
functions to call spi flash ops, so mark it default only
for DM_SPI_FLASH.This would prevent explicit adding of CONFIG_CMD_SF when
DM_SPI_FLASH being enabled.Cc: Tom Rini
Acked-by: Vignesh Raghavendra
Signed-off-by: Jagan Teki -
We need distinguish the following two situations in various SPI APIs:
- given chip select num is invalid
- given chip select num is valid, but no device is attachedCurrently -ENODEV is returned for both cases.
For the first case, it's more reasonable to return -EINVAL instead of
-ENODEV for invalid chip select numbers.Signed-off-by: Bin Meng
Tested-by: Jagan Teki # SoPine
Reviewed-by: Jagan Teki -
If an SPI controller driver does not implement ops->cs_info, that
probably means any chip select number could be valid, hence let's
return 0 for spi_cs_info().Signed-off-by: Bin Meng
Tested-by: Jagan Teki # SoPine
Reviewed-by: Jagan Teki -
Add detailed help text for SPI support.
Signed-off-by: Jagan Teki
-
Add is25wp256, chip to spi-nor id table.
Tested on SiFive FU540 board.
Signed-off-by: Jagan Teki
Reviewed-by: Bin Meng
Tested-by: Bin Meng -
1) CONFIG_SPI_FLASH is not just a legacy code, but it has common
core code which handle both dm and non-dm spi flash code. So
fix the info text to make it clear globally.2) Since it's flash core it shouldn't depends on legacy SPI,
so remove the 'depends on SPI'Cc: Vignesh R
Signed-off-by: Jagan Teki
24 Oct, 2019
20 commits
-
- Add Universal Flash Storage (UFS) support
-
- Add support for HyperBus Memory Controller of TI's J721e
and AM654 SoCs (Vignesh) -
Enable HBMC and HyperFlash in A72 SPL and A72 U-Boot
Signed-off-by: Vignesh Raghavendra
Reviewed-by: Stefan Roese -
Define CONFIG_SYS_MAX_FLASH_BANKS_DETECT so that number of flash banks
are automatically detected by CFI flash driverSigned-off-by: Vignesh Raghavendra
Reviewed-by: Stefan Roese -
J721e SoM as a 64MB HyperFlash on board. Add pinmux and DT node for the
same.Signed-off-by: Vignesh Raghavendra
Reviewed-by: Stefan Roese -
Add DT node for HyperBus Memory Controller in the FSS. On J721e, its not
possible to use OSPI0 and HBMC simultaneously as they are muxed within
the Flash Subsystem hence disable HBMC by default as keep OSPI enabled.
Bootloader will fixup DT when it detects HyperFlash instead of OSPI.Signed-off-by: Vignesh Raghavendra
Reviewed-by: Stefan Roese -
AM654/J721e has HyperBus Memory Controller that supports HyperFlash and
HyperRAM devices. It provides a memory mapped interface to interact with
these devices. Add a driver to support the same.
Driver calibrates the controller, setups up for MMIO access and probes
HyperFlash child node.Signed-off-by: Vignesh Raghavendra
Reviewed-by: Stefan Roese -
Make use of CONFIG_SYS_MONITOR_BASE only when available to avoid build
error when CONFIG_SYS_MONITOR_BASE is not defined.Signed-off-by: Vignesh Raghavendra
Reviewed-by: Stefan Roese -
Enable SCSI and UFS related configs.
Signed-off-by: Faiz Abbas
-
Add environment variables to boot kernel from a filesystem contained in
the 2nd UFS LUN. The user can boot from a ufs filesystem just by
entering the following commands.=> setenv boot ufs
=> bootSigned-off-by: Faiz Abbas
-
Add Support for commands to initialize and configure UFS devices.
TODO: Add Support for commands to resize and reconfigure LUNs
Signed-off-by: Faiz Abbas -
Add TI UFS glue layer and Cadence UFS Host controller DT nodes.
Signed-off-by: Faiz Abbas
-
Add glue layer driver for the controller present on TI's J721E devices.
Signed-off-by: Faiz Abbas
-
Add Support for the platform driver for the Cadence device present on
TI's J721e device.Signed-off-by: Faiz Abbas
-
Add Support for UFS Host Controller Interface (UFSHCI) for communicating
with Universal Flash Storage (UFS) devices. The steps to initialize the
host controller interface are the following:- Initiate the Host Controller Initialization process by writing to the
Host controller enable register.
- Configure the Host Controller base address registers by allocating a
host memory space and related data structures.
- Unipro link startup procedure
- Check for connected device
- Configure UFS host controller to process requestsAlso register this host controller as a SCSI host controller.
Taken from Linux Kernel v5.2 (drivers/scsi/ufs/ufshcd.c) and ported to
U-boot.Signed-off-by: Faiz Abbas
-
Some SCSI devices like UFS use DMA for executing scsi commands and hence
need to know the direction of transfer of the dma. Add a dma_dir element
to the command structure to facilitate this.Signed-off-by: Faiz Abbas
-
The UFS SCSI device LUNs are observed to return failure the first time a
unit ready inquiry is sent and pass on the second try. Send this
inquiry 3 times to make sure device is ready.Signed-off-by: Faiz Abbas
-
Add max_bytes_per_req to scsi_platdata to enable the host driver to limit
the number of bytes that can be read/written per request.Signed-off-by: Faiz Abbas
-
With no non-DM driver using scsi_read()/_write() APIs, remove
the legacy implementations.Signed-off-by: Faiz Abbas
[trini: Reorder slightly and mark scsi_read/write behind BLK test to
avoid warnings]
Signed-off-by: Tom Rini -
- Disable CONFIG_NET flag for MCU STM32
- Fix ramdisk_addr_r for stm32f746-disco
- Fix USB product id for stm32mp1
23 Oct, 2019
1 commit
-
- Add LS1027A, LS1018A, LS1017A support
- Few updates related to usb, ls1012a, lx2160a