summaryrefslogtreecommitdiff
path: root/drivers/char/consolemap.c
diff options
context:
space:
mode:
authorJesper Juhl <jesper.juhl@gmail.com>2005-11-07 01:01:29 -0800
committerLinus Torvalds <torvalds@g5.osdl.org>2005-11-07 07:54:02 -0800
commit735d5661d5c5f023a78fbe68e771e261040ff1b7 (patch)
treeb9865f0322d8e74661639f5f33b1897b23004659 /drivers/char/consolemap.c
parentfa671646f61182cd18234461a6e65f50c6558695 (diff)
[PATCH] kfree cleanup: drivers/char
This is the drivers/char/ part of the big kfree cleanup patch. Remove pointless checks for NULL prior to calling kfree() in drivers/char/. Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/char/consolemap.c')
-rw-r--r--drivers/char/consolemap.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/drivers/char/consolemap.c b/drivers/char/consolemap.c
index 406dea91463..c85a4fa60da 100644
--- a/drivers/char/consolemap.c
+++ b/drivers/char/consolemap.c
@@ -345,17 +345,15 @@ static void con_release_unimap(struct uni_pagedir *p)
for (i = 0; i < 32; i++) {
if ((p1 = p->uni_pgdir[i]) != NULL) {
for (j = 0; j < 32; j++)
- if (p1[j])
- kfree(p1[j]);
+ kfree(p1[j]);
kfree(p1);
}
p->uni_pgdir[i] = NULL;
}
- for (i = 0; i < 4; i++)
- if (p->inverse_translations[i]) {
- kfree(p->inverse_translations[i]);
- p->inverse_translations[i] = NULL;
- }
+ for (i = 0; i < 4; i++) {
+ kfree(p->inverse_translations[i]);
+ p->inverse_translations[i] = NULL;
+ }
}
void con_free_unimap(struct vc_data *vc)