cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Adventurer
Adventurer
1,034 Views
Registered: ‎06-14-2018

multiple tasks in echo test SDK 2018.3

Jump to solution

Hi all,

The OpenAMP demos have a big change in SDK 2018.3 compare to previous. It makes my app which has multiple/parallel tasks stop working, because the poll function requests the core to sleep (https://github.com/Xilinx/embeddedsw/blob/release-2018.3/lib/sw_apps/openamp_echo_test/src/machine/zynqmp_r5/platform_info.c#L392). My application is based on FreeRTOS.

So, do you have any idea to add more tasks into echo test example? Thank you.

0 Kudos
1 Solution

Accepted Solutions
Highlighted
Adventurer
Adventurer
970 Views
Registered: ‎06-14-2018

Re: multiple tasks in echo test SDK 2018.3

Jump to solution

I found it myself.

The echo_test (same with other OpenAMP demos) will disable the FreeRTOS task scheduler because of re-initialize GIC (code here: https://github.com/Xilinx/embeddedsw/blob/release-2018.3/lib/sw_apps/openamp_echo_test/src/system/freertos/machine/zynqmp_r5/helper.c#L23). So the FreeRTOS task scheduler will not work. Solution is update the app_gic_initialize() function to make it compatible with FreeRTOS task scheduler GIC setup.

View solution in original post

0 Kudos
4 Replies
Highlighted
Adventurer
Adventurer
971 Views
Registered: ‎06-14-2018

Re: multiple tasks in echo test SDK 2018.3

Jump to solution

I found it myself.

The echo_test (same with other OpenAMP demos) will disable the FreeRTOS task scheduler because of re-initialize GIC (code here: https://github.com/Xilinx/embeddedsw/blob/release-2018.3/lib/sw_apps/openamp_echo_test/src/system/freertos/machine/zynqmp_r5/helper.c#L23). So the FreeRTOS task scheduler will not work. Solution is update the app_gic_initialize() function to make it compatible with FreeRTOS task scheduler GIC setup.

View solution in original post

0 Kudos
Observer
Observer
820 Views
Registered: ‎08-31-2017

Re: multiple tasks in echo test SDK 2018.3

Jump to solution

I have trouble with this problem.

Could you tell me how to update the app_gic_initialize() function to make compatible with FreeRTOS task scheduler GIC setup?

0 Kudos
Highlighted
Adventurer
Adventurer
816 Views
Registered: ‎06-14-2018

Re: multiple tasks in echo test SDK 2018.3

Jump to solution

Hi @shinya,

You can replace this code https://github.com/Xilinx/embeddedsw/blob/release-2018.3/lib/sw_apps/openamp_echo_test/src/system/freertos/machine/zynqmp_r5/helper.c#L20-L77 by below:

extern XScuGic xInterruptController;

/* Interrupt Controller setup */
static int app_gic_initialize(void)
{
	/* Connect Interrupt ID with ISR */
	XScuGic_Connect(&xInterruptController, IPI_IRQ_VECT_ID,
			(Xil_ExceptionHandler)metal_irq_isr,
			(void *)IPI_IRQ_VECT_ID);

	return 0;
}
Highlighted
Observer
Observer
803 Views
Registered: ‎08-31-2017

Re: multiple tasks in echo test SDK 2018.3

Jump to solution

Hi, @nvl1109.

Thank you for your quick response. I can solve this problem!

 

0 Kudos