PiyushPatle26 commented on code in PR #18907: URL: https://github.com/apache/nuttx/pull/18907#discussion_r3293811797
########## boards/arm64/am62x/beagleplay/src/beagleplay_appinit.c: ########## @@ -0,0 +1,69 @@ +/**************************************************************************** + * boards/arm64/am62x/beagleplay/src/beagleplay_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 "beagleplay.h" + +#ifdef CONFIG_BOARDCTL + +/**************************************************************************** + * Public Functions + ****************************************************************************/ + +/**************************************************************************** + * Name: board_app_initialize + * + * Description: + * Called indirectly through boardctl(BOARDIOC_INIT) from the NSH start-up + * code. This is the application-level initialisation hook — it runs in + * task context (not interrupt context) with the scheduler fully running. + * + * When CONFIG_BOARD_LATE_INITIALIZE is set, beagleplay_bringup() has + * already been called from board_late_initialize() so we return OK + * immediately. Otherwise we call it here. + * + * Input Parameters: + * arg - boardctl() argument (unused for BOARDIOC_INIT) + * + * Returned Value: + * Zero (OK) on success; a negated errno on failure. + * + ****************************************************************************/ + +int board_app_initialize(uintptr_t arg) +{ + UNUSED(arg); + +#ifndef CONFIG_BOARD_LATE_INITIALIZE + return beagleplay_bringup(); +#else + return OK; +#endif +} + Review Comment: Removed this deprecated interface. I switched the AM62x boards to use `board_late_initialize()` only and validated the updated branch on current main with local builds for beagleplay:{nsh,ostest} and pocketbeagle2:{nsh,ostest}. Will perform boot test and update the PR soon -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
