Arcady,
What versions of components are you using? OSD3358-SM-RED device tree is mainlined. See here: https://github.com/torvalds/linux/blob/master/arch/arm/boot/dts/ti/omap/am335x-osd3358-sm-red.dts.
I am waiting on a RED board to do testing, I will report back when I have some additional info.
Best,
Neeraj
Arcady,
Looking at the error message, it looks like it is originating here: https://github.com/torvalds/linux/blob/v6.6/drivers/clk/ti/clkctrl.c#L578. Can you check if you have the right config file that defines CONFIG_SOC_AM33XX(https://github.com/torvalds/linux/blob/v6.6/drivers/clk/ti/clkctrl.c#L548) and if you defined the compatible property for the board in the device tree with “ti, am33xx” as being checked here: https://github.com/torvalds/linux/blob/v6.6/drivers/clk/ti/clkctrl.c#L549?
Best,
Neeraj
Doug,
Apologies, this was overlooked for updates. Will add to the next release.
Best,
Neeraj
Gil,
(1) & (2) – Yes you are correct.
(3) – The patch is essentially checking whether the regulator was set as “always on” supply in the device tree. If it is configured as an always on regulator, it will not turn the regulator off even when a function call is made to turn it off.
Best,
Neeraj
Arcady,
The pinmux should be setup parts of the device tree overlay. You can make sure you are using the right pins looking at the pinmux section of the overlay(for example: https://github.com/beagleboard/bb.org-overlays/blob/master/src/arm/BB-UART2-00A0.dts#L29).
You can also use the config-pin utility to check on the pinmux states of the pins: https://github.com/beagleboard/bb.org-overlays/blob/master/tools/pmunts_muntsos/config-pin.c.
Depending on your kernel version and config, you should also be able to “cat /sys/kernel/debug/pinctrl” to get status of all pinmux for the device.
The bootlog you posted indicates that drivers were successfully initialized for several UARTs. So, it is probably a pinmux issue.
Best,
Neeraj
Gil,
The patch has been integrated into newer releases of OpenSTLinux. So, I would use the patch as opposed to the DT work around.
Best,
Neeraj
Gil,
From the bootlog of the failure, it looks like CMD13 issued by TF-A is not getting a response from the SD card. See detail here: https://chlazza.nfshost.com/sdcardinfo.html.
I found https://community.st.com/t5/stm32-mpus-products/stm32mp1-occasionally-emmc-boot-fail-with-quot-cmd13-failed/td-p/108285 on ST’s forums looks very close to what you are seeing. The issue you are encountering may be because power cycling of the regulator that supplied power to the SD card during TF-A execution.
The solution proposed by ST: https://community.st.com/t5/stm32-mpus-embedded-software/when-updating-from-arm-trusted-firmware-v2-4-stm32mp-r1-to-arm/td-p/94079 is a patch that disables this cycling. Can you try this solution and check if the issue still exists?
Best,
Neeraj
Hey Gil,
A few questions on the board behavior:
1. When you observe DDR at 0V, do you see all the other power rails with RANK 0 coming up normally?
2. Is this ‘erratic’ boot observed on all the prototypes?
As Michal suggests, it may be that TF-A execution is running into error. Can you post the boot log file when the failure is observed?
You are correct that TF-A would bring up DDR power rail and initialize the clocks and DDR interface. TF-A is being read from SD card. If you don’t observe any boot logs when boot fails, it could be that the SD interface may be failing to transfer TF-A. I would try using a different SD card to see if that fixes the issue.
If TF-A successfully initializes and runs, the logs could give you an indication of where execution if failing. See https://wiki.st.com/stm32mpu/wiki/How_to_debug_TF-A_BL2 for additional help on enabling traces.
Best,
Neeraj
Ryan,
Please take a look at the Beaglebone Black Wireless(https://github.com/beagleboard/beaglebone-black-wireless/blob/master/BeagleBone_Black_Wireless_SCH.pdf) for an example use of MMC2. In this design, MMC2 is used for WiFi as SDIO interface.
Best,
Neeraj
Ryan,
Yes, you can use multiple SD cards. There are 3 MMC interfaces for AM335x inside OSD335x. As you mentioned, you can use MMC0 for boot and additional SD cards on MMC1 and MMC2 interfaces. Please note that MMC1 interface is used for eMMC in OSD3358-ICB. So, you will need to use MMC2 for the additional SD card interface on ICB device.
Best,
Neeraj
Apporva,
The above log seems to indicate that there was a kernel panic during initialization of the WiFi module. Here are a few debug inputs:
First, I suggest making sure the module is powered and enabled. The Beaglebone black sets up an enable signal here: https://github.com/RobertCNelson/dtb-rebuilder/blob/4.19-ti/src/arm/am335x-boneblack-wireless.dts#L20.
In addition, please check for proper pinmux setup. The MMC interface pinmux for BBWireless is here: https://github.com/RobertCNelson/dtb-rebuilder/blob/4.19-ti/src/arm/am335x-boneblack-wireless.dts#L40. Also verify GPIO control pinmux for the WiFi module here: https://github.com/RobertCNelson/dtb-rebuilder/blob/4.19-ti/src/arm/am335x-boneblack-wireless.dts#L60.
Please probe the ENABLE signal to the WiFi module to make sure the module is being enabled to respond to probing.
Best,
Neeraj
Apoorva,
Please take a look at the device tree bindings for WLXX devices here: https://elixir.bootlin.com/linux/v4.19.315/source/Documentation/devicetree/bindings/net/wireless/ti,wlcore.txt
Beaglebonne Black Wireless uses a similar Wilink modue(WL1835). The schematics are available here: https://github.com/beagleboard/beaglebone-black-wireless/blob/master/BeagleBone_Black_Wireless_SCH.pdf. The device tree for WiFi for Beaglebone Black Wireless is here: https://github.com/RobertCNelson/dtb-rebuilder/blob/4.19-ti/src/arm/am335x-boneblack-wireless.dts#L73. You should be able to use this device tree as a reference.
Additional documentation if you want to dig deeper: https://www.ti.com/lit/ug/swru561a/swru561a.pdf.
Best,
Neeraj
Craig,
In addition to Eshtaartha’s notes on M4 debug in production mode, please see https://community.st.com/t5/stm32-mpus-other-tools/how-to-generate-elf-file-for-cortex-m4-using-iar/td-p/84786 for a discussion on 3rd party tools working with MP1.
Best,
Neeraj
Palmer,
Apologies for the late reply.
The Flashlayout file format for SD card is different from the Flahslayout file for eMMC. Please take a look at Section 3 of this page: https://wiki.st.com/stm32mpu-ecosystem-v3/wiki/STM32CubeProgrammer_flashlayout#Typical_FlashLayout_file_with_FIP. Also note that the mmc interface used looks like mmc0. Make sure that your mmc interface is correct. Once you replace the Flashlayout file with the one for eMMC and chose the right mmc interface, this flashing procedure over UART should work.
Best,
Neeraj
Yanjun,
You can do this, but you will need to add the mass storage gadget drivers to the kernel first:
CONFIG_USB_GADGETFS=m
CONFIG_USB_G_ACM_MS=m
CONFIG_USB_MASS_STORAGE=m
Once you add these drivers, you will also need to disable the current USB RNDIS network on the board. Then, you should be able to do:
modprobe g_mass_storage file=/path_to_storage_file
Best,
Neeraj
Octavo Systems LLC all rights reserved
OCTAVO is registered in the U.S. Patent and Trademark Office. OSD, C-SiP, and the Octavo Logo are trademarks of Octavo Systems LLC.
"*" indicates required fields
"*" indicates required fields
"*" indicates required fields
"*" indicates required fields