<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>S32G中的主题 in Linux flashing sja1110 failed</title>
    <link>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2019993#M12151</link>
    <description>&lt;P&gt;on board S32G-VNP-RDB2 with bsp41.0&lt;/P&gt;&lt;P&gt;accoring to the doc: S32G-VNP-RDB2 Ethernet Enablement Guide&lt;/P&gt;&lt;P&gt;In Linux flashing the sja1110 firmware:&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;rmmod sja1110&lt;BR /&gt;modprobe sja1110&lt;BR /&gt;echo flash_image_2G5.bin &amp;gt; /sys/devices/platform/soc/402d0000.spi/spi_master/spi5/spi5.0/uc-configuration/uc_fw_upload&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;it failed.&lt;/P&gt;&lt;P&gt;dmesg information run the above 3 commands:&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;[Apr28 23:30] sja1110 spi5.1: [sja1110_remove]&lt;BR /&gt;[ +0.000439] sja1110 spi5.0: [sja1110_remove]&lt;BR /&gt;[ +21.808442] SPI driver sja1110 has no spi_device_id for nxp,sja1110-switch&lt;BR /&gt;[ +0.000022] SPI driver sja1110 has no spi_device_id for nxp,sja1110-uc&lt;BR /&gt;[ +0.000109] sja1110 spi5.0: probing uc&lt;BR /&gt;[ +0.000173] sja1110 spi5.1: probing switch&lt;BR /&gt;[ +0.000347] sja1110 spi5.1: Could not get GPIO from device tree&lt;BR /&gt;[ +0.000031] sja1110 spi5.1: [sja1110_post_probe_upload_worker] Trying to initialize switch&lt;BR /&gt;[ +0.000103] sja1110 spi5.1: Direct firmware load for sja1110_switch.bin failed with error -2&lt;BR /&gt;[ +0.000011] sja1110 spi5.1: request_firmware failed with -2&lt;BR /&gt;[ +0.000007] sja1110 spi5.0: [sja1110_post_probe_upload_worker] Trying to initialize uC&lt;BR /&gt;[ +0.000033] sja1110 spi5.0: Direct firmware load for sja1110_uc.bin failed with error -2&lt;BR /&gt;[ +0.000008] sja1110 spi5.0: request_firmware failed with -2&lt;BR /&gt;[Apr28 23:31] sja1110 spi5.0: [sysfs_set_cfg_upload] received command to upload binary 'flash_image_2G5.bin' to uc&lt;BR /&gt;[ +0.000156] sja1110 spi5.0: Direct firmware load for flash_image_2G5.bin failed with error -2&lt;BR /&gt;[ +0.000018] sja1110 spi5.0: request_firmware failed with -2&lt;BR /&gt;[ +0.000006] sja1110 spi5.0: Could not initialize hw (type=1)&lt;/P&gt;&lt;/BLOCKQUOTE&gt;</description>
    <pubDate>Fri, 27 Dec 2024 09:05:11 GMT</pubDate>
    <dc:creator>liujialu_2024</dc:creator>
    <dc:date>2024-12-27T09:05:11Z</dc:date>
    <item>
      <title>in Linux flashing sja1110 failed</title>
      <link>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2019993#M12151</link>
      <description>&lt;P&gt;on board S32G-VNP-RDB2 with bsp41.0&lt;/P&gt;&lt;P&gt;accoring to the doc: S32G-VNP-RDB2 Ethernet Enablement Guide&lt;/P&gt;&lt;P&gt;In Linux flashing the sja1110 firmware:&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;rmmod sja1110&lt;BR /&gt;modprobe sja1110&lt;BR /&gt;echo flash_image_2G5.bin &amp;gt; /sys/devices/platform/soc/402d0000.spi/spi_master/spi5/spi5.0/uc-configuration/uc_fw_upload&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;it failed.&lt;/P&gt;&lt;P&gt;dmesg information run the above 3 commands:&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;[Apr28 23:30] sja1110 spi5.1: [sja1110_remove]&lt;BR /&gt;[ +0.000439] sja1110 spi5.0: [sja1110_remove]&lt;BR /&gt;[ +21.808442] SPI driver sja1110 has no spi_device_id for nxp,sja1110-switch&lt;BR /&gt;[ +0.000022] SPI driver sja1110 has no spi_device_id for nxp,sja1110-uc&lt;BR /&gt;[ +0.000109] sja1110 spi5.0: probing uc&lt;BR /&gt;[ +0.000173] sja1110 spi5.1: probing switch&lt;BR /&gt;[ +0.000347] sja1110 spi5.1: Could not get GPIO from device tree&lt;BR /&gt;[ +0.000031] sja1110 spi5.1: [sja1110_post_probe_upload_worker] Trying to initialize switch&lt;BR /&gt;[ +0.000103] sja1110 spi5.1: Direct firmware load for sja1110_switch.bin failed with error -2&lt;BR /&gt;[ +0.000011] sja1110 spi5.1: request_firmware failed with -2&lt;BR /&gt;[ +0.000007] sja1110 spi5.0: [sja1110_post_probe_upload_worker] Trying to initialize uC&lt;BR /&gt;[ +0.000033] sja1110 spi5.0: Direct firmware load for sja1110_uc.bin failed with error -2&lt;BR /&gt;[ +0.000008] sja1110 spi5.0: request_firmware failed with -2&lt;BR /&gt;[Apr28 23:31] sja1110 spi5.0: [sysfs_set_cfg_upload] received command to upload binary 'flash_image_2G5.bin' to uc&lt;BR /&gt;[ +0.000156] sja1110 spi5.0: Direct firmware load for flash_image_2G5.bin failed with error -2&lt;BR /&gt;[ +0.000018] sja1110 spi5.0: request_firmware failed with -2&lt;BR /&gt;[ +0.000006] sja1110 spi5.0: Could not initialize hw (type=1)&lt;/P&gt;&lt;/BLOCKQUOTE&gt;</description>
      <pubDate>Fri, 27 Dec 2024 09:05:11 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2019993#M12151</guid>
      <dc:creator>liujialu_2024</dc:creator>
      <dc:date>2024-12-27T09:05:11Z</dc:date>
    </item>
    <item>
      <title>Re: in Linux flashing sja1110 failed</title>
      <link>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2020106#M12164</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/75590"&gt;@liujialu_2024&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;Althought it is not mentioned in the Ethernet enablement guide, you need to configure the following u-boot variable to be able to probe the SJA1110 device. This is mentioned in the BSP41 user manual page 64:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="alejandro_e_1-1735324092580.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/317511i8458E7924607136F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="alejandro_e_1-1735324092580.png" alt="alejandro_e_1-1735324092580.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I was able to correctly probe the device after this configuration:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;root@s32g274ardb2:~# dmesg | grep -i "sja"
