grutables.h 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545
  1. /*
  2. * SN Platform GRU Driver
  3. *
  4. * GRU DRIVER TABLES, MACROS, externs, etc
  5. *
  6. * Copyright (c) 2008 Silicon Graphics, Inc. All Rights Reserved.
  7. *
  8. * This program is free software; you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License as published by
  10. * the Free Software Foundation; either version 2 of the License, or
  11. * (at your option) any later version.
  12. *
  13. * This program is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with this program; if not, write to the Free Software
  20. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  21. */
  22. #ifndef __GRUTABLES_H__
  23. #define __GRUTABLES_H__
  24. /*
  25. * Tables:
  26. *
  27. * VDATA-VMA Data - Holds a few parameters. Head of linked list of
  28. * GTS tables for threads using the GSEG
  29. * GTS - Gru Thread State - contains info for managing a GSEG context. A
  30. * GTS is allocated for each thread accessing a
  31. * GSEG.
  32. * GTD - GRU Thread Data - contains shadow copy of GRU data when GSEG is
  33. * not loaded into a GRU
  34. * GMS - GRU Memory Struct - Used to manage TLB shootdowns. Tracks GRUs
  35. * where a GSEG has been loaded. Similar to
  36. * an mm_struct but for GRU.
  37. *
  38. * GS - GRU State - Used to manage the state of a GRU chiplet
  39. * BS - Blade State - Used to manage state of all GRU chiplets
  40. * on a blade
  41. *
  42. *
  43. * Normal task tables for task using GRU.
  44. * - 2 threads in process
  45. * - 2 GSEGs open in process
  46. * - GSEG1 is being used by both threads
  47. * - GSEG2 is used only by thread 2
  48. *
  49. * task -->|
  50. * task ---+---> mm ->------ (notifier) -------+-> gms
  51. * | |
  52. * |--> vma -> vdata ---> gts--->| GSEG1 (thread1)
  53. * | | |
  54. * | +-> gts--->| GSEG1 (thread2)
  55. * | |
  56. * |--> vma -> vdata ---> gts--->| GSEG2 (thread2)
  57. * .
  58. * .
  59. *
  60. * GSEGs are marked DONTCOPY on fork
  61. *
  62. * At open
  63. * file.private_data -> NULL
  64. *
  65. * At mmap,
  66. * vma -> vdata
  67. *
  68. * After gseg reference
  69. * vma -> vdata ->gts
  70. *
  71. * After fork
  72. * parent
  73. * vma -> vdata -> gts
  74. * child
  75. * (vma is not copied)
  76. *
  77. */
  78. #include <linux/rmap.h>
  79. #include <linux/interrupt.h>
  80. #include <linux/mutex.h>
  81. #include <linux/wait.h>
  82. #include <linux/mmu_notifier.h>
  83. #include "gru.h"
  84. #include "gruhandles.h"
  85. extern struct gru_stats_s gru_stats;
  86. extern struct gru_blade_state *gru_base[];
  87. extern unsigned long gru_start_paddr, gru_end_paddr;
  88. #define GRU_MAX_BLADES MAX_NUMNODES
  89. #define GRU_MAX_GRUS (GRU_MAX_BLADES * GRU_CHIPLETS_PER_BLADE)
  90. #define GRU_DRIVER_ID_STR "SGI GRU Device Driver"
  91. #define GRU_DRIVER_VERSION_STR "0.80"
  92. /*
  93. * GRU statistics.
  94. */
  95. struct gru_stats_s {
  96. atomic_long_t vdata_alloc;
  97. atomic_long_t vdata_free;
  98. atomic_long_t gts_alloc;
  99. atomic_long_t gts_free;
  100. atomic_long_t vdata_double_alloc;
  101. atomic_long_t gts_double_allocate;
  102. atomic_long_t assign_context;
  103. atomic_long_t assign_context_failed;
  104. atomic_long_t free_context;
  105. atomic_long_t load_context;
  106. atomic_long_t unload_context;
  107. atomic_long_t steal_context;
  108. atomic_long_t steal_context_failed;
  109. atomic_long_t nopfn;
  110. atomic_long_t break_cow;
  111. atomic_long_t asid_new;
  112. atomic_long_t asid_next;
  113. atomic_long_t asid_wrap;
  114. atomic_long_t asid_reuse;
  115. atomic_long_t intr;
  116. atomic_long_t call_os;
  117. atomic_long_t call_os_check_for_bug;
  118. atomic_long_t call_os_wait_queue;
  119. atomic_long_t user_flush_tlb;
  120. atomic_long_t user_unload_context;
  121. atomic_long_t user_exception;
  122. atomic_long_t set_task_slice;
  123. atomic_long_t migrate_check;
  124. atomic_long_t migrated_retarget;
  125. atomic_long_t migrated_unload;
  126. atomic_long_t migrated_unload_delay;
  127. atomic_long_t migrated_nopfn_retarget;
  128. atomic_long_t migrated_nopfn_unload;
  129. atomic_long_t tlb_dropin;
  130. atomic_long_t tlb_dropin_fail_no_asid;
  131. atomic_long_t tlb_dropin_fail_upm;
  132. atomic_long_t tlb_dropin_fail_invalid;
  133. atomic_long_t tlb_dropin_fail_range_active;
  134. atomic_long_t tlb_dropin_fail_idle;
  135. atomic_long_t tlb_dropin_fail_fmm;
  136. atomic_long_t mmu_invalidate_range;
  137. atomic_long_t mmu_invalidate_page;
  138. atomic_long_t mmu_clear_flush_young;
  139. atomic_long_t flush_tlb;
  140. atomic_long_t flush_tlb_gru;
  141. atomic_long_t flush_tlb_gru_tgh;
  142. atomic_long_t flush_tlb_gru_zero_asid;
  143. atomic_long_t copy_gpa;
  144. atomic_long_t mesq_receive;
  145. atomic_long_t mesq_receive_none;
  146. atomic_long_t mesq_send;
  147. atomic_long_t mesq_send_failed;
  148. atomic_long_t mesq_noop;
  149. atomic_long_t mesq_send_unexpected_error;
  150. atomic_long_t mesq_send_lb_overflow;
  151. atomic_long_t mesq_send_qlimit_reached;
  152. atomic_long_t mesq_send_amo_nacked;
  153. atomic_long_t mesq_send_put_nacked;
  154. atomic_long_t mesq_qf_not_full;
  155. atomic_long_t mesq_qf_locked;
  156. atomic_long_t mesq_qf_noop_not_full;
  157. atomic_long_t mesq_qf_switch_head_failed;
  158. atomic_long_t mesq_qf_unexpected_error;
  159. atomic_long_t mesq_noop_unexpected_error;
  160. atomic_long_t mesq_noop_lb_overflow;
  161. atomic_long_t mesq_noop_qlimit_reached;
  162. atomic_long_t mesq_noop_amo_nacked;
  163. atomic_long_t mesq_noop_put_nacked;
  164. };
  165. #define OPT_DPRINT 1
  166. #define OPT_STATS 2
  167. #define GRU_QUICKLOOK 4
  168. #define IRQ_GRU 110 /* Starting IRQ number for interrupts */
  169. /* Delay in jiffies between attempts to assign a GRU context */
  170. #define GRU_ASSIGN_DELAY ((HZ * 20) / 1000)
  171. /*
  172. * If a process has it's context stolen, min delay in jiffies before trying to
  173. * steal a context from another process.
  174. */
  175. #define GRU_STEAL_DELAY ((HZ * 200) / 1000)
  176. #define STAT(id) do { \
  177. if (options & OPT_STATS) \
  178. atomic_long_inc(&gru_stats.id); \
  179. } while (0)
  180. #ifdef CONFIG_SGI_GRU_DEBUG
  181. #define gru_dbg(dev, fmt, x...) \
  182. do { \
  183. if (options & OPT_DPRINT) \
  184. dev_dbg(dev, "%s: " fmt, __func__, x); \
  185. } while (0)
  186. #else
  187. #define gru_dbg(x...)
  188. #endif
  189. /*-----------------------------------------------------------------------------
  190. * ASID management
  191. */
  192. #define MAX_ASID 0xfffff0
  193. #define MIN_ASID 8
  194. #define ASID_INC 8 /* number of regions */
  195. /* Generate a GRU asid value from a GRU base asid & a virtual address. */
  196. #if defined CONFIG_IA64
  197. #define VADDR_HI_BIT 64
  198. #define GRUREGION(addr) ((addr) >> (VADDR_HI_BIT - 3) & 3)
  199. #elif defined __x86_64
  200. #define VADDR_HI_BIT 48
  201. #define GRUREGION(addr) (0) /* ZZZ could do better */
  202. #else
  203. #error "Unsupported architecture"
  204. #endif
  205. #define GRUASID(asid, addr) ((asid) + GRUREGION(addr))
  206. /*------------------------------------------------------------------------------
  207. * File & VMS Tables
  208. */
  209. struct gru_state;
  210. /*
  211. * This structure is pointed to from the mmstruct via the notifier pointer.
  212. * There is one of these per address space.
  213. */
  214. struct gru_mm_tracker {
  215. unsigned int mt_asid_gen; /* ASID wrap count */
  216. int mt_asid; /* current base ASID for gru */
  217. unsigned short mt_ctxbitmap; /* bitmap of contexts using
  218. asid */
  219. };
  220. struct gru_mm_struct {
  221. struct mmu_notifier ms_notifier;
  222. atomic_t ms_refcnt;
  223. spinlock_t ms_asid_lock; /* protects ASID assignment */
  224. atomic_t ms_range_active;/* num range_invals active */
  225. char ms_released;
  226. wait_queue_head_t ms_wait_queue;
  227. DECLARE_BITMAP(ms_asidmap, GRU_MAX_GRUS);
  228. struct gru_mm_tracker ms_asids[GRU_MAX_GRUS];
  229. };
  230. /*
  231. * One of these structures is allocated when a GSEG is mmaped. The
  232. * structure is pointed to by the vma->vm_private_data field in the vma struct.
  233. */
  234. struct gru_vma_data {
  235. spinlock_t vd_lock; /* Serialize access to vma */
  236. struct list_head vd_head; /* head of linked list of gts */
  237. long vd_user_options;/* misc user option flags */
  238. int vd_cbr_au_count;
  239. int vd_dsr_au_count;
  240. };
  241. /*
  242. * One of these is allocated for each thread accessing a mmaped GRU. A linked
  243. * list of these structure is hung off the struct gru_vma_data in the mm_struct.
  244. */
  245. struct gru_thread_state {
  246. struct list_head ts_next; /* list - head at vma-private */
  247. struct mutex ts_ctxlock; /* load/unload CTX lock */
  248. struct mm_struct *ts_mm; /* mm currently mapped to
  249. context */
  250. struct vm_area_struct *ts_vma; /* vma of GRU context */
  251. struct gru_state *ts_gru; /* GRU where the context is
  252. loaded */
  253. struct gru_mm_struct *ts_gms; /* asid & ioproc struct */
  254. unsigned long ts_cbr_map; /* map of allocated CBRs */
  255. unsigned long ts_dsr_map; /* map of allocated DATA
  256. resources */
  257. unsigned long ts_steal_jiffies;/* jiffies when context last
  258. stolen */
  259. long ts_user_options;/* misc user option flags */
  260. pid_t ts_tgid_owner; /* task that is using the
  261. context - for migration */
  262. int ts_tsid; /* thread that owns the
  263. structure */
  264. int ts_tlb_int_select;/* target cpu if interrupts
  265. enabled */
  266. int ts_ctxnum; /* context number where the
  267. context is loaded */
  268. atomic_t ts_refcnt; /* reference count GTS */
  269. unsigned char ts_dsr_au_count;/* Number of DSR resources
  270. required for contest */
  271. unsigned char ts_cbr_au_count;/* Number of CBR resources
  272. required for contest */
  273. char ts_force_unload;/* force context to be unloaded
  274. after migration */
  275. char ts_cbr_idx[GRU_CBR_AU];/* CBR numbers of each
  276. allocated CB */
  277. unsigned long ts_gdata[0]; /* save area for GRU data (CB,
  278. DS, CBE) */
  279. };
  280. /*
  281. * Threaded programs actually allocate an array of GSEGs when a context is
  282. * created. Each thread uses a separate GSEG. TSID is the index into the GSEG
  283. * array.
  284. */
  285. #define TSID(a, v) (((a) - (v)->vm_start) / GRU_GSEG_PAGESIZE)
  286. #define UGRUADDR(gts) ((gts)->ts_vma->vm_start + \
  287. (gts)->ts_tsid * GRU_GSEG_PAGESIZE)
  288. #define NULLCTX (-1) /* if context not loaded into GRU */
  289. /*-----------------------------------------------------------------------------
  290. * GRU State Tables
  291. */
  292. /*
  293. * One of these exists for each GRU chiplet.
  294. */
  295. struct gru_state {
  296. struct gru_blade_state *gs_blade; /* GRU state for entire
  297. blade */
  298. unsigned long gs_gru_base_paddr; /* Physical address of
  299. gru segments (64) */
  300. void *gs_gru_base_vaddr; /* Virtual address of
  301. gru segments (64) */
  302. unsigned char gs_gid; /* unique GRU number */
  303. unsigned char gs_tgh_local_shift; /* used to pick TGH for
  304. local flush */
  305. unsigned char gs_tgh_first_remote; /* starting TGH# for
  306. remote flush */
  307. unsigned short gs_blade_id; /* blade of GRU */
  308. spinlock_t gs_asid_lock; /* lock used for
  309. assigning asids */
  310. spinlock_t gs_lock; /* lock used for
  311. assigning contexts */
  312. /* -- the following are protected by the gs_asid_lock spinlock ---- */
  313. unsigned int gs_asid; /* Next availe ASID */
  314. unsigned int gs_asid_limit; /* Limit of available
  315. ASIDs */
  316. unsigned int gs_asid_gen; /* asid generation.
  317. Inc on wrap */
  318. /* --- the following fields are protected by the gs_lock spinlock --- */
  319. unsigned long gs_context_map; /* bitmap to manage
  320. contexts in use */
  321. unsigned long gs_cbr_map; /* bitmap to manage CB
  322. resources */
  323. unsigned long gs_dsr_map; /* bitmap used to manage
  324. DATA resources */
  325. unsigned int gs_reserved_cbrs; /* Number of kernel-
  326. reserved cbrs */
  327. unsigned int gs_reserved_dsr_bytes; /* Bytes of kernel-
  328. reserved dsrs */
  329. unsigned short gs_active_contexts; /* number of contexts
  330. in use */
  331. struct gru_thread_state *gs_gts[GRU_NUM_CCH]; /* GTS currently using
  332. the context */
  333. };
  334. /*
  335. * This structure contains the GRU state for all the GRUs on a blade.
  336. */
  337. struct gru_blade_state {
  338. void *kernel_cb; /* First kernel
  339. reserved cb */
  340. void *kernel_dsr; /* First kernel
  341. reserved DSR */
  342. /* ---- the following are protected by the bs_lock spinlock ---- */
  343. spinlock_t bs_lock; /* lock used for
  344. stealing contexts */
  345. int bs_lru_ctxnum; /* STEAL - last context
  346. stolen */
  347. struct gru_state *bs_lru_gru; /* STEAL - last gru
  348. stolen */
  349. struct gru_state bs_grus[GRU_CHIPLETS_PER_BLADE];
  350. };
  351. /*-----------------------------------------------------------------------------
  352. * Address Primitives
  353. */
  354. #define get_tfm_for_cpu(g, c) \
  355. ((struct gru_tlb_fault_map *)get_tfm((g)->gs_gru_base_vaddr, (c)))
  356. #define get_tfh_by_index(g, i) \
  357. ((struct gru_tlb_fault_handle *)get_tfh((g)->gs_gru_base_vaddr, (i)))
  358. #define get_tgh_by_index(g, i) \
  359. ((struct gru_tlb_global_handle *)get_tgh((g)->gs_gru_base_vaddr, (i)))
  360. #define get_cbe_by_index(g, i) \
  361. ((struct gru_control_block_extended *)get_cbe((g)->gs_gru_base_vaddr,\
  362. (i)))
  363. /*-----------------------------------------------------------------------------
  364. * Useful Macros
  365. */
  366. /* Given a blade# & chiplet#, get a pointer to the GRU */
  367. #define get_gru(b, c) (&gru_base[b]->bs_grus[c])
  368. /* Number of bytes to save/restore when unloading/loading GRU contexts */
  369. #define DSR_BYTES(dsr) ((dsr) * GRU_DSR_AU_BYTES)
  370. #define CBR_BYTES(cbr) ((cbr) * GRU_HANDLE_BYTES * GRU_CBR_AU_SIZE * 2)
  371. /* Convert a user CB number to the actual CBRNUM */
  372. #define thread_cbr_number(gts, n) ((gts)->ts_cbr_idx[(n) / GRU_CBR_AU_SIZE] \
  373. * GRU_CBR_AU_SIZE + (n) % GRU_CBR_AU_SIZE)
  374. /* Convert a gid to a pointer to the GRU */
  375. #define GID_TO_GRU(gid) \
  376. (gru_base[(gid) / GRU_CHIPLETS_PER_BLADE] ? \
  377. (&gru_base[(gid) / GRU_CHIPLETS_PER_BLADE]-> \
  378. bs_grus[(gid) % GRU_CHIPLETS_PER_BLADE]) : \
  379. NULL)
  380. /* Scan all active GRUs in a GRU bitmap */
  381. #define for_each_gru_in_bitmap(gid, map) \
  382. for ((gid) = find_first_bit((map), GRU_MAX_GRUS); (gid) < GRU_MAX_GRUS;\
  383. (gid)++, (gid) = find_next_bit((map), GRU_MAX_GRUS, (gid)))
  384. /* Scan all active GRUs on a specific blade */
  385. #define for_each_gru_on_blade(gru, nid, i) \
  386. for ((gru) = gru_base[nid]->bs_grus, (i) = 0; \
  387. (i) < GRU_CHIPLETS_PER_BLADE; \
  388. (i)++, (gru)++)
  389. /* Scan all active GTSs on a gru. Note: must hold ss_lock to use this macro. */
  390. #define for_each_gts_on_gru(gts, gru, ctxnum) \
  391. for ((ctxnum) = 0; (ctxnum) < GRU_NUM_CCH; (ctxnum)++) \
  392. if (((gts) = (gru)->gs_gts[ctxnum]))
  393. /* Scan each CBR whose bit is set in a TFM (or copy of) */
  394. #define for_each_cbr_in_tfm(i, map) \
  395. for ((i) = find_first_bit(map, GRU_NUM_CBE); \
  396. (i) < GRU_NUM_CBE; \
  397. (i)++, (i) = find_next_bit(map, GRU_NUM_CBE, i))
  398. /* Scan each CBR in a CBR bitmap. Note: multiple CBRs in an allocation unit */
  399. #define for_each_cbr_in_allocation_map(i, map, k) \
  400. for ((k) = find_first_bit(map, GRU_CBR_AU); (k) < GRU_CBR_AU; \
  401. (k) = find_next_bit(map, GRU_CBR_AU, (k) + 1)) \
  402. for ((i) = (k)*GRU_CBR_AU_SIZE; \
  403. (i) < ((k) + 1) * GRU_CBR_AU_SIZE; (i)++)
  404. /* Scan each DSR in a DSR bitmap. Note: multiple DSRs in an allocation unit */
  405. #define for_each_dsr_in_allocation_map(i, map, k) \
  406. for ((k) = find_first_bit((const unsigned long *)map, GRU_DSR_AU);\
  407. (k) < GRU_DSR_AU; \
  408. (k) = find_next_bit((const unsigned long *)map, \
  409. GRU_DSR_AU, (k) + 1)) \
  410. for ((i) = (k) * GRU_DSR_AU_CL; \
  411. (i) < ((k) + 1) * GRU_DSR_AU_CL; (i)++)
  412. #define gseg_physical_address(gru, ctxnum) \
  413. ((gru)->gs_gru_base_paddr + ctxnum * GRU_GSEG_STRIDE)
  414. #define gseg_virtual_address(gru, ctxnum) \
  415. ((gru)->gs_gru_base_vaddr + ctxnum * GRU_GSEG_STRIDE)
  416. /*-----------------------------------------------------------------------------
  417. * Lock / Unlock GRU handles
  418. * Use the "delresp" bit in the handle as a "lock" bit.
  419. */
  420. /* Lock hierarchy checking enabled only in emulator */
  421. static inline void __lock_handle(void *h)
  422. {
  423. while (test_and_set_bit(1, h))
  424. cpu_relax();
  425. }
  426. static inline void __unlock_handle(void *h)
  427. {
  428. clear_bit(1, h);
  429. }
  430. static inline void lock_cch_handle(struct gru_context_configuration_handle *cch)
  431. {
  432. __lock_handle(cch);
  433. }
  434. static inline void unlock_cch_handle(struct gru_context_configuration_handle
  435. *cch)
  436. {
  437. __unlock_handle(cch);
  438. }
  439. static inline void lock_tgh_handle(struct gru_tlb_global_handle *tgh)
  440. {
  441. __lock_handle(tgh);
  442. }
  443. static inline void unlock_tgh_handle(struct gru_tlb_global_handle *tgh)
  444. {
  445. __unlock_handle(tgh);
  446. }
  447. /*-----------------------------------------------------------------------------
  448. * Function prototypes & externs
  449. */
  450. struct gru_unload_context_req;
  451. extern struct vm_operations_struct gru_vm_ops;
  452. extern struct device *grudev;
  453. extern struct gru_vma_data *gru_alloc_vma_data(struct vm_area_struct *vma,
  454. int tsid);
  455. extern struct gru_thread_state *gru_find_thread_state(struct vm_area_struct
  456. *vma, int tsid);
  457. extern struct gru_thread_state *gru_alloc_thread_state(struct vm_area_struct
  458. *vma, int tsid);
  459. extern void gru_unload_context(struct gru_thread_state *gts, int savestate);
  460. extern void gts_drop(struct gru_thread_state *gts);
  461. extern void gru_tgh_flush_init(struct gru_state *gru);
  462. extern int gru_kservices_init(struct gru_state *gru);
  463. extern irqreturn_t gru_intr(int irq, void *dev_id);
  464. extern int gru_handle_user_call_os(unsigned long address);
  465. extern int gru_user_flush_tlb(unsigned long arg);
  466. extern int gru_user_unload_context(unsigned long arg);
  467. extern int gru_get_exception_detail(unsigned long arg);
  468. extern int gru_set_task_slice(long address);
  469. extern int gru_cpu_fault_map_id(void);
  470. extern struct vm_area_struct *gru_find_vma(unsigned long vaddr);
  471. extern void gru_flush_all_tlb(struct gru_state *gru);
  472. extern int gru_proc_init(void);
  473. extern void gru_proc_exit(void);
  474. extern unsigned long reserve_gru_cb_resources(struct gru_state *gru,
  475. int cbr_au_count, char *cbmap);
  476. extern unsigned long reserve_gru_ds_resources(struct gru_state *gru,
  477. int dsr_au_count, char *dsmap);
  478. extern int gru_fault(struct vm_area_struct *, struct vm_fault *vmf);
  479. extern struct gru_mm_struct *gru_register_mmu_notifier(void);
  480. extern void gru_drop_mmu_notifier(struct gru_mm_struct *gms);
  481. extern void gru_flush_tlb_range(struct gru_mm_struct *gms, unsigned long start,
  482. unsigned long len);
  483. extern unsigned long options;
  484. #endif /* __GRUTABLES_H__ */