4.104.114.95
Last change
on this file since a3ddb08b was
a3ddb08b,
checked in by Joel Sherrill <joel.sherrill@…>, on 03/05/08 at 02:49:35
|
2008-03-04 Joel Sherrill <joel.sherrill@…>
- libmisc/Makefile.am, libmisc/shell/main_cp.c,
libmisc/shell/main_cpuuse.c, libmisc/shell/main_date.c,
libmisc/shell/main_mallocinfo.c, libmisc/shell/main_netstats.c,
libmisc/shell/main_perioduse.c, libmisc/shell/main_stackuse.c,
libmisc/shell/main_wkspaceinfo.c, libmisc/shell/print_heapinfo.c,
libmisc/shell/shell.c, libmisc/shell/shell.h,
libmisc/shell/shell_makeargs.c, libmisc/shell/shellconfig.c,
libmisc/shell/shellconfig.h, libmisc/shell/write_file.c: Add initial
capability to automatically execute a script from the filesystem. Add
echo command from NetBSD and sleep command.
- libmisc/shell/main_echo.c, libmisc/shell/main_sleep.c,
libmisc/shell/shell_script.c: New files.
|
-
Property mode set to
100644
|
File size:
1.3 KB
|
Line | |
---|
1 | /* |
---|
2 | * MALLOC_INFO Shell Command Implmentation |
---|
3 | * |
---|
4 | * COPYRIGHT (c) 1989-2008. |
---|
5 | * On-Line Applications Research Corporation (OAR). |
---|
6 | * |
---|
7 | * The license and distribution terms for this file may be |
---|
8 | * found in the file LICENSE in this distribution or at |
---|
9 | * http://www.rtems.com/license/LICENSE. |
---|
10 | * |
---|
11 | * $Id$ |
---|
12 | */ |
---|
13 | |
---|
14 | #define __RTEMS_VIOLATE_KERNEL_VISIBILITY__ |
---|
15 | #ifdef HAVE_CONFIG_H |
---|
16 | #include "config.h" |
---|
17 | #endif |
---|
18 | |
---|
19 | #include <inttypes.h> |
---|
20 | |
---|
21 | #include <rtems.h> |
---|
22 | #include <rtems/malloc.h> |
---|
23 | #include <rtems/shell.h> |
---|
24 | #include <rtems/score/protectedheap.h> |
---|
25 | #include "internal.h" |
---|
26 | |
---|
27 | int rtems_shell_main_wkspace_info( |
---|
28 | int argc, |
---|
29 | char *argv[] |
---|
30 | ) |
---|
31 | { |
---|
32 | Heap_Information_block info; |
---|
33 | extern void classinfo_tester(); |
---|
34 | |
---|
35 | _Protected_heap_Get_information( &_Workspace_Area, &info ); |
---|
36 | rtems_shell_print_heap_info( "free", &info.Free ); |
---|
37 | rtems_shell_print_heap_info( "used", &info.Used ); |
---|
38 | |
---|
39 | return 0; |
---|
40 | } |
---|
41 | |
---|
42 | rtems_shell_cmd_t rtems_shell_WKSPACE_INFO_Command = { |
---|
43 | "wkspace", /* name */ |
---|
44 | "Report on RTEMS Executive Workspace", /* usage */ |
---|
45 | "rtems", /* topic */ |
---|
46 | rtems_shell_main_wkspace_info, /* command */ |
---|
47 | NULL, /* alias */ |
---|
48 | NULL /* next */ |
---|
49 | }; |
---|
50 | |
---|
Note: See
TracBrowser
for help on using the repository browser.