Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

92 lines
2.2 KiB

  1. /*
  2. * sim32.h - Sim32 for Microsoft NT SoftPC include file.
  3. *
  4. * Ade Brownlow
  5. * Wed Jun 5 91
  6. *
  7. * %W% %G% (c) Insignia Solutions 1991
  8. */
  9. /* Microsoft Sas memory map extension */
  10. typedef struct _IMEM
  11. {
  12. struct _IMEM *Next;
  13. sys_addr StartAddress;
  14. sys_addr EndAddress;
  15. half_word Type;
  16. } IMEMBLOCK, *PIMEMBLOCK;
  17. /* structures for passing our registers about */
  18. typedef union
  19. {
  20. word x;
  21. struct
  22. {
  23. half_word l;
  24. half_word h;
  25. } byte;
  26. } REG;
  27. typedef struct _VDMREG
  28. {
  29. /* registers */
  30. REG SS,SP;
  31. } VDMREG;
  32. //
  33. // Constants
  34. //
  35. #define MSW_PE 0x1
  36. UCHAR *Sim32pGetVDMPointer(ULONG addr, UCHAR pm);
  37. #define Sim32GetVDMPointer(Addr,Size,Mode) Sim32pGetVDMPointer(Addr,Mode)
  38. #ifdef MONITOR
  39. #include <monsim32.h>
  40. #else
  41. /********************************************************/
  42. #ifdef ANSI
  43. /* Sas/gmi Sim32 crossovers */
  44. extern BOOL Sim32FlushVDMPointer (double_word, word, UTINY *, BOOL);
  45. extern BOOL Sim32FreeVDMPointer (double_word, word, UTINY *, BOOL);
  46. extern BOOL Sim32GetVDMMemory (double_word, word, UTINY *, BOOL);
  47. extern BOOL Sim32SetVDMMemory (double_word, word, UTINY *, BOOL);
  48. /* Sim32 cpu crossovers */
  49. extern VDMREG *EnterIdle(void);
  50. extern void LeaveIdle(void);
  51. /* Sim32 cpu idle interrupt handler should only be called by the event manager */
  52. extern void Sim32_cpu_stall(int);
  53. /* Microsoft sas extensions */
  54. extern IMEMBLOCK *sas_mem_map(void);
  55. extern void sas_clear_map(void);
  56. #else /*ANSI*/
  57. /* Sas/gmi Sim32 crossovers */
  58. extern BOOL Sim32FlushVDMPointer ();
  59. extern BOOL Sim32FreeVDMPointer ();
  60. extern BOOL Sim32GetVDMMemory ();
  61. extern BOOL Sim32SetVDMMemory ();
  62. /* Sim32 cpu crossovers */
  63. extern VDMREG *EnterIdle();
  64. extern void LeaveIdle();
  65. /* Sim32 cpu idle interrupt handler should only be called by the event manager */
  66. extern void Sim32_cpu_stall();
  67. #endif /* ANSI */
  68. /* Microsoft sas extensions */
  69. extern IMEMBLOCK *sas_mem_map ();
  70. extern void sas_clear_map();
  71. #endif /* MONITOR */
  72. /* This flag is used to signal that the cpu has gone idle due to a call to EnterIdle */
  73. extern BOOL cpu_flagged_idle;
  74. extern sys_addr sim32_effective_addr(double_word, BOOL);