[patch 15/38] cio: cm_enable memory leak.
From: Martin Schwidefsky
Date: Fri Apr 27 2007 - 10:21:23 EST
From: Cornelia Huck <cornelia.huck@xxxxxxxxxx>
We allocage two pages when channel path measurements are enabled
via cm_enable. We must not forget to free them again when
channel path measurements are disabled again.
Signed-off-by: Cornelia Huck <cornelia.huck@xxxxxxxxxx>
Signed-off-by: Martin Schwidefsky <schwidefsky@xxxxxxxxxx>
---
drivers/s390/cio/chsc.c | 2 +-
1 files changed, 1 insertion(+), 1 deletion(-)
Index: quilt-2.6/drivers/s390/cio/chsc.c
===================================================================
--- quilt-2.6.orig/drivers/s390/cio/chsc.c 2007-04-27 16:04:55.000000000 +0200
+++ quilt-2.6/drivers/s390/cio/chsc.c 2007-04-27 16:04:55.000000000 +0200
@@ -818,7 +818,7 @@
} else
chsc_remove_cmg_attr(css);
}
- if (enable && !css->cm_enabled) {
+ if (!css->cm_enabled) {
free_page((unsigned long)css->cub_addr1);
free_page((unsigned long)css->cub_addr2);
}
--
blue skies,
Martin.
"Reality continues to ruin my life." - Calvin.
-
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/