boards/arm: Replace board_app_initialize

Replaced board_app_initialize logic with board_late_initialize.

Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
This commit is contained in:
Matteo Golin 2026-02-19 12:58:00 -05:00 committed by Xiang Xiao
parent d54f3a31cb
commit 66ae075ae8
941 changed files with 6569 additions and 27015 deletions

View file

@ -22,10 +22,6 @@
set(SRCS a1x_boot.c a1x_bringup.c a1x_leds.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS a1x_appinit.c)
endif()
if(CONFIG_ARCH_BUTTONS)
list(APPEND SRCS a1x_buttons.c)
endif()

View file

@ -24,10 +24,6 @@ include $(TOPDIR)/Make.defs
CSRCS = a1x_boot.c a1x_bringup.c a1x_leds.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += a1x_appinit.c
endif
ifeq ($(CONFIG_ARCH_BUTTONS),y)
CSRCS += a1x_buttons.c
endif

View file

@ -1,80 +0,0 @@
/****************************************************************************
* boards/arm/a1x/pcduino-a10/src/a1x_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <stdint.h>
#include <nuttx/board.h>
#include "pcduino_a10.h"
/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#ifdef CONFIG_BOARD_LATE_INITIALIZE
/* Board initialization already performed by board_late_initialize() */
return OK;
#else
/* Perform board-specific initialization */
return a1x_bringup();
#endif
}

View file

@ -22,10 +22,6 @@
set(SRCS am335x_boot.c am335x_bringup.c am335x_leds.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS am335x_appinit.c)
endif()
if(CONFIG_ARCH_BUTTONS)
list(APPEND SRCS am335x_buttons.c)
endif()

View file

@ -24,10 +24,6 @@ include $(TOPDIR)/Make.defs
CSRCS = am335x_boot.c am335x_bringup.c am335x_leds.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += am335x_appinit.c
endif
ifeq ($(CONFIG_ARCH_BUTTONS),y)
CSRCS += am335x_buttons.c
endif

View file

@ -1,78 +0,0 @@
/****************************************************************************
* boards/arm/am335x/beaglebone-black/src/am335x_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "beaglebone-black.h"
/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#ifdef CONFIG_BOARD_LATE_INITIALIZE
/* Board initialization already performed by board_late_initialize() */
return OK;
#else
/* Perform board-specific initialization */
return am335x_bringup();
#endif
}

View file

@ -24,10 +24,6 @@ include $(TOPDIR)/Make.defs
CSRCS = at32_boot.c at32_bringup.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += at32_appinit.c
endif
ifeq ($(CONFIG_DEV_GPIO),y)
CSRCS += at32_gpio.c
endif

View file

@ -1,78 +0,0 @@
/****************************************************************************
* boards/arm/at32/at32f437-mini/src/at32_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "at32f437-mini.h"
/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#ifdef CONFIG_BOARD_LATE_INITIALIZE
/* Board initialization already performed by board_late_initialize() */
return OK;
#else
/* Perform board-specific initialization */
return at32_bringup();
#endif
}

View file

@ -96,3 +96,22 @@ void board_autoled_off(int led)
}
#endif /* CONFIG_ARCH_LEDS */
/****************************************************************************
* Name: board_late_initialize
*
* Description:
* If CONFIG_BOARD_LATE_INITIALIZE is selected, then an additional
* initialization call will be performed in the boot-up sequence to a
* function called board_late_initialize(). board_late_initialize() will be
* called immediately after up_initialize() is called and just before the
* initial application is started. This additional initialization phase
* may be used, for example, to initialize board-specific device drivers.
*
****************************************************************************/
#ifdef CONFIG_BOARD_LATE_INITIALIZE
void board_late_initialize(void)
{
}
#endif /* CONFIG_BOARD_LATE_INITIALIZE */

View file

@ -20,7 +20,7 @@
#
# ##############################################################################
set(SRCS csk6011a_nano_appinit.c)
set(SRCS csk6011a_nano_boardinit.c)
target_sources(board PRIVATE ${SRCS})

View file

@ -22,6 +22,6 @@
include $(TOPDIR)/Make.defs
CSRCS = csk6011a_nano_appinit.c
CSRCS = csk6011a_nano_boardinit.c
include $(TOPDIR)/boards/Board.mk

View file

@ -1,5 +1,5 @@
/****************************************************************************
* boards/arm/csk6/csk6011a-nano/src/csk6011a_nano_appinit.c
* boards/arm/csk6/csk6011a-nano/src/csk6011a_nano_boardinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
@ -26,7 +26,12 @@
#include <nuttx/config.h>
#include <nuttx/debug.h>
#include <stdio.h>
#include <errno.h>
#include <sys/types.h>
#include <nuttx/board.h>
/****************************************************************************
@ -60,46 +65,23 @@ static const char verification_table[] VERIFICATION_TABLE_ATTR =
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
* Name: board_late_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
* If CONFIG_BOARD_LATE_INITIALIZE is selected, then an additional
* initialization call will be performed in the boot-up sequence to a
* function called board_late_initialize(). board_late_initialize() will be
* called immediately after up_intitialize() is called and just before the
* initial application is started. This additional initialization phase
* may be used, for example, to initialize board-specific device drivers.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
/* Perform board-specific initialization */
/* TODO */
return OK;
}
#ifdef CONFIG_BOARD_LATE_INITIALIZE
void board_late_initialize(void)
{
/* Perform board-specific initialization */
/* TODO */
}
#endif

View file

