S32G2 - SJA1110 firware enable

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

S32G2 - SJA1110 firware enable

Jump to solution
778 Views
irfank
Contributor III

Hello,

 

We have our own board which has s32g processor. We are useing  bsp37. S32CC_HWCOnfig is ". pfe version :1.7

"pcie1:mode=sgmii,clock=int,fmhz=100,xpcs_mode=both"

 

There is a pfe interface but I can not ping my pc. 

irfank_0-1699247159292.png

 

irfank_1-1699247187745.png

---------------------------------

 

i do not understand exactly what are these binaries?

  1. ‘flash_image.bin’  (which is generated depends on S32G-VNP-RDB2 Ethernet Enablement Guide via SJA1110 SDK)
  2. sja1110_uc.bin and sja1110_switch.bin which is mentioned under bsp user manual?

Is flash_image.bin same as sja1110_uc.bin? Can you give more information of purpose of these binaries?

--------------------------

i got below error and i think reason is boot option selection. My board boot option selection is 1 - 1 (Serial boot). Is there any yocto recipes or application note for default serial boot?

 


[ 0.538271] gpio-345 (sja1110-rst-phy-t1): hogged as output/low
[ 0.543783] gpio-402 (sja1110-rst-core): hogged as output/low
[ 2.591837] SPI driver sja1110 has no spi_device_id for nxp,sja1110-switch
[ 2.591854] SPI driver sja1110 has no spi_device_id for nxp,sja1110-uc
[ 2.591958] sja1110 spi2.0: probing switch
[ 2.592460] sja1110 spi2.0: [sja1110_post_probe_upload_worker] Trying to initialize switch
[ 2.592980] sja1110 spi2.0: [sja1110_init_hw] loaded fw 'sja1110_switch.bin'
[ 2.593023] sja1110 spi2.1: probing uc
[ 2.593078] sja1110 spi2.0: Device id 0x0 is not supported!
[ 2.593083] sja1110 spi2.0: checking firmware failed with -22
[ 2.593098] sja1110 spi2.1: [sja1110_post_probe_upload_worker] Trying to initialize uC
[ 2.595460] sja1110 spi2.1: [sja1110_init_hw] loaded fw 'sja1110_uc.bin'
[ 2.595479] sja1110 spi2.1: [sja1110_pre_uc_upload] Found firmware of size 320280
[ 2.595577] sja1110 spi2.0: [sja1110_write_reg] Register 1860637, Resp0:83886080
[ 2.595587] sja1110 spi2.1: [sja1110_pre_uc_upload] firmware appears to be valid
[ 2.595629] sja1110 spi2.1: [sja1110_uc_parse_status] Invalid status header (0xff)
[ 2.595637] sja1110 spi2.1: [sja1110_uc_read_status] Parsing uC status failed with -22
[ 2.595643] sja1110 spi2.1: [sja1110_pre_uc_upload] Could not read \xc2\xb5C status
[ 2.595682] sja1110 spi2.1: [sja1110_uc_parse_status] Invalid status header (0xff)
[ 2.595689] sja1110 spi2.1: [sja1110_uc_read_status] Parsing uC status failed with -22
[ 2.595695] sja1110 spi2.1: [sja1110_pre_uc_upload] Could not read \xc2\xb5C status
[ 2.595747] sja1110 spi2.1: [sja1110_uc_parse_status] Invalid status header (0xff)
[ 2.595754] sja1110 spi2.1: [sja1110_uc_read_status] Parsing uC status failed with -22
[ 2.595760] sja1110 spi2.1: [sja1110_pre_uc_upload] Could not read \xc2\xb5C status
[ 2.595830] sja1110 spi2.1: [sja1110_uc_parse_status] Invalid status header (0xff)
[ 2.595837] sja1110 spi2.1: [sja1110_uc_read_status] Parsing uC status failed with -22
[ 2.595843] sja1110 spi2.1: [sja1110_pre_uc_upload] Could not read \xc2\xb5C status
[ 2.595888] sja1110 spi2.1: [sja1110_uc_parse_status] Invalid status header (0xff)
[ 2.595895] sja1110 spi2.1: [sja1110_uc_read_status] Parsing uC status failed with -22
[ 2.595901] sja1110 spi2.1: [sja1110_pre_uc_upload] Could not read \xc2\xb5C status
[ 2.595945] sja1110 spi2.1: [sja1110_uc_parse_status] Invalid status header (0xff)
[ 2.595952] sja1110 spi2.1: [sja1110_uc_read_status] Parsing uC status failed with -22
[ 2.595958] sja1110 spi2.1: [sja1110_pre_uc_upload] Could not read \xc2\xb5C status
[ 2.596001] sja1110 spi2.1: [sja1110_uc_parse_status] Invalid status header (0xff)
[ 2.596008] sja1110 spi2.1: [sja1110_uc_read_status] Parsing uC status failed with -22
[ 2.596014] sja1110 spi2.1: [sja1110_pre_uc_upload] Could not read \xc2\xb5C status
[ 2.596053] sja1110 spi2.1: [sja1110_uc_parse_status] Invalid status header (0xff)
[ 2.596059] sja1110 spi2.1: [sja1110_uc_read_status] Parsing uC status failed with -22
[ 2.596066] sja1110 spi2.1: [sja1110_pre_uc_upload] Could not read \xc2\xb5C status
[ 2.596103] sja1110 spi2.1: [sja1110_uc_parse_status] Invalid status header (0xff)
[ 2.596109] sja1110 spi2.1: [sja1110_uc_read_status] Parsing uC status failed with -22
[ 2.596115] sja1110 spi2.1: [sja1110_pre_uc_upload] Could not read \xc2\xb5C status
[ 2.596152] sja1110 spi2.1: [sja1110_uc_parse_status] Invalid status header (0xff)
[ 2.596159] sja1110 spi2.1: [sja1110_uc_read_status] Parsing uC status failed with -22
[ 2.596165] sja1110 spi2.1: [sja1110_pre_uc_upload] Could not read \xc2\xb5C status
[ 2.596170] sja1110 spi2.1: checking firmware failed with -22

 

