Hello,
I’m trying to put the SPI2 interface into idle mode by setting a specific pin configuration but I cannot find a document explaining how to set registries or configure functions.
I tried playing with CS line in hikey960-pinctrl.dtsi as following :
spi2_cfg_csn_idle: spi2_cfg_csn_idle {
pinctrl-single,pins = <
0x0a8 0x0 /* SPI2_CS0_N */
>;
pinctrl-single,bias-pulldown = <
PULL_DOWN
PULL_DOWN
PULL_DIS
PULL_DOWN
>;
pinctrl-single,bias-pullup = <
PULL_DIS
PULL_UP
PULL_DIS
PULL_UP
>;
pinctrl-single,drive-strength = <
DRIVE7_02MA DRIVE6_MASK
>;
};
but no change when I stop communicating over SPI.
Following is my setting for SPI driver:
spi2: spi@ffd68000 {
compatible = “arm,pl022”, “arm,primecell”;
reg = <0x0 0xffd68000 0x0 0x1000>;
#address-cells = <1>;
#size-cells = <0>;
interrupts = <GIC_SPI 116 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&crg_ctrl HI3660_CLK_GATE_SPI2>;
clock-names = “apb_pclk”;
pinctrl-names = “default” , “idle”;
pinctrl-0 = <&spi2_pmx_func>;
pinctrl-1 = <&spi2_cfg_csn_idle>;
num-cs = <1>;
cs-gpios = <&gpio27 2 0>;
Thanks for helping me.