History log of /u-boot/board/gateworks/gw_ventana/eeprom.c
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# d678a59d 18-May-2024 Tom Rini <trini@konsulko.com>

Revert "Merge patch series "arm: dts: am62-beagleplay: Fix Beagleplay Ethernet""

When bringing in the series 'arm: dts: am62-beagleplay: Fix Beagleplay
Ethernet"' I failed to notice that b4 noticed it was based on next and
so took that as the base commit and merged that part of next to master.

This reverts commit c8ffd1356d42223cbb8c86280a083cc3c93e6426, reversing
changes made to 2ee6f3a5f7550de3599faef9704e166e5dcace35.

Reported-by: Jonas Karlman <jonas@kwiboo.se>
Signed-off-by: Tom Rini <trini@konsulko.com>

# 5b1d20b5 30-Apr-2024 Tom Rini <trini@konsulko.com>

board: gateworks: Remove <common.h> and add needed includes

Remove <common.h> from this board vendor directory and when needed
add missing include files directly.

Acked-By: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Tom Rini <trini@konsulko.com>

# 61cf2250 13-Apr-2022 Tim Harvey <tharvey@gateworks.com>

board: gateworks: gw_ventana: use comomn GSC driver

Use the common GSC driver.

This allows us to do some additional cleanup:
- use the GSC driver functions
- move waiting for the EEPROM to the SPL int (it will always be ready
after this)
- move eeprom functions into eeprom file and elimate GSC_I2C_BUS
- eliminate some redundant EEPROM reads (the EEPROM must be read in
SPL before relocation, in SPL after relocation, and in U-Boot init.
All subsequent uses can use the global structure)
- remove unnecessary header files and alphabatize includes

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# cb339a00 07-Mar-2022 Tim Harvey <tharvey@gateworks.com>

board: gateworks: gw_ventana: convert to DM_I2C

convert to DM_I2C for U-Boot while leaving SPL legacy I2C:
- Move I2C config from common to SPL
- Move PMIC config from common to SPL (no need to re-configure pmic)
- add DM_I2C support to eeprom/gsc functions shared by SPL and U-Boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3ef59acd 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5913 support

The GW5913 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- Digital I/O connector (I2C/GPIO/UART)
- u-blox Zoe-M8Q GPS
- 1x RJ45 GbE
- 1x MiniPCIe socket with PCIe USB 2.0 and nanoSIM socket
- Passive PoE and wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 744d21c1 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5912 support

The GW5912 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- microSD socket
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- RS232 connector (2x UARTs)
- CAN/RS485 connector
- Digital I/O connector (I2C/GPIO)
- SPI connector
- u-blox Zoe-M8Q GPS
- LIS2DE12 Accellerometer
- 1x FEC GbE RJ45 with 802.3at Active PoE
- 1x PCI GbE RJ45 with Passive PoE
- 5x MiniPCIe socket with PCIe/USB 2.0
- 1x MiniPCIe socket with PCIe/USB 2.0 and SIM socket
- Aux power input with wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 25805401 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5910 support

The GW5910 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- microSD socket
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- RS232 connector (2x UARTs)
- Digital I/O connector (I2C/GPIO)
- SPI connector
- u-blox Zoe-M8Q GPS
- LIS2DE12 Accellerometer
- TI CC1352 ARM Cortex-M4 multiprotocol sub-1GHz / 2.4GHz wireless MCU
- On-board brcmfmac WiFi and BT module
- RGMII RJ45 GbE
- 1x MiniPCIe socket with PCIe/USB 2.0
- 1x MiniPCIe socket with USB 2.0 and nanoSIM socket
- Passive PoE and wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1afa31a4 16-Apr-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add delay before reading EEPROM

fixes: d863d054397a ("imx: ventana: convert U-Boot to OF_CONTROL using FIT image")

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# c05ed00a 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop linux/delay.h from common header

Move this uncommon header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# f7ae49fc 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop log.h from common header

Move this header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 09140113 10-May-2020 Simon Glass <sjg@chromium.org>

command: Remove the cmd_tbl_t typedef

We should not use typedefs in U-Boot. They cannot be used as forward
declarations which means that header files must include the full header to
access them.

Drop the typedef and rename the struct to remove the _s suffix which is
now not useful.

This requires quite a few header-file additions.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 74389c13 21-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: hexdump invalid EEPROM data

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9cdb1c6e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5901/GW5902

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 2285094e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5909

The GW5909 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW5904 but with half the DRAM loaded
and an additional RS232 transceiver off UART2.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# ebe07ef7 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5908

The GW5908 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW530x but with 1GiB density DRAM
(64bit 512MiB).

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 00606b51 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5907

The GW5907 is a small single board computer based on the i.MX6DL SoC
with the following peripheral set:
- DDR3 memory (512MB default)
- 1x GigE (i.MX6 FEC)
- Gateworks System Controller

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 988916ad 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5906

The GW5906 is a GW552x with mechanical and power supply connector
differences.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# d1c3867a 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5905

The GW5905 is single-board tablet computer based on the i.MX6 SoC with the
following peripheral set:
- eMMC flash (boot device)
- microSD expansion
- LVDS display connector for off-board 3D+1C with PWM backlight
and I2C based touch controller
- MIPI camera connector supporting the TRULY CM8487-B500SA-E (OV5640)
- ublox EMMY-W1 WiFi/Bluetooth/NFC module (SDIO/UART)
- ublox ZOE-M8Q GPS
- LSM9DS1 9-DOF IMU
- 1x 1-lane miniPCIe socket with USB 2.0
- Gateworks System Controller
- Audio jack with TLV320AIC Audio Codec, Speaker AMP
and TSA227E Headphone detect
- MAX8607 3-mode LED camera flash
- DECT ULE module
- FUSB302 USB-C PD and ISL9238 Battery charger

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 83d290c5 06-May-2018 Tom Rini <trini@konsulko.com>

SPDX: Convert all of our single license tags to Linux Kernel style

When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from. So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry. Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.

In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.

This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents. There's also a few places where I found we did not have a tag
and have introduced one.

Signed-off-by: Tom Rini <trini@konsulko.com>

# c10b1c43 03-Jan-2018 Tom Rini <trini@konsulko.com>

imx: ventana: Rework CONFIG_CMD_EECONFIG code to not be included in SPL

The command can only be used from full U-Boot, so do not build it into
SPL.

Cc: Stefano Babic <sbabic@denx.de>
Cc: Fabio Estevam <fabio.estevam@nxp.com>
Cc: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>

# 214fb19b 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5903 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 94a1d6c6 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW560x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 8d1a6ff8 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5904 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 385575bc 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW553x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# fe63fcb6 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: remove several EEPROM config bit dependence

Removed several EEPROM bit dependencies:
- for dt aliases that don't exist and thus don't ever do anything
(pcie,lvds1,uart*,vpu,csi*,hdmi_in,hdmi_out,cvbs_in,cvbs_out,gps)
- for features that don't effect bus ordering or have no detrimental affect
if erroneously enabled when not present (ahci,nand,i2c*)
- for features that have little to no impact on being erroneously enabled
but high impact if erroneously disabled (can*, spi*)
- for features that have an high adverse affect of not being set when they
should and no adverse affect of being set when they
shouldn't (ipu*).

Removing these means the following:
- these no longer are supported with the econfig command
- these no longer affect the device-tree in any way

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 75f21e31 08-Apr-2015 Tim Harvey <tharvey@gateworks.com>

