Hello,
I am using i.MX6UL and i want to access the SPI from "void kernel_power_off(void)" function before shutdown process. so please guide me that how can i access SPI from this function which is in reboot.c file. I want to send some data to my slave device using SPI from this function. I have accessed SPI from user space using spidev and it is working fine. But i could not able to access it from reboot.c file so please guide me ASAP. Thanks in advance.
Hi Lalabhai
please refer to spi ioctls described in linux/Documentation/spi/spidev
linux-imx.git - i.MX Linux Kernel
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hello sir,
Thanks for your quick response, but I still not able to access SPI from reboot.c kernel file. I want to access the SPI from kernel's file "reboot.c" directly, not from user space. So what should I have to do? please guide.
Function from where I want to access SPI is shown below,