Hello,
we would like to upload a basic configuration to the switch during u-boot (when the kernel is loaded, the DSA driver will kick-in).
On the online resources I found some python scripts that generates a .hex file, that can be provided to another python script (sja1105_converter.py): this final script will generate a C source code with some binary data to be pushed to the switch through SPI.
The only problem is that the generated source code is referencing some libraries from NXP:
#include "NXP_SJA1105P_config.h"
#include "NXP_SJA1105P_spi.h"
and it is eventually using this function:
SJA1105P_gpf_spiWrite32()
Where can I find those libraries?
If they are not available to download, can I simply push all the generated configBurst0_X (that are uint32_t arrays of 64 entries each) through SPI?
Many thanks,
Marco
Solved! Go to Solution.
Hi Marco,
I urged it several times and I urged it now again. Honestly, I also do not understand why it takes so much time. I hope I will hear from the team soon.
Regards,
Lukas
Hi Marco,
these files can be found in package "sw425010 - Device Drivers (1.0)" in Secure Files.
https://www.nxp.com/docs/en/user-guide/nxp-secure-access-rights-registration.pdf
Notice that the code is platform independent, so it's up to user to add SPI read/write functions depending on used platform.
If static configuration of SJA1105 is sufficient, you just need to load the generated hex file to the switch via SPI. If anything more is needed, please follow user manual which can be found in the mentioned package.
Regards,
Lukas
Hi Lukas,
thanks for the reply.
It seems that I am unable to find "sw425010 - Device Drivers (1.0)" and request access to it.
Anyway, my goal is to configure the switch through SPI during u-boot, allowing it to behave as a standard L2 unmanaged switch (L2 forwarding on all ports).
My approach will be to create a static configuration with the help of the python scripts, then generate the HEX file and push its content to the switch through SPI.
Do you think this is feasible?
Best Regards,
Marco
Hi Marco,
I'm sorry for delayed response. It looks like there are some issues on SJA1105 summary page. I have already reported it and I'm waiting for resolution. I will let you know the result later. Thanks for patience.
Regards,
Lukas
Hi Marco,
I urged it several times and I urged it now again. Honestly, I also do not understand why it takes so much time. I hope I will hear from the team soon.
Regards,
Lukas
I was finally able to program a static config and let the switch behave as a L2 unmanaged switch.
I had to read the kernel driver implementation to understand how to correctly pack the information.
One remark: pushing a static config is not enough to have packet forwarding working. You also need to correctly configure CGU, as described in AH1704 document.
Best Regards,
Marco