imx: ventana: Add support for GW551x

The GW551x is a small form factor board based on the IMX6 SoC that includes:
* up to 512MB DDR3 memory
* up to 2GB NAND flash
* 1x miniPCIe socket (with USB)
* HDMI out (micro-HDMI)
* HDMI in (micro-HDMI)
* TTL level I/O (supported by GW16111 breakout board):
* I2C
* 2x UART
* CAN
* 2x DIO (GPIO/PWM)
* USB OTG

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3aa22674 21-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5520 support

The GW5520 has an IMX6Q SoC with 512MB of DDR3, 256MB of NAND flash as well as:
* 2x MiniPCIe sockets
* 2x USB host sockets
* 2x i210 GigE
* HDMI out
* digital I/O expansion

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9c0fe83e 07-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add econfig command

The Gateworks Ventana EEPROM contains a set of configuration bits that
affect the removal of device-tree nodes that support peripherals that do not
exist on sub-loaded boards. This patch adds:
- a structure to define a config bit name, dt node alias, bit position
- an array of supported configuration items
- an econfig command to get/set/list configuration bits
- use of the array when adjusting the FDT prior to boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1badf2f4 02-Jun-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: split read_eeprom into standalone file

Split the read_eeprom function out so that it can be shared (ie with SPL)

Cc: Stefan Roese <sr@denx.de>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Andy Ng <andreas2025@gmail.com>
Cc: Eric Nelson <eric.nelson@boundarydevices.com>
Cc: Tapani Utriainen <tapani@technexion.com>
Cc: Tom Rini <trini@ti.com>

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 5b1d20b5 30-Apr-2024 Tom Rini <trini@konsulko.com>

board: gateworks: Remove <common.h> and add needed includes

Remove <common.h> from this board vendor directory and when needed
add missing include files directly.

Acked-By: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Tom Rini <trini@konsulko.com>

# 61cf2250 13-Apr-2022 Tim Harvey <tharvey@gateworks.com>

board: gateworks: gw_ventana: use comomn GSC driver

Use the common GSC driver.

This allows us to do some additional cleanup:
- use the GSC driver functions
- move waiting for the EEPROM to the SPL int (it will always be ready
after this)
- move eeprom functions into eeprom file and elimate GSC_I2C_BUS
- eliminate some redundant EEPROM reads (the EEPROM must be read in
SPL before relocation, in SPL after relocation, and in U-Boot init.
All subsequent uses can use the global structure)
- remove unnecessary header files and alphabatize includes

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# cb339a00 07-Mar-2022 Tim Harvey <tharvey@gateworks.com>

board: gateworks: gw_ventana: convert to DM_I2C

convert to DM_I2C for U-Boot while leaving SPL legacy I2C:
- Move I2C config from common to SPL
- Move PMIC config from common to SPL (no need to re-configure pmic)
- add DM_I2C support to eeprom/gsc functions shared by SPL and U-Boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3ef59acd 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5913 support

The GW5913 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- Digital I/O connector (I2C/GPIO/UART)
- u-blox Zoe-M8Q GPS
- 1x RJ45 GbE
- 1x MiniPCIe socket with PCIe USB 2.0 and nanoSIM socket
- Passive PoE and wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 744d21c1 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5912 support

The GW5912 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- microSD socket
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- RS232 connector (2x UARTs)
- CAN/RS485 connector
- Digital I/O connector (I2C/GPIO)
- SPI connector
- u-blox Zoe-M8Q GPS
- LIS2DE12 Accellerometer
- 1x FEC GbE RJ45 with 802.3at Active PoE
- 1x PCI GbE RJ45 with Passive PoE
- 5x MiniPCIe socket with PCIe/USB 2.0
- 1x MiniPCIe socket with PCIe/USB 2.0 and SIM socket
- Aux power input with wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 25805401 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5910 support

The GW5910 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- microSD socket
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- RS232 connector (2x UARTs)
- Digital I/O connector (I2C/GPIO)
- SPI connector
- u-blox Zoe-M8Q GPS
- LIS2DE12 Accellerometer
- TI CC1352 ARM Cortex-M4 multiprotocol sub-1GHz / 2.4GHz wireless MCU
- On-board brcmfmac WiFi and BT module
- RGMII RJ45 GbE
- 1x MiniPCIe socket with PCIe/USB 2.0
- 1x MiniPCIe socket with USB 2.0 and nanoSIM socket
- Passive PoE and wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1afa31a4 16-Apr-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add delay before reading EEPROM

fixes: d863d054397a ("imx: ventana: convert U-Boot to OF_CONTROL using FIT image")

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# c05ed00a 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop linux/delay.h from common header

Move this uncommon header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# f7ae49fc 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop log.h from common header

Move this header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 09140113 10-May-2020 Simon Glass <sjg@chromium.org>

command: Remove the cmd_tbl_t typedef

We should not use typedefs in U-Boot. They cannot be used as forward
declarations which means that header files must include the full header to
access them.

Drop the typedef and rename the struct to remove the _s suffix which is
now not useful.

This requires quite a few header-file additions.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 74389c13 21-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: hexdump invalid EEPROM data

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9cdb1c6e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5901/GW5902

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 2285094e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5909

The GW5909 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW5904 but with half the DRAM loaded
and an additional RS232 transceiver off UART2.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# ebe07ef7 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5908

The GW5908 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW530x but with 1GiB density DRAM
(64bit 512MiB).

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 00606b51 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5907

The GW5907 is a small single board computer based on the i.MX6DL SoC
with the following peripheral set:
- DDR3 memory (512MB default)
- 1x GigE (i.MX6 FEC)
- Gateworks System Controller

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 988916ad 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5906

The GW5906 is a GW552x with mechanical and power supply connector
differences.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# d1c3867a 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5905

The GW5905 is single-board tablet computer based on the i.MX6 SoC with the
following peripheral set:
- eMMC flash (boot device)
- microSD expansion
- LVDS display connector for off-board 3D+1C with PWM backlight
and I2C based touch controller
- MIPI camera connector supporting the TRULY CM8487-B500SA-E (OV5640)
- ublox EMMY-W1 WiFi/Bluetooth/NFC module (SDIO/UART)
- ublox ZOE-M8Q GPS
- LSM9DS1 9-DOF IMU
- 1x 1-lane miniPCIe socket with USB 2.0
- Gateworks System Controller
- Audio jack with TLV320AIC Audio Codec, Speaker AMP
and TSA227E Headphone detect
- MAX8607 3-mode LED camera flash
- DECT ULE module
- FUSB302 USB-C PD and ISL9238 Battery charger

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 83d290c5 06-May-2018 Tom Rini <trini@konsulko.com>

SPDX: Convert all of our single license tags to Linux Kernel style

When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from. So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry. Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.

In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.

This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents. There's also a few places where I found we did not have a tag
and have introduced one.

Signed-off-by: Tom Rini <trini@konsulko.com>

# c10b1c43 03-Jan-2018 Tom Rini <trini@konsulko.com>

imx: ventana: Rework CONFIG_CMD_EECONFIG code to not be included in SPL

The command can only be used from full U-Boot, so do not build it into
SPL.

Cc: Stefano Babic <sbabic@denx.de>
Cc: Fabio Estevam <fabio.estevam@nxp.com>
Cc: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>

# 214fb19b 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5903 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 94a1d6c6 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW560x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 8d1a6ff8 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5904 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 385575bc 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW553x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# fe63fcb6 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: remove several EEPROM config bit dependence

