AM6442: DTS config to load ICSS prusw firmware

Part Number: AM6442


Hi

I've successfully changed the ICSSG0-pru firmware from  *-prueth-fw.elf to  *-prusw-fw.elf using the devlink to activate theswitch-mode.

However, I’d now like to make this change permanent via .dts file. To do so, I tried updating the .dts file to reference the new firmware files, but it didn’t work.

Below are the relevant lines from my .dts file:

icssg0_eth: icssg0-eth {
		compatible = "ti,am642-icssg-prueth";
		pinctrl-names = "default";
		pinctrl-0 = <&icssg0_rgmii1_pins_default &icssg0_rgmii2_pins_default>;

		sram = <&oc_sram>;
		ti,prus = <&pru0_0>, <&rtu0_0>, <&tx_pru0_0>, <&pru0_1>, <&rtu0_1>, <&tx_pru0_1>;
		firmware-name = "ti-pruss/am65x-sr2-pru0-prusw-fw.elf",
				"ti-pruss/am65x-sr2-rtu0-prusw-fw.elf",
				"ti-pruss/am65x-sr2-txpru0-prusw-fw.elf",
				"ti-pruss/am65x-sr2-pru1-prusw-fw.elf",
				"ti-pruss/am65x-sr2-rtu1-prusw-fw.elf",
				"ti-pruss/am65x-sr2-txpru1-prusw-fw.elf";

		ti,pruss-gp-mux-sel = <2>,	/* MII mode */
				      <2>,
				      <2>,
				      <2>,	/* MII mode */
				      <2>,
				      <2>;

		ti,mii-g-rt = <&icssg0_mii_g_rt>;
		ti,mii-rt = <&icssg0_mii_rt>;
		ti,pa-stats = <&icssg0_pa_stats>;
		iep = <&icssg0_iep0>, <&icssg0_iep1>;

		interrupt-parent = <&icssg0_intc>;
		interrupts = <24 0 2>, <25 1 3>;
		interrupt-names = "tx_ts0", "tx_ts1";

		dmas = <&main_pktdma 0xc100 0>, /* egress slice 0 */
		       <&main_pktdma 0xc101 0>, /* egress slice 0 */
		       <&main_pktdma 0xc102 0>, /* egress slice 0 */
		       <&main_pktdma 0xc103 0>, /* egress slice 0 */
		       <&main_pktdma 0xc104 0>, /* egress slice 1 */
		       <&main_pktdma 0xc105 0>, /* egress slice 1 */
		       <&main_pktdma 0xc106 0>, /* egress slice 1 */
		       <&main_pktdma 0xc107 0>, /* egress slice 1 */
		       <&main_pktdma 0x4100 0>, /* ingress slice 0 */
		       <&main_pktdma 0x4101 0>, /* ingress slice 1 */
		       <&main_pktdma 0x4102 0>, /* mgmnt rsp slice 0 */
		       <&main_pktdma 0x4103 0>; /* mgmnt rsp slice 1 */
		dma-names = "tx0-0", "tx0-1", "tx0-2", "tx0-3",
			    "tx1-0", "tx1-1", "tx1-2", "tx1-3",
			    "rx0", "rx1";

		ethernet-ports {
			#address-cells = <1>;
			#size-cells = <0>;
			icssg0_emac0: port@0 {
				reg = <0>;
				phy-handle = <&icssg0_phy1>;
				phy-mode = "rgmii-id";
				syscon-rgmii-delay = <&main_conf 0x4100>;
				/* Filled in by bootloader */
				local-mac-address = [00 00 00 00 00 00];
			};

			icssg0_emac1: port@1 {
				reg = <1>;
				phy-handle = <&icssg0_phy2>;
				phy-mode = "rgmii-id";
				syscon-rgmii-delay = <&main_conf 0x4104>;
				/* Filled in by bootloader */
				local-mac-address = [00 00 00 00 00 00];
			};
		};
	};

I suspect I may also need to explicitly enable the switch-mode in the device tree, but after reviewing other .dts files, I haven’t been able to find the correct way to do this.

Is there a standard method to configure and load the *-prusw-fw.elf firmware for ICSSG0-PRU directly through the device tree?

Thanks in advance for your help!

Best regards,
LeoUL