[S390] hypfs fixes

Correct typo to make hypfs work on systems that support only diag204
subcode 4 and fix error handling in hypfs_diag_init.

Signed-off-by: Christian Borntraeger <cborntra@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
This commit is contained in:
Christian Borntraeger 2006-12-15 17:18:10 +01:00 committed by Martin Schwidefsky
parent 240bfbef67
commit 86b22470f6
1 changed files with 2 additions and 2 deletions

View File

@ -379,7 +379,7 @@ static void *diag204_alloc_vbuf(int pages)
static void *diag204_alloc_rbuf(void) static void *diag204_alloc_rbuf(void)
{ {
diag204_buf = (void*)__get_free_pages(GFP_KERNEL,0); diag204_buf = (void*)__get_free_pages(GFP_KERNEL,0);
if (diag204_buf) if (!diag204_buf)
return ERR_PTR(-ENOMEM); return ERR_PTR(-ENOMEM);
diag204_buf_pages = 1; diag204_buf_pages = 1;
return diag204_buf; return diag204_buf;
@ -521,7 +521,7 @@ __init int hypfs_diag_init(void)
} }
rc = diag224_get_name_table(); rc = diag224_get_name_table();
if (rc) { if (rc) {
diag224_delete_name_table(); diag204_free_buffer();
printk(KERN_ERR "hypfs: could not get name table.\n"); printk(KERN_ERR "hypfs: could not get name table.\n");
} }
return rc; return rc;