Removed several EEPROM bit dependencies:
- for dt aliases that don't exist and thus don't ever do anything
(pcie,lvds1,uart*,vpu,csi*,hdmi_in,hdmi_out,cvbs_in,cvbs_out,gps)
- for features that don't effect bus ordering or have no detrimental affect
if erroneously enabled when not present (ahci,nand,i2c*)
- for features that have little to no impact on being erroneously enabled
but high impact if erroneously disabled (can*, spi*)
- for features that have an high adverse affect of not being set when they
should and no adverse affect of being set when they
shouldn't (ipu*).

Removing these means the following:
- these no longer are supported with the econfig command
- these no longer affect the device-tree in any way

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 75f21e31 08-Apr-2015 Tim Harvey <tharvey@gateworks.com>

imx: ventana: Add support for GW551x

The GW551x is a small form factor board based on the IMX6 SoC that includes:
* up to 512MB DDR3 memory
* up to 2GB NAND flash
* 1x miniPCIe socket (with USB)
* HDMI out (micro-HDMI)
* HDMI in (micro-HDMI)
* TTL level I/O (supported by GW16111 breakout board):
* I2C
* 2x UART
* CAN
* 2x DIO (GPIO/PWM)
* USB OTG

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3aa22674 21-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5520 support

The GW5520 has an IMX6Q SoC with 512MB of DDR3, 256MB of NAND flash as well as:
* 2x MiniPCIe sockets
* 2x USB host sockets
* 2x i210 GigE
* HDMI out
* digital I/O expansion

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9c0fe83e 07-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add econfig command

The Gateworks Ventana EEPROM contains a set of configuration bits that
affect the removal of device-tree nodes that support peripherals that do not
exist on sub-loaded boards. This patch adds:
- a structure to define a config bit name, dt node alias, bit position
- an array of supported configuration items
- an econfig command to get/set/list configuration bits
- use of the array when adjusting the FDT prior to boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1badf2f4 02-Jun-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: split read_eeprom into standalone file

Split the read_eeprom function out so that it can be shared (ie with SPL)

Cc: Stefan Roese <sr@denx.de>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Andy Ng <andreas2025@gmail.com>
Cc: Eric Nelson <eric.nelson@boundarydevices.com>
Cc: Tapani Utriainen <tapani@technexion.com>
Cc: Tom Rini <trini@ti.com>

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 61cf2250 13-Apr-2022 Tim Harvey <tharvey@gateworks.com>

board: gateworks: gw_ventana: use comomn GSC driver

Use the common GSC driver.

This allows us to do some additional cleanup:
- use the GSC driver functions
- move waiting for the EEPROM to the SPL int (it will always be ready
after this)
- move eeprom functions into eeprom file and elimate GSC_I2C_BUS
- eliminate some redundant EEPROM reads (the EEPROM must be read in
SPL before relocation, in SPL after relocation, and in U-Boot init.
All subsequent uses can use the global structure)
- remove unnecessary header files and alphabatize includes

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# cb339a00 07-Mar-2022 Tim Harvey <tharvey@gateworks.com>

board: gateworks: gw_ventana: convert to DM_I2C

convert to DM_I2C for U-Boot while leaving SPL legacy I2C:
- Move I2C config from common to SPL
- Move PMIC config from common to SPL (no need to re-configure pmic)
- add DM_I2C support to eeprom/gsc functions shared by SPL and U-Boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3ef59acd 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5913 support

The GW5913 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- Digital I/O connector (I2C/GPIO/UART)
- u-blox Zoe-M8Q GPS
- 1x RJ45 GbE
- 1x MiniPCIe socket with PCIe USB 2.0 and nanoSIM socket
- Passive PoE and wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 744d21c1 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5912 support

The GW5912 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- microSD socket
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- RS232 connector (2x UARTs)
- CAN/RS485 connector
- Digital I/O connector (I2C/GPIO)
- SPI connector
- u-blox Zoe-M8Q GPS
- LIS2DE12 Accellerometer
- 1x FEC GbE RJ45 with 802.3at Active PoE
- 1x PCI GbE RJ45 with Passive PoE
- 5x MiniPCIe socket with PCIe/USB 2.0
- 1x MiniPCIe socket with PCIe/USB 2.0 and SIM socket
- Aux power input with wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 25805401 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5910 support

The GW5910 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- microSD socket
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- RS232 connector (2x UARTs)
- Digital I/O connector (I2C/GPIO)
- SPI connector
- u-blox Zoe-M8Q GPS
- LIS2DE12 Accellerometer
- TI CC1352 ARM Cortex-M4 multiprotocol sub-1GHz / 2.4GHz wireless MCU
- On-board brcmfmac WiFi and BT module
- RGMII RJ45 GbE
- 1x MiniPCIe socket with PCIe/USB 2.0
- 1x MiniPCIe socket with USB 2.0 and nanoSIM socket
- Passive PoE and wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1afa31a4 16-Apr-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add delay before reading EEPROM

fixes: d863d054397a ("imx: ventana: convert U-Boot to OF_CONTROL using FIT image")

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# c05ed00a 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop linux/delay.h from common header

Move this uncommon header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# f7ae49fc 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop log.h from common header

Move this header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 09140113 10-May-2020 Simon Glass <sjg@chromium.org>

command: Remove the cmd_tbl_t typedef

We should not use typedefs in U-Boot. They cannot be used as forward
declarations which means that header files must include the full header to
access them.

Drop the typedef and rename the struct to remove the _s suffix which is
now not useful.

This requires quite a few header-file additions.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 74389c13 21-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: hexdump invalid EEPROM data

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9cdb1c6e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5901/GW5902

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 2285094e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5909

The GW5909 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW5904 but with half the DRAM loaded
and an additional RS232 transceiver off UART2.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# ebe07ef7 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5908

The GW5908 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW530x but with 1GiB density DRAM
(64bit 512MiB).

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 00606b51 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5907

The GW5907 is a small single board computer based on the i.MX6DL SoC
with the following peripheral set:
- DDR3 memory (512MB default)
- 1x GigE (i.MX6 FEC)
- Gateworks System Controller

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 988916ad 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5906

The GW5906 is a GW552x with mechanical and power supply connector
differences.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# d1c3867a 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5905

The GW5905 is single-board tablet computer based on the i.MX6 SoC with the
following peripheral set:
- eMMC flash (boot device)
- microSD expansion
- LVDS display connector for off-board 3D+1C with PWM backlight
and I2C based touch controller
- MIPI camera connector supporting the TRULY CM8487-B500SA-E (OV5640)
- ublox EMMY-W1 WiFi/Bluetooth/NFC module (SDIO/UART)
- ublox ZOE-M8Q GPS
- LSM9DS1 9-DOF IMU
- 1x 1-lane miniPCIe socket with USB 2.0
- Gateworks System Controller
- Audio jack with TLV320AIC Audio Codec, Speaker AMP
and TSA227E Headphone detect
- MAX8607 3-mode LED camera flash
- DECT ULE module
- FUSB302 USB-C PD and ISL9238 Battery charger

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 83d290c5 06-May-2018 Tom Rini <trini@konsulko.com>

SPDX: Convert all of our single license tags to Linux Kernel style

When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from. So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry. Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.

In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.

This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents. There's also a few places where I found we did not have a tag
and have introduced one.

