
From: Hirokazu Takahashi <taka@valinux.co.jp>

Hi Kame,

Ok, I see gcc-3.4 doen't allow that though I'm not sure why.

How about if we move the default statement at end of the switch block.

> Hi
> 
> 2.6.12-rc1-mhp (IA64_GENERIC + SPARSEMEM)works fine on my tiger4 :)
> Attached patch was needed to fix below problem with gcc-3.4
> >   CC      mm/mmigrate.o
> > mm/mmigrate.c: In function `generic_migrate_page':
> > mm/mmigrate.c:333: error: label at end of compound statement
> > make[1]: *** [mm/mmigrate.o]

Signed-off-by: Hirokazu Takahashi <taka@valinux.co.jp>
Signed-off-by: Dave Hansen <haveblue@us.ibm.com>
---

 memhotplug-dave/mm/mmigrate.c |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff -puN mm/mmigrate.c~AA-PM-28-fix-gcc-3.4-error mm/mmigrate.c
--- memhotplug/mm/mmigrate.c~AA-PM-28-fix-gcc-3.4-error	2005-03-28 16:38:34.000000000 -0800
+++ memhotplug-dave/mm/mmigrate.c	2005-03-28 16:38:34.000000000 -0800
@@ -319,17 +319,17 @@ generic_migrate_page(struct page *page, 
 	/* Wait for all operations against the page to finish. */
 	ret = migrate_fn(page, newpage, &vlist);
 	switch (ret) {
-	default:
-		/* The page is busy. Try it later. */
-		goto out_busy;
 	case -ENOENT:
 		/* The file the page belongs to has been truncated. */
 		page_cache_get(page);
 		page_cache_release(newpage);
 		newpage->mapping = NULL;
-		/* fall thru */
+		break;
 	case 0:
-		/* fall thru */
+		break;
+	default:
+		/* The page is busy. Try it later. */
+		goto out_busy;
 	}
 
 	arch_migrate_page(page, newpage);
_
