summaryrefslogtreecommitdiff
path: root/board/toradex/common/tdx-cfg-block.c
AgeCommit message (Collapse)Author
2025-07-24toradex: tdx-cfg-block: add verdin i.mx8m mini 0216 pid4Vitor Soares
Add PID4 0216 Verdin iMX8M Mini Quad 2GB WB IT to config block handling. Signed-off-by: Vitor Soares <vitor.soares@toradex.com> Acked-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2025-06-03toradex: tdx-cfg-block: add new pid4 supportVitor Soares
Add the new PID4 to the ConfigBlock handling: - 0098 Aquila iMX95 Hexa 16GB WB IT - 0099 Verdin AM62P Quad 2GB WB IT - 0201 SMARC iMX95 Hexa 8GB IT - 0202 SMARC iMX95 Hexa 4GB WB IT - 0203 SMARC iMX95 Hexa 4GB ET - 0204 SMARC iMX95 Hexa 2GB WB IT - 0205 SMARC iMX95 Hexa 2GB ET - 0206 SMARC iMX8M Plus Quad 4GB IT - 0207 SMARC iMX8M Plus Quad 2GB WB IT - 0208 SMARC iMX8M Plus Quad 2GB IT - 0209 SMARC iMX8M Plus Quadlite 1GB WB ET - 0210 SMARC iMX8M Plus Quadlite 1GB ET - 0211 Aquila AM69 Octa 32GB IT - 0212 Aquila AM69 Octa 16GB WB IT - 0213 Aquila AM69 Octa 16GB IT - 0214 Aquila AM69 Octa 8GB WB IT - 0215 Aquila AM69 Octa 8GB IT Signed-off-by: Vitor Soares <vitor.soares@toradex.com>
2025-04-25toradex: tdx-cfg-block: fix verdin imx95 sku 0089 pid4Emanuele Ghidoli
The memory size of the 0089 SKU is 8 GB instead of 16 GB. Fix PID4 0089 Verdin iMX95 definition, in the configuration block. Fixes: ce53f46f33b4 ("toradex: tdx-cfg-block: add verdin imx95 sku 0089 pid4") Signed-off-by: Emanuele Ghidoli <emanuele.ghidoli@toradex.com> Reviewed-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2025-04-11board: toradex: add Toradex SMARC iMX8MPVitor Soares
Add support for the Toradex SMARC iMX8MP. Link: https://www.toradex.com/computer-on-modules/smarc-arm-family/nxp-imx-8m-plus Link: https://www.toradex.com/products/carrier-board/smarc-development-board-kit Signed-off-by: Vitor Soares <vitor.soares@toradex.com>
2025-04-11toradex: tdx-cfg-block: add 0096 Toradex SMARC iMX95Vitor Soares
Add PID4 0096 Toradex SMARC iMX95 Hexa 8GB WB IT to config block handling. Signed-off-by: Vitor Soares <vitor.soares@toradex.com>
2025-01-31toradex: tdx-cfg-block: fix switch to user partitionStefan Eichenberger
The Toradex configuration block is stored in the first boot partition of the eMMC. After reading the configuration block, U-Boot switches back to the user partition. Currently, this operation always targets mmc device 0, even when the configuration block is stored on mmc device 2. This patch addresses the issue by switching the mmc device set in CONFIG_TDX_CFG_BLOCK_DEV to the user partition, rather than using the hardcoded device 0. Fixes: a2777ecb9d11 ("toradex: config block handling") Signed-off-by: Stefan Eichenberger <stefan.eichenberger@toradex.com> Reviewed-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2024-12-15toradex: tdx-cfg-block: add new apalis imx8 pidsStefan Eichenberger
Add new PIDs for the Apalis iMX8 modules featuring the industrial variant of the SoC, which supports a maximum CPU frequency of 1300 MHz. Signed-off-by: Stefan Eichenberger <stefan.eichenberger@toradex.com>
2024-12-15toradex: tdx-cfg-block: increase indentation for longer definesStefan Eichenberger
This preparation step ensures that the first column has sufficient space to handle longer defines. This is necessary for the new Apalis iMX8 defines. Signed-off-by: Stefan Eichenberger <stefan.eichenberger@toradex.com>
2024-12-15toradex: tdx-cfg-block: set apalis imx8dxp to always disabledStefan Eichenberger
Apalis iMX8DXP 1GB is currently set to enable when compiling for Apalis iMX8. This is a mistake the Apalis iMX8DXP 1GB was never released and is not compatible to the Apalis iMX8 series. Signed-off-by: Stefan Eichenberger <stefan.eichenberger@toradex.com>
2024-12-13toradex: tdx-cfg-block: rework modules pid4 handlingVitor Soares
The module pid4 currently corresponds to the index of the toradex_module array. If a new pid4 is introduced that does not follow the sequence of the previous entries, it will create a gap in the array. To address this, embed pid4 within the toradex_som structure and implement a function to retrieve the index corresponding to pid4. Signed-off-by: Vitor Soares <vitor.soares@toradex.com> Acked-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2024-06-03toradex: tdx-cfg-block: add verdin i.mx8m mini 0090 pid4Emanuele Ghidoli
Add new PID4 0090 Verdin iMX8M Mini Quad 4GB WB ET to support the new hardware variant. Signed-off-by: Emanuele Ghidoli <emanuele.ghidoli@toradex.com>
2024-06-03toradex: tdx-cfg-block: add verdin imx95 sku 0089 pid4Emanuele Ghidoli
Add new PID4 0089 Verdin iMX95 Hexa 16GB WB IT to config block handling. Signed-off-by: Emanuele Ghidoli <emanuele.ghidoli@toradex.com>
2024-06-03toradex: tdx-cfg-block: add aquila am69 sku 0088 pid4Emanuele Ghidoli
Add new PID4 0088 Aquila AM69 Octa 32GB WB IT to config block handling. Signed-off-by: Emanuele Ghidoli <emanuele.ghidoli@toradex.com>
2024-05-20Restore patch series "arm: dts: am62-beagleplay: Fix Beagleplay Ethernet"Tom Rini
As part of bringing the master branch back in to next, we need to allow for all of these changes to exist here. Reported-by: Jonas Karlman <jonas@kwiboo.se> Signed-off-by: Tom Rini <trini@konsulko.com>
2024-05-19Revert "Merge patch series "arm: dts: am62-beagleplay: Fix Beagleplay Ethernet""Tom Rini
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>
2024-05-07board: toradex: Remove <common.h> and add needed includesTom Rini
Remove <common.h> from this board vendor directory and when needed add missing include files directly. Signed-off-by: Tom Rini <trini@konsulko.com>
2024-03-11toradex: tdx-cfg-block: add 0087 i.mx8m mini product variantJoao Paulo Goncalves
Add new product id 0087 Verdin iMX8M Mini Quad 2GB IT. Signed-off-by: Joao Paulo Goncalves <joao.goncalves@toradex.com>
2024-02-08toradex: tdx-cfg-block: add 0086 i.mx8m mini skuJoao Paulo Goncalves
Add new product id 0086 Verdin iMX8M Mini DualLite 2GB IT. Signed-off-by: Joao Paulo Goncalves <joao.goncalves@toradex.com> Reviewed-by: Igor Opaniuk <igor.opaniuk@foundries.io>
2024-02-08toradex: tdx-cfg-block: Add new apalis and colibri pidJoao Paulo Goncalves
Add new apalis imx6 and colibri imx6/imx7 products IDs. Signed-off-by: Joao Paulo Goncalves <joao.goncalves@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2023-08-04toradex: tdx-cfg-block: add verdin am62 skusMarcel Ziswiler
Add initial Verdin AM62 Quad 1GB WB IT prototype and launch configuration SKUs to ConfigBlock handling. 0069: Verdin AM62 Quad 1GB WB IT 0071: Verdin AM62 Solo 512MB 0072: Verdin AM62 Solo 512MB WB IT 0073: Verdin AM62 Dual 1GB ET 0074: Verdin AM62 Dual 1GB IT 0075: Verdin AM62 Dual 1GB WB IT 0076: Verdin AM62 Quad 2GB WB IT Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Signed-off-by: Emanuele Ghidoli <emanuele.ghidoli@toradex.com>
2023-08-04toradex: tdx-cfg-block: rework display adapter name handlingMax Krummenacher
Rework the rather big array of zero length strings with 4 entries of actual display adapter names to a array of structs which ties a pid4 to its correspondent human readable string. Provide an accessor to get the string for a given PID4. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Signed-off-by: Andrejs Cainikovs <andrejs.cainikovs@toradex.com>
2023-08-04toradex: tdx-cfg-block: rework carrier board name handlingMax Krummenacher
Rework the rather big array of zero length strings with 4 entries of actual carrier board names to a array of structs which ties a pid4 to its correspondent human readable string. Provide an accessor to get the string for a given PID4. Rework the user of the information to use the accessor. Note that check_pid8_sanity() is used for early samples of Dahlia and the development board. Yavia isn't affected. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Signed-off-by: Andrejs Cainikovs <andrejs.cainikovs@toradex.com>
2023-08-04toradex: tdx-cfg-block: add yavia carrier cfg block infoMax Krummenacher
Add the Yavia Carrier board name string to the known carrier board list. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Signed-off-by: Andrejs Cainikovs <andrejs.cainikovs@toradex.com>
2023-07-11toradex: tdx-cfg-block: add 0070 verdin i.mx 8m plus quad skuEmanuele Ghidoli
Add new i.MX 8M Plus Quad SKU to ConfigBlock handling. 0070: Verdin iMX8M Plus Quad 8GB WB IT This SKU is identical to 0066 but supporting Industrial Temperature range. Signed-off-by: Emanuele Ghidoli <emanuele.ghidoli@toradex.com> Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2022-09-16blk: Switch over to using uclass IDsSimon Glass
We currently have an if_type (interface type) and a uclass id. These are closely related and we don't need to have both. Drop the if_type values and use the uclass ones instead. Maintain the existing, subtle, one-way conversion between UCLASS_USB and UCLASS_MASS_STORAGE for now, and add a comment. Signed-off-by: Simon Glass <sjg@chromium.org>
2022-08-04Audit <flash.h> inclusionTom Rini
A large number of files include <flash.h> as it used to be how various SPI flash related functions were found, or for other reasons entirely. In order to migrate some further CONFIG symbols to Kconfig we need to not include flash.h in cases where we don't have a NOR flash of some sort enabled. Furthermore, in cases where we are in common code and it doesn't make sense to try and further refactor the code itself in to new files we need to guard this inclusion. Signed-off-by: Tom Rini <trini@konsulko.com>
2022-07-25toradex: tdx-cfg-block: Use official SKU namesFrancesco Dolcini
Up to now in the code we named Toradex SKUs in a slightly different way compared to the official product name, start using the official names from now on to avoid misunderstanding. This has also the nice benefit of the string being shorter, allowing to fit nicely in 80 columns even adding the product ID when printing the hardware information. Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2022-07-25toradex: tdx-cfg-block: Cleanup interactive cfg block creationFrancesco Dolcini
Simplify interactive config block creation code, instead of having a a long list of questions and a complex tree of preprocessor directive to guess the exact SKU, just ask the user to select it from a list. The modules list is filtered out to include only SKUs that are supported by the specific u-boot binary in execution. Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2022-07-25toradex: common: Use ARRAY_SIZE macroFrancesco Dolcini
Use generally available ARRAY_SIZE macro, instead of hand-coding it every time is needed. Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2022-07-25toradex: common: Remove stale comments about modules availabilityFrancesco Dolcini
Remove comment "not currently on sale" on specific SKUs, this information does not belong to the code and will never be accurate. Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2022-07-25toradex: tdx-cfg-block: add 0068 i.mx 8m mini skuPhilippe Schenker
Add new i.MX 8M Mini SKU to ConfigBlock handling. 0068: Verdin iMX8M Mini Quad 2GB WB IT No CAN This SKU is identical to 0055 but without CAN. Mention this in the name so those modules can be distinguished. Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com> Reviewed-by: Francesco Dolcini <francesco.dolcini@toradex.com> Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2022-07-06toradex: tdx-cfg-block: add new toradex oui rangePhilippe Schenker
Add new Toradex MAC OUI (8c:06:cb), to the config block. With this change we extend the possible serial-numbers as follows: For serial-numbers 00000000-16777215 OUI 00:14:2d is taken For serial-numbers 16777216-33554431 OUI 8c:06:cb is taken Lower 24-bit of the serial number are used in the NIC part of the MAC address, the complete serial number can be calculated using the OUI. Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com> Reviewed-by: Francesco Dolcini <francesco.dolcini@toradex.com> Reviewed-by: Fabio Estevam <festevam@denx.de> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2022-07-06toradex: tdx-cfg-block: extend assembly versionPhilippe Schenker
There are two decimal digits reserved to encode the module version and revision. This code so far implemented A-Z which used 0-25 of this range. This commit extends the range to make use of all 99 numbers. After capital letters the form with a hashtag and number (e.g. #26) is used. Examples: If the assembly version is between zero and 25 the numbering is as follows, as it also has been before this commit: 0: V0.0A 1: V0.0B ... 25: V0.0Z New numbering of assembly version: If the number is between 26 and 99 the new assembly version name is: 26: V0.0#26 27: V0.0#27 ... 99: V0.0#99 Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com> Reviewed-by: Francesco Dolcini <francesco.dolcini@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2022-06-14toradex: tdx-cfg-block: add new 8gb apalis-imx8Philippe Schenker
0067: Apalis iMX8 QuadMax 8GB Wi-Fi / BT IT This module is identical to its 4GB counterpart 0037: Apalis iMX8 QuadMax 4GB Wi-Fi / BT IT except for the RAM size. Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com> Reviewed-by: Francesco Dolcini <francesco.dolcini@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2022-04-21board: toradex: drop colibri pxa270 supportMarcel Ziswiler
The Colibri PXA270 has been end-of-life since quite a while and would require more and more maintenance (e.g. DM conversions). Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2022-04-21toradex: apalis-imx8x: drop support for apalis imx8xDenys Drozdov
Drop Apalis iMX8X platform as it never left sample state and is no longer supported. Signed-off-by: Denys Drozdov <denys.drozdov@toradex.com> Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2021-10-20toradex: tdx-cfg-block: add new i.mx 6ull and 8m plus skusMarcel Ziswiler
Add new i.MX 6ULL and 8M Plus SKUs to ConfigBlock handling: 0062: Colibri iMX6ULL 1GB IT (eMMC) 0063: Verdin iMX8M Plus Quad 4GB IT 0064: Verdin iMX8M Plus Quad 2GB Wi-Fi / BT IT 0065: Verdin iMX8M Plus QuadLite 1GB IT 0066: Verdin iMX8M Plus Quad 8GB Wi-Fi / BT Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2021-10-20toradex: configblock: fix interactive mode it handlingDenys Drozdov
Restore "Is the module an IT version? [y/N]" for "cfgblock create" interactive mode command, which was leading to invalid detection of 0051 Colibri iMX8DX 1GB WB module; Fixes: a5b5ad4d859b ("toradex: tdx-cfg-clock: add new i.mx 8m mini/plus skus") Related-to: ELB-3482 Signed-off-by: Denys Drozdov <denys.drozdov@toradex.com> Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2021-09-07arm: Finish migration of CONFIG_MACH_TYPETom Rini
As this is only useful when booting with ATAGs, which are now largely disabled, remove this value for the remaining platforms. We have a few places in the code that had been testing for MACH_TYPE as a sort of internal logic. Update those to use different but still correct CONFIG symbols. Cc: Phil Sutter <phil@nwl.cc> Signed-off-by: Tom Rini <trini@konsulko.com>
2021-08-02global: Convert simple_strtoul() with decimal to dectoul()Simon Glass
It is a pain to have to specify the value 10 in each call. Add a new dectoul() function and update the code to use it. Signed-off-by: Simon Glass <sjg@chromium.org>
2021-04-20toradex: configblock: fix module revision in config blockDenys Drozdov
U-boot might display wrong module revision information for modules with an assembly version 'K'. "cfgblock create" does not takes into account all revision digits from PID8. This fix takes into account all digits of PID8 to store module revision. Signed-off-by: Denys Drozdov <denys.drozdov@toradex.com> Reviewed-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
2021-02-02common: Drop asm/global_data.h from common headerSimon Glass
Move this out of the common header and include it only where needed. In a number of cases this requires adding "struct udevice;" to avoid adding another large header or in other cases replacing / adding missing header files that had been pulled in, very indirectly. Finally, we have a few cases where we did not need to include <asm/global_data.h> at all, so remove that include. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Rini <trini@konsulko.com>
2020-12-06toradex: tdx-cfg-clock: fix i.mx 8m mini interactiveMarcel Ziswiler
Now with them first Verdin iMX8M Mini DualLite modules in for bring-up we got clarity how is_cpu_type() actually behaves. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Reviewed-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
2020-12-06toradex: tdx-cfg-clock: add new i.mx 8m mini/plus skusMarcel Ziswiler
Add new i.MX 8M Mini/Plus SKUs to ConfigBlock handling: 0058: Verdin iMX8M Plus Quad 4GB Wi-Fi / BT IT 0059: Verdin iMX8M Mini Quad 2GB IT 0060: Verdin iMX8M Mini DualLite 1GB WB IT 0061: Verdin iMX8M Plus Quad 2GB Rename existing SKU (use correct one): Verdin iMX8M Nano SoloLite 1GB -> Verdin iMX8M Nano Quad 1GB Wi-Fi Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com> Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2020-07-27toradex: tdx-cfg-clock: add migration routine from PID8Igor Opaniuk
Add migration routine from PID8 pre-stored values on EEPROM (including sane value checks). Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-07-27toradex: tdx-cfg-block: add support for EEPROMIgor Opaniuk
This introduces support for EEPROM as a storage for the main Toradex config block and additional config blocks on extra EEPROM chips (on carrier board or video adapters). To enable EEPROM as a storage for the main config block: TDX_HAVE_EEPROM=y. For additional EEPROMs please enable this Kconfig symbol: TDX_CFG_BLOCK_EXTRA=y. Information about existing EEPROM chips is provided via Device Tree using aliases. You can also write configuration for the carrier board using create_carrier subcommand for cfgblock. Example: Verdin iMX8MM # cfgblock create_carrier Supported carrier boards: UNKNOWN CARRIER = [0] Verdin Carrier Board = [1] Choose your carrier board (provide ID): 1 Enter carrier board version (e.g. V1.1B): V1.0A Enter carrier board serial number: 10622780 Also with barcode: Verdin iMX8MM # cfgblock create carrier -y 0156100010622780 Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-07-27toradex: tdx-cfg-block: add carrier boards and display adaptersIgor Opaniuk
Add defines for supported carrier boards and display adapters. Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-05-18command: Remove the cmd_tbl_t typedefSimon Glass
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>
2020-05-18common: Drop net.h from common headerSimon Glass
Move this header out of the common header. Network support is used in quite a few places but it still does not warrant blanket inclusion. Note that this net.h header itself has quite a lot in it. It could be split into the driver-mode support, functions, structures, checksumming, etc. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-02-09toradex: tdx-cfg-block: add Verdin iMX8M Mini/Nano supportMarcel Ziswiler
Add support for storing configuration for Verdin iMX8M Mini and Nano SoMs in Toradex config block. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com> Reviewed-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>