[    0.547163] gpio-24 (sja1110-rst-phy-t1): hogged as output/low
[    0.552584] gpio-81 (sja1110-rst-core): hogged as output/low
[    0.761346] sja1105 spi5.1: Probed switch chip: SJA1110A
[    4.441672] sja1105 spi5.1: Probed switch chip: SJA1110A
[    4.487130] sja1105 spi5.1: Probed switch chip: SJA1110A
[    4.487503] sja1105 spi5.1: Probed switch chip: SJA1110A
[    6.430754] sja1110: loading out-of-tree module taints kernel.
[    6.431356] SPI driver sja1110 has no spi_device_id for nxp,sja1110-switch
[    6.431363] SPI driver sja1110 has no spi_device_id for nxp,sja1110-uc
[    7.797913] sja1105 spi5.1: Probed switch chip: SJA1110A
[    7.809068] sja1105 spi5.1: Probed switch chip: SJA1110A
[    8.112979] sja1105 spi5.1 p1 (uninitialized): PHY [spi5.1-base-tx:01] driver [NXP CBTX (SJA1110)] (irq=POLL)
[    8.149055] sja1105 spi5.1: configuring for fixed/2500base-x link mode
[    8.152055] sja1105 spi5.1: Link is Up - 2.5Gbps/Full - flow control off
[    8.158514] sja1105 spi5.1 trx5 (uninitialized): PHY [spi5.1-base-t1:01] driver [NXP C45 TJA1103] (irq=POLL)
[    8.185793] sja1105 spi5.1 trx6 (uninitialized): PHY [spi5.1-base-t1:02] driver [NXP C45 TJA1103] (irq=POLL)
[    8.215230] sja1105 spi5.1 trx7 (uninitialized): PHY [spi5.1-base-t1:03] driver [NXP C45 TJA1103] (irq=POLL)
[    8.250855] sja1105 spi5.1 trx8 (uninitialized): PHY [spi5.1-base-t1:04] driver [NXP C45 TJA1103] (irq=POLL)
[    8.268145] sja1105 spi5.1 trx9 (uninitialized): PHY [spi5.1-base-t1:05] driver [NXP C45 TJA1103] (irq=POLL)
[    8.297809] sja1105 spi5.1 trx10 (uninitialized): PHY [spi5.1-base-t1:06] driver [NXP C45 TJA1103] (irq=POLL)
root@s32g274ardb2:~#
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please note that you should run the following two commands in u-boot:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;=&amp;gt; setenv sja1110_dsa yes
=&amp;gt; saveenv
Saving Environment to MMC... Writing to MMC(0)... OK
=&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;After configuring and saving, please reboot de board so the changes may take effect.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Let me know if this steps solved your problem.&lt;/P&gt;</description>
      <pubDate>Fri, 27 Dec 2024 18:31:40 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2020106#M12164</guid>
      <dc:creator>alejandro_e</dc:creator>
      <dc:date>2024-12-27T18:31:40Z</dc:date>
    </item>
    <item>
      <title>Re: in Linux flashing sja1110 failed</title>
      <link>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2021673#M12203</link>
      <description>&lt;P&gt;after set u-boot:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;setenv sja1110_dsa yes&lt;/LI-CODE&gt;&lt;P&gt;reboot, and in linux file system, the below file lost.&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;/sys/devices/platform/soc/402d0000.spi/spi_master/spi5/spi5.0/uc-configuration/uc_fw_upload&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;and disable the sja1110_dsa in u-boot.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;setenv sja1110_dsa&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;the uc_fw_upload file in linux file system appeared.&lt;/P&gt;</description>
      <pubDate>Fri, 03 Jan 2025 06:44:01 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2021673#M12203</guid>
      <dc:creator>liujialu_2024</dc:creator>
      <dc:date>2025-01-03T06:44:01Z</dc:date>
    </item>
    <item>
      <title>Re: in Linux flashing sja1110 failed</title>
      <link>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2022000#M12214</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/75590"&gt;@liujialu_2024&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;You are correct, the file/device is no longer present with that configuration. The method I described automatically loads the firmware at Linux boot time, you will only need to put your FW in the following path and with the following name:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;/lib/firmware/sja1110_uc.bin&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And define de environment variable I mentioned before.&lt;/P&gt;
