Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

U-boot-at91 prints strange characters #31

Open
SimoneBongini opened this issue Jun 21, 2023 · 8 comments
Open

U-boot-at91 prints strange characters #31

SimoneBongini opened this issue Jun 21, 2023 · 8 comments

Comments

@SimoneBongini
Copy link

SimoneBongini commented Jun 21, 2023

Hello

I'm using an ArrowElectronic Shield96 boad which based on SAMA5D27_SIP.

I was able to build:

  • at91bootstrap (4.0.5+gitAUTOINC+8fe4b67188-r0 )
  • at91 u-boot (v2022.01-at91+gitAUTOINC+76f7f55e04-r0)
  • at91 linux kernel (5.15+gitAUTOINC+5aedde3bc3-r0)
  • rootFS

obtaining a .wic image.
After flashed successfully the SDCard with balenaEtcher, I got that the U-boot print strange characters.

AT91Bootstrap 4.0.5 (2022-11-09 13:05:42) 
SD/MMC: Image: Read file u-boot.bin to 0x23f0000 
MMC: ADMA supported 
SD: Card Capacity: High or Extended 
SD: Specification Version 3.0X 
SD/MMC: Done to load image
serial_atmel serial@f8020000: pinctrl_select_state_full: uclass_get_device_by_phandle_id: err=-19
 怘▒怘▒f3▒0▒▒▒▒?▒▒▒▒?▒▒<f̆▒f?▒▒▒▒f▒f▒f▒ x ▒x x ▒▒0?3▒x?
▒▒▒▒▒▒▒▒▒▒x ~ ▒▒▒▒▒▒f ▒▒▒▒▒▒03 03▒0▒f3▒▒▒ffff▒ ▒x▒0fx
▒0▒▒f▒▒▒▒▒ ▒▒▒x ▒▒▒▒fff ▒▒f▒▒▒▒f▒▒▒
...
...
 ▒▒Ø▒▒f▒x<x ▒▒▒▒▒▒
Ø▒▒3▒f3xx0▒▒▒▒▒怘▒怘▒3?<??▒▒▒~<▒▒fÆ▒f<▒???▒0303▒ 
Booting Linux on physical CPU 0x0 
Linux version 5.15.68-linux4microchip-2022.10 (oe-user@oe-host) (arm-poky-linux-gnueabi-gcc (GCC) 11.3.0, GNU ld (GNU Binutils) 2.38.20220708) #1 Wed Nov 9 12:48:42 UTC 2022
CPU: ARMv7 Processor [410fc051] revision 1 (ARMv7), cr=10c53c7d CPU: PIPT / VIPT nonaliasing data cache, VIP

Then kernel start normally.
I noticed
serial_atmel serial@f8020000: pinctrl_select_state_full: uclass_get_device_by_phandle_id: err=-19

I'm using, more or less, a sama5d27_som1_ek devices tree, so it should be defined correctly.
Seems u-boot change serial baudrate. Is it possible?

@SimoneBongini
Copy link
Author

Going deeper enabling more verbose logs