@ -54,8 +54,7 @@
int board_usbmsc_initialize(int port)
{
/* If system/usbmsc is built as an NSH command, then SD slot should
* already have been initialized in board_app_initialize()
* (see stm32_appinit.c).
* already have been initialized.
* In this case, there is nothing further to be done here.
*/

View file

@ -22,12 +22,8 @@
set(SRCS)
set(SRCS cxd56_main.c cxd56_clock.c cxd56_bringup.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS cxd56_appinit.c)
list(APPEND SRCS cxd56_power.c)
endif()
set(SRCS cxd56_main.c cxd56_clock.c cxd56_bringup.c cxd56_boardinit.c
cxd56_power.c)
if(CONFIG_BOARDCTL_IOCTL)
list(APPEND SRCS cxd56_ioctl.c)

View file

@ -23,11 +23,8 @@
CSRCS += cxd56_main.c
CSRCS += cxd56_clock.c
CSRCS += cxd56_bringup.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += cxd56_appinit.c
CSRCS += cxd56_boardinit.c
CSRCS += cxd56_power.c
endif
ifeq ($(CONFIG_BOARDCTL_IOCTL),y)
CSRCS += cxd56_ioctl.c

View file

@ -1,104 +0,0 @@
/****************************************************************************
* boards/arm/cxd56xx/spresense/src/cxd56_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <nuttx/compiler.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "spresense.h"
/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#ifdef CONFIG_BOARD_LATE_INITIALIZE
/* Board initialization already performed by board_late_initialize() */
return OK;
#else
/* Perform board-specific initialization */
return cxd56_bringup();
#endif
}
/****************************************************************************
* Name: board_late_initialize
*
* Description:
* If CONFIG_BOARD_LATE_INITIALIZE is selected, then an additional
* initialization call will be performed in the boot-up sequence to a
* function called board_late_initialize(). board_late_initialize()
* will be called immediately after up_initialize() is called and just
* before the initial application is started. This additional
* initialization phase may be used, for example, to initialize board-
* specific device drivers.
*
****************************************************************************/
#ifdef CONFIG_BOARD_LATE_INITIALIZE
void weak_function board_late_initialize(void)
{
/* Perform board bring-up here instead of from the
* board_app_initialize().
*/
cxd56_bringup();
}
#endif

View file

@ -1,5 +1,5 @@
/****************************************************************************
* boards/arm/tiva/ekk-lm3s9b96/src/lm_appinit.c
* boards/arm/cxd56xx/spresense/src/cxd56_boardinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
@ -25,13 +25,18 @@
****************************************************************************/
#include <nuttx/config.h>
#include <nuttx/compiler.h>
#include <nuttx/debug.h>
#include <stdio.h>
#include <syslog.h>
#include <errno.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "spresense.h"
/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
@ -41,29 +46,22 @@
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
* Name: board_late_initialize
*
* Description:
* Perform architecture specific initialization
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
* If CONFIG_BOARD_LATE_INITIALIZE is selected, then an additional
* initialization call will be performed in the boot-up sequence to a
* function called board_late_initialize(). board_late_initialize()
* will be called immediately after up_initialize() is called and just
* before the initial application is started. This additional
* initialization phase may be used, for example, to initialize board-
* specific device drivers.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
#ifdef CONFIG_BOARD_LATE_INITIALIZE
void weak_function board_late_initialize(void)
{
return OK;
cxd56_bringup();
}
#endif

View file

@ -85,7 +85,6 @@ int board_ioctl(unsigned int cmd, uintptr_t arg)
* and supply current value.
* ARG: None
* CONFIGURATION: CONFIG_BOARDCTL
* DEPENDENCIES: Board logic must provide board_app_initialization
*/
case BOARDIOC_USBDEV_SETNOTIFYSIG:

View file

@ -28,8 +28,4 @@ ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += dm320_boardinit.c
endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += dm320_appinit.c
endif
include $(TOPDIR)/boards/Board.mk

View file

@ -1,68 +0,0 @@
/****************************************************************************
* boards/arm/dm320/ntosd-dm320/src/dm320_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
return OK;
}

View file

@ -20,7 +20,7 @@
#
# ##############################################################################
set(SRCS eoss3_boot.c eoss3_bringup.c eoss3_appinit.c)
set(SRCS eoss3_boot.c eoss3_bringup.c)
if(CONFIG_ARCH_LEDS)
list(APPEND SRCS eoss3_autoleds.c)

View file

@ -22,7 +22,7 @@
include $(TOPDIR)/Make.defs
CSRCS = eoss3_boot.c eoss3_bringup.c eoss3_appinit.c
CSRCS = eoss3_boot.c eoss3_bringup.c
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += eoss3_autoleds.c
@ -30,4 +30,4 @@ else
CSRCS += eoss3_userleds.c
endif
include $(TOPDIR)/boards/Board.mk
include $(TOPDIR)/boards/Board.mk

View file

@ -1,68 +0,0 @@
/****************************************************************************
* boards/arm/eoss3/quickfeather/src/eoss3_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
return OK;
}
#endif /* CONFIG_BOARDCTL */

View file

@ -22,10 +22,6 @@
set(SRCS fvp_boardinit.c fvp_bringup.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS fvp_appinit.c)
endif()
target_sources(board PRIVATE ${SRCS})
set_property(GLOBAL PROPERTY LD_SCRIPT "${NUTTX_BOARD_DIR}/scripts/dramboot.ld")

View file

@ -24,8 +24,4 @@ include $(TOPDIR)/Make.defs
CSRCS = fvp_boardinit.c fvp_bringup.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += fvp_appinit.c
endif
include $(TOPDIR)/boards/Board.mk

View file

