rthw.h 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. /*
  2. * File : rthw.h
  3. * This file is part of RT-Thread RTOS
  4. * COPYRIGHT (C) 2006, 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://openlab.rt-thread.com/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, void *parameter,
  31. rt_uint8_t *stack_addr, void *exit);
  32. void rt_hw_interrupt_init(void);
  33. void rt_hw_interrupt_mask(int vector);
  34. void rt_hw_interrupt_umask(int vector);
  35. void rt_hw_interrupt_install(int vector, rt_isr_handler_t new_handler, rt_isr_handler_t *old_handler);
  36. void rt_hw_interrupt_handle(int vector);
  37. rt_base_t rt_hw_interrupt_disable(void);
  38. void rt_hw_interrupt_enable(rt_base_t level);
  39. void rt_hw_context_switch(rt_uint32_t from, rt_uint32_t to);
  40. void rt_hw_context_switch_to(rt_uint32_t to);
  41. void rt_hw_context_switch_interrupt(rt_uint32_t from, rt_uint32_t to);
  42. void rt_hw_console_output(const char* str);
  43. void rt_hw_backtrace(rt_uint32_t *fp, rt_uint32_t thread_entry);
  44. void rt_hw_show_memory(rt_uint32_t addr, rt_uint32_t size);
  45. #ifdef __cplusplus
  46. }
  47. #endif
  48. #endif