mbed

Fork of mbed-dev by mbed official

Revision:
177:447f873cad2f
Parent:
175:b96e65c34a4d
--- a/targets/TARGET_NUVOTON/TARGET_NANO100/spi_api.c	Wed Oct 11 12:45:49 2017 +0100
+++ b/targets/TARGET_NUVOTON/TARGET_NANO100/spi_api.c	Wed Oct 25 14:53:38 2017 +0100
@@ -505,24 +505,6 @@
     return SPI_IS_BUSY(spi_base);
 }
 
-int spi_allow_powerdown(void)
-{
-    uint32_t modinit_mask = spi_modinit_mask;
-    while (modinit_mask) {
-        int spi_idx = nu_ctz(modinit_mask);
-        const struct nu_modinit_s *modinit = spi_modinit_tab + spi_idx;
-        if (modinit->modname != NC) {
-            SPI_T *spi_base = (SPI_T *) NU_MODBASE(modinit->modname);
-            if (SPI_IS_BUSY(spi_base)) {
-                return 0;
-            }
-        }
-        modinit_mask &= ~(1 << spi_idx);
-    }
-    
-    return 1;
-}
-
 void SPI0_IRQHandler(void)
 {
     spi_irq(spi0_var.obj);