Tags (1)
0 Kudos
1 Solution
687 Views
Daniel-Aguirre
NXP TechSupport
NXP TechSupport

Hi,

Thanks for your feedback. Seems odd, since we are able to load the SJA1110-FW no problem from our side, as shown below:

DanielAguirre_0-1700070040273.png

What we are seeing is that from our side we are using SPI5 interface, while your log shows SPI2. When we were referring to SW12, we were referring to the NXP development board RDB2 which controls the SJA boot scheme. Can you confirm if you are using any NXP development board? Or is this a custom board?

We can replicate the outcome you are seeing, but only if we do not set the SJA for serial boot mode:

DanielAguirre_1-1700070306835.png

This is caused due to the SJA not being configured to expect the kernel to send it FW. This outcome is expected if the SJA is not configured for serial boot mode.

As for why the SJA1110 cannot be configured a second time, is due to the same scenario as before, it is not in a state which is expecting FW to be sent. First, the SJA should be in Serial Boot Mode, second you should reset it for the SJA to be sent back to be expecting FW loading. A more in-depth explanation is provided under the following thread:

modprobe sja1110 fail - NXP Community

Please, let us know.

View solution in original post

7 Replies
656 Views
irfank
Contributor III

 Hello;

Thanks for you support.

we have custom board

Pmic configuration can cause that problem? Below logs are same flash image but different atf code. In atf i tried to configure some registers in different ways. 

irfank_0-1700211182413.png

irfank_1-1700211302604.png

 

0 Kudos
648 Views
Daniel-Aguirre
NXP TechSupport
NXP TechSupport

Hi,

Thanks for your feedback.

Since this is a custom board, we are not able to reproduce your outcome, we do apologize. Since you are also modifying the ATF code, could be one of the problems.

Again, since we cannot reproduce your outcome, help us either contacting your local NXP FAE/DFAE or submitting an online ticket under the NXP online support. We do apologize.

Please, let us know.

0 Kudos
765 Views
Daniel-Aguirre
NXP TechSupport
NXP TechSupport

Hi,

Below will be some comments on regards of your questions:

