commit 5efaeef02639e962b23931373c67efde1b23124d
Author: Nikhil Dasan <n-dasan@ti.com>
Date:   Wed Aug 2 13:55:01 2023 +0530

    A72 Target Vision_apps
    
    Signed-off-by: Nikhil Dasan <n-dasan@ti.com>

diff --git a/apps/basic_demos/app_linux_target_init/concerto.mak b/apps/basic_demos/app_linux_target_init/concerto.mak
new file mode 100644
index 0000000..c8e3a69
--- /dev/null
+++ b/apps/basic_demos/app_linux_target_init/concerto.mak
@@ -0,0 +1,18 @@
+ifeq ($(TARGET_CPU),A72)
+ifeq ($(TARGET_OS), $(filter $(TARGET_OS), LINUX QNX))
+
+include $(PRELUDE)
+
+TARGETTYPE  := exe
+TARGET      := vx_app_A72target_init
+CSOURCES    := main_linux_arm.c
+
+IDIRS := $(VISION_APPS_PATH)/kernels/img_proc/include
+IDIRS += $(CUSTOM_KERNEL_PATH)/hwa/include
+
+include $(VISION_APPS_PATH)/apps/concerto_a72_inc.mak
+
+include $(FINALE)
+
+endif
+endif
diff --git a/apps/basic_demos/app_linux_target_init/main_linux_arm.c b/apps/basic_demos/app_linux_target_init/main_linux_arm.c
new file mode 100644
index 0000000..103333a
--- /dev/null
+++ b/apps/basic_demos/app_linux_target_init/main_linux_arm.c
@@ -0,0 +1,104 @@
+/*
+ *
+ * Copyright (c) 2017 Texas Instruments Incorporated
+ *
+ * All rights reserved not granted herein.
+ *
+ * Limited License.
+ *
+ * Texas Instruments Incorporated grants a world-wide, royalty-free, non-exclusive
+ * license under copyrights and patents it now or hereafter owns or controls to make,
+ * have made, use, import, offer to sell and sell ("Utilize") this software subject to the
+ * terms herein.  With respect to the foregoing patent license, such license is granted
+ * solely to the extent that any such patent is necessary to Utilize the software alone.
+ * The patent license shall not apply to any combinations which include this software,
+ * other than combinations with devices manufactured by or for TI ("TI Devices").
+ * No hardware patent is licensed hereunder.
+ *
+ * Redistributions must preserve existing copyright notices and reproduce this license
+ * (including the above copyright notice and the disclaimer and (if applicable) source
+ * code license limitations below) in the documentation and/or other materials provided
+ * with the distribution
+ *
+ * Redistribution and use in binary form, without modification, are permitted provided
+ * that the following conditions are met:
+ *
+ * *       No reverse engineering, decompilation, or disassembly of this software is
+ * permitted with respect to any software provided in binary form.
+ *
+ * *       any redistribution and use are licensed by TI for use only with TI Devices.
+ *
+ * *       Nothing shall obligate TI to provide you with source code for the software
+ * licensed and provided to you in object code.
+ *
+ * If software source code is provided to you, modification and redistribution of the
+ * source code are permitted provided that the following conditions are met:
+ *
+ * *       any redistribution and use of the source code, including any resulting derivative
+ * works, are licensed by TI for use only with TI Devices.
+ *
+ * *       any redistribution and use of any object code compiled from the source code
+ * and any resulting derivative works, are licensed by TI for use only with TI Devices.
+ *
+ * Neither the name of Texas Instruments Incorporated nor the names of its suppliers
+ *
+ * may be used to endorse or promote products derived from this software without
+ * specific prior written permission.
+ *
+ * DISCLAIMER.
+ *
+ * THIS SOFTWARE IS PROVIDED BY TI AND TI'S LICENSORS "AS IS" AND ANY EXPRESS
+ * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL TI AND TI'S LICENSORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+ * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+ * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
+ * OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ */
+
+#include <stdio.h>
+#include <utils/app_init/include/app_init.h>
+#include <TI/tivx_img_proc.h>
+#include <TI/tivx_task.h>
+#include<tivx_hwa_kernels.h>
+#include <utils/remote_service/include/app_remote_service.h>
+#include <utils/ipc/include/app_ipc.h>
+#include <utils/console_io/include/app_log.h>
+
+int main(int argc, char *argv[])
+{
+    int status = 0;
+    uint8_t  cmdPrm = 0;
+    
+    status = appInit();
+    tivxRegisterImgProcTargetA72Kernels();
+    tivxRegisterHwaTargetA72Kernels();
+
+    status = appIpcSendNotify(APP_IPC_CPU_MCU2_0, 0xDEAD0000);
+    status|= appIpcSendNotify(APP_IPC_CPU_C6x_1, 0xDEAD0000);
+    printf("APP IPC: Waiting for message to get echoed from remote core...\n");
+    appLogWaitMsecs(500);
+    printf("APP IPC: ... Done.\n");
+
+    if(status==0)
+    {
+        printf("A72 Target initialized\n");
+        appRemoteServiceRun(APP_IPC_CPU_MCU2_0, "A72_target_init", 0, &cmdPrm, sizeof(cmdPrm), 0);
+        printf("Remote service Sent\n");
+    } 
+    else
+    {
+        printf("App Init Failed\n");
+    }
+
+    while(1)
+    {
+        tivxTaskWaitMsecs(1000);
+    }
+    
+    return status;
+}
diff --git a/apps/basic_demos/app_multi_cam/concerto.mak b/apps/basic_demos/app_multi_cam/concerto.mak
index b24b0fc..573c4a5 100755
--- a/apps/basic_demos/app_multi_cam/concerto.mak
+++ b/apps/basic_demos/app_multi_cam/concerto.mak
@@ -36,7 +36,7 @@ endif
 
 
 ifeq ($(TARGET_CPU),R5F)