@ -1,75 +0,0 @@
/****************************************************************************
* boards/arm/fvp-v8r-aarch32/fvp-armv8r-aarch32/src/fvp_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "fvp-armv8r.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
UNUSED(arg);
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return fvp_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -22,9 +22,7 @@
set(SRCS gd32f4xx_boot.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS gd32f4xx_appinit.c gd32f4xx_bringup.c)
elseif(CONFIG_BOARD_LATE_INITIALIZE)
if(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS gd32f4xx_bringup.c)
endif()

View file

@ -22,17 +22,7 @@
include $(TOPDIR)/Make.defs
CSRCS = gd32f4xx_boot.c
# ifeq ($(CONFIG_BOARDCTL),y)
# CSRCS += gd32f4xx_appinit.c
# endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += gd32f4xx_appinit.c gd32f4xx_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += gd32f4xx_bringup.c
endif
CSRCS = gd32f4xx_boot.c gd32f4xx_bringup.c
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += gd32f4xx_autoleds.c

View file

@ -136,16 +136,9 @@
* Description:
* Perform architecture specific initialization
*
* CONFIG_BOARDCTL=y:
* If CONFIG_NSH_ARCHINIT=y:
* Called from the NSH library (or other application)
* Otherwise, assumed to be called from some other application.
*
* Otherwise CONFIG_BOARD_LATE_INITIALIZE=y:
* CONFIG_BOARD_LATE_INITIALIZE=y:
* Called from board_late_initialize().
*
* Otherwise, bad news: Never called
*
****************************************************************************/
int gd32_bringup(void);
@ -348,16 +341,9 @@ void gd32_i2c_initialize(void);
* Description:
* Perform architecture specific initialization
*
* CONFIG_BOARDCTL=y:
* If CONFIG_NSH_ARCHINIT=y:
* Called from the NSH library (or other application)
* Otherwise, assumed to be called from some other application.
*
* Otherwise CONFIG_BOARD_LATE_INITIALIZE=y:
* CONFIG_BOARD_LATE_INITIALIZE=y:
* Called from board_late_initialize().
*
* Otherwise, bad news: Never called
*
****************************************************************************/
int gd32_bringup(void);
@ -422,4 +408,4 @@ int gd32_sdio_initialize(void);
#ifdef CONFIG_I2C
void gd32_i2c_initialize(void);
#endif
#endif

View file

@ -1,73 +0,0 @@
/****************************************************************************
* boards/arm/gd32f4/gd32f450zk-aiotbox/src/gd32f4xx_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <stdbool.h>
#include <stdio.h>
#include <syslog.h>
#include <errno.h>
#include <nuttx/board.h>
#include "gd32f4xx.h"
#include "gd32f450z_aiotbox.h"
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
/* Perform board initialization here */
return gd32_bringup();
}

View file

@ -22,9 +22,7 @@
set(SRCS gd32f4xx_boot.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS gd32f4xx_appinit.c gd32f4xx_bringup.c)
elseif(CONFIG_BOARD_LATE_INITIALIZE)
if(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS gd32f4xx_bringup.c)
endif()

View file

@ -22,17 +22,7 @@
include $(TOPDIR)/Make.defs
CSRCS = gd32f4xx_boot.c
# ifeq ($(CONFIG_BOARDCTL),y)
# CSRCS += gd32f4xx_appinit.c
# endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += gd32f4xx_appinit.c gd32f4xx_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += gd32f4xx_bringup.c
endif
CSRCS = gd32f4xx_boot.c gd32f4xx_bringup.c
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += gd32f4xx_autoleds.c

View file

@ -188,16 +188,9 @@
* Description:
* Perform architecture specific initialization
*
* CONFIG_BOARDCTL=y:
* If CONFIG_NSH_ARCHINIT=y:
* Called from the NSH library (or other application)
* Otherwise, assumed to be called from some other application.
*
* Otherwise CONFIG_BOARD_LATE_INITIALIZE=y:
* CONFIG_BOARD_LATE_INITIALIZE=y:
* Called from board_late_initialize().
*
* Otherwise, bad news: Never called
*
****************************************************************************/
int gd32_bringup(void);

View file

@ -1,73 +0,0 @@
/****************************************************************************
* boards/arm/gd32f4/gd32f450zk-eval/src/gd32f4xx_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <stdbool.h>
#include <stdio.h>
#include <syslog.h>
#include <errno.h>
#include <nuttx/board.h>
#include "gd32f4xx.h"
#include "gd32f450z_eval.h"
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
/* Perform board initialization here */
return gd32_bringup();
}

View file

@ -22,9 +22,7 @@
set(SRCS gd32f4xx_boot.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS gd32f4xx_appinit.c gd32f4xx_bringup.c)
elseif(CONFIG_BOARD_LATE_INITIALIZE)
if(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS gd32f4xx_bringup.c)
endif()

View file

@ -22,17 +22,7 @@
include $(TOPDIR)/Make.defs
CSRCS = gd32f4xx_boot.c
# ifeq ($(CONFIG_BOARDCTL),y)
# CSRCS += gd32f4xx_appinit.c
# endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += gd32f4xx_appinit.c gd32f4xx_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += gd32f4xx_bringup.c
endif
CSRCS = gd32f4xx_boot.c gd32f4xx_bringup.c
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += gd32f4xx_autoleds.c

View file

@ -188,16 +188,9 @@
* Description:
* Perform architecture specific initialization
*
* CONFIG_BOARDCTL=y:
* If CONFIG_NSH_ARCHINITIALIZE=y:
* Called from the NSH library (or other application)
* Otherwise, assumed to be called from some other application.
*
* Otherwise CONFIG_BOARD_LATE_INITIALIZE=y:
* CONFIG_BOARD_LATE_INITIALIZE=y:
* Called from board_late_initialize().
*
* Otherwise, bad news: Never called
*
****************************************************************************/
int gd32_bringup(void);

View file

@ -1,73 +0,0 @@
/****************************************************************************
* boards/arm/gd32f4/gd32f470ik-eval/src/gd32f4xx_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <stdbool.h>
#include <stdio.h>
#include <syslog.h>
#include <errno.h>
#include <nuttx/board.h>
#include "gd32f4xx.h"
#include "gd32f470i_eval.h"
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
/* Perform board initialization here */
return gd32_bringup();
}

View file