Signed-off-by: Tom Rini <trini@konsulko.com>

# c10b1c43 03-Jan-2018 Tom Rini <trini@konsulko.com>

imx: ventana: Rework CONFIG_CMD_EECONFIG code to not be included in SPL

The command can only be used from full U-Boot, so do not build it into
SPL.

Cc: Stefano Babic <sbabic@denx.de>
Cc: Fabio Estevam <fabio.estevam@nxp.com>
Cc: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>

# 214fb19b 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5903 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 94a1d6c6 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW560x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 8d1a6ff8 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5904 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 385575bc 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW553x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# fe63fcb6 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: remove several EEPROM config bit dependence

Removed several EEPROM bit dependencies:
- for dt aliases that don't exist and thus don't ever do anything
(pcie,lvds1,uart*,vpu,csi*,hdmi_in,hdmi_out,cvbs_in,cvbs_out,gps)
- for features that don't effect bus ordering or have no detrimental affect
if erroneously enabled when not present (ahci,nand,i2c*)
- for features that have little to no impact on being erroneously enabled
but high impact if erroneously disabled (can*, spi*)
- for features that have an high adverse affect of not being set when they
should and no adverse affect of being set when they
shouldn't (ipu*).

Removing these means the following:
- these no longer are supported with the econfig command
- these no longer affect the device-tree in any way

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 75f21e31 08-Apr-2015 Tim Harvey <tharvey@gateworks.com>

imx: ventana: Add support for GW551x

The GW551x is a small form factor board based on the IMX6 SoC that includes:
* up to 512MB DDR3 memory
* up to 2GB NAND flash
* 1x miniPCIe socket (with USB)
* HDMI out (micro-HDMI)
* HDMI in (micro-HDMI)
* TTL level I/O (supported by GW16111 breakout board):
* I2C
* 2x UART
* CAN
* 2x DIO (GPIO/PWM)
* USB OTG

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3aa22674 21-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5520 support

The GW5520 has an IMX6Q SoC with 512MB of DDR3, 256MB of NAND flash as well as:
* 2x MiniPCIe sockets
* 2x USB host sockets
* 2x i210 GigE
* HDMI out
* digital I/O expansion

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9c0fe83e 07-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add econfig command

The Gateworks Ventana EEPROM contains a set of configuration bits that
affect the removal of device-tree nodes that support peripherals that do not
exist on sub-loaded boards. This patch adds:
- a structure to define a config bit name, dt node alias, bit position
- an array of supported configuration items
- an econfig command to get/set/list configuration bits
- use of the array when adjusting the FDT prior to boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1badf2f4 02-Jun-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: split read_eeprom into standalone file

Split the read_eeprom function out so that it can be shared (ie with SPL)

Cc: Stefan Roese <sr@denx.de>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Andy Ng <andreas2025@gmail.com>
Cc: Eric Nelson <eric.nelson@boundarydevices.com>
Cc: Tapani Utriainen <tapani@technexion.com>
Cc: Tom Rini <trini@ti.com>

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# cb339a00 07-Mar-2022 Tim Harvey <tharvey@gateworks.com>

board: gateworks: gw_ventana: convert to DM_I2C

convert to DM_I2C for U-Boot while leaving SPL legacy I2C:
- Move I2C config from common to SPL
- Move PMIC config from common to SPL (no need to re-configure pmic)
- add DM_I2C support to eeprom/gsc functions shared by SPL and U-Boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3ef59acd 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5913 support

The GW5913 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- Digital I/O connector (I2C/GPIO/UART)
- u-blox Zoe-M8Q GPS
- 1x RJ45 GbE
- 1x MiniPCIe socket with PCIe USB 2.0 and nanoSIM socket
- Passive PoE and wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 744d21c1 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5912 support

The GW5912 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- microSD socket
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- RS232 connector (2x UARTs)
- CAN/RS485 connector
- Digital I/O connector (I2C/GPIO)
- SPI connector
- u-blox Zoe-M8Q GPS
- LIS2DE12 Accellerometer
- 1x FEC GbE RJ45 with 802.3at Active PoE
- 1x PCI GbE RJ45 with Passive PoE
- 5x MiniPCIe socket with PCIe/USB 2.0
- 1x MiniPCIe socket with PCIe/USB 2.0 and SIM socket
- Aux power input with wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 25805401 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5910 support

The GW5910 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- microSD socket
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- RS232 connector (2x UARTs)
- Digital I/O connector (I2C/GPIO)
- SPI connector
- u-blox Zoe-M8Q GPS
- LIS2DE12 Accellerometer
- TI CC1352 ARM Cortex-M4 multiprotocol sub-1GHz / 2.4GHz wireless MCU
- On-board brcmfmac WiFi and BT module
- RGMII RJ45 GbE
- 1x MiniPCIe socket with PCIe/USB 2.0
- 1x MiniPCIe socket with USB 2.0 and nanoSIM socket
- Passive PoE and wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1afa31a4 16-Apr-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add delay before reading EEPROM

fixes: d863d054397a ("imx: ventana: convert U-Boot to OF_CONTROL using FIT image")

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# c05ed00a 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop linux/delay.h from common header

Move this uncommon header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# f7ae49fc 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop log.h from common header

Move this header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 09140113 10-May-2020 Simon Glass <sjg@chromium.org>

command: Remove the cmd_tbl_t typedef

We should not use typedefs in U-Boot. They cannot be used as forward
declarations which means that header files must include the full header to
access them.

Drop the typedef and rename the struct to remove the _s suffix which is
now not useful.

This requires quite a few header-file additions.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 74389c13 21-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: hexdump invalid EEPROM data

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9cdb1c6e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5901/GW5902

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 2285094e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5909

The GW5909 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW5904 but with half the DRAM loaded
and an additional RS232 transceiver off UART2.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# ebe07ef7 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5908

The GW5908 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW530x but with 1GiB density DRAM
(64bit 512MiB).

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 00606b51 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5907

The GW5907 is a small single board computer based on the i.MX6DL SoC
with the following peripheral set:
- DDR3 memory (512MB default)
- 1x GigE (i.MX6 FEC)
- Gateworks System Controller

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 988916ad 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5906

The GW5906 is a GW552x with mechanical and power supply connector
differences.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# d1c3867a 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5905

The GW5905 is single-board tablet computer based on the i.MX6 SoC with the
following peripheral set:
- eMMC flash (boot device)
- microSD expansion
- LVDS display connector for off-board 3D+1C with PWM backlight
and I2C based touch controller
- MIPI camera connector supporting the TRULY CM8487-B500SA-E (OV5640)
- ublox EMMY-W1 WiFi/Bluetooth/NFC module (SDIO/UART)
- ublox ZOE-M8Q GPS
- LSM9DS1 9-DOF IMU
- 1x 1-lane miniPCIe socket with USB 2.0
- Gateworks System Controller
- Audio jack with TLV320AIC Audio Codec, Speaker AMP
and TSA227E Headphone detect
- MAX8607 3-mode LED camera flash
- DECT ULE module
- FUSB302 USB-C PD and ISL9238 Battery charger

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 83d290c5 06-May-2018 Tom Rini <trini@konsulko.com>

SPDX: Convert all of our single license tags to Linux Kernel style

When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from. So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry. Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.

In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.

This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents. There's also a few places where I found we did not have a tag
and have introduced one.

Signed-off-by: Tom Rini <trini@konsulko.com>

# c10b1c43 03-Jan-2018 Tom Rini <trini@konsulko.com>

