Hi, On Wed, Aug 31, 2011 at 17:47:43, Aníbal Almeida Pinto wrote: > Hi, > > I am using the OMAP L138 logic evaluation board with 3.0.0 linux-davinci > kernel. > > To the default configuration I have added spi support and build the > spi_davinci as a module. > > After the boards boot I was able to insmod davinci_spi.ko but when tried > to make rmmod davinci_spi.ko the board halted. > > Anyone have reported this ? > > Inserting printk on davinci_spi remove function it appears to be on > clk_disable. >
I also noticed this issue. When I debugged this I found out that, the SPI driver enables the local low-power mode. This is achieved by setting the POWERDOWN bit (9th bit) in SPIGCR1 register. In local low-power mode, clock to SPI internal logic is stopped. At this point of time, doing a clk_disable() is not behaving properly. When SPI is not in low-power mode, clk_disable() works fine. So for rmmod to work, you need to remove all references to SPIGCR1_POWERDOWN_MASK in the code. Please test this at your end and let me know the outcome. If it is working, then I can submit a patch to the list which takes care of this. Thanks, Sudhakar _______________________________________________ Davinci-linux-open-source mailing list [email protected] http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source
