spi for ls1028

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

spi for ls1028

657 Views
Alik_Y1
Contributor II

Hello

I am prototyping on ls1028ardb , and we have altera based fpga firmware loading

connected via  spi3 signals (without read/MISO ).

I want to write  firmware file in uboot .

I have added to fsl-ls1028a-rdb.dts in uboot :

&dspi2 {
status = "okay";
+ fpga: fpga@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "fsl,vf610-dspi";
+ reg = <0>; /* Chip select 0 */
+ spi-max-frequency = <20000000>;/* 20Mhz */
+
+ };
+
};

And i enabled SPI3 in RCW.

And i can see TX/MOSI transmission on Scope , but the time to transmit the whole file

is unproportionately  big, differently  not 20Mhz, it is somewhere around 12 Mega.

My  questions :

 Is fsl_dspi is suitable dirver for my purpose (i need just basic/general spi functionality)?

If not , which driver should i use?

if yes , should i configure the driver somehow different in device tree or in code?

BR

Alik

 

 

 

Tags (4)
0 Kudos
Reply
1 Reply

600 Views
yipingwang
NXP TechSupport
NXP TechSupport

You need to add FPGA driver for SPI, compatible = "fsl,vf610-dspi" in your dts is incorrect.

Please refer to drivers/fpga/stratixv.c to create your own driver file and include it in u-boot.

Please refer to Linux Kernel driver drivers/fpga/altera-ps-spi.c.

&dspi1 {
status = "okay";

fpga_mgr_spi: fpga-mgr@0 {
compatible = "altr,fpga-arria10-passive-serial";
spi-max-frequency = <20000000>;
reg = <0>; 
nconfig-gpios = <&gpio2 7 GPIO_ACTIVE_LOW>;
nstat-gpios = <&gpio2 9 GPIO_ACTIVE_LOW>;
confd-gpios = <&gpio2 8 GPIO_ACTIVE_LOW>;
status = "okay";
};
};

 

 

0 Kudos
Reply