diff options
author | Joel Sherrill <joel.sherrill@oarcorp.com> | 2014-05-26 12:46:20 -0500 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@oarcorp.com> | 2014-05-26 12:46:20 -0500 |
commit | e340e9652d1586fd6990f8bb5119c1c14e332385 (patch) | |
tree | f4f5f1a43787ac9b9a8fc62e4d858cf4c35ecd4c /schedsim/shell/schedsim_smpsimple | |
parent | configure.ac: Generate config.h (diff) | |
download | rtems-schedsim-e340e9652d1586fd6990f8bb5119c1c14e332385.tar.bz2 |
current_cpu is now a shared SMP command
Diffstat (limited to 'schedsim/shell/schedsim_smpsimple')
-rw-r--r-- | schedsim/shell/schedsim_smpsimple/Makefile.am | 1 | ||||
-rw-r--r-- | schedsim/shell/schedsim_smpsimple/add_commands.c | 9 | ||||
-rw-r--r-- | schedsim/shell/schedsim_smpsimple/main_current_cpu.c | 46 |
3 files changed, 0 insertions, 56 deletions
diff --git a/schedsim/shell/schedsim_smpsimple/Makefile.am b/schedsim/shell/schedsim_smpsimple/Makefile.am index d85d554..a7c7237 100644 --- a/schedsim/shell/schedsim_smpsimple/Makefile.am +++ b/schedsim/shell/schedsim_smpsimple/Makefile.am @@ -2,7 +2,6 @@ bin_PROGRAMS = schedsim_smpsimple schedsim_smpsimple_SOURCES = schedsim_smpsimple_SOURCES += add_commands.c schedsim_smpsimple_SOURCES += config.c -schedsim_smpsimple_SOURCES += main_current_cpu.c schedsim_smpsimple_SOURCES += main_dispatch.c schedsim_smpsimple_SOURCES += main_dump_ready_tasks.c schedsim_smpsimple_SOURCES += printheir_executing.c diff --git a/schedsim/shell/schedsim_smpsimple/add_commands.c b/schedsim/shell/schedsim_smpsimple/add_commands.c index ad1dde2..f975da7 100644 --- a/schedsim/shell/schedsim_smpsimple/add_commands.c +++ b/schedsim/shell/schedsim_smpsimple/add_commands.c @@ -18,7 +18,6 @@ #include "rtems_sched.h" extern int main_dump_ready_tasks(int argc, char **argv); -extern int main_set_current_cpu(int argc, char **argv); extern int main_dispatch(int argc, char **argv); void add_commands(void) @@ -34,14 +33,6 @@ void add_commands(void) assert( cmd ); cmd = rtems_shell_add_cmd( - "current_cpu", - "rtems", - "number", - main_set_current_cpu - ); - assert( cmd ); - - cmd = rtems_shell_add_cmd( "dispatch", "rtems", "", diff --git a/schedsim/shell/schedsim_smpsimple/main_current_cpu.c b/schedsim/shell/schedsim_smpsimple/main_current_cpu.c deleted file mode 100644 index 8a4a6cc..0000000 --- a/schedsim/shell/schedsim_smpsimple/main_current_cpu.c +++ /dev/null @@ -1,46 +0,0 @@ -/* - * COPYRIGHT (c) 1989-2013. - * On-Line Applications Research Corporation (OAR). - * - * The license and distribution terms for this file may be - * found in the file LICENSE in this distribution or at - * http://www.rtems.com/license/LICENSE. - */ - -#include <newlib/getopt.h> -#include <stdio.h> -#include <stdlib.h> -#include <string.h> -#include <ctype.h> - -#include "shell.h" -#include "rtems_sched.h" - -#include <rtems.h> -#include <rtems/score/percpu.h> -#include <rtems/score/schedulerpriority.h> -#include <rtems/stringto.h> - -extern uint32_t Schedsim_Current_cpu; - -int main_set_current_cpu(int argc, char **argv) -{ - long cpu; - - if ( argc >= 2 ) { - if ( rtems_string_to_long(argv[1], &cpu, NULL, 0) ) { - printf( "CPU argument (%s) is not a number\n", argv[1] ); - return -1; - } - printf( - "Changing current CPU from %d to %d\n", - Schedsim_Current_cpu, - cpu - ); - Schedsim_Current_cpu = cpu; - } else { - printf( "Current CPU is %d\n", Schedsim_Current_cpu ); - } - - return 0; -} |