Re: [PATCH 5/5] Swapless V2: Revise main migration logic
From: KAMEZAWA Hiroyuki
Date: Thu Apr 13 2006 - 22:43:12 EST
soryy...This is wrong.
On Fri, 14 Apr 2006 11:34:55 +0900
KAMEZAWA Hiroyuki <kamezawa.hiroyu@xxxxxxxxxxxxxx> wrote:
> /* Use last entry for page migration swap entries */
> -#define MAX_SWAPFILES ((1 << MAX_SWAPFILES_SHIFT)-1)
> -#define SWP_TYPE_MIGRATION MAX_SWAPFILES
> +#define MAX_SWAPFILES ((1 << MAX_SWAPFILES_SHIFT)-2)
> +/* write protected page under migration*/
> +#define SWP_TYPE_MIGRATION_WP (MAX_SWAPFILES - 1)
> +/* write enabled migration type */
> +#define SWP_TYPE_MIGRATION_WE (MAX_SWAPFILES)
> #endif
maybe I need one more eye..
This is fix.
-Kame
Index: Christoph-New-Migration/include/linux/swap.h
===================================================================
--- Christoph-New-Migration.orig/include/linux/swap.h 2006-04-14 11:13:55.000000000 +0900
+++ Christoph-New-Migration/include/linux/swap.h 2006-04-14 11:40:28.000000000 +0900
@@ -35,9 +35,9 @@
/* Use last entry for page migration swap entries */
#define MAX_SWAPFILES ((1 << MAX_SWAPFILES_SHIFT)-2)
/* write protected page under migration*/
-#define SWP_TYPE_MIGRATION_WP (MAX_SWAPFILES - 1)
+#define SWP_TYPE_MIGRATION_WP (MAX_SWAPFILES)
/* write enabled migration type */
-#define SWP_TYPE_MIGRATION_WE (MAX_SWAPFILES)
+#define SWP_TYPE_MIGRATION_WE (MAX_SWAPFILES + 1)
#endif
/*
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/