&lt;P&gt;Once you do that you can see the following messages in the system log:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;root@s32g274ardb2:~# dmesg | grep -i "sja"
[    0.546665] gpio-24 (sja1110-rst-phy-t1): hogged as output/low
[    0.552087] gpio-81 (sja1110-rst-core): hogged as output/low
[    0.617716] sja1110-sw@1 enforce active low on chipselect handle
[    6.340111] sja1110: loading out-of-tree module taints kernel.
[    6.340758] SPI driver sja1110 has no spi_device_id for nxp,sja1110-switch
[    6.340766] SPI driver sja1110 has no spi_device_id for nxp,sja1110-uc
[    6.340881] sja1110 spi5.0: probing uc
[    6.341089] sja1110 spi5.1: probing switch
[    6.341490] sja1110 spi5.1: Could not get GPIO from device tree
[    6.341521] sja1110 spi5.1: [sja1110_post_probe_upload_worker] Trying to initialize switch
[    6.343934] sja1110 spi5.1: Direct firmware load for sja1110_switch.bin failed with error -2
[    6.343970] sja1110 spi5.1: request_firmware failed with -2
[    6.343979] sja1110 spi5.0: [sja1110_post_probe_upload_worker] Trying to initialize uC
[    6.354041] sja1110 spi5.0: [sja1110_init_hw] loaded fw 'sja1110_uc.bin'
[    6.354061] sja1110 spi5.0: [sja1110_pre_uc_upload] Found firmware of size 129912
[    6.354155] sja1110 spi5.0: [sja1110_pre_uc_upload] firmware appears to be valid
[    6.354201] sja1110 spi5.0: [sja1110_pre_uc_upload] \xc2\xb5C not ready for download (Status=0x31)
[    6.354324] sja1110 spi5.0: Uploading firmware...
[    6.781008] sja1110 spi5.0: Upload successfully verified!&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;as you can see Linux will automatically find the binary file and load it.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Let me know if this method works for you.&lt;/P&gt;</description>
      <pubDate>Fri, 03 Jan 2025 21:01:28 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2022000#M12214</guid>
      <dc:creator>alejandro_e</dc:creator>
      <dc:date>2025-01-03T21:01:28Z</dc:date>
    </item>
    <item>
      <title>Re: in Linux flashing sja1110 failed</title>
      <link>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2022157#M12220</link>
      <description>&lt;P&gt;thanks for reply. it works as you mentioned.&lt;/P&gt;&lt;P&gt;but my original question is:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;on board S32G-VNP-RDB2 with bsp41.0&lt;/P&gt;&lt;P&gt;accoring to the doc: S32G-VNP-RDB2 Ethernet Enablement Guide&lt;/P&gt;&lt;P&gt;In Linux flashing the sja1110 firmware:&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;rmmod sja1110&lt;BR /&gt;modprobe sja1110&lt;BR /&gt;echo flash_image_2G5.bin &amp;gt; /sys/devices/platform/soc/402d0000.spi/spi_master/spi5/spi5.0/uc-configuration/uc_fw_upload&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;it failed.&lt;/P&gt;&lt;P&gt;then how can i update the firmware in qspi flash attached with SJA1110, in Linux user space?&lt;/P&gt;</description>
      <pubDate>Mon, 06 Jan 2025 00:50:57 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2022157#M12220</guid>
      <dc:creator>liujialu_2024</dc:creator>
      <dc:date>2025-01-06T00:50:57Z</dc:date>
    </item>
    <item>
      <title>Re: in Linux flashing sja1110 failed</title>
      <link>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2022776#M12238</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/75590"&gt;@liujialu_2024&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;I was able to load the FW into the SJA1110 with BSP41, I just located my terminal in the directory where the firmware is and executed the following:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;root@s32g274ardb2:~# rmmod sja1110
