rthw.h 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. /*
  2. * File : rthw.h
  3. * This file is part of RT-Thread RTOS
  4. * COPYRIGHT (C) 2006 - 2012, 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. * 2006-03-18 Bernard the first version
  13. * 2006-04-25 Bernard add rt_hw_context_switch_interrupt declaration
  14. * 2006-09-24 Bernard add rt_hw_context_switch_to declaration
  15. */
  16. #ifndef __RT_HW_H__
  17. #define __RT_HW_H__
  18. #include <rtthread.h>
  19. #ifdef __cplusplus
  20. extern "C" {
  21. #endif
  22. void rt_hw_cpu_icache_enable(void);
  23. void rt_hw_cpu_icache_disable(void);
  24. rt_base_t rt_hw_cpu_icache_status(void);
  25. void rt_hw_cpu_dcache_enable(void);
  26. void rt_hw_cpu_dcache_disable(void);
  27. rt_base_t rt_hw_cpu_dcache_status(void);
  28. void rt_hw_cpu_reset(void);
  29. void rt_hw_cpu_shutdown(void);
  30. rt_uint8_t *rt_hw_stack_init(void *entry,
  31. void *parameter,
  32. rt_uint8_t *stack_addr,
  33. void *exit);
  34. void rt_hw_interrupt_init(void);
  35. void rt_hw_interrupt_mask(int vector);
  36. void rt_hw_interrupt_umask(int vector);
  37. void rt_hw_interrupt_install(int vector,
  38. rt_isr_handler_t new_handler,
  39. rt_isr_handler_t *old_handler);
  40. void rt_hw_interrupt_handle(int vector);
  41. rt_base_t rt_hw_interrupt_disable(void);
  42. void rt_hw_interrupt_enable(rt_base_t level);
  43. void rt_hw_context_switch(rt_uint32_t from, rt_uint32_t to);
  44. void rt_hw_context_switch_to(rt_uint32_t to);
  45. void rt_hw_context_switch_interrupt(rt_uint32_t from, rt_uint32_t to);
  46. void rt_hw_console_output(const char *str);
  47. void rt_hw_backtrace(rt_uint32_t *fp, rt_uint32_t thread_entry);
  48. void rt_hw_show_memory(rt_uint32_t addr, rt_uint32_t size);
  49. #ifdef __cplusplus
  50. }
  51. #endif
  52. #endif