@ -22,17 +22,7 @@
include $(TOPDIR)/Make.defs
CSRCS = gd32f4xx_boot.c
# ifeq ($(CONFIG_BOARDCTL),y)
# CSRCS += gd32f4xx_appinit.c
# endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += gd32f4xx_appinit.c gd32f4xx_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += gd32f4xx_bringup.c
endif
CSRCS = gd32f4xx_boot.c gd32f4xx_bringup.c
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += gd32f4xx_autoleds.c

View file

@ -188,16 +188,9 @@
* Description:
* Perform architecture specific initialization
*
* CONFIG_BOARDCTL=y:
* If CONFIG_NSH_ARCHINITIALIZE=y:
* Called from the NSH library (or other application)
* Otherwise, assumed to be called from some other application.
*
* Otherwise CONFIG_BOARD_LATE_INITIALIZE=y:
* CONFIG_BOARD_LATE_INITIALIZE=y:
* Called from board_late_initialize().
*
* Otherwise, bad news: Never called
*
****************************************************************************/
int gd32_bringup(void);

View file

@ -1,73 +0,0 @@
/****************************************************************************
* boards/arm/gd32f4/gd32f470zk-aiotbox/src/gd32f4xx_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <stdbool.h>
#include <stdio.h>
#include <syslog.h>
#include <errno.h>
#include <nuttx/board.h>
#include "gd32f4xx.h"
#include "gd32f470z_aiotbox.h"
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
/* Perform board initialization here */
return gd32_bringup();
}

View file

@ -22,17 +22,7 @@
include $(TOPDIR)/Make.defs
CSRCS = gd32f4xx_boot.c
# ifeq ($(CONFIG_BOARDCTL),y)
# CSRCS += gd32f4xx_appinit.c
# endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += gd32f4xx_appinit.c gd32f4xx_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += gd32f4xx_bringup.c
endif
CSRCS = gd32f4xx_boot.c gd32f4xx_bringup.c
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += gd32f4xx_autoleds.c

View file

@ -188,16 +188,9 @@
* Description:
* Perform architecture specific initialization
*
* CONFIG_BOARDCTL=y:
* If CONFIG_NSH_ARCHINITIALIZE=y:
* Called from the NSH library (or other application)
* Otherwise, assumed to be called from some other application.
*
* Otherwise CONFIG_BOARD_LATE_INITIALIZE=y:
* CONFIG_BOARD_LATE_INITIALIZE=y:
* Called from board_late_initialize().
*
* Otherwise, bad news: Never called
*
****************************************************************************/
int gd32_bringup(void);

View file

@ -1,73 +0,0 @@
/****************************************************************************
* boards/arm/gd32f4/gd32f470zk-eval/src/gd32f4xx_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <stdbool.h>
#include <stdio.h>
#include <syslog.h>
#include <errno.h>
#include <nuttx/board.h>
#include "gd32f4xx.h"
#include "gd32f470z_eval.h"
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
/* Perform board initialization here */
return gd32_bringup();
}

View file

@ -118,8 +118,6 @@
void ht32f491x3_clockconfig(void);
void ht32f491x3_boardinitialize(void);
int board_app_initialize(uintptr_t arg);
#ifdef CONFIG_PWM
int ht32_pwm_setup(void);
#endif

View file

@ -22,8 +22,8 @@
set(SRCS ht32_boot.c)
if(CONFIG_BOARDCTL OR CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS ht32_appinit.c)
if(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS ht32_bringup.c)
endif()
if(CONFIG_USERLED)

View file

@ -24,10 +24,8 @@ include $(TOPDIR)/Make.defs
CSRCS += ht32_boot.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += ht32_appinit.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += ht32_appinit.c
ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += ht32_bringup.c
endif
ifeq ($(CONFIG_USERLED),y)

View file

