]> git.saurik.com Git - apple/xnu.git/blobdiff - osfmk/i386/commpage/commpage.h
xnu-4903.221.2.tar.gz
[apple/xnu.git] / osfmk / i386 / commpage / commpage.h
index a39d47b4628b4e32174d8f70ad3ffeada99fbbd6..e4a2c7ac36fed989922940df98efec578a7175ff 100644 (file)
@@ -106,6 +106,14 @@ COMMPAGE_DESCRIPTOR_NAME(label) ## :                               ;\
 
 #define UNIQUEID(name) L ## name
 
+/* COMMPAGE_JMP(target,from,start)
+ *
+ * This macro perform a jump to another commpage routine.
+ * Used to return from the PFZ by jumping via a return outside the PFZ.
+ */
+#define COMMPAGE_JMP(target,from,start)                                \
+       jmp      L ## start - from + target
+
 #else /* __ASSEMBLER__ */
 
 /* Each potential commpage routine is described by one of these.
@@ -134,17 +142,21 @@ typedef   volatile struct commpage_time_data      {
        uint64_t        gtod_sec_base;                          // _COMM_PAGE_GTOD_SEC_BASE
 } commpage_time_data;
 
-
 extern char    *commPagePtr32;                         // virt address of 32-bit commpage in kernel map
 extern char    *commPagePtr64;                         // ...and of 64-bit commpage
 
-extern void    commpage_set_timestamp(uint64_t abstime, uint64_t secs);
-extern void    commpage_disable_timestamp( void );
+extern  void   commpage_set_timestamp(uint64_t abstime, uint64_t sec, uint64_t frac, uint64_t scale, uint64_t tick_per_sec);
+#define commpage_disable_timestamp() commpage_set_timestamp( 0, 0, 0, 0, 0 );
 extern  void   commpage_set_nanotime(uint64_t tsc_base, uint64_t ns_base, uint32_t scale, uint32_t shift);
 extern void    commpage_set_memory_pressure(unsigned int  pressure);
 extern void    commpage_set_spin_count(unsigned int  count);
 extern void    commpage_sched_gen_inc(void);
 extern void    commpage_update_active_cpus(void);
+extern void    commpage_update_mach_approximate_time(uint64_t abstime);
+extern  void   commpage_update_mach_continuous_time(uint64_t sleeptime);
+extern  void   commpage_update_boottime(uint64_t boottime_usec);
+extern void    commpage_update_kdebug_state(void);
+extern void    commpage_update_atm_diagnostic_config(uint32_t);
 
 extern uint32_t        commpage_is_in_pfz32(uint32_t);
 extern uint32_t        commpage_is_in_pfz64(addr64_t);