imx: ventana: Rework CONFIG_CMD_EECONFIG code to not be included in SPL

The command can only be used from full U-Boot, so do not build it into
SPL.

Cc: Stefano Babic <sbabic@denx.de>
Cc: Fabio Estevam <fabio.estevam@nxp.com>
Cc: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>

# 214fb19b 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5903 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 94a1d6c6 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW560x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 8d1a6ff8 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5904 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 385575bc 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW553x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# fe63fcb6 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: remove several EEPROM config bit dependence

Removed several EEPROM bit dependencies:
- for dt aliases that don't exist and thus don't ever do anything
(pcie,lvds1,uart*,vpu,csi*,hdmi_in,hdmi_out,cvbs_in,cvbs_out,gps)
- for features that don't effect bus ordering or have no detrimental affect
if erroneously enabled when not present (ahci,nand,i2c*)
- for features that have little to no impact on being erroneously enabled
but high impact if erroneously disabled (can*, spi*)
- for features that have an high adverse affect of not being set when they
should and no adverse affect of being set when they
shouldn't (ipu*).

Removing these means the following:
- these no longer are supported with the econfig command
- these no longer affect the device-tree in any way

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 75f21e31 08-Apr-2015 Tim Harvey <tharvey@gateworks.com>

imx: ventana: Add support for GW551x

The GW551x is a small form factor board based on the IMX6 SoC that includes:
* up to 512MB DDR3 memory
* up to 2GB NAND flash
* 1x miniPCIe socket (with USB)
* HDMI out (micro-HDMI)
* HDMI in (micro-HDMI)
* TTL level I/O (supported by GW16111 breakout board):
* I2C
* 2x UART
* CAN
* 2x DIO (GPIO/PWM)
* USB OTG

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3aa22674 21-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5520 support

The GW5520 has an IMX6Q SoC with 512MB of DDR3, 256MB of NAND flash as well as:
* 2x MiniPCIe sockets
* 2x USB host sockets
* 2x i210 GigE
* HDMI out
* digital I/O expansion

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9c0fe83e 07-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add econfig command

The Gateworks Ventana EEPROM contains a set of configuration bits that
affect the removal of device-tree nodes that support peripherals that do not
exist on sub-loaded boards. This patch adds:
- a structure to define a config bit name, dt node alias, bit position
- an array of supported configuration items
- an econfig command to get/set/list configuration bits
- use of the array when adjusting the FDT prior to boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1badf2f4 02-Jun-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: split read_eeprom into standalone file

Split the read_eeprom function out so that it can be shared (ie with SPL)

Cc: Stefan Roese <sr@denx.de>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Andy Ng <andreas2025@gmail.com>
Cc: Eric Nelson <eric.nelson@boundarydevices.com>
Cc: Tapani Utriainen <tapani@technexion.com>
Cc: Tom Rini <trini@ti.com>

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3ef59acd 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5913 support

The GW5913 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- Digital I/O connector (I2C/GPIO/UART)
- u-blox Zoe-M8Q GPS
- 1x RJ45 GbE
- 1x MiniPCIe socket with PCIe USB 2.0 and nanoSIM socket
- Passive PoE and wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 744d21c1 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5912 support

The GW5912 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- microSD socket
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- RS232 connector (2x UARTs)
- CAN/RS485 connector
- Digital I/O connector (I2C/GPIO)
- SPI connector
- u-blox Zoe-M8Q GPS
- LIS2DE12 Accellerometer
- 1x FEC GbE RJ45 with 802.3at Active PoE
- 1x PCI GbE RJ45 with Passive PoE
- 5x MiniPCIe socket with PCIe/USB 2.0
- 1x MiniPCIe socket with PCIe/USB 2.0 and SIM socket
- Aux power input with wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 25805401 24-Jul-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5910 support

The GW5910 is a Single Board Computer based on the NXP i.MX6Q/DL SoC
with the following features:
- DDR3 DRAM
- NAND FLASH (256MiB or 2048MiB)
- microSD socket
- Gateworks System Periperhal Controller
- front panel LED's
- front panel pushbutton
- RS232 connector (2x UARTs)
- Digital I/O connector (I2C/GPIO)
- SPI connector
- u-blox Zoe-M8Q GPS
- LIS2DE12 Accellerometer
- TI CC1352 ARM Cortex-M4 multiprotocol sub-1GHz / 2.4GHz wireless MCU
- On-board brcmfmac WiFi and BT module
- RGMII RJ45 GbE
- 1x MiniPCIe socket with PCIe/USB 2.0
- 1x MiniPCIe socket with USB 2.0 and nanoSIM socket
- Passive PoE and wide-range DC power supply

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1afa31a4 16-Apr-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add delay before reading EEPROM

fixes: d863d054397a ("imx: ventana: convert U-Boot to OF_CONTROL using FIT image")

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# c05ed00a 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop linux/delay.h from common header

Move this uncommon header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# f7ae49fc 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop log.h from common header

Move this header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 09140113 10-May-2020 Simon Glass <sjg@chromium.org>

command: Remove the cmd_tbl_t typedef

We should not use typedefs in U-Boot. They cannot be used as forward
declarations which means that header files must include the full header to
access them.

Drop the typedef and rename the struct to remove the _s suffix which is
now not useful.

This requires quite a few header-file additions.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 74389c13 21-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: hexdump invalid EEPROM data

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9cdb1c6e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5901/GW5902

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 2285094e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5909

The GW5909 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW5904 but with half the DRAM loaded
and an additional RS232 transceiver off UART2.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# ebe07ef7 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5908

The GW5908 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW530x but with 1GiB density DRAM
(64bit 512MiB).

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 00606b51 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5907

The GW5907 is a small single board computer based on the i.MX6DL SoC
with the following peripheral set:
- DDR3 memory (512MB default)
- 1x GigE (i.MX6 FEC)
- Gateworks System Controller

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 988916ad 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5906

The GW5906 is a GW552x with mechanical and power supply connector
differences.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# d1c3867a 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5905

The GW5905 is single-board tablet computer based on the i.MX6 SoC with the
following peripheral set:
- eMMC flash (boot device)
- microSD expansion
- LVDS display connector for off-board 3D+1C with PWM backlight
and I2C based touch controller
- MIPI camera connector supporting the TRULY CM8487-B500SA-E (OV5640)
- ublox EMMY-W1 WiFi/Bluetooth/NFC module (SDIO/UART)
- ublox ZOE-M8Q GPS
- LSM9DS1 9-DOF IMU
- 1x 1-lane miniPCIe socket with USB 2.0
- Gateworks System Controller
- Audio jack with TLV320AIC Audio Codec, Speaker AMP
and TSA227E Headphone detect
- MAX8607 3-mode LED camera flash
- DECT ULE module
- FUSB302 USB-C PD and ISL9238 Battery charger

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 83d290c5 06-May-2018 Tom Rini <trini@konsulko.com>

SPDX: Convert all of our single license tags to Linux Kernel style

When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from. So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry. Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.

In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.

This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents. There's also a few places where I found we did not have a tag
and have introduced one.

Signed-off-by: Tom Rini <trini@konsulko.com>

# c10b1c43 03-Jan-2018 Tom Rini <trini@konsulko.com>

imx: ventana: Rework CONFIG_CMD_EECONFIG code to not be included in SPL

The command can only be used from full U-Boot, so do not build it into
SPL.