@ -1,5 +1,5 @@
/****************************************************************************
* boards/arm/ht32f491x3/esk32/src/ht32_appinit.c
* boards/arm/ht32f491x3/esk32/src/ht32_bringup.c
*
* SPDX-License-Identifier: Apache-2.0
*
@ -91,17 +91,6 @@ static int ht32_bringup(void)
* Public Functions
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
(void)arg;
#ifdef CONFIG_BOARD_LATE_INITIALIZE
return OK;
#else
return ht32_bringup();
#endif
}
#ifdef CONFIG_BOARD_LATE_INITIALIZE
void board_late_initialize(void)
{

View file

@ -22,10 +22,6 @@
set(SRCS imx_boardinit.c imx_bringup.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS imx_appinit.c)
endif()
if(CONFIG_ARCH_LEDS)
list(APPEND SRCS imx_autoleds.c)
else()

View file

@ -24,10 +24,6 @@ include $(TOPDIR)/Make.defs
CSRCS = imx_boardinit.c imx_bringup.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += imx_appinit.c
endif
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += imx_autoleds.c
else

View file

@ -1,77 +0,0 @@
/****************************************************************************
* boards/arm/imx6/sabre-6quad/src/imx_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "sabre-6quad.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return imx_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -22,10 +22,6 @@
set(SRCS imx93_boardinit.c imx93_bringup.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS imx93_appinit.c)
endif()
target_sources(board PRIVATE ${SRCS})
if(CONFIG_IMX93_RUN_FROM_ITCM)

View file

@ -25,8 +25,4 @@ include $(TOPDIR)/Make.defs
CSRCS = imx93_boardinit.c imx93_bringup.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += imx93_appinit.c
endif
include $(TOPDIR)/boards/Board.mk

View file

@ -1,76 +0,0 @@
/****************************************************************************
* boards/arm/imx9/imx93-qsb/src/imx93_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
* SPDX-FileCopyrightText: 2024 NXP
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "imx93-qsb.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
UNUSED(arg);
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return imx93_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -22,10 +22,6 @@
set(SRCS imx95_boardinit.c imx95_bringup.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS imx95_appinit.c)
endif()
if(CONFIG_PWM)
list(APPEND SRCS imx95_pwm.c)
endif()

View file

@ -25,10 +25,6 @@ include $(TOPDIR)/Make.defs
CSRCS = imx95_boardinit.c imx95_bringup.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += imx95_appinit.c
endif
ifeq ($(CONFIG_PWM),y)
CSRCS += imx95_pwm.c
endif

View file

@ -1,76 +0,0 @@
/****************************************************************************
* boards/arm/imx9/imx95-evk/src/imx95_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
* SPDX-FileCopyrightText: 2024 NXP
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "imx95-evk.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
UNUSED(arg);
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return imx95_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -22,10 +22,6 @@
set(SRCS imx95_boardinit.c imx95_bringup.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS imx95_appinit.c)
endif()
if(CONFIG_PWM)
list(APPEND SRCS imx95_pwm.c)
endif()

View file

@ -25,10 +25,6 @@ include $(TOPDIR)/Make.defs
CSRCS = imx95_boardinit.c imx95_bringup.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += imx95_appinit.c
endif
ifeq ($(CONFIG_PWM),y)
CSRCS += imx95_pwm.c
endif

View file

@ -1,76 +0,0 @@
/****************************************************************************
* boards/arm/imx9/mr-navq95b/src/imx95_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
* SPDX-FileCopyrightText: 2026 NXP
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "mr-navq95b.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
UNUSED(arg);
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return imx95_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -20,18 +20,13 @@
#
# ##############################################################################
set(SRCS imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c)
set(SRCS imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
imxrt_bringup.c)
if(CONFIG_IMXRT_SDRAMC)
list(APPEND SRCS imxrt_sdram.c)
endif()
if(CONFIG_BOARDCTL)
list(APPEND SRCS imxrt_appinit.c imxrt_bringup.c)
elseif(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS imxrt_bringup.c)
endif()
if(CONFIG_ARCH_LEDS)
list(APPEND SRCS imxrt_autoleds.c)
else()

View file

@ -23,17 +23,12 @@
include $(TOPDIR)/Make.defs
CSRCS = imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
CSRCS += imxrt_bringup.c
ifeq ($(CONFIG_IMXRT_SDRAMC),y)
CSRCS += imxrt_sdram.c
endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += imxrt_appinit.c imxrt_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += imxrt_bringup.c
endif
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += imxrt_autoleds.c
else

View file

@ -138,9 +138,7 @@
*
****************************************************************************/
#if defined(CONFIG_BOARDCTL) || defined(CONFIG_BOARD_LATE_INITIALIZE)
int imxrt_bringup(void);
#endif
/****************************************************************************
* Name: imxrt_spidev_initialize

View file

@ -1,77 +0,0 @@
/****************************************************************************
* boards/arm/imxrt/arcx-socket-grid/src/imxrt_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "arcx-socket-grid.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return imxrt_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -20,18 +20,13 @@
#
# ##############################################################################
set(SRCS imxrt_flexspi_nor_flash.c imxrt_boot.c imxrt_flexspi_nor_boot.c)
set(SRCS imxrt_flexspi_nor_flash.c imxrt_boot.c imxrt_flexspi_nor_boot.c
imxrt_bringup.c)
if(CONFIG_IMXRT_SDRAMC)
list(APPEND SRCS imxrt_sdram.c)
endif()
if(CONFIG_BOARDCTL)
list(APPEND SRCS imxrt_appinit.c imxrt_bringup.c)
elseif(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS imxrt_bringup.c)
endif()
if(CONFIG_ARCH_LEDS)
list(APPEND SRCS imxrt_autoleds.c)
else()

View file

@ -23,16 +23,12 @@
include $(TOPDIR)/Make.defs
CSRCS = imxrt_flexspi_nor_flash.c imxrt_boot.c imxrt_flexspi_nor_boot.c
CSRCS += imxrt_bringup.c
ifeq ($(CONFIG_IMXRT_SDRAMC),y)
CSRCS += imxrt_sdram.c
endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += imxrt_appinit.c imxrt_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += imxrt_bringup.c
endif
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += imxrt_autoleds.c
else

View file

@ -1,77 +0,0 @@
/****************************************************************************
* boards/arm/imxrt/imxrt1020-evk/src/imxrt_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "imxrt1020-evk.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return imxrt_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -20,18 +20,13 @@
#
# ##############################################################################
set(SRCS imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c)
set(SRCS imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
imxrt_bringup.c)
if(CONFIG_IMXRT_SDRAMC)
list(APPEND SRCS imxrt_sdram.c)
endif()
if(CONFIG_BOARDCTL)
list(APPEND SRCS imxrt_appinit.c imxrt_bringup.c)
elseif(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS imxrt_bringup.c)
endif()
if(CONFIG_ARCH_LEDS)
list(APPEND SRCS imxrt_autoleds.c)
else()

View file

@ -23,17 +23,12 @@
include $(TOPDIR)/Make.defs
CSRCS = imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
CSRCS += imxrt_bringup.c
ifeq ($(CONFIG_IMXRT_SDRAMC),y)
CSRCS += imxrt_sdram.c
endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += imxrt_appinit.c imxrt_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += imxrt_bringup.c
endif
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += imxrt_autoleds.c
else

View file

@ -1,77 +0,0 @@
/****************************************************************************
* boards/arm/imxrt/imxrt1050-evk/src/imxrt_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "imxrt1050-evk.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return imxrt_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -20,18 +20,13 @@
#
# ##############################################################################
set(SRCS imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c)
set(SRCS imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
imxrt_bringup.c)
if(CONFIG_IMXRT_SDRAMC)
list(APPEND SRCS imxrt_sdram.c)
endif()
if(CONFIG_BOARDCTL)
list(APPEND SRCS imxrt_appinit.c imxrt_bringup.c)
elseif(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS imxrt_bringup.c)
endif()
if(CONFIG_ARCH_LEDS)
list(APPEND SRCS imxrt_autoleds.c)
else()

View file

@ -23,17 +23,12 @@
include $(TOPDIR)/Make.defs
CSRCS = imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
CSRCS += imxrt_bringup.c
ifeq ($(CONFIG_IMXRT_SDRAMC),y)
CSRCS += imxrt_sdram.c
endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += imxrt_appinit.c imxrt_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += imxrt_bringup.c
endif
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += imxrt_autoleds.c
else

View file

@ -1,90 +0,0 @@
/****************************************************************************
* boards/arm/imxrt/imxrt1060-evk/src/imxrt_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <syslog.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include <nuttx/leds/userled.h>
#include "imxrt1060-evk.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#if !defined(CONFIG_ARCH_LEDS) && defined(CONFIG_USERLED_LOWER)
/* Register the LED driver */
int ret;
ret = userled_lower_initialize(LED_DRIVER_PATH);
if (ret < 0)
{
syslog(LOG_ERR, "ERROR: userled_lower_initialize() failed: %d\n", ret);
return ret;
}
#endif
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return imxrt_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -26,8 +26,12 @@
#include <nuttx/config.h>
#include <syslog.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include <arch/board/board.h>
#include <nuttx/leds/userled.h>
#include "imxrt_start.h"
#include "imxrt1060-evk.h"
@ -112,6 +116,17 @@ void imxrt_boardinitialize(void)
#ifdef CONFIG_BOARD_LATE_INITIALIZE
void board_late_initialize(void)
{
#if !defined(CONFIG_ARCH_LEDS) && defined(CONFIG_USERLED_LOWER)
/* Register the LED driver */
int ret;
ret = userled_lower_initialize(LED_DRIVER_PATH);
if (ret < 0)
{
syslog(LOG_ERR, "ERROR: userled_lower_initialize() failed: %d\n", ret);
}
#endif
/* Perform board initialization */
imxrt_bringup();

View file

@ -20,18 +20,13 @@
#
# ##############################################################################
set(SRCS imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c)
set(SRCS imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
imxrt_bringup.c)
if(CONFIG_IMXRT_SDRAMC)
list(APPEND SRCS imxrt_sdram.c)
endif()
if(CONFIG_BOARDCTL)
list(APPEND SRCS imxrt_appinit.c imxrt_bringup.c)
elseif(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS imxrt_bringup.c)
endif()
if(CONFIG_ARCH_LEDS)
list(APPEND SRCS imxrt_autoleds.c)
else()

View file

@ -23,17 +23,12 @@
include $(TOPDIR)/Make.defs
CSRCS = imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
CSRCS += imxrt_bringup.c
ifeq ($(CONFIG_IMXRT_SDRAMC),y)
CSRCS += imxrt_sdram.c
endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += imxrt_appinit.c imxrt_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += imxrt_bringup.c
endif
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += imxrt_autoleds.c
else

View file

@ -1,90 +0,0 @@
/****************************************************************************
* boards/arm/imxrt/imxrt1064-evk/src/imxrt_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <syslog.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include <nuttx/leds/userled.h>
#include "imxrt1064-evk.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#if !defined(CONFIG_ARCH_LEDS) && defined(CONFIG_USERLED_LOWER)
/* Register the LED driver */
int ret;
ret = userled_lower_initialize(LED_DRIVER_PATH);
if (ret < 0)
{
syslog(LOG_ERR, "ERROR: userled_lower_initialize() failed: %d\n", ret);
return ret;
}
#endif
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return imxrt_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -26,8 +26,12 @@
#include <nuttx/config.h>
#include <syslog.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include <arch/board/board.h>
#include <nuttx/leds/userled.h>
#include "imxrt_start.h"
#include "imxrt1064-evk.h"
@ -112,6 +116,17 @@ void imxrt_boardinitialize(void)
#ifdef CONFIG_BOARD_LATE_INITIALIZE
void board_late_initialize(void)
{
#if !defined(CONFIG_ARCH_LEDS) && defined(CONFIG_USERLED_LOWER)
/* Register the LED driver */
int ret;
ret = userled_lower_initialize(LED_DRIVER_PATH);
if (ret < 0)
{
syslog(LOG_ERR, "ERROR: userled_lower_initialize() failed: %d\n", ret);
}
#endif
/* Perform board initialization */
imxrt_bringup();

View file

@ -21,18 +21,12 @@
# ##############################################################################
set(SRCS imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
imxrt_clockconfig.c)
imxrt_clockconfig.c imxrt_bringup.c)
if(CONFIG_IMXRT_SDRAMC)
list(APPEND SRCS imxrt_sdram.c)
endif()
if(CONFIG_BOARDCTL)
list(APPEND SRCS imxrt_appinit.c imxrt_bringup.c)
elseif(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS imxrt_bringup.c)
endif()
if(CONFIG_ARCH_LEDS)
list(APPEND SRCS imxrt_autoleds.c)
else()

View file

@ -23,18 +23,12 @@
include $(TOPDIR)/Make.defs
CSRCS = imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
CSRCS += imxrt_clockconfig.c
CSRCS += imxrt_clockconfig.c imxrt_bringup.c
ifeq ($(CONFIG_IMXRT_SDRAMC),y)
CSRCS += imxrt_sdram.c
endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += imxrt_appinit.c imxrt_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += imxrt_bringup.c
endif
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += imxrt_autoleds.c
else

View file

@ -1,90 +0,0 @@
/****************************************************************************
* boards/arm/imxrt/imxrt1170-evk/src/imxrt_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <syslog.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include <nuttx/leds/userled.h>
#include "imxrt1170-evk.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#if !defined(CONFIG_ARCH_LEDS) && defined(CONFIG_USERLED_LOWER)
/* Register the LED driver */
int ret;
ret = userled_lower_initialize(LED_DRIVER_PATH);
if (ret < 0)
{
syslog(LOG_ERR, "ERROR: userled_lower_initialize() failed: %d\n", ret);
return ret;
}
#endif
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return imxrt_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -26,8 +26,12 @@
#include <nuttx/config.h>
#include <syslog.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include <arch/board/board.h>
#include <nuttx/leds/userled.h>
#include "imxrt_start.h"
#include "imxrt1170-evk.h"
@ -124,6 +128,17 @@ void imxrt_boardinitialize(void)
#ifdef CONFIG_BOARD_LATE_INITIALIZE
void board_late_initialize(void)
{
#if !defined(CONFIG_ARCH_LEDS) && defined(CONFIG_USERLED_LOWER)
/* Register the LED driver */
int ret;
ret = userled_lower_initialize(LED_DRIVER_PATH);
if (ret < 0)
{
syslog(LOG_ERR, "ERROR: userled_lower_initialize() failed: %d\n", ret);
}
#endif
/* Perform board initialization */
imxrt_bringup();

View file

@ -20,13 +20,8 @@
#
# ##############################################################################
set(SRCS imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS imxrt_appinit.c imxrt_bringup.c)
elseif(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS imxrt_bringup.c)
endif()
set(SRCS imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
imxrt_bringup.c)
if(CONFIG_BOARDCTL_RESET)
list(APPEND SRCS imxrt_reset.c)

View file

@ -23,12 +23,7 @@
include $(TOPDIR)/Make.defs
CSRCS = imxrt_boot.c imxrt_flexspi_nor_boot.c imxrt_flexspi_nor_flash.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += imxrt_appinit.c imxrt_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += imxrt_bringup.c
endif
ifeq ($(CONFIG_BOARDCTL_RESET),y)
CSRCS += imxrt_reset.c

View file

@ -1,98 +0,0 @@
/****************************************************************************
* boards/arm/imxrt/teensy-4.x/src/imxrt_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <syslog.h>
#include <nuttx/board.h>
#include <nuttx/leds/userled.h>
#include "teensy-4.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
int ret;
#if !defined(CONFIG_ARCH_LEDS) && defined(CONFIG_USERLED_LOWER)
/* Register the LED driver */
ret = userled_lower_initialize(LED_DRIVER_PATH);
if (ret < 0)
{
syslog(LOG_ERR, "ERROR: userled_lower_initialize() failed: %d\n", ret);
return ret;
}
#endif
#if defined(CONFIG_IMXRT_LPSPI1) || defined(CONFIG_IMXRT_LPSPI2) || \
defined(CONFIG_IMXRT_LPSPI3) || defined(CONFIG_IMXRT_LPSPI4)
imxrt_spidev_initialize();
#endif
# ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return imxrt_bringup();
# else
return OK;
# endif
UNUSED(ret);
}
#endif /* CONFIG_BOARDCTL */

View file

@ -26,8 +26,12 @@
#include <nuttx/config.h>
#include <sys/types.h>
#include <syslog.h>
#include <nuttx/board.h>
#include <arch/board/board.h>
#include <nuttx/leds/userled.h>
#include "imxrt_start.h"
#include "teensy-4.h"
@ -113,8 +117,24 @@ void imxrt_boardinitialize(void)
#ifdef CONFIG_BOARD_LATE_INITIALIZE
void board_late_initialize(void)
{
/* Perform board initialization */
int ret;
#if !defined(CONFIG_ARCH_LEDS) && defined(CONFIG_USERLED_LOWER)
/* Register the LED driver */
ret = userled_lower_initialize(LED_DRIVER_PATH);
if (ret < 0)
{
syslog(LOG_ERR, "ERROR: userled_lower_initialize() failed: %d\n", ret);
}
#endif
#if defined(CONFIG_IMXRT_LPSPI1) || defined(CONFIG_IMXRT_LPSPI2) || \
defined(CONFIG_IMXRT_LPSPI3) || defined(CONFIG_IMXRT_LPSPI4)
imxrt_spidev_initialize();
#endif
imxrt_bringup();
UNUSED(ret);
}
#endif /* CONFIG_BOARD_LATE_INITIALIZE */

View file

@ -22,10 +22,6 @@
set(SRCS k28_boot.c k28_bringup.c k28_spi.c k28_i2c.c)
if(CONFIG_BOARDCTL)
list(APPEND SRCS k28_appinit.c)
endif()
# If the RGB driver is not enabled, then treat the RGB as 3 LEDs
if(NOT CONFIG_RGBLED)

View file

@ -24,10 +24,6 @@ include $(TOPDIR)/Make.defs
CSRCS = k28_boot.c k28_bringup.c k28_spi.c k28_i2c.c
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += k28_appinit.c
endif
# If the RGB driver is not enabled, then treat the RGB as 3 LEDs
ifneq ($(CONFIG_RGBLED),y)

View file

@ -1,85 +0,0 @@
/****************************************************************************
* boards/arm/kinetis/freedom-k28f/src/k28_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <syslog.h>
#include <nuttx/board.h>
#include "kinetis_usbotg.h"
#include "freedom-k28f.h"
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#ifdef CONFIG_BOARD_LATE_INITIALIZE
/* Board initialization already performed by board_late_initialize() */
return OK;
#else
/* Perform board-specific initialization */
return k28_bringup();
#endif
}

