04-05-2014 05:16 AM
Hello every body,
I am trying ton run two tasks (one on the fisrt CPU other on the second) under FreeRTOS or Linux. I have installed FreeRTOS on the Zynq. I have tested it by running 2 tasks on one CPU and it ok.
But i don't how to share both CPU.
Via SDK i create a project (using ps7_cortexa9_0) than another one (using ps7_cortexa9_1) and in the main of each one i create my tasks. How to link between each projetc ? i mean how to link between each task in each Core ?
Thanks a lot
04-05-2014 06:41 AM
04-07-2014 01:39 AM
Thaks for your reply.
But what i want to do is a sample SMP architecture. I mean a single OS to utilize both cores and scedule 2 tasks for example on both cores.
04-07-2014 05:25 AM
If you run Linux on the zynq, it will automatically allocate tasks to CPUs as it sees fit. It will do a better job than manually assigning tasks to cores, even though it allows you to bind tasks to cores if you insist.
04-09-2014 01:25 AM
But how bind tasks to core ? I mean i want to choose the core that will contain the task is it possible to do that ?
04-09-2014 08:41 AM
Sounds like you want to set processor affinity. Do a google search for the C functions or command line options.
04-10-2014 02:23 AM
Just google on "cpu affinity".
Be aware that manually assigning threads to CPUs will invariably result in lower performance. Don't do it - unless there's a very specific reason that you know better than the OS how to schedule processes.
I'm very curious to what you are trying to accomplish. Please tell us why you think you can do better than the Linux scheduler!