Cc: Stefano Babic <sbabic@denx.de>
Cc: Fabio Estevam <fabio.estevam@nxp.com>
Cc: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>

# 214fb19b 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5903 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 94a1d6c6 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW560x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 8d1a6ff8 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5904 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 385575bc 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW553x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# fe63fcb6 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: remove several EEPROM config bit dependence

Removed several EEPROM bit dependencies:
- for dt aliases that don't exist and thus don't ever do anything
(pcie,lvds1,uart*,vpu,csi*,hdmi_in,hdmi_out,cvbs_in,cvbs_out,gps)
- for features that don't effect bus ordering or have no detrimental affect
if erroneously enabled when not present (ahci,nand,i2c*)
- for features that have little to no impact on being erroneously enabled
but high impact if erroneously disabled (can*, spi*)
- for features that have an high adverse affect of not being set when they
should and no adverse affect of being set when they
shouldn't (ipu*).

Removing these means the following:
- these no longer are supported with the econfig command
- these no longer affect the device-tree in any way

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 75f21e31 08-Apr-2015 Tim Harvey <tharvey@gateworks.com>

imx: ventana: Add support for GW551x

The GW551x is a small form factor board based on the IMX6 SoC that includes:
* up to 512MB DDR3 memory
* up to 2GB NAND flash
* 1x miniPCIe socket (with USB)
* HDMI out (micro-HDMI)
* HDMI in (micro-HDMI)
* TTL level I/O (supported by GW16111 breakout board):
* I2C
* 2x UART
* CAN
* 2x DIO (GPIO/PWM)
* USB OTG

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3aa22674 21-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5520 support

The GW5520 has an IMX6Q SoC with 512MB of DDR3, 256MB of NAND flash as well as:
* 2x MiniPCIe sockets
* 2x USB host sockets
* 2x i210 GigE
* HDMI out
* digital I/O expansion

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9c0fe83e 07-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add econfig command

The Gateworks Ventana EEPROM contains a set of configuration bits that
affect the removal of device-tree nodes that support peripherals that do not
exist on sub-loaded boards. This patch adds:
- a structure to define a config bit name, dt node alias, bit position
- an array of supported configuration items
- an econfig command to get/set/list configuration bits
- use of the array when adjusting the FDT prior to boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1badf2f4 02-Jun-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: split read_eeprom into standalone file

Split the read_eeprom function out so that it can be shared (ie with SPL)

Cc: Stefan Roese <sr@denx.de>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Andy Ng <andreas2025@gmail.com>
Cc: Eric Nelson <eric.nelson@boundarydevices.com>
Cc: Tapani Utriainen <tapani@technexion.com>
Cc: Tom Rini <trini@ti.com>

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1afa31a4 16-Apr-2021 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add delay before reading EEPROM

fixes: d863d054397a ("imx: ventana: convert U-Boot to OF_CONTROL using FIT image")

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# c05ed00a 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop linux/delay.h from common header

Move this uncommon header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# f7ae49fc 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop log.h from common header

Move this header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 09140113 10-May-2020 Simon Glass <sjg@chromium.org>

command: Remove the cmd_tbl_t typedef

We should not use typedefs in U-Boot. They cannot be used as forward
declarations which means that header files must include the full header to
access them.

Drop the typedef and rename the struct to remove the _s suffix which is
now not useful.

This requires quite a few header-file additions.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 74389c13 21-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: hexdump invalid EEPROM data

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9cdb1c6e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5901/GW5902

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 2285094e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5909

The GW5909 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW5904 but with half the DRAM loaded
and an additional RS232 transceiver off UART2.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# ebe07ef7 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5908

The GW5908 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW530x but with 1GiB density DRAM
(64bit 512MiB).

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 00606b51 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5907

The GW5907 is a small single board computer based on the i.MX6DL SoC
with the following peripheral set:
- DDR3 memory (512MB default)
- 1x GigE (i.MX6 FEC)
- Gateworks System Controller

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 988916ad 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5906

The GW5906 is a GW552x with mechanical and power supply connector
differences.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# d1c3867a 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5905

The GW5905 is single-board tablet computer based on the i.MX6 SoC with the
following peripheral set:
- eMMC flash (boot device)
- microSD expansion
- LVDS display connector for off-board 3D+1C with PWM backlight
and I2C based touch controller
- MIPI camera connector supporting the TRULY CM8487-B500SA-E (OV5640)
- ublox EMMY-W1 WiFi/Bluetooth/NFC module (SDIO/UART)
- ublox ZOE-M8Q GPS
- LSM9DS1 9-DOF IMU
- 1x 1-lane miniPCIe socket with USB 2.0
- Gateworks System Controller
- Audio jack with TLV320AIC Audio Codec, Speaker AMP
and TSA227E Headphone detect
- MAX8607 3-mode LED camera flash
- DECT ULE module
- FUSB302 USB-C PD and ISL9238 Battery charger

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 83d290c5 06-May-2018 Tom Rini <trini@konsulko.com>

SPDX: Convert all of our single license tags to Linux Kernel style

When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from. So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry. Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.

In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.

This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents. There's also a few places where I found we did not have a tag
and have introduced one.

Signed-off-by: Tom Rini <trini@konsulko.com>

# c10b1c43 03-Jan-2018 Tom Rini <trini@konsulko.com>

imx: ventana: Rework CONFIG_CMD_EECONFIG code to not be included in SPL

The command can only be used from full U-Boot, so do not build it into
SPL.

Cc: Stefano Babic <sbabic@denx.de>
Cc: Fabio Estevam <fabio.estevam@nxp.com>
Cc: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>

# 214fb19b 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5903 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 94a1d6c6 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW560x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 8d1a6ff8 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5904 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 385575bc 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW553x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# fe63fcb6 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: remove several EEPROM config bit dependence

Removed several EEPROM bit dependencies:
- for dt aliases that don't exist and thus don't ever do anything
(pcie,lvds1,uart*,vpu,csi*,hdmi_in,hdmi_out,cvbs_in,cvbs_out,gps)
- for features that don't effect bus ordering or have no detrimental affect
if erroneously enabled when not present (ahci,nand,i2c*)
- for features that have little to no impact on being erroneously enabled
but high impact if erroneously disabled (can*, spi*)
- for features that have an high adverse affect of not being set when they
should and no adverse affect of being set when they
shouldn't (ipu*).

Removing these means the following:
- these no longer are supported with the econfig command
- these no longer affect the device-tree in any way

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 75f21e31 08-Apr-2015 Tim Harvey <tharvey@gateworks.com>

imx: ventana: Add support for GW551x

The GW551x is a small form factor board based on the IMX6 SoC that includes:
* up to 512MB DDR3 memory
* up to 2GB NAND flash
* 1x miniPCIe socket (with USB)
* HDMI out (micro-HDMI)
* HDMI in (micro-HDMI)
* TTL level I/O (supported by GW16111 breakout board):
* I2C
* 2x UART
* CAN
* 2x DIO (GPIO/PWM)
* USB OTG

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3aa22674 21-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5520 support

The GW5520 has an IMX6Q SoC with 512MB of DDR3, 256MB of NAND flash as well as:
* 2x MiniPCIe sockets
* 2x USB host sockets
* 2x i210 GigE
* HDMI out
* digital I/O expansion

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9c0fe83e 07-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add econfig command

