]> err.no Git - linux-2.6/blobdiff - include/linux/suspend.h
locks: add lock cancel command
[linux-2.6] / include / linux / suspend.h
index c11cacf1a13b68b4b5cb703ce02949d1a13dc386..bf99bd49f8efd3af5f13004ca3c84c57bc532e91 100644 (file)
@@ -9,22 +9,16 @@
 #include <linux/init.h>
 #include <linux/pm.h>
 
-/* page backup entry */
+/* struct pbe is used for creating lists of pages that should be restored
+ * atomically during the resume from disk, because the page frames they have
+ * occupied before the suspend are in use.
+ */
 struct pbe {
-       unsigned long address;          /* address of the copy */
-       unsigned long orig_address;     /* original address of page */
+       void *address;          /* address of the copy */
+       void *orig_address;     /* original address of a page */
        struct pbe *next;
 };
 
-#define for_each_pbe(pbe, pblist) \
-       for (pbe = pblist ; pbe ; pbe = pbe->next)
-
-#define PBES_PER_PAGE      (PAGE_SIZE/sizeof(struct pbe))
-#define PB_PAGE_SKIP       (PBES_PER_PAGE-1)
-
-#define for_each_pb_page(pbe, pblist) \
-       for (pbe = pblist ; pbe ; pbe = (pbe+PB_PAGE_SKIP)->next)
-
 /* mm/page_alloc.c */
 extern void drain_local_pages(void);
 extern void mark_free_pages(struct zone *zone);