Tool/software:
Hi team,
We want to access pmic through mcu_spi0 in the spl stage,and now we encounter some problems:
first, mcu_spi0 cannot be enabled in the spl dts, here is the code we added in the dts:
&wkup_pmx0 {
status = "okay";
};
&cbass_mcu_wakeup {
mcu_spi0: spi@40300000 {
u-boot,dm-spl;
compatible = "ti,omap4-mcspi";
reg = <0x00 0x040300000 0x00 0x400>;
interrupts = <GIC_SPI 848 IRQ_TYPE_LEVEL_HIGH>;
#address-cells = <1>;
#size-cells = <0>;
power-domains = <&k3_pds 274 TI_SCI_PD_EXCLUSIVE>;
clocks = <&k3_clks 274 0>;
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&mcu_spi0_pins_default>;
};
};
&wkup_pmx0 {
mcu_spi0_pins_default: mcu_spi0_pins_default {
u-boot,dm-spl;
pinctrl-single,pins = <
J721E_WKUP_IOPAD(0x90, PIN_OUTPUT, 0) /* (E27) MCU_SPI0_CLK */
J721E_WKUP_IOPAD(0x94, PIN_OUTPUT, 0) /* (E24) MCU_SPI0_D0 */
J721E_WKUP_IOPAD(0x98, PIN_INPUT, 0) /* (E28) MCU_SPI0_D1 */
J721E_WKUP_IOPAD(0x9C, PIN_OUTPUT, 0) /* (E25) MCU_SPI0_CS0 */
>;
};
};
We added some logs in omap3_spi_probe() in drivers/spi/omap3_spi.c, which are not shown in the serial port.
Second, are there any spi read/write functions avaliable to access pmic, the type of pmic is FS8510