View file

@ -20,7 +20,7 @@
#
# ##############################################################################
set(SRCS k64_boot.c k64_spi.c)
set(SRCS k64_boot.c k64_spi.c k64_bringup.c)
if(CONFIG_ARCH_LEDS)
list(APPEND SRCS k64_autoleds.c)
@ -32,12 +32,6 @@ if(CONFIG_ARCH_BUTTONS)
list(APPEND SRCS k64_buttons.c)
endif()
if(CONFIG_BOARDCTL)
list(APPEND SRCS k64_appinit.c k64_bringup.c)
elseif(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS k64_bringup.c)
endif()
if(CONFIG_I2C)
list(APPEND SRCS k64_i2c.c)
endif()

View file

@ -22,7 +22,7 @@
include $(TOPDIR)/Make.defs
CSRCS = k64_boot.c k64_spi.c
CSRCS = k64_bringup.c k64_boot.c k64_spi.c
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += k64_autoleds.c
@ -34,12 +34,6 @@ ifeq ($(CONFIG_ARCH_BUTTONS),y)
CSRCS += k64_buttons.c
endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += k64_appinit.c k64_bringup.c
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += k64_bringup.c
endif
ifeq ($(CONFIG_I2C),y)
CSRCS += k64_i2c.c
endif