The Gateworks Ventana EEPROM contains a set of configuration bits that
affect the removal of device-tree nodes that support peripherals that do not
exist on sub-loaded boards. This patch adds:
- a structure to define a config bit name, dt node alias, bit position
- an array of supported configuration items
- an econfig command to get/set/list configuration bits
- use of the array when adjusting the FDT prior to boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1badf2f4 02-Jun-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: split read_eeprom into standalone file

Split the read_eeprom function out so that it can be shared (ie with SPL)

Cc: Stefan Roese <sr@denx.de>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Andy Ng <andreas2025@gmail.com>
Cc: Eric Nelson <eric.nelson@boundarydevices.com>
Cc: Tapani Utriainen <tapani@technexion.com>
Cc: Tom Rini <trini@ti.com>

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# c05ed00a 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop linux/delay.h from common header

Move this uncommon header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# f7ae49fc 10-May-2020 Simon Glass <sjg@chromium.org>

common: Drop log.h from common header

Move this header out of the common header.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 09140113 10-May-2020 Simon Glass <sjg@chromium.org>

command: Remove the cmd_tbl_t typedef

We should not use typedefs in U-Boot. They cannot be used as forward
declarations which means that header files must include the full header to
access them.

Drop the typedef and rename the struct to remove the _s suffix which is
now not useful.

This requires quite a few header-file additions.

Signed-off-by: Simon Glass <sjg@chromium.org>

# 74389c13 21-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: hexdump invalid EEPROM data

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9cdb1c6e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5901/GW5902

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 2285094e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5909

The GW5909 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW5904 but with half the DRAM loaded
and an additional RS232 transceiver off UART2.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# ebe07ef7 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5908

The GW5908 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW530x but with 1GiB density DRAM
(64bit 512MiB).

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 00606b51 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5907

The GW5907 is a small single board computer based on the i.MX6DL SoC
with the following peripheral set:
- DDR3 memory (512MB default)
- 1x GigE (i.MX6 FEC)
- Gateworks System Controller

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 988916ad 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5906

The GW5906 is a GW552x with mechanical and power supply connector
differences.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# d1c3867a 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5905

The GW5905 is single-board tablet computer based on the i.MX6 SoC with the
following peripheral set:
- eMMC flash (boot device)
- microSD expansion
- LVDS display connector for off-board 3D+1C with PWM backlight
and I2C based touch controller
- MIPI camera connector supporting the TRULY CM8487-B500SA-E (OV5640)
- ublox EMMY-W1 WiFi/Bluetooth/NFC module (SDIO/UART)
- ublox ZOE-M8Q GPS
- LSM9DS1 9-DOF IMU
- 1x 1-lane miniPCIe socket with USB 2.0
- Gateworks System Controller
- Audio jack with TLV320AIC Audio Codec, Speaker AMP
and TSA227E Headphone detect
- MAX8607 3-mode LED camera flash
- DECT ULE module
- FUSB302 USB-C PD and ISL9238 Battery charger

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 83d290c5 06-May-2018 Tom Rini <trini@konsulko.com>

SPDX: Convert all of our single license tags to Linux Kernel style

When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from. So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry. Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.

In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.

This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents. There's also a few places where I found we did not have a tag
and have introduced one.

Signed-off-by: Tom Rini <trini@konsulko.com>

# c10b1c43 03-Jan-2018 Tom Rini <trini@konsulko.com>

imx: ventana: Rework CONFIG_CMD_EECONFIG code to not be included in SPL

The command can only be used from full U-Boot, so do not build it into
SPL.

Cc: Stefano Babic <sbabic@denx.de>
Cc: Fabio Estevam <fabio.estevam@nxp.com>
Cc: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>

# 214fb19b 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5903 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 94a1d6c6 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW560x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 8d1a6ff8 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5904 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 385575bc 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW553x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# fe63fcb6 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: remove several EEPROM config bit dependence

Removed several EEPROM bit dependencies:
- for dt aliases that don't exist and thus don't ever do anything
(pcie,lvds1,uart*,vpu,csi*,hdmi_in,hdmi_out,cvbs_in,cvbs_out,gps)
- for features that don't effect bus ordering or have no detrimental affect
if erroneously enabled when not present (ahci,nand,i2c*)
- for features that have little to no impact on being erroneously enabled
but high impact if erroneously disabled (can*, spi*)
- for features that have an high adverse affect of not being set when they
should and no adverse affect of being set when they
shouldn't (ipu*).

Removing these means the following:
- these no longer are supported with the econfig command
- these no longer affect the device-tree in any way

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 75f21e31 08-Apr-2015 Tim Harvey <tharvey@gateworks.com>

imx: ventana: Add support for GW551x

The GW551x is a small form factor board based on the IMX6 SoC that includes:
* up to 512MB DDR3 memory
* up to 2GB NAND flash
* 1x miniPCIe socket (with USB)
* HDMI out (micro-HDMI)
* HDMI in (micro-HDMI)
* TTL level I/O (supported by GW16111 breakout board):
* I2C
* 2x UART
* CAN
* 2x DIO (GPIO/PWM)
* USB OTG

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3aa22674 21-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5520 support

The GW5520 has an IMX6Q SoC with 512MB of DDR3, 256MB of NAND flash as well as:
* 2x MiniPCIe sockets
* 2x USB host sockets
* 2x i210 GigE
* HDMI out
* digital I/O expansion

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9c0fe83e 07-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add econfig command

The Gateworks Ventana EEPROM contains a set of configuration bits that
affect the removal of device-tree nodes that support peripherals that do not
exist on sub-loaded boards. This patch adds:
- a structure to define a config bit name, dt node alias, bit position
- an array of supported configuration items
- an econfig command to get/set/list configuration bits
- use of the array when adjusting the FDT prior to boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1badf2f4 02-Jun-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: split read_eeprom into standalone file

Split the read_eeprom function out so that it can be shared (ie with SPL)

Cc: Stefan Roese <sr@denx.de>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Andy Ng <andreas2025@gmail.com>
Cc: Eric Nelson <eric.nelson@boundarydevices.com>
Cc: Tapani Utriainen <tapani@technexion.com>
Cc: Tom Rini <trini@ti.com>

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 74389c13 21-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: hexdump invalid EEPROM data

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9cdb1c6e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5901/GW5902

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 2285094e 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5909

The GW5909 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW5904 but with half the DRAM loaded
and an additional RS232 transceiver off UART2.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# ebe07ef7 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5908

The GW5908 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW530x but with 1GiB density DRAM
(64bit 512MiB).

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 00606b51 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5907

The GW5907 is a small single board computer based on the i.MX6DL SoC
with the following peripheral set:
- DDR3 memory (512MB default)
- 1x GigE (i.MX6 FEC)
- Gateworks System Controller

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 988916ad 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5906

The GW5906 is a GW552x with mechanical and power supply connector
differences.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# d1c3867a 04-Feb-2019 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add support for GW5905

The GW5905 is single-board tablet computer based on the i.MX6 SoC with the
following peripheral set:
- eMMC flash (boot device)
- microSD expansion
- LVDS display connector for off-board 3D+1C with PWM backlight
and I2C based touch controller
- MIPI camera connector supporting the TRULY CM8487-B500SA-E (OV5640)
- ublox EMMY-W1 WiFi/Bluetooth/NFC module (SDIO/UART)
- ublox ZOE-M8Q GPS
- LSM9DS1 9-DOF IMU
- 1x 1-lane miniPCIe socket with USB 2.0
- Gateworks System Controller
- Audio jack with TLV320AIC Audio Codec, Speaker AMP
and TSA227E Headphone detect
- MAX8607 3-mode LED camera flash
- DECT ULE module
- FUSB302 USB-C PD and ISL9238 Battery charger

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 83d290c5 06-May-2018 Tom Rini <trini@konsulko.com>

