From c9137abe72234cbc13c9680659c3ac3d99ce6f74 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Thu, 28 Jan 2016 09:53:22 -0600 Subject: [PATCH] More missed SPI initialization function renaming; clean up some warnings --- configs/dk-tm4c129x/src/dk-tm4c129x.h | 4 ++-- configs/dk-tm4c129x/src/tm4c_boot.c | 6 +++--- configs/dk-tm4c129x/src/tm4c_ssi.c | 4 ++-- configs/eagle100/src/eagle100.h | 4 ++-- configs/eagle100/src/lm_nsh.c | 4 +++- configs/eagle100/src/lm_ssi.c | 4 ---- configs/ekk-lm3s9b96/src/ekk-lm3s9b96.h | 4 ++-- configs/lm3s6432-s2e/src/lm3s6432-s2e.h | 4 ++-- configs/lm3s6432-s2e/src/lm_boot.c | 6 +++--- configs/lm4f120-launchpad/src/lm4f_boot.c | 2 +- configs/mcu123-lpc214x/src/lpc2148_nsh.c | 2 ++ configs/tm4c123g-launchpad/src/tm4c123g-launchpad.h | 4 ++-- configs/tm4c123g-launchpad/src/tm4c_boot.c | 6 +++--- configs/tm4c123g-launchpad/src/tm4c_ssi.c | 4 ++-- configs/tm4c1294-launchpad/src/tm4c1294-launchpad.h | 4 ++-- configs/tm4c1294-launchpad/src/tm4c_boot.c | 6 +++--- configs/zp214xpa/src/lpc2148_ug2864ambag01.c | 1 + 17 files changed, 35 insertions(+), 34 deletions(-) diff --git a/configs/dk-tm4c129x/src/dk-tm4c129x.h b/configs/dk-tm4c129x/src/dk-tm4c129x.h index 8ef4046cb4..37d79c5f55 100644 --- a/configs/dk-tm4c129x/src/dk-tm4c129x.h +++ b/configs/dk-tm4c129x/src/dk-tm4c129x.h @@ -138,14 +138,14 @@ #ifndef __ASSEMBLY__ /************************************************************************************ - * Name: tm4c_ssiinitialize + * Name: tm4c_spidev_initialize * * Description: * Called to configure SPI chip select GPIO pins for the DK-TM4C129X. * ************************************************************************************/ -void weak_function tm4c_ssiinitialize(void); +void weak_function tm4c_spidev_initialize(void); /**************************************************************************** * Name: tm4c_led_initialize diff --git a/configs/dk-tm4c129x/src/tm4c_boot.c b/configs/dk-tm4c129x/src/tm4c_boot.c index 399ce83820..27d45222ea 100644 --- a/configs/dk-tm4c129x/src/tm4c_boot.c +++ b/configs/dk-tm4c129x/src/tm4c_boot.c @@ -73,15 +73,15 @@ void tiva_boardinitialize(void) { /* Configure SPI chip selects if 1) SSI is not disabled, and 2) the weak function - * tm4c_ssiinitialize() has been brought into the link. + * tm4c_spidev_initialize() has been brought into the link. */ /* The DK-TM4C129X microSD CS and OLED are on SSI0 */ #if defined(CONFIG_TIVA_SSI0) || defined(CONFIG_TIVA_SSI1) - if (tm4c_ssiinitialize) + if (tm4c_spidev_initialize) { - tm4c_ssiinitialize(); + tm4c_spidev_initialize(); } #endif diff --git a/configs/dk-tm4c129x/src/tm4c_ssi.c b/configs/dk-tm4c129x/src/tm4c_ssi.c index 5b8ccf147d..2dcd45bc11 100644 --- a/configs/dk-tm4c129x/src/tm4c_ssi.c +++ b/configs/dk-tm4c129x/src/tm4c_ssi.c @@ -86,14 +86,14 @@ ************************************************************************************/ /************************************************************************************ - * Name: tm4c_ssiinitialize + * Name: tm4c_spidev_initialize * * Description: * Called to configure SPI chip select GPIO pins for the DK-TM4C129X. * ************************************************************************************/ -void weak_function tm4c_ssiinitialize(void) +void weak_function tm4c_spidev_initialize(void) { } diff --git a/configs/eagle100/src/eagle100.h b/configs/eagle100/src/eagle100.h index 9f65b44511..995bf9eb14 100644 --- a/configs/eagle100/src/eagle100.h +++ b/configs/eagle100/src/eagle100.h @@ -77,14 +77,14 @@ #ifndef __ASSEMBLY__ /************************************************************************************ - * Name: lm_ssiinitialize + * Name: lm_spidev_initialize * * Description: * Called to configure SPI chip select GPIO pins for the Eagle100 board. * ************************************************************************************/ -void weak_function lm_ssiinitialize(void); +void weak_function lm_spidev_initialize(void); #endif /* __ASSEMBLY__ */ #endif /* __CONFIGS_EAGLE100_SRC_EAGLE100_H */ diff --git a/configs/eagle100/src/lm_nsh.c b/configs/eagle100/src/lm_nsh.c index 9410fa0b36..42216ef9fa 100644 --- a/configs/eagle100/src/lm_nsh.c +++ b/configs/eagle100/src/lm_nsh.c @@ -1,7 +1,7 @@ /**************************************************************************** * config/eagle100/src/lm_nsh.c * - * Copyright (C) 2009, 2012 Gregory Nutt. All rights reserved. + * Copyright (C) 2009, 2012, 2016 Gregory Nutt. All rights reserved. * Author: Gregory Nutt * * Redistribution and use in source and binary forms, with or without @@ -47,6 +47,8 @@ #include #include +#include "tiva_ssi.h" + /**************************************************************************** * Pre-processor Definitions ****************************************************************************/ diff --git a/configs/eagle100/src/lm_ssi.c b/configs/eagle100/src/lm_ssi.c index 81782c229c..2f2337ad6e 100644 --- a/configs/eagle100/src/lm_ssi.c +++ b/configs/eagle100/src/lm_ssi.c @@ -85,10 +85,6 @@ # define ssi_dumpgpio(m) #endif -/************************************************************************************ - * Private Functions - ************************************************************************************/ - /************************************************************************************ * Public Functions ************************************************************************************/ diff --git a/configs/ekk-lm3s9b96/src/ekk-lm3s9b96.h b/configs/ekk-lm3s9b96/src/ekk-lm3s9b96.h index 5541c57be4..a592c2f882 100644 --- a/configs/ekk-lm3s9b96/src/ekk-lm3s9b96.h +++ b/configs/ekk-lm3s9b96/src/ekk-lm3s9b96.h @@ -98,14 +98,14 @@ #ifndef __ASSEMBLY__ /************************************************************************************ - * Name: lm_ssiinitialize + * Name: lm_spidev_initialize * * Description: * Called to configure SPI chip select GPIO pins for the LM3S6965 Eval Kit. * ************************************************************************************/ -extern void weak_function lm_ssiinitialize(void); +extern void weak_function lm_spidev_initialize(void); #endif /* __ASSEMBLY__ */ #endif /* __CONFIGS_EKK_LM3S9B96_SRC_EKKLM3S9B96_H */ diff --git a/configs/lm3s6432-s2e/src/lm3s6432-s2e.h b/configs/lm3s6432-s2e/src/lm3s6432-s2e.h index 9b9368c341..ff40116530 100644 --- a/configs/lm3s6432-s2e/src/lm3s6432-s2e.h +++ b/configs/lm3s6432-s2e/src/lm3s6432-s2e.h @@ -110,14 +110,14 @@ #ifndef __ASSEMBLY__ /************************************************************************************ - * Name: lm_ssiinitialize + * Name: lm_spidev_initialize * * Description: * Called to configure SPI chip select GPIO pins for the MDL-S2E. * ************************************************************************************/ -void weak_function lm_ssiinitialize(void); +void weak_function lm_spidev_initialize(void); #endif /* __ASSEMBLY__ */ #endif /* __CONFIGS_LM3S6432_S2E_SRC_LM3S6432S2E_H */ diff --git a/configs/lm3s6432-s2e/src/lm_boot.c b/configs/lm3s6432-s2e/src/lm_boot.c index f18e0a91d9..301c46007c 100644 --- a/configs/lm3s6432-s2e/src/lm_boot.c +++ b/configs/lm3s6432-s2e/src/lm_boot.c @@ -79,13 +79,13 @@ void tiva_boardinitialize(void) { /* Configure SPI chip selects if 1) SSI is not disabled, and 2) the weak function - * lm_ssiinitialize() has been brought into the link. + * lm_spidev_initialize() has been brought into the link. */ #if defined(CONFIG_TIVA_SSI0) - if (lm_ssiinitialize) + if (lm_spidev_initialize) { - lm_ssiinitialize(); + lm_spidev_initialize(); } #endif diff --git a/configs/lm4f120-launchpad/src/lm4f_boot.c b/configs/lm4f120-launchpad/src/lm4f_boot.c index 0d64706d50..981a459af8 100644 --- a/configs/lm4f120-launchpad/src/lm4f_boot.c +++ b/configs/lm4f120-launchpad/src/lm4f_boot.c @@ -73,7 +73,7 @@ void tiva_boardinitialize(void) { /* Configure SPI chip selects if 1) SSI is not disabled, and 2) the weak function - * lm_ssiinitialize() has been brought into the link. + * lm_spidev_initialize() has been brought into the link. */ /* The LM4F LaunchPad microSD CS and OLED are on SSI0 (Duh! There is no SSI1) */ diff --git a/configs/mcu123-lpc214x/src/lpc2148_nsh.c b/configs/mcu123-lpc214x/src/lpc2148_nsh.c index 81682947ae..90e434439c 100644 --- a/configs/mcu123-lpc214x/src/lpc2148_nsh.c +++ b/configs/mcu123-lpc214x/src/lpc2148_nsh.c @@ -47,6 +47,8 @@ #include #include +#include "lpc214x_spi.h" + /**************************************************************************** * Pre-processor Definitions ****************************************************************************/ diff --git a/configs/tm4c123g-launchpad/src/tm4c123g-launchpad.h b/configs/tm4c123g-launchpad/src/tm4c123g-launchpad.h index 5641f72b37..d92628a8b1 100644 --- a/configs/tm4c123g-launchpad/src/tm4c123g-launchpad.h +++ b/configs/tm4c123g-launchpad/src/tm4c123g-launchpad.h @@ -182,14 +182,14 @@ #ifndef __ASSEMBLY__ /************************************************************************************ - * Name: tm4c_ssiinitialize + * Name: tm4c_spidev_initialize * * Description: * Called to configure SPI chip select GPIO pins for the TM4C123G LaunchPad. * ************************************************************************************/ -void weak_function tm4c_ssiinitialize(void); +void weak_function tm4c_spidev_initialize(void); /**************************************************************************** * Name: tm4c_led_initialize diff --git a/configs/tm4c123g-launchpad/src/tm4c_boot.c b/configs/tm4c123g-launchpad/src/tm4c_boot.c index 7882b05d14..9740494de1 100644 --- a/configs/tm4c123g-launchpad/src/tm4c_boot.c +++ b/configs/tm4c123g-launchpad/src/tm4c_boot.c @@ -73,15 +73,15 @@ void tiva_boardinitialize(void) { /* Configure SPI chip selects if 1) SSI is not disabled, and 2) the weak function - * tm4c_ssiinitialize() has been brought into the link. + * tm4c_spidev_initialize() has been brought into the link. */ /* The TM4C123G LaunchPad microSD CS and OLED are on SSI0 */ #if defined(CONFIG_TIVA_SSI0) || defined(CONFIG_TIVA_SSI1) - if (tm4c_ssiinitialize) + if (tm4c_spidev_initialize) { - tm4c_ssiinitialize(); + tm4c_spidev_initialize(); } #endif diff --git a/configs/tm4c123g-launchpad/src/tm4c_ssi.c b/configs/tm4c123g-launchpad/src/tm4c_ssi.c index c97f26f8aa..18c9a9c284 100644 --- a/configs/tm4c123g-launchpad/src/tm4c_ssi.c +++ b/configs/tm4c123g-launchpad/src/tm4c_ssi.c @@ -86,14 +86,14 @@ ************************************************************************************/ /************************************************************************************ - * Name: tm4c_ssiinitialize + * Name: tm4c_spidev_initialize * * Description: * Called to configure SPI chip select GPIO pins for the TM4C123G LaunchPad. * ************************************************************************************/ -void weak_function tm4c_ssiinitialize(void) +void weak_function tm4c_spidev_initialize(void) { } diff --git a/configs/tm4c1294-launchpad/src/tm4c1294-launchpad.h b/configs/tm4c1294-launchpad/src/tm4c1294-launchpad.h index 89e834a80c..e871249f65 100644 --- a/configs/tm4c1294-launchpad/src/tm4c1294-launchpad.h +++ b/configs/tm4c1294-launchpad/src/tm4c1294-launchpad.h @@ -127,14 +127,14 @@ #ifndef __ASSEMBLY__ /************************************************************************************ - * Name: tm4c_ssiinitialize + * Name: tm4c_spidev_initialize * * Description: * Called to configure SPI chip select GPIO pins for the EK-TM4C1294XL. * ************************************************************************************/ -void weak_function tm4c_ssiinitialize(void); +void weak_function tm4c_spidev_initialize(void); /**************************************************************************** * Name: tm4c_led_initialize diff --git a/configs/tm4c1294-launchpad/src/tm4c_boot.c b/configs/tm4c1294-launchpad/src/tm4c_boot.c index 5f48767be3..9e2098fe2b 100644 --- a/configs/tm4c1294-launchpad/src/tm4c_boot.c +++ b/configs/tm4c1294-launchpad/src/tm4c_boot.c @@ -73,15 +73,15 @@ void tiva_boardinitialize(void) { /* Configure SPI chip selects if 1) SSI is not disabled, and 2) the weak function - * tm4c_ssiinitialize() has been brought into the link. + * tm4c_spidev_initialize() has been brought into the link. */ /* The DK-TM4C129X microSD CS and OLED are on SSI0 */ #if defined(CONFIG_TIVA_SSI0) || defined(CONFIG_TIVA_SSI1) - if (tm4c_ssiinitialize) + if (tm4c_spidev_initialize) { - tm4c_ssiinitialize(); + tm4c_spidev_initialize(); } #endif diff --git a/configs/zp214xpa/src/lpc2148_ug2864ambag01.c b/configs/zp214xpa/src/lpc2148_ug2864ambag01.c index 68e98ef9e2..c857b43ba8 100644 --- a/configs/zp214xpa/src/lpc2148_ug2864ambag01.c +++ b/configs/zp214xpa/src/lpc2148_ug2864ambag01.c @@ -49,6 +49,7 @@ #include "up_arch.h" #include "chip.h" #include "lpc214x_pinsel.h" +#include "lpc214x_spi.h" #ifdef CONFIG_LCD_UG2864AMBAG01