-ifeq ($(TARGET_OS), FREERTOS)
+ifeq ($(TARGET_OS),$(filter $(TARGET_OS), FREERTOS SAFERTOS))
 
 include $(PRELUDE)
 
diff --git a/apps/basic_demos/app_multi_cam/main.c b/apps/basic_demos/app_multi_cam/main.c
index 38070b5..81fea07 100755
--- a/apps/basic_demos/app_multi_cam/main.c
+++ b/apps/basic_demos/app_multi_cam/main.c
@@ -63,7 +63,9 @@
 #include <utils/draw2d/include/draw2d.h>
 #include <utils/perf_stats/include/app_perf_stats.h>
 #include <utils/console_io/include/app_get.h>
+#ifndef TIOVX_HOST_R5F
 #include <utils/grpx/include/app_grpx.h>
+#endif
 #include <utils/hwa/include/app_hwa_api.h>
 #include <VX/vx_khr_pipelining.h>
 
@@ -161,8 +163,9 @@ static void app_pipeline_params_defaults(AppObj *obj);
 static void add_graph_parameter_by_node_index(vx_graph graph, vx_node node, vx_uint32 node_parameter_index);
 static vx_int32 calc_grid_size(vx_uint32 ch);
 static void set_img_mosaic_params(ImgMosaicObj *imgMosaicObj, vx_uint32 in_width, vx_uint32 in_height, vx_int32 numCh, ObjArrSplitObj *objArrSplitObj, int32_t enable_split_graph);
+#ifndef TIOVX_HOST_R5F
 static void app_draw_graphics(Draw2D_Handle *handle, Draw2D_BufInfo *draw2dBufInfo, uint32_t update_type);
