From 2614239fe46277179b9b56681bc8b80c1d61c03f Mon Sep 17 00:00:00 2001 From: Robin Mueller Date: Tue, 27 Sep 2022 09:27:40 +0200 Subject: [PATCH] this should work for the same chip/copy as well --- bsp_q7s/core/CoreController.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/bsp_q7s/core/CoreController.cpp b/bsp_q7s/core/CoreController.cpp index ab54e94c..210e1a20 100644 --- a/bsp_q7s/core/CoreController.cpp +++ b/bsp_q7s/core/CoreController.cpp @@ -206,6 +206,9 @@ ReturnValue_t CoreController::executeAction(ActionId_t actionId, MessageQueueId_ case (OBSW_UPDATE_FROM_SD_1): { return executeSwUpdate(SwUpdateSources::SD_1, data, size); } + case (OBSW_UPDATE_FROM_TMP): { + return executeSwUpdate(SwUpdateSources::TMP_DIR, data, size); + } case (SWITCH_IMG_LOCK): { if (size != 3) { return HasActionsIF::INVALID_PARAMETERS; @@ -1894,10 +1897,6 @@ ReturnValue_t CoreController::executeSwUpdate(SwUpdateSources sourceDir, const u } sif::info << "Executing SW update for Chip " << static_cast(data[0]) << " Copy " << static_cast(data[1]) << " from " << sourceStr << std::endl; - if (chip == CURRENT_CHIP and copy == CURRENT_COPY) { - // Not allowed / possible. TODO: Dedicated returnvalue? - return returnvalue::FAILED; - } path prefixPath; if (sourceDir == SwUpdateSources::SD_0) { prefixPath = path(config::SD_0_MOUNT_POINT);