Bound device i2s1_gclk to slowck
size=40, ptr=4e20, limit=8000: aligned to 20008cc0
size=40, ptr=4e60, limit=8000: aligned to 20008d00
clk_register: name: can0_gclk parent: slowck [0x20004c80]
size=50, ptr=4eb0, limit=8000: 20008d40
Bound device can0_gclk to slowck
size=40, ptr=4f20, limit=8000: aligned to 20008dc0
size=40, ptr=4f60, limit=8000: aligned to 20008e00
clk_register: name: can1_gclk parent: slowck [0x20004c80]
size=50, ptr=4fb0, limit=8000: 20008e40
Bound device can1_gclk to slowck
master clk is overclock▒怘▒怘▒f3▒0▒▒▒▒?▒▒▒▒?▒▒<f̆▒f?▒▒▒▒f▒f▒f▒ x ▒x▒x ▒▒0▒▒▒▒
▒x
▒x
▒x▒x
▒▒▒▒▒▒▒▒▒▒▒▒f
▒▒▒▒▒▒0303▒f̆▒fx3▒▒▒<▒▒▒f▒
▒▒▒▒
▒<f▒f▒f▒▒f▒
▒▒▒▒▒▒▒▒▒▒f▒
▒03`▒f̆▒f▒f▒▒▒▒<▒▒▒f▒
▒f▒▒
▒<f▒f▒f▒▒f▒
▒▒▒▒▒▒▒▒▒▒f▒▒▒3▒?▒▒▒f▒f▒▒▒▒<▒▒▒f▒▒▒▒x
▒▒<f▒f▒f▒▒f▒

@ryan-wanner
Copy link

It looks like your USART registers are configured very differently. Could you send a copy of your u-boot.bin and uboot.env Are you using USART1 for the serial output? Could you also try a full clean rebuild for the whole project?

@ryan-wanner
Copy link

Hi Simone,
Booted up your u-boot.bin file I do see the correct output in 115200. Did you make any changes to the device tree in uboot? Based on this error I see that you get "serial_atmel serial@f8020000: pinctrl_select_state_full: uclass_get_device_by_phandle_id: err=-19" I think you might have the pinctrl wrong on the dts file

@SimoneBongini
Copy link
Author

Hi Simone, Booted up your u-boot.bin file I do see the correct output in 115200. Did you make any changes to the device tree in uboot? Based on this error I see that you get "serial_atmel serial@f8020000: pinctrl_select_state_full: uclass_get_device_by_phandle_id: err=-19" I think you might have the pinctrl wrong on the dts file

Hi Ryan,
I'm using
https://github.com/linux4sam/u-boot-at91/blob/linux4sam-2022.10/arch/arm/dts/at91-sama5d27_som1_ek.dts
No modifications or other..

@SimoneBongini
Copy link
Author

Hello Ryan,
enabling more verbose log I got:

D/TC:0 0 call_initcalls:40 level 6 sam_init_scmi_server()
D/TC:0 0 call_initcalls:40 level 6 mobj_init()
D/TC:0 0 call_initcalls:40 level 6 default_mobj_init()
D/TC:0 0 call_initcalls:40 level 7 release_probe_lists()
D/TC:0 0 call_finalcalls:59 level 1 release_external_dt()
I/TC: Primary CPU switching to normal world boot
size=18, ptr=18, limit=8000: 22003ee0
common/malloc_simple.c:26- alloc_simple() size=18, ptr=30, limit=8000: 22003ef8
common/malloc_simple.c:26- alloc_simple() size=50, ptr=80, limit=8000: 22003f10
drivers/core/lists.c:201- lists_bind_fdt() bind node chosen
drivers/core/lists.c:206- lists_bind_fdt() Device 'chosen' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node aliases
drivers/core/lists.c:206- lists_bind_fdt() Device 'aliases' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node memory
drivers/core/lists.c:206- lists_bind_fdt() Device 'memory' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node clocks
drivers/core/lists.c:206- lists_bind_fdt() Device 'clocks' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node cpus
drivers/core/lists.c:206- lists_bind_fdt() Device 'cpus' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node ahb
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'simple-bus'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'simple_bus': 'simple-bus' matches 'simple-bus'
common/malloc_simple.c:26- alloc_simple() size=18, ptr=98, limit=8000: 22003f60
common/malloc_simple.c:26- alloc_simple() size=50, ptr=e8, limit=8000: 22003f78
common/malloc_simple.c:26- alloc_simple() size=c, ptr=f4, limit=8000: 22003fc8
drivers/core/lists.c:201- lists_bind_fdt() bind node ohci@400000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,at91rm9200-ohci'
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'usb-ohci'
drivers/core/lists.c:266- lists_bind_fdt() No match for node 'ohci@400000'
drivers/core/lists.c:201- lists_bind_fdt() bind node ehci@500000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,at91sam9g45-ehci'
drivers/core/lists.c:239- lists_bind_fdt() Skipping device pre-relocation
drivers/core/lists.c:201- lists_bind_fdt() bind node sdio-host@a0000000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,sama5d2-sdhci'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'atmel_sdhci': 'atmel,sama5d2-sdhci' matches 'atmel,sama5d2-sdhci'
common/malloc_simple.c:26- alloc_simple() size=18, ptr=10c, limit=8000: 22003fd4
common/malloc_simple.c:26- alloc_simple() size=50, ptr=15c, limit=8000: 22003fec
common/malloc_simple.c:26- alloc_simple() size=130, ptr=28c, limit=8000: 2200403c
common/malloc_simple.c:26- alloc_simple() size=17, ptr=2a3, limit=8000: 2200416c
common/malloc_simple.c:26- alloc_simple() size=18, ptr=2bc, limit=8000: 22004184
common/malloc_simple.c:26- alloc_simple() size=50, ptr=30c, limit=8000: 2200419c
common/malloc_simple.c:26- alloc_simple() size=80, ptr=38c, limit=8000: 220041ec
drivers/core/lists.c:201- lists_bind_fdt() bind node sdio-host@b0000000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,sama5d2-sdhci'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'atmel_sdhci': 'atmel,sama5d2-sdhci' matches 'atmel,sama5d2-sdhci'
common/malloc_simple.c:26- alloc_simple() size=50, ptr=3dc, limit=8000: 2200426c
common/malloc_simple.c:26- alloc_simple() size=130, ptr=50c, limit=8000: 220042bc
common/malloc_simple.c:26- alloc_simple() size=17, ptr=523, limit=8000: 220043ec
common/malloc_simple.c:26- alloc_simple() size=50, ptr=574, limit=8000: 22004404
common/malloc_simple.c:26- alloc_simple() size=80, ptr=5f4, limit=8000: 22004454
drivers/core/lists.c:201- lists_bind_fdt() bind node apb
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'simple-bus'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'simple_bus': 'simple-bus' matches 'simple-bus'
common/malloc_simple.c:26- alloc_simple() size=50, ptr=644, limit=8000: 220044d4
common/malloc_simple.c:26- alloc_simple() size=c, ptr=650, limit=8000: 22004524
drivers/core/lists.c:201- lists_bind_fdt() bind node hlcdc@f0000000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,at91sam9x5-hlcdc'
drivers/core/lists.c:266- lists_bind_fdt() No match for node 'hlcdc@f0000000'
drivers/core/lists.c:201- lists_bind_fdt() bind node spi@f0024000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,sama5d2-qspi'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'atmel_qspi': 'atmel,sama5d2-qspi' matches 'atmel,sama5d2-qspi'
common/malloc_simple.c:26- alloc_simple() size=18, ptr=668, limit=8000: 22004530
common/malloc_simple.c:26- alloc_simple() size=50, ptr=6b8, limit=8000: 22004548
drivers/core/device.c:93- device_bind_common() - seq=0
drivers/core/lists.c:201- lists_bind_fdt() bind node spi_flash@0
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'jedec,spi-nor'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'jedec_spi_nor': 'jedec,spi-nor' matches 'jedec,spi-nor'
common/malloc_simple.c:26- alloc_simple() size=18, ptr=6d0, limit=8000: 22004598
common/malloc_simple.c:26- alloc_simple() size=50, ptr=720, limit=8000: 220045b0
common/malloc_simple.c:26- alloc_simple() size=c, ptr=72c, limit=8000: 22004600
drivers/core/lists.c:201- lists_bind_fdt() bind node ethernet@f8008000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'cdns,macb'
drivers/core/lists.c:239- lists_bind_fdt() Skipping device pre-relocation
drivers/core/lists.c:201- lists_bind_fdt() bind node timer@f800c000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,sama5d2-tcb'
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'simple-mfd'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'simple_bus': 'simple-bus' matches 'simple-mfd'
common/malloc_simple.c:26- alloc_simple() size=50, ptr=77c, limit=8000: 2200460c
common/malloc_simple.c:26- alloc_simple() size=c, ptr=788, limit=8000: 2200465c
drivers/core/lists.c:201- lists_bind_fdt() bind node timer@0
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,tcb-timer'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'atmel_tcb': 'atmel,tcb-timer' matches 'atmel,tcb-timer'
common/malloc_simple.c:26- alloc_simple() size=18, ptr=7a0, limit=8000: 22004668
common/malloc_simple.c:26- alloc_simple() size=50, ptr=7f0, limit=8000: 22004680
common/malloc_simple.c:26- alloc_simple() size=4, ptr=7f4, limit=8000: 220046d0
drivers/core/lists.c:201- lists_bind_fdt() bind node serial@f8020000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,at91sam9260-usart'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'serial_atmel': 'atmel,at91sam9260-dbgu' matches 'atmel,at91sam9260-usart'
common/malloc_simple.c:26- alloc_simple() size=18, ptr=80c, limit=8000: 220046d4
common/malloc_simple.c:26- alloc_simple() size=50, ptr=85c, limit=8000: 220046ec
common/malloc_simple.c:26- alloc_simple() size=4, ptr=860, limit=8000: 2200473c
drivers/core/lists.c:201- lists_bind_fdt() bind node i2c@f8028000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,sama5d2-i2c'
drivers/core/lists.c:239- lists_bind_fdt() Skipping device pre-relocation
drivers/core/lists.c:201- lists_bind_fdt() bind node sfr@f8030000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,sama5d2-sfr'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'microchip_sfr': 'atmel,sama5d2-sfr' matches 'atmel,sama5d2-sfr'
common/malloc_simple.c:26- alloc_simple() size=18, ptr=878, limit=8000: 22004740
common/malloc_simple.c:26- alloc_simple() size=50, ptr=8c8, limit=8000: 22004758
drivers/core/lists.c:201- lists_bind_fdt() bind node interrupt-controller@fc020000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,sama5d2-aic'
drivers/core/lists.c:266- lists_bind_fdt() No match for node 'interrupt-controller@fc020000'
drivers/core/lists.c:201- lists_bind_fdt() bind node i2c@fc028000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,sama5d2-i2c'
drivers/core/lists.c:239- lists_bind_fdt() Skipping device pre-relocation
drivers/core/lists.c:201- lists_bind_fdt() bind node pinctrl@fc038000
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'atmel,sama5d2-pinctrl'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'pinctrl_atmel_pio4': 'atmel,sama5d2-pinctrl' matches 'atmel,sama5d2-pinctrl'
common/malloc_simple.c:26- alloc_simple() size=18, ptr=8e0, limit=8000: 220047a8
common/malloc_simple.c:26- alloc_simple() size=50, ptr=930, limit=8000: 220047c0
common/malloc_simple.c:26- alloc_simple() size=8, ptr=938, limit=8000: 22004810
common/malloc_simple.c:26- alloc_simple() size=18, ptr=950, limit=8000: 22004818
common/malloc_simple.c:26- alloc_simple() size=50, ptr=9a0, limit=8000: 22004830
common/malloc_simple.c:26- alloc_simple() size=4, ptr=9a4, limit=8000: 22004880
drivers/core/lists.c:201- lists_bind_fdt() bind node i2c0_default
drivers/core/lists.c:206- lists_bind_fdt() Device 'i2c0_default' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node i2c1_default
drivers/core/lists.c:206- lists_bind_fdt() Device 'i2c1_default' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node macb0_phy_irq
drivers/core/lists.c:206- lists_bind_fdt() Device 'macb0_phy_irq' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node macb0_rmii
drivers/core/lists.c:206- lists_bind_fdt() Device 'macb0_rmii' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node qspi1_sck_cs_default
drivers/core/lists.c:206- lists_bind_fdt() Device 'qspi1_sck_cs_default' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node qspi1_dat_default
drivers/core/lists.c:206- lists_bind_fdt() Device 'qspi1_dat_default' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node pinctrl
drivers/core/lists.c:206- lists_bind_fdt() Device 'pinctrl' has no compatible string
common/malloc_simple.c:26- alloc_simple() size=18, ptr=9bc, limit=8000: 22004884
common/malloc_simple.c:26- alloc_simple() size=50, ptr=a0c, limit=8000: 2200489c
common/malloc_simple.c:26- alloc_simple() size=50, ptr=a5c, limit=8000: 220048ec
drivers/core/lists.c:201- lists_bind_fdt() bind node onewire
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'w1-gpio'
drivers/core/lists.c:239- lists_bind_fdt() Skipping device pre-relocation
drivers/core/lists.c:201- lists_bind_fdt() bind node reserved-memory
drivers/core/lists.c:206- lists_bind_fdt() Device 'reserved-memory' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node firmware
drivers/core/lists.c:206- lists_bind_fdt() Device 'firmware' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node psci
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'arm,psci-1.0'
drivers/core/lists.c:239- lists_bind_fdt() Skipping device pre-relocation
drivers/core/lists.c:201- lists_bind_fdt() bind node symbols
drivers/core/lists.c:206- lists_bind_fdt() Device 'symbols' has no compatible string
drivers/core/lists.c:201- lists_bind_fdt() bind node slow_rc_osc
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'fixed-clock'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'fixed_clock': 'fixed-clock' matches 'fixed-clock'
common/malloc_simple.c:26- alloc_simple() size=18, ptr=a74, limit=8000: 2200493c
common/malloc_simple.c:26- alloc_simple() size=50, ptr=ac4, limit=8000: 22004954
common/malloc_simple.c:26- alloc_simple() size=28, ptr=aec, limit=8000: 220049a4
drivers/core/lists.c:201- lists_bind_fdt() bind node main_rc
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'fixed-clock'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'fixed_clock': 'fixed-clock' matches 'fixed-clock'
common/malloc_simple.c:26- alloc_simple() size=50, ptr=b3c, limit=8000: 220049cc
common/malloc_simple.c:26- alloc_simple() size=28, ptr=b64, limit=8000: 22004a1c
drivers/core/lists.c:201- lists_bind_fdt() bind node slow_xtal
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'fixed-clock'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'fixed_clock': 'fixed-clock' matches 'fixed-clock'
common/malloc_simple.c:26- alloc_simple() size=50, ptr=bb4, limit=8000: 22004a44
common/malloc_simple.c:26- alloc_simple() size=28, ptr=bdc, limit=8000: 22004a94
drivers/core/lists.c:201- lists_bind_fdt() bind node main_xtal
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'fixed-clock'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'fixed_clock': 'fixed-clock' matches 'fixed-clock'
common/malloc_simple.c:26- alloc_simple() size=50, ptr=c2c, limit=8000: 22004abc
common/malloc_simple.c:26- alloc_simple() size=28, ptr=c54, limit=8000: 22004b0c
drivers/core/lists.c:201- lists_bind_fdt() bind node scmi0
drivers/core/lists.c:222- lists_bind_fdt() - attempt to match compatible string 'arm,scmi-smc'
drivers/core/lists.c:244- lists_bind_fdt() - found match at 'scmi-over-smccc': 'arm,scmi-smc' matches 'arm,scmi-smc'
common/malloc_simple.c:26- alloc_simple() size=18, ptr=c6c, limit=8000: 22004b34
common/malloc_simple.c:26- alloc_simple() size=50, ptr=cbc, limit=8000: 22004b4c
common/malloc_simple.c:26- alloc_simple() size=50, ptr=d0c, limit=8000: 22004b9c
common/malloc_simple.c:26- alloc_simple() size=8, ptr=d14, limit=8000: 22004bec
common/malloc_simple.c:26- alloc_simple() size=10, ptr=d24, limit=8000: 22004bf4
drivers/core/uclass.c:325-uclass_find_device_by_seq() 0
drivers/core/uclass.c:333-uclass_find_device_by_seq() - 0 'pinctrl@fc038000'
drivers/core/uclass.c:336-uclass_find_device_by_seq() - found
drivers/core/uclass.c:325-uclass_find_device_by_seq() 0
drivers/core/uclass.c:333-uclass_find_device_by_seq() - 0 'pinctrl@fc038000'
drivers/core/uclass.c:336-uclass_find_device_by_seq() - found
drivers/core/uclass.c:325-uclass_find_device_by_seq() 0
drivers/core/uclass.c:333-uclass_find_device_by_seq() - 0 'pinctrl@fc038000'
drivers/core/uclass.c:336-uclass_find_device_by_seq() - found
drivers/pinctrl/pinctrl-uclass.c:300-pinctrl_select_state_simple() pinctrl_atmel_pio4 pinctrl@fc038000: set_state_simple op missing
drivers/pinctrl/pinctrl-uclass.c:300-pinctrl_select_state_simple() simple_bus apb: set_state_simple op missing
drivers/pinctrl/pinctrl-uclass.c:300-pinctrl_select_state_simple() simple_bus ahb: set_state_simple op missing
drivers/pinctrl/pinctrl-uclass.c:88-pinctrl_select_state_full() serial_atmel serial@f8020000: pinctrl_select_state_full: uclass_get_device_by_phandle_id: err=-19
drivers/core/uclass.c:516-uclass_get_device_by_ofnode() Looking for scmi0_clock@14
drivers/core/uclass.c:376-uclass_find_device_by_ofnode() Looking for scmi0_clock@14
drivers/core/uclass.c:385-uclass_find_device_by_ofnode() - checking slow_rc_osc
drivers/core/uclass.c:385-uclass_find_device_by_ofnode() - checking main_rc
drivers/core/uclass.c:385-uclass_find_device_by_ofnode() - checking slow_xtal
drivers/core/uclass.c:385-uclass_find_device_by_ofnode() - checking main_xtal
drivers/core/uclass.c:385-uclass_find_device_by_ofnode() - checking scmi0_clock@14
drivers/core/uclass.c:395-uclass_find_device_by_ofnode() - result for scmi0_clock@14: scmi0_clock@14 (ret=0)
drivers/core/uclass.c:519-uclass_get_device_by_ofnode() - result for scmi0_clock@14: scmi0_clock@14 (ret=0)
common/malloc_simple.c:26- alloc_simple() size=c, ptr=d30, limit=8000: 22004c04
drivers/core/uclass.c:325-uclass_find_device_by_seq() 0
drivers/core/uclass.c:333-uclass_find_device_by_seq() - 0 'pinctrl@fc038000'
drivers/core/uclass.c:336-uclass_find_device_by_seq() - found
drivers/pinctrl/pinctrl-uclass.c:300-pinctrl_select_state_simple() scmi-over-smccc scmi0: set_state_simple op missing
drivers/core/uclass.c:325-uclass_find_device_by_seq() 0
drivers/core/uclass.c:333-uclass_find_device_by_seq() - 0 'pinctrl@fc038000'
drivers/core/uclass.c:336-uclass_find_device_by_seq() - found
Šæ€˜€æ€˜€f3æ†0þžþž?ÃÀÃÃ?À˜à˜ž<f̆žf?€óÌøfÀfÏfÏlect_state_simple() scmi_clk scmi0_clock@14: set_state_simple op missing x ðxÌx †‡0˜à†øÀ
à˜x
Àx
ðxÌx
À˜ž˜àÀóÌðóÃϘf

Thanks in advance,
Simone

@ryan-wanner
Copy link

Hello Simone,
After looking at the schematics for the shield96 I see that you have a 12MHz crystal oscillator. You need to go into the at91bootstrap menuconfig then inside the clock signals menu navigate to main crystal configuration then select crystal frequency and select 12MHz. Then make sure that the device tree in u-boot, sama5d27_som1.dtsi, the main_xtal frequency is set to 12MHz. This should match with your original dtsi file you had for linux that has the main xtal set at 12MHz.

See if this helps

Ryan

@SimoneBongini
Copy link
Author

SimoneBongini commented Sep 27, 2023

Hello Ryan, thanks a lot for the feedback.
Yes, shield96 have a 12MHz crystal oscillator. I have already set main_xtal to 12MHz. But the problem persists.
Find attached:

I'm using.
Find below the serial log I got: log.txt.txt

@ryan-wanner
Copy link

Hello Simone,
When I use your config files you gave me I do get the correct u-boot output. I think there is an issue with the UART initialization in either at91bootstrap or u-boot. I do recommend to visit this link HERE and make a free account. You will be able to get more timely responses and more focused help.

SDHC: fix in place for SAMA5D2 SoM VDDSDMMC over-consumption errata
SD/MMC: Image: Read file u-boot.bin to 0x23f00000
MMC: ADMA supported
SD: Card Capacity: High or Extended
SD: Specification Version 3.0X
SD/MMC: Done to load image

<debug_uart>

U-Boot 2023.01-dirty (Sep 29 2023 - 11:11:10 -0700)

CPU: SAMA5D27 1G bits DDR2 SDRAM
Crystal frequency: 12 MHz
CPU clock : 498 MHz
Master clock : 166 MHz

DRAM: 128 MiB
Core: 141 devices, 24 uclasses, devicetree: separate
MMC: sdio-host@a0000000: 0, sdio-host@b0000000: 1
Loading Environment from FAT... MMC: no card present
** Bad device specification mmc 1 **
In: serial@f8020000
Out: serial@f8020000
Err: serial@f8020000
Net: eth0: ethernet@f8008000
Hit any key to stop autoboot: 0
=>
=>
=> print
arch=arm
baudrate=115200
board=sama5d27_som1_ek
board_name=sama5d27_som1_ek
bootargs=console=ttyS0,115200 earlyprintk root=/dev/mmcblk1p2 rw rootwait
bootcmd=fatload mmc 1 0x22000000 at91-sama5d27_som1_ek.dtb; fatload mmc 1 0x23000000 zImage; bootz 0x23000000 - 0x22000000
bootdelay=3
cpu=armv7
ethaddr=54:10:ec:a4:49:81
fdtcontroladdr=27b63ea0
loadaddr=0x22000000
soc=at91
stderr=serial@f8020000
stdin=serial@f8020000
stdout=serial@f8020000
vendor=atmel

Environment size: 456/4092 bytes
=>

Best,
Ryan

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants