symbol.c 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. /*
  2. * File : symbol.c
  3. * This file is part of RT-Thread RTOS
  4. * COPYRIGHT (C) 2006 - 2010, RT-Thread Development Team
  5. *
  6. * The license and distribution terms for this file may be
  7. * found in the file LICENSE in this distribution or at
  8. * http://www.rt-thread.org/license/LICENSE
  9. *
  10. * Change Logs:
  11. * Date Author Notes
  12. * 2010-03-22 Bernard first version
  13. */
  14. #include "finsh.h"
  15. long hello(void);
  16. long version(void);
  17. long list(void);
  18. long list_thread(void);
  19. long list_sem(void);
  20. long list_mutex(void);
  21. long list_fevent(void);
  22. long list_event(void);
  23. long list_mailbox(void);
  24. long list_msgqueue(void);
  25. long list_mempool(void);
  26. long list_timer(void);
  27. #ifdef FINSH_USING_SYMTAB
  28. struct finsh_syscall *_syscall_table_begin = NULL;
  29. struct finsh_syscall *_syscall_table_end = NULL;
  30. struct finsh_sysvar *_sysvar_table_begin = NULL;
  31. struct finsh_sysvar *_sysvar_table_end = NULL;
  32. #else
  33. struct finsh_syscall _syscall_table[] =
  34. {
  35. {"hello", hello},
  36. {"version", version},
  37. {"list", list},
  38. {"list_thread", list_thread},
  39. #ifdef RT_USING_SEMAPHORE
  40. {"list_sem", list_sem},
  41. #endif
  42. #ifdef RT_USING_MUTEX
  43. {"list_mutex", list_mutex},
  44. #endif
  45. #ifdef RT_USING_FEVENT
  46. {"list_fevent", list_fevent},
  47. #endif
  48. #ifdef RT_USING_EVENT
  49. {"list_event", list_event},
  50. #endif
  51. #ifdef RT_USING_MAILBOX
  52. {"list_mb", list_mailbox},
  53. #endif
  54. #ifdef RT_USING_MESSAGEQUEUE
  55. {"list_mq", list_msgqueue},
  56. #endif
  57. #ifdef RT_USING_MEMPOOL
  58. {"list_memp", list_mempool},
  59. #endif
  60. {"list_timer", list_timer},
  61. };
  62. struct finsh_syscall *_syscall_table_begin = &_syscall_table[0];
  63. struct finsh_syscall *_syscall_table_end = &_syscall_table[sizeof(_syscall_table) / sizeof(struct finsh_syscall)];
  64. struct finsh_sysvar *_sysvar_table_begin = NULL;
  65. struct finsh_sysvar *_sysvar_table_end = NULL;
  66. #endif