Q1 >> Is flash_image.bin same as sja1110_uc.bin? Can you give more information of purpose of these binaries?

A1 >> As for the flash_image.bin, it is the same as the "sja1110_uc.bin", since it will be the image that provides the firmware to the SJA1110. sja1110_switch.bin is the configuration file for the switch.

 

Q2 >> i got below error and i think reason is boot option selection. My board boot option selection is 1 - 1 (Serial boot). Is there any yocto recipes or application note for default serial boot?

A2 >> What do you mean by "application note for default serial boot"? If you have the binaries available under the SD card boot partition, you set the switch as you are saying:

DanielAguirre_0-1699295643047.png

Aside from this, you should also have the SJA feature added to your build, so that you see the following binaries available under /lib/firmware of your image:

DanielAguirre_1-1699295772745.png

With that, we see the following on our boot log:

DanielAguirre_2-1699295863691.pngDanielAguirre_3-1699295875986.png

Please, let us know.

0 Kudos
736 Views
irfank
Contributor III

Thanks for your support.

I have some misunderstandings now it is clear.

I download sja1110_switch.bin and sja1110_uc.bin under goldvip. Why do I get the below errors related to sja1110_switch.bin and sja1110_uc.bin?

irfank_0-1699964042327.png

-------------------------------

Also When i followed  S32G-VNP-RDB2 Ethernet Enablement Guide. I get below errors

irfank_0-1699975855454.png

 

Regards,

irfan

0 Kudos
716 Views
Daniel-Aguirre
NXP TechSupport
NXP TechSupport

Hi,

Thanks for your feedback.

Can you confirm the switch setting for SW12 under your first scenario? The log shows that kernel was not able to communicate with the SJA1110, for which we assume that the SJA was not waiting for information from the kernel.

As for the second, it may be related to the file names, since the Ethernet Enablement Guide uses an old BSP. You should use the sja1110_switch.bin and sja1110_uc.bin for the commands. More information can be seen under the following threads:

modprobe sja1110 fail - NXP Community

Solved: Re: S32G SJA1110 enable - NXP Community

Please, let us know.

0 Kudos
693 Views
irfank
Contributor III

Hello,

I confirm that SW12 is 1-1. 

The log of boot up:

irfank_0-1700060676070.png

 

 as you have seen switch configuration was ok but uc_bin did not probe. What does that mean? Was the kernel  able to communicate with the SJA1110?

----------------------------------------------------------------------------------

Also, i can not configure second time after bootup. 

After booted up, i tried to configure. The log was below:

irfank_1-1700060676271.png

 

 

I cant access board, it is remote. After booted up, I tried to reset sja1110 before modprobe  through software by RST_N(P4) and RST_CORE_N(G4). it did not worked.

Case : Reset sja1110 before modprobe

irfank_2-1700060676863.png

 

Also, Just for info : When i set one of them(RST_N or RST_CORE_N to 1) before modprobe:

irfank_3-1700060676562.png

 

irfank_4-1700060676180.png

 

 

Do you have any suggestion?

0 Kudos
688 Views
Daniel-Aguirre
NXP TechSupport
NXP TechSupport

Hi,

Thanks for your feedback. Seems odd, since we are able to load the SJA1110-FW no problem from our side, as shown below:

DanielAguirre_0-1700070040273.png

What we are seeing is that from our side we are using SPI5 interface, while your log shows SPI2. When we were referring to SW12, we were referring to the NXP development board RDB2 which controls the SJA boot scheme. Can you confirm if you are using any NXP development board? Or is this a custom board?

We can replicate the outcome you are seeing, but only if we do not set the SJA for serial boot mode:

DanielAguirre_1-1700070306835.png

This is caused due to the SJA not being configured to expect the kernel to send it FW. This outcome is expected if the SJA is not configured for serial boot mode.

As for why the SJA1110 cannot be configured a second time, is due to the same scenario as before, it is not in a state which is expecting FW to be sent. First, the SJA should be in Serial Boot Mode, second you should reset it for the SJA to be sent back to be expecting FW loading. A more in-depth explanation is provided under the following thread:

modprobe sja1110 fail - NXP Community

Please, let us know.