View file

@ -260,9 +260,7 @@ void weak_function k64_usbinitialize(void);
*
****************************************************************************/
#if defined(CONFIG_BOARDCTL) || defined(CONFIG_BOARD_LATE_INITIALIZE)
int k64_bringup(void);
#endif
/****************************************************************************
* Name: k64_sdhc_initialize

View file

@ -1,77 +0,0 @@
/****************************************************************************
* boards/arm/kinetis/freedom-k64f/src/k64_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "freedom-k64f.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return k64_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -73,8 +73,7 @@
int board_usbmsc_initialize(int port)
{
/* If system/usbmsc is built as an NSH command, then SD slot should
* already have been initialized in board_app_initialize()
* (see k64_appinit.c).
* already have been initialized.
* In this case, there is nothing further to be done here.
*/

View file

@ -20,7 +20,7 @@
#
# ##############################################################################
set(SRCS k66_boot.c k66_spi.c)
set(SRCS k66_boot.c k66_spi.c k66_bringup.c)
if(CONFIG_ARCH_LEDS)
list(APPEND SRCS k66_autoleds.c)
@ -32,13 +32,8 @@ if(CONFIG_ARCH_BUTTONS)
list(APPEND SRCS k66_buttons.c)
endif()
if(CONFIG_BOARDCTL)
list(APPEND SRCS k66_appinit.c k66_bringup.c)
if(CONFIG_BOARDCTL_RESET)
list(APPEND SRCS k66_reset.c)
endif()
elseif(CONFIG_BOARD_LATE_INITIALIZE)
list(APPEND SRCS k66_bringup.c)
if(CONFIG_BOARDCTL_RESET)
list(APPEND SRCS k66_reset.c)
endif()
if(CONFIG_KINETIS_SDHC)