SPDX: Convert all of our single license tags to Linux Kernel style

When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from. So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry. Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.

In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.

This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents. There's also a few places where I found we did not have a tag
and have introduced one.

Signed-off-by: Tom Rini <trini@konsulko.com>

# c10b1c43 03-Jan-2018 Tom Rini <trini@konsulko.com>

imx: ventana: Rework CONFIG_CMD_EECONFIG code to not be included in SPL

The command can only be used from full U-Boot, so do not build it into
SPL.

Cc: Stefano Babic <sbabic@denx.de>
Cc: Fabio Estevam <fabio.estevam@nxp.com>
Cc: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>

# 214fb19b 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5903 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 94a1d6c6 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW560x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 8d1a6ff8 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5904 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 385575bc 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW553x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# fe63fcb6 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: remove several EEPROM config bit dependence

Removed several EEPROM bit dependencies:
- for dt aliases that don't exist and thus don't ever do anything
(pcie,lvds1,uart*,vpu,csi*,hdmi_in,hdmi_out,cvbs_in,cvbs_out,gps)
- for features that don't effect bus ordering or have no detrimental affect
if erroneously enabled when not present (ahci,nand,i2c*)
- for features that have little to no impact on being erroneously enabled
but high impact if erroneously disabled (can*, spi*)
- for features that have an high adverse affect of not being set when they
should and no adverse affect of being set when they
shouldn't (ipu*).

Removing these means the following:
- these no longer are supported with the econfig command
- these no longer affect the device-tree in any way

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 75f21e31 08-Apr-2015 Tim Harvey <tharvey@gateworks.com>

imx: ventana: Add support for GW551x

The GW551x is a small form factor board based on the IMX6 SoC that includes:
* up to 512MB DDR3 memory
* up to 2GB NAND flash
* 1x miniPCIe socket (with USB)
* HDMI out (micro-HDMI)
* HDMI in (micro-HDMI)
* TTL level I/O (supported by GW16111 breakout board):
* I2C
* 2x UART
* CAN
* 2x DIO (GPIO/PWM)
* USB OTG

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 3aa22674 21-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5520 support

The GW5520 has an IMX6Q SoC with 512MB of DDR3, 256MB of NAND flash as well as:
* 2x MiniPCIe sockets
* 2x USB host sockets
* 2x i210 GigE
* HDMI out
* digital I/O expansion

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 9c0fe83e 07-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add econfig command

The Gateworks Ventana EEPROM contains a set of configuration bits that
affect the removal of device-tree nodes that support peripherals that do not
exist on sub-loaded boards. This patch adds:
- a structure to define a config bit name, dt node alias, bit position
- an array of supported configuration items
- an econfig command to get/set/list configuration bits
- use of the array when adjusting the FDT prior to boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 1badf2f4 02-Jun-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: split read_eeprom into standalone file

Split the read_eeprom function out so that it can be shared (ie with SPL)

Cc: Stefan Roese <sr@denx.de>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Andy Ng <andreas2025@gmail.com>
Cc: Eric Nelson <eric.nelson@boundarydevices.com>
Cc: Tapani Utriainen <tapani@technexion.com>
Cc: Tom Rini <trini@ti.com>

Signed-off-by: Tim Harvey <tharvey@gateworks.com>

# 83d290c5 06-May-2018 Tom Rini <trini@konsulko.com>

SPDX: Convert all of our single license tags to Linux Kernel style

When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from. So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry. Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.

In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.

This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents. There's also a few places where I found we did not have a tag
and have introduced one.

Signed-off-by: Tom Rini <trini@konsulko.com>


# c10b1c43 03-Jan-2018 Tom Rini <trini@konsulko.com>

imx: ventana: Rework CONFIG_CMD_EECONFIG code to not be included in SPL

The command can only be used from full U-Boot, so do not build it into
SPL.

Cc: Stefano Babic <sbabic@denx.de>
Cc: Fabio Estevam <fabio.estevam@nxp.com>
Cc: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>


# 214fb19b 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5903 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>


# 94a1d6c6 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW560x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>


# 8d1a6ff8 17-Mar-2017 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5904 support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>


# 385575bc 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW553x support

Signed-off-by: Tim Harvey <tharvey@gateworks.com>


# fe63fcb6 24-May-2016 Tim Harvey <tharvey@gateworks.com>

imx: ventana: remove several EEPROM config bit dependence

Removed several EEPROM bit dependencies:
- for dt aliases that don't exist and thus don't ever do anything
(pcie,lvds1,uart*,vpu,csi*,hdmi_in,hdmi_out,cvbs_in,cvbs_out,gps)
- for features that don't effect bus ordering or have no detrimental affect
if erroneously enabled when not present (ahci,nand,i2c*)
- for features that have little to no impact on being erroneously enabled
but high impact if erroneously disabled (can*, spi*)
- for features that have an high adverse affect of not being set when they
should and no adverse affect of being set when they
shouldn't (ipu*).

Removing these means the following:
- these no longer are supported with the econfig command
- these no longer affect the device-tree in any way

Signed-off-by: Tim Harvey <tharvey@gateworks.com>


# 75f21e31 08-Apr-2015 Tim Harvey <tharvey@gateworks.com>

imx: ventana: Add support for GW551x

The GW551x is a small form factor board based on the IMX6 SoC that includes:
* up to 512MB DDR3 memory
* up to 2GB NAND flash
* 1x miniPCIe socket (with USB)
* HDMI out (micro-HDMI)
* HDMI in (micro-HDMI)
* TTL level I/O (supported by GW16111 breakout board):
* I2C
* 2x UART
* CAN
* 2x DIO (GPIO/PWM)
* USB OTG

Signed-off-by: Tim Harvey <tharvey@gateworks.com>


# 3aa22674 21-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add GW5520 support

The GW5520 has an IMX6Q SoC with 512MB of DDR3, 256MB of NAND flash as well as:
* 2x MiniPCIe sockets
* 2x USB host sockets
* 2x i210 GigE
* HDMI out
* digital I/O expansion

Signed-off-by: Tim Harvey <tharvey@gateworks.com>


# 9c0fe83e 07-Aug-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: add econfig command

The Gateworks Ventana EEPROM contains a set of configuration bits that
affect the removal of device-tree nodes that support peripherals that do not
exist on sub-loaded boards. This patch adds:
- a structure to define a config bit name, dt node alias, bit position
- an array of supported configuration items
- an econfig command to get/set/list configuration bits
- use of the array when adjusting the FDT prior to boot

Signed-off-by: Tim Harvey <tharvey@gateworks.com>


# 1badf2f4 02-Jun-2014 Tim Harvey <tharvey@gateworks.com>

imx: ventana: split read_eeprom into standalone file

Split the read_eeprom function out so that it can be shared (ie with SPL)

Cc: Stefan Roese <sr@denx.de>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Andy Ng <andreas2025@gmail.com>
Cc: Eric Nelson <eric.nelson@boundarydevices.com>
Cc: Tapani Utriainen <tapani@technexion.com>
Cc: Tom Rini <trini@ti.com>

Signed-off-by: Tim Harvey <tharvey@gateworks.com>