root@s32g274ardb2:~# modprobe sja1110
root@s32g274ardb2:~# echo flash_image_1G.bin &amp;gt; /sys/devices/platform/soc/402d0000.spi/spi_master/spi5/spi5.0/uc-configuration/uc_fw_upload
root@s32g274ardb2:~# dmesg | grep -i "sja"
[    0.546645] gpio-24 (sja1110-rst-phy-t1): hogged as output/low
[    0.552070] gpio-81 (sja1110-rst-core): hogged as output/low
[    0.617667] sja1110-sw@1 enforce active low on chipselect handle
[    6.453853] sja1110: loading out-of-tree module taints kernel.
[    6.462097] SPI driver sja1110 has no spi_device_id for nxp,sja1110-switch
[    6.462120] SPI driver sja1110 has no spi_device_id for nxp,sja1110-uc
[    6.462231] sja1110 spi5.0: probing uc
[    6.462392] sja1110 spi5.1: probing switch
[    6.462739] sja1110 spi5.1: Could not get GPIO from device tree
[    6.462766] sja1110 spi5.1: [sja1110_post_probe_upload_worker] Trying to initialize switch
[    6.466091] sja1110 spi5.1: Direct firmware load for sja1110_switch.bin failed with error -2
[    6.466121] sja1110 spi5.1: request_firmware failed with -2
[    6.466130] sja1110 spi5.0: [sja1110_post_probe_upload_worker] Trying to initialize uC
[    6.466172] sja1110 spi5.0: Direct firmware load for sja1110_uc.bin failed with error -2
[    6.466180] sja1110 spi5.0: request_firmware failed with -2
[   49.460579] sja1110 spi5.1: [sja1110_remove]
[   49.461042] sja1110 spi5.0: [sja1110_remove]
[   54.337266] SPI driver sja1110 has no spi_device_id for nxp,sja1110-switch
[   54.337290] SPI driver sja1110 has no spi_device_id for nxp,sja1110-uc
[   54.337403] sja1110 spi5.0: probing uc
[   54.337571] sja1110 spi5.1: probing switch
[   54.337935] sja1110 spi5.1: Could not get GPIO from device tree
[   54.337970] sja1110 spi5.1: [sja1110_post_probe_upload_worker] Trying to initialize switch
[   54.338057] sja1110 spi5.1: Direct firmware load for sja1110_switch.bin failed with error -2
[   54.338069] sja1110 spi5.1: request_firmware failed with -2
[   54.338076] sja1110 spi5.0: [sja1110_post_probe_upload_worker] Trying to initialize uC
[   54.338110] sja1110 spi5.0: Direct firmware load for sja1110_uc.bin failed with error -2
[   54.338118] sja1110 spi5.0: request_firmware failed with -2
[   67.488628] sja1110 spi5.0: [sysfs_set_cfg_upload] received command to upload binary 'flash_image_1G.bin' to uc
[   67.488970] sja1110 spi5.0: [sja1110_init_hw] loaded fw 'flash_image_1G.bin'
[   67.488983] sja1110 spi5.0: [sja1110_pre_uc_upload] Found firmware of size 129912
[   67.489090] sja1110 spi5.0: [sja1110_pre_uc_upload] firmware appears to be valid
[   67.489138] sja1110 spi5.0: [sja1110_pre_uc_upload] \xc2\xb5C not ready for download (Status=0x31)
[   67.489256] sja1110 spi5.0: Uploading firmware...
[   67.803842] sja1110 spi5.0: Upload successfully verified!
root@s32g274ardb2:~#
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As you can see, the last messages related to the SJA1110 is that the upload was verified successfully. Please note that before loading the FW into the SJA1110, the green led close to it (D33) hast to be OFF, after loading the FW it has to turn ON. And as you mentioned the u-boot environment variable&amp;nbsp;&lt;STRONG&gt;sja1110_dsa&lt;/STRONG&gt; has to be undefined or with no value. if you are not able to load the FW please share the error you see or the system log, executing this command:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;dmesg | grep -i "sja"&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Let me know the result of the test.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Jan 2025 20:26:20 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32G/in-Linux-flashing-sja1110-failed/m-p/2022776#M12238</guid>
      <dc:creator>alejandro_e</dc:creator>
      <dc:date>2025-01-06T20:26:20Z</dc:date>
    </item>
  </channel>
</rss>

