Hi everyone,
I am trying to enable the SPI and I2C interfaces on my HiKey board, running Android. All Android stuff is done and in the HAL shared library I want to open the SPI like:
fh = open( "/dev/spi0", O_RDWR );
SPI is not enabled by default in the standard build. In file:
device/linaro/bootloader/OpenPlatformPkg/Platforms/Hisilicon/HiKey/DeviceTree/hi6220.dtsi
I find:
spi0: spi@f7106000 {
compatible = "arm,pl022", "arm,primecell";
...
pinctrl-0 = <&spi0_pmx_func &spi0_cfg_func>;
num-cs = <1>;
cs-gpios = <&gpio6 2 0>;
status = "disabled";
};
I download the Kernel and change the Device Tree file, enable SPI (status=”ok”), build the kenel and move the files into device/linaro/hikey-kernel folder (AOSP build take it from here).
After building the new boot image unfortunately the SPI is still unavailable. But I see in the Kernel log:
[ 1.727900] ssp-pl022 f7106000.spi: could not find pctldev for node /soc/pinmux@f7010000/spi0_pmx_func, deferring probe
[ 4.991628] ssp-pl022 f7106000.spi: ARM PL022 driver, device ID: 0x00041022
[ 4.998769] ssp-pl022 f7106000.spi: mapped registers from 0x00000000f7106000 to ffffff80098a0000
My question:
Can I change the Device Tree without building a new kernel? Is there a way to integrate the required steps in the AOSP build? For me it seems that the DTB file is not built.
Thanks,
Tristar