-
+#endif
 #ifndef TIOVX_HOST_R5F
 static void app_show_usage(vx_int32 argc, vx_char* argv[])
 {
@@ -664,6 +667,12 @@ vx_int32 app_multi_cam_main(vx_int32 argc, vx_char* argv[])
 #ifndef TIOVX_HOST_R5F
     /*Config parameter reading*/
     app_parse_cmd_line_args(obj, argc, argv);
+#else
+    obj->objArrSplitObj.num_outputs = 2;
+    obj->objArrSplitObj.output0_num_elements = 0;
+    obj->objArrSplitObj.output1_num_elements = 0;
+    obj->objArrSplitObj.output2_num_elements = 0;
+    obj->objArrSplitObj.output3_num_elements = 0;
 #endif
 
     /* Querry sensor parameters */
@@ -752,7 +761,9 @@ vx_int32 app_multi_cam_main(vx_int32 argc, vx_char* argv[])
 static vx_status app_init(AppObj *obj)
 {
     vx_status status = VX_SUCCESS;
+#ifndef TIOVX_HOST_R5F
     app_grpx_init_prms_t grpx_prms;
+#endif
 
     if (1U == obj->enable_configure_hwa_freq)
     {
@@ -855,11 +866,11 @@ static vx_status app_init(AppObj *obj)
         status = app_init_display(obj->context, &obj->displayObj, "display_obj");
         APP_PRINTF("Display init done!\n");
     }
-
+#ifndef TIOVX_HOST_R5F
     appGrpxInitParamsInit(&grpx_prms, obj->context);
     grpx_prms.draw_callback = app_draw_graphics;
     appGrpxInit(&grpx_prms);
-
+#endif
     appPerfPointSetName(&obj->total_perf , "TOTAL");
     appPerfPointSetName(&obj->fileio_perf, "FILEIO");
     return status;
@@ -921,9 +932,9 @@ static void app_deinit(AppObj *obj)
 
     app_deinit_display(&obj->displayObj);
     APP_PRINTF("Display deinit done!\n");
-
+#ifndef TIOVX_HOST_R5F
     appGrpxDeInit();
-
+#endif
     tivxHwaUnLoadKernels(obj->context);
     tivxImagingUnLoadKernels(obj->context);
     tivxFileIOUnLoadKernels(obj->context);
@@ -1639,7 +1650,7 @@ static void add_graph_parameter_by_node_index(vx_graph graph, vx_node node, vx_u
     vxAddParameterToGraph(graph, parameter);
     vxReleaseParameter(&parameter);
 }
-
+#ifndef TIOVX_HOST_R5F
 static void app_draw_graphics(Draw2D_Handle *handle, Draw2D_BufInfo *draw2dBufInfo, uint32_t update_type)
 {
     appGrpxDrawDefault(handle, draw2dBufInfo, update_type);
@@ -1654,3 +1665,4 @@ static void app_draw_graphics(Draw2D_Handle *handle, Draw2D_BufInfo *draw2dBufIn
 
   return;
 }
+#endif
\ No newline at end of file
diff --git a/kernels/img_proc/a72/vx_img_hist_target.c b/kernels/img_proc/a72/vx_img_hist_target.c
index c35ebcd..7621cea 100644
--- a/kernels/img_proc/a72/vx_img_hist_target.c
+++ b/kernels/img_proc/a72/vx_img_hist_target.c
@@ -67,6 +67,7 @@
 #include <TI/tivx_target_kernel.h>
 #include "tivx_kernels_target_utils.h"
 #include "tivx_img_hist_host.h"
+#include <utils/ipc/src/app_ipc_linux_priv.h>
 
 #if defined(SOC_AM62A)
 #define NUM_A72_TARGETS (1)
@@ -115,6 +116,7 @@ static vx_status VX_CALLBACK tivxKernelImgHistProcess(
         dst = (tivx_obj_desc_distribution_t *)obj_desc[TIVX_KERNEL_IMG_HIST_DISTRIBUTION_IDX];
 
         src_target_ptr[0] = tivxMemShared2TargetPtr(&src->mem_ptr[0]);
+
         dst_target_ptr = tivxMemShared2TargetPtr(&dst->mem_ptr);
 
         tivxMemBufferMap(src_target_ptr[0], src->mem_size[0],
@@ -125,7 +127,13 @@ static vx_status VX_CALLBACK tivxKernelImgHistProcess(
         tivxSetPointerLocation(src, src_target_ptr, src_addr);
         tivxInitBufParams(src, vxlib_src);
 
+        #ifdef TIOVX_HOST_R5F
+        for(int x=0; x<dst->mem_size/sizeof(vx_int32); x++){
+            *((uint32_t *)dst_target_ptr + x)=0;
+        }
+        #else
         memset(dst_target_ptr, 0, dst->mem_size);
+        #endif
 
         status = (vx_status)VXLIB_histogram_i8u_o32u_cn(src_addr[0], &vxlib_src[0],
                 dst_target_ptr, (uint8_t)dst->offset, (uint16_t)dst->range, (uint16_t)dst->num_bins);
@@ -216,10 +224,12 @@ vx_status VXLIB_histogram_i8u_o32u_cn(uint8_t src[],
 
     uint32_t  x, y;
 
+    #ifndef TIOVX_HOST_R5F
     for( x = 0; x < numBins; x++ )
     {
         dist[x] = 0;
     }
+    #endif
 
     for( y=0; y < src_addr->dim_y; y++ )
     {
diff --git a/modules/src/concerto.mak b/modules/src/concerto.mak
index 800cba7..00f0931 100755
--- a/modules/src/concerto.mak
+++ b/modules/src/concerto.mak
@@ -30,7 +30,7 @@ include $(FINALE)
 endif
 
 ifeq ($(TARGET_CPU), R5F)
-ifeq ($(TARGET_OS), FREERTOS)
+ifeq ($(TARGET_OS),$(filter $(TARGET_OS), FREERTOS SAFERTOS))
 
 include $(PRELUDE)
 
diff --git a/platform/j721e/rtos/common/app_run.c b/platform/j721e/rtos/common/app_run.c
index ada41d1..7fa4366 100755
--- a/platform/j721e/rtos/common/app_run.c
+++ b/platform/j721e/rtos/common/app_run.c
@@ -74,10 +74,42 @@
 #include <ti/drv/uart/UART.h>
 #include <ti/drv/uart/UART_stdio.h>
 
+#ifdef TIOVX_HOST_R5F
+#include <TI/tivx_event.h>
+#include <utils/remote_service/include/app_remote_service.h>
+#endif
+
 #if defined(ENABLE_TIOVX_HOST)
 int app_single_cam_main(int argc, char* argv[]);
 int app_multi_cam_main(int argc, char* argv[]);
 
+#ifdef TIOVX_HOST_R5F
+static tivx_event glock;
+
+static int32_t appA72TargetInitHandler(char *service_name, uint32_t cmd, void *prm, uint32_t prm_size, uint32_t flags)
+{
+    tivxEventPost(glock);
+    printf("Event posted\n");
+    return 0;
+}
+
+static int32_t app_A72_TargetInit_Register()
+{
+    vx_status status;
+    status = appRemoteServiceRegister("A72_target_init", appA72TargetInitHandler);
+    if(status == VX_SUCCESS)
+    {
+       printf("A72_target_init registered\n");
+       status = tivxEventCreate(&glock);
+       if(status == VX_SUCCESS)
+       {
+           printf("A72 target event Created\n");
+       }
+    }
+    return status;
+}
+#endif
+
 #ifndef TIOVX_HOST_R5F
 char vx_tutorial_get_char()
 {
@@ -269,9 +301,24 @@ void appMenuMain()
         appCliShowPrompt(&is_exit);
     }
 #else
-    // vx_tutorial_run_interactive();
-    app_single_cam_main(0,NULL);
-    // app_multi_cam_main(0,NULL);
+    vx_status status;
+    status = app_A72_TargetInit_Register();
+    if(status == VX_SUCCESS)
+    {
+       printf("Entering wait state\n");
+       status = tivxEventWait(glock, TIVX_EVENT_TIMEOUT_WAIT_FOREVER);
+       if(status == VX_SUCCESS)
+       {
+            // vx_tutorial_run_interactive();
+            // app_single_cam_main(0,NULL);
+            app_multi_cam_main(0,NULL);
+        }
+    }
+    status = tivxEventDelete(&glock);
+    if(status == VX_SUCCESS)
+    {
+       printf("Event Deleted\n");
+    }
 #endif
 }
 
diff --git a/platform/j721e/rtos/mcu2_0/concerto_mcu2_0_inc.mak b/platform/j721e/rtos/mcu2_0/concerto_mcu2_0_inc.mak
index fa7da80..fff841a 100755
--- a/platform/j721e/rtos/mcu2_0/concerto_mcu2_0_inc.mak
+++ b/platform/j721e/rtos/mcu2_0/concerto_mcu2_0_inc.mak
@@ -19,7 +19,11 @@ endif
 
 ifeq ($(RTOS),SAFERTOS)
 	CSOURCES += $(SOC)_safertos_mpu_cfg.c
-	LINKER_CMD_FILES +=  $($(_MODULE)_SDIR)/$(SOC)_linker_safertos.cmd
+	ifeq ($(TIOVX_HOST_R5F),yes)
+		LINKER_CMD_FILES +=  $($(_MODULE)_SDIR)/$(SOC)_linker_host_safertos.cmd
+	else
+		LINKER_CMD_FILES +=  $($(_MODULE)_SDIR)/$(SOC)_linker_safertos.cmd
+	endif
 endif
 
 LINKER_CMD_FILES +=  $($(_MODULE)_SDIR)/linker_mem_map.cmd
diff --git a/platform/j721e/rtos/mcu2_0/j721e_linker_host_safertos.cmd b/platform/j721e/rtos/mcu2_0/j721e_linker_host_safertos.cmd
new file mode 100644
index 0000000..05f7548
--- /dev/null
+++ b/platform/j721e/rtos/mcu2_0/j721e_linker_host_safertos.cmd
@@ -0,0 +1,122 @@
+/*=========================*/
+/*     Linker Settings     */
+/*=========================*/
+
+--retain="*(.rstvectors)"
+--retain="*(.bootCode)"
+--retain="*(.startupCode)"
+--retain="*(.startupData)"
+--retain="*(.intvecs)"
+--retain="*(.intc_text)"
+--retain="*(.rstvectors)"
+--retain="*(.safeRTOSrstvectors)"
+--retain="*(.irqStack)"
+--retain="*(.fiqStack)"
+--retain="*(.abortStack)"
+--retain="*(.undStack)"
+--retain="*(.svcStack)"
+
+--fill_value=0
+--diag_suppress=10063                   /* entry point not _c_int00 */
+--stack_size=0x8000
+--heap_size=0x10000
+--entry_point=_axSafeRTOSresetVectors     /* C RTS boot.asm with added SVC handler	*/
+
+-stack  0x8000  /* SOFTWARE STACK SIZE */
+-heap   0x10000 /* HEAP AREA SIZE      */
+
+/*-------------------------------------------*/
+/*       Stack Sizes for various modes       */
+/*-------------------------------------------*/
+__IRQ_STACK_SIZE   = 0x1000;
+__FIQ_STACK_SIZE   = 0x1000;
+__ABORT_STACK_SIZE = 0x1000;
+__UND_STACK_SIZE   = 0x1000;
+__SVC_STACK_SIZE   = 0x1000;
+
+/*----------------------------------------------------------------------------*/
+/* Section Configuration                                                      */
+
+SECTIONS
+{
+    GROUP
+    {
+        .safeRTOSrstvectors                                 : {} palign(8)
+        .rstvectors                                         : {} palign(8)
+    } > R5F_TCMA_VECS
+    GROUP
+    {
+        .bootCode                                               : {} palign( 8 )
+        .startupCode                                            : {} palign( 8 )
+        .pinit                                                  : {} align( 32 )
+        .MPU_INIT_FUNCTION                                      : {} palign( 8 )
+        .startupData                                            : {} palign( 8 ), type = NOINIT
+    } > R5F_TCMA
+
+    .cinit                                                  : {} align( 32 ) > DDR_MCU2_0
+
+    .data_buffer     : {} palign(128)    > DDR_MCU2_0
+
+    /* USB or any other LLD buffer for benchmarking */
+    .benchmark_buffer (NOLOAD) {} ALIGN (8) > DDR_MCU2_0
+    
+    .resource_table          :
+    {
+        __RESOURCE_TABLE = .;
+    }                                           > DDR_MCU2_0_RESOURCE_TABLE
+
+    GROUP LOAD_START( lnkFlashStartAddr ), LOAD_END( lnkFlashEndAddr )
+    {
+        .KERNEL_FUNCTION LOAD_START( lnkKernelFuncStartAddr ),
+                         LOAD_END( lnkKernelFuncEndAddr )       : {} palign( 0x10000 )
+    } > DDR_MCU2_0
+
+    .unpriv_flash palign( 0x10000 ) :
+    {
+        *(.text)
+        *(.rodata)
+    } > DDR_MCU2_0
+
+    intercore_eth_desc_mem (NOLOAD) : {} palign(128) > INTERCORE_ETH_DESC_MEM
+    intercore_eth_data_mem (NOLOAD) : {} palign(128) > INTERCORE_ETH_DATA_MEM
+
+    .tracebuf                : {} align(1024)   > DDR_MCU2_0
+
+    .bss:l3mem              (NOLOAD) : {} > MAIN_OCRAM_MCU2_0
+    .bss:ddr_local_mem      (NOLOAD) : {} > DDR_SHARED_MEM
+    .bss:app_log_mem        (NOLOAD) : {} > APP_LOG_MEM
+    .bss:tiovx_obj_desc_mem (NOLOAD) : {} > TIOVX_OBJ_DESC_MEM
+    .bss:ipc_vring_mem      (NOLOAD) : {} > IPC_VRING_MEM
+
+   /* Data sections. */
+    GROUP  palign( 0x10000 ), LOAD_START( lnkRamStartAddr ), LOAD_END( lnkRamEndAddr )
+    {
+        .bss                                                    : {} align( 4 )
+        .far                                                    : {} align( 4 )
+        .data                                                   : {} palign( 128 )
+        .boardcfg_data                                          : {} palign( 128 )
+        .sysmem                                                 : {}
+        .bss.devgroup*                                          : {} align( 4 )
+        .bss:taskStackSection                                   : {}
+        .const.devgroup*                                        : {} align( 4 )
+        .KERNEL_DATA LOAD_START( lnkKernelDataStartAddr ),
+                     LOAD_END( lnkKernelDataEndAddr )           : {} palign( 0x800 )
+     /* Stack sections. */
+        .stack  RUN_START( lnkStacksStartAddr ) : {}                            align(4)
+        .irqStack                               : {. = . + __IRQ_STACK_SIZE;}   align(4)
+        RUN_START(__IRQ_STACK_START)
+        RUN_END(__IRQ_STACK_END)
+        .fiqStack                               : {. = . + __FIQ_STACK_SIZE;}   align(4)
+        RUN_START(__FIQ_STACK_START)
+        RUN_END(__FIQ_STACK_END)
+        .abortStack                             : {. = . + __ABORT_STACK_SIZE;} align(4)
+        RUN_START(__ABORT_STACK_START)
+        RUN_END(__ABORT_STACK_END)
+        .undStack                               : {. = . + __UND_STACK_SIZE;}   align(4)
+        RUN_START(__UND_STACK_START)
+        RUN_END(__UND_STACK_END)
+        .svcStack    END( lnkStacksEndAddr )    : {. = . + __SVC_STACK_SIZE;}   align(4)
+        RUN_START(__SVC_STACK_START)
+        RUN_END(__SVC_STACK_END)
+    } > DDR_MCU2_0   (HIGH)
+}
diff --git a/utils/app_init/src/app_init.c b/utils/app_init/src/app_init.c
index 8a3556d..daa042b 100644
--- a/utils/app_init/src/app_init.c
+++ b/utils/app_init/src/app_init.c
@@ -98,7 +98,9 @@ int32_t appInit()
     if (status == 0)
     {
         tivxInit();
+#ifndef TIOVX_HOST_R5F
         tivxHostInit();
+#endif
     }
 
     return status;
@@ -107,8 +109,9 @@ int32_t appInit()
 int32_t appDeInit()
 {
     int32_t status;
-
+#ifndef TIOVX_HOST_R5F
     tivxHostDeInit();
+#endif
     tivxDeInit();
 
     status = appCommonDeInit();
diff --git a/utils/grpx/src/concerto.mak b/utils/grpx/src/concerto.mak
index 3191cf0..055bd86 100644
--- a/utils/grpx/src/concerto.mak
+++ b/utils/grpx/src/concerto.mak
@@ -1,5 +1,5 @@
 ifneq ($(TARGET_PLATFORM),PC)
-ifeq ($(TARGET_OS),$(filter $(TARGET_OS),LINUX QNX FREERTOS))
+ifeq ($(TARGET_OS),$(filter $(TARGET_OS),LINUX QNX FREERTOS SAFERTOS))
 
 include $(PRELUDE)
 TARGET      := app_utils_grpx
diff --git a/utils/ipc/src/app_ipc_rtos.c b/utils/ipc/src/app_ipc_rtos.c
index 5d910e6..3cd8995 100755
--- a/utils/ipc/src/app_ipc_rtos.c
+++ b/utils/ipc/src/app_ipc_rtos.c
@@ -135,6 +135,10 @@ __attribute__ ((section(".bss:taskStackSection")))
 __attribute__ ((aligned(APP_IPC_RPMESSAGE_CTRL_TASK_ALIGNMENT)))
     ;
 
+#ifdef TIOVX_HOST_R5F
+uint32_t gA72port_id = 0U;
+#endif
+
 #if defined(FREERTOS) || defined(SAFERTOS)
 
 typedef struct
@@ -318,6 +322,12 @@ static void appIpcRpmsgRxHandler(RPMessage_Handle rpmsg_handle,
         if((payload & 0xFFFF0000) == 0xDEAD0000)
         {
             /* echo this message back to src */
+            #ifdef TIOVX_HOST_R5F
+           if (app_cpu_id == APP_IPC_CPU_MPU1_0)
+           {
+               gA72port_id = src_endpt;
+           }
+           #endif
             appIpcSendNotifyPort(app_cpu_id, payload, src_endpt);
         }
         else
@@ -751,6 +761,13 @@ int32_t appIpcSendNotify(uint32_t dest_cpu_id, uint32_t payload)
 
     if( (dest_cpu_id<APP_IPC_CPU_MAX) && (obj->rpmsg_tx_handle[dest_cpu_id] != NULL))
     {
+        #ifdef TIOVX_HOST_R5F
+       if (dest_cpu_id == APP_IPC_CPU_MPU1_0)
+       {
+           status = appIpcSendNotifyPort(dest_cpu_id, payload, gA72port_id);
+           return status;
+       }
+       #endif
         status = appIpcSendNotifyPort(dest_cpu_id, payload,
             (uint32_t)obj->prm.tiovx_rpmsg_port_id);
     }
diff --git a/utils/mem/include/app_mem.h b/utils/mem/include/app_mem.h
index cd186f6..88c396c 100755
--- a/utils/mem/include/app_mem.h
+++ b/utils/mem/include/app_mem.h
@@ -69,6 +69,8 @@
 extern "C" {
 #endif
 
+extern void *PHY_VIRT_ADDR_OFFSET;
+
 /**
  * \defgroup group_vision_apps_utils_mem Memory allocation APIs
  *
diff --git a/utils/mem/src/app_mem_linux_dma_heap.c b/utils/mem/src/app_mem_linux_dma_heap.c
index 0d03345..83a6237 100755
--- a/utils/mem/src/app_mem_linux_dma_heap.c
+++ b/utils/mem/src/app_mem_linux_dma_heap.c
@@ -77,6 +77,7 @@
 #include <linux/dma-heap.h>
 #include <linux/dma-buf.h>
 #include <app_mem_map.h>
+#include <utils/ipc/src/app_ipc_linux_priv.h>
 
 /*MACROS*/
 /* #define APP_MEM_DEBUG */
@@ -87,6 +88,9 @@
 #endif
 #define DMA_HEAP_ALLOC_FLAGS   (0u)
 
+/*Global Variables*/
+void *PHY_VIRT_ADDR_OFFSET;
+
 /*STRUCTURES*/
 
 typedef struct
@@ -129,6 +133,7 @@ void appMemRemoveFromList(app_mem_list_t **list, app_mem_list_t *node);
 int  appMemPushToList(app_mem_list_t **list, app_mem_type_t *data);
 int  appMemDmaHeapGetPhys(int phys_fd, int fd, uint64_t *phys);
 void appMemFreeList(app_mem_list_t *list);
+void mem_Mapping_DDR_Shared_to_virt_offset();
 static int32_t appMemAddTupleToList(uint32_t dmaBufFd, uint32_t size, uint64_t *virtPtr, uint64_t *phyPtr);
 
 int32_t appMemInit(app_mem_init_prm_t *prm)
@@ -153,7 +158,9 @@ int32_t appMemInit(app_mem_init_prm_t *prm)
     pthread_mutex_init(&obj->list_mutex, NULL);
 
     printf("MEM: Init ... !!!\n");
-
+#ifdef TIOVX_HOST_R5F
+    mem_Mapping_DDR_Shared_to_virt_offset();
+#else
     /* Initialize the DMA HEAP module */
     obj->dma_heap_fd = open(DMA_HEAP_NAME, O_RDONLY | O_CLOEXEC);
     if (obj->dma_heap_fd < 0)
@@ -166,6 +173,7 @@ int32_t appMemInit(app_mem_init_prm_t *prm)
         printf("MEM: Initialized DMA HEAP (fd=%d) !!!\n", obj->dma_heap_fd);
     }
 
+#endif
     printf("MEM: Init ... Done !!!\n");
 
     return(status);
@@ -790,4 +798,7 @@ static int32_t appMemAddTupleToList(uint32_t dmaBufFd, uint32_t size, uint64_t *
 
     return status;
 }
-
+void mem_Mapping_DDR_Shared_to_virt_offset(){
+    void *DDR_shared_addr_virt = appMemMap((void *)DDR_SHARED_MEM_ADDR, (uint32_t)DDR_SHARED_MEM_SIZE);
+    PHY_VIRT_ADDR_OFFSET = (DDR_shared_addr_virt - DDR_SHARED_MEM_ADDR);
+}
diff --git a/utils/remote_service/src/app_remote_service.c b/utils/remote_service/src/app_remote_service.c
index 97577aa..c11a381 100755
--- a/utils/remote_service/src/app_remote_service.c
+++ b/utils/remote_service/src/app_remote_service.c
@@ -74,7 +74,7 @@
 #define IPC_RPMESSAGE_OBJ_SIZE      (256u)
 #define IPC_RPMESSAGE_BUF_SIZE(n)   (IPC_RPMESSAGE_MSG_SIZE*(n)+IPC_RPMESSAGE_OBJ_SIZE)
 
-#define APP_REMOTE_SERVICE_HANDLERS_MAX  (  8u)
+#define APP_REMOTE_SERVICE_HANDLERS_MAX  (  9u)
 
 
 #define APP_REMOTE_SERVICE_RPMSG_TX_NUM_BUF   (1u)
