aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/misc/sgi-gru/grulib.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/misc/sgi-gru/grulib.h')
-rw-r--r--drivers/misc/sgi-gru/grulib.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/drivers/misc/sgi-gru/grulib.h b/drivers/misc/sgi-gru/grulib.h
index 87586551d16f..c5865dd19eec 100644
--- a/drivers/misc/sgi-gru/grulib.h
+++ b/drivers/misc/sgi-gru/grulib.h
@@ -50,6 +50,9 @@
50/* For dumpping GRU chiplet state */ 50/* For dumpping GRU chiplet state */
51#define GRU_DUMP_CHIPLET_STATE _IOWR(GRU_IOCTL_NUM, 11, void *) 51#define GRU_DUMP_CHIPLET_STATE _IOWR(GRU_IOCTL_NUM, 11, void *)
52 52
53/* For getting gseg statistics */
54#define GRU_GET_GSEG_STATISTICS _IOWR(GRU_IOCTL_NUM, 12, void *)
55
53/* For user TLB flushing (primarily for tests) */ 56/* For user TLB flushing (primarily for tests) */
54#define GRU_USER_FLUSH_TLB _IOWR(GRU_IOCTL_NUM, 50, void *) 57#define GRU_USER_FLUSH_TLB _IOWR(GRU_IOCTL_NUM, 50, void *)
55 58
@@ -61,6 +64,21 @@
61 64
62#define CONTEXT_WINDOW_BYTES(th) (GRU_GSEG_PAGESIZE * (th)) 65#define CONTEXT_WINDOW_BYTES(th) (GRU_GSEG_PAGESIZE * (th))
63#define THREAD_POINTER(p, th) (p + GRU_GSEG_PAGESIZE * (th)) 66#define THREAD_POINTER(p, th) (p + GRU_GSEG_PAGESIZE * (th))
67#define GSEG_START(cb) ((void *)((unsigned long)(cb) & ~(GRU_GSEG_PAGESIZE - 1)))
68
69/*
70 * Statictics kept on a per-GTS basis.
71 */
72struct gts_statistics {
73 unsigned long fmm_tlbdropin;
74 unsigned long upm_tlbdropin;
75 unsigned long context_stolen;
76};
77
78struct gru_get_gseg_statistics_req {
79 unsigned long gseg;
80 struct gts_statistics stats;
81};
64 82
65/* 83/*
66 * Structure used to pass TLB flush parameters to the driver 84 * Structure used to pass TLB flush parameters to the driver