|
可能需要修改设备树,为 SPI1_CS1 添加支持。参考如下:
pinctrl_spi1: spi1grp {
fsl,pins = <
MX6QDL_PAD_EIM_D16__ECSPI1_SCLK 0x100b1
MX6QDL_PAD_EIM_D17__ECSPI1_MISO 0x100b1
MX6QDL_PAD_EIM_D18__ECSPI1_MOSI 0x100b1
/* SPI1_CS1 */
MX6QDL_PAD_EIM_D19__GPIO3_IO19 0x80000000
/* SPI1_CS0: SPI Flash */
MX6QDL_PAD_EIM_EB2__GPIO2_IO30 0x80000000
>;
};
&ecspi1 {
fsl,spi-num-chipselects = <2>;
cs-gpios = <&gpio2 30 0>, <&gpio3 19 0>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_spi1>;
status = "okay";
flash: m25p80@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "sst,sst25vf016b";
spi-max-frequency = <20000000>;
reg = <0>;
};
spidev@1 {
compatible = "spidev";
spi-max-frequency = <20000000>;
reg = <1>;
};
};
|
|