View file

@ -22,7 +22,7 @@
include $(TOPDIR)/Make.defs
CSRCS = k66_boot.c k66_spi.c
CSRCS = k66_boot.c k66_spi.c k66_bringup.c
ifeq ($(CONFIG_ARCH_LEDS),y)
CSRCS += k66_autoleds.c
@ -34,14 +34,9 @@ ifeq ($(CONFIG_ARCH_BUTTONS),y)
CSRCS += k66_buttons.c
endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += k66_appinit.c k66_bringup.c
ifeq ($(CONFIG_BOARDCTL_RESET),y)
CSRCS += k66_reset.c
endif
else ifeq ($(CONFIG_BOARD_LATE_INITIALIZE),y)
CSRCS += k66_bringup.c
endif
ifeq ($(CONFIG_KINETIS_SDHC),y)
CSRCS += k66_sdhc.c

View file

@ -1,77 +0,0 @@
/****************************************************************************
* boards/arm/kinetis/freedom-k66f/src/k66_appinit.c
*
* SPDX-License-Identifier: Apache-2.0
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <sys/types.h>
#include <nuttx/board.h>
#include "freedom-k66f.h"
#ifdef CONFIG_BOARDCTL
/****************************************************************************
* Public Functions
****************************************************************************/
/****************************************************************************
* Name: board_app_initialize
*
* Description:
* Perform application specific initialization. This function is never
* called directly from application code, but only indirectly via the
* (non-standard) boardctl() interface using the command BOARDIOC_INIT.
*
* Input Parameters:
* arg - The boardctl() argument is passed to the board_app_initialize()
* implementation without modification. The argument has no
* meaning to NuttX; the meaning of the argument is a contract
* between the board-specific initialization logic and the
* matching application logic. The value could be such things as a
* mode enumeration value, a set of DIP switch switch settings, a
* pointer to configuration data read from a file or serial FLASH,
* or whatever you would like to do with it. Every implementation
* should accept zero/NULL as a default configuration.
*
* Returned Value:
* Zero (OK) is returned on success; a negated errno value is returned on
* any failure to indicate the nature of the failure.
*
****************************************************************************/
int board_app_initialize(uintptr_t arg)
{
#ifndef CONFIG_BOARD_LATE_INITIALIZE
/* Perform board initialization */
return k66_bringup();
#else
return OK;
#endif
}
#endif /* CONFIG_BOARDCTL */

View file

@ -73,8 +73,7 @@
int board_usbmsc_initialize(int port)
{
/* If system/usbmsc is built as an NSH command, then SD slot should
* already have been initialized in board_app_initialize()
* (see k66_appinit.c).
* already have been initialized.
* In this case, there is nothing further to be done here.
*/

View file

@ -30,10 +30,6 @@ if(CONFIG_ARCH_BUTTONS)
list(APPEND SRCS k40_buttons.c)
endif()
if(CONFIG_BOARDCTL)
list(APPEND SRCS k40_appinit.c)
endif()
if(CONFIG_USBDEV)
list(APPEND SRCS k40_usbdev.c)
endif()

View file

@ -32,10 +32,6 @@ ifeq ($(CONFIG_ARCH_BUTTONS),y)
CSRCS += k40_buttons.c
endif
ifeq ($(CONFIG_BOARDCTL),y)
CSRCS += k40_appinit.c
endif
ifeq ($(CONFIG_USBDEV),y)
CSRCS += k40_usbdev.c
endif

Some files were not shown because too many files have changed in this diff Show more