diff options
author | Jesper Juhl <juhl-lkml@dif.dk> | 2005-10-22 04:51:23 +0200 |
---|---|---|
committer | Kyle McMartin <kyle@parisc-linux.org> | 2005-10-22 04:51:23 +0200 |
commit | c8e8b1937a788ec46ee11d84437311d4cb8be218 (patch) | |
tree | 6095b828530f992d03825fc7dd379bfda0ee8751 /arch | |
parent | [PARISC] Cleanup whitespace and handle proc_mkdir() failures in pci-dma.c (diff) | |
download | linux-c8e8b1937a788ec46ee11d84437311d4cb8be218.tar.xz linux-c8e8b1937a788ec46ee11d84437311d4cb8be218.zip |
[PARISC] kfree cleanups to ioctl32.c
2.6.12-rc2-pa2 kfree cleanups from Jesper Juhl
Signed-off-by: Jesper Juhl <juhl-lkml@dif.dk>
Signed-off-by: Grant Grundler <grundler@parisc-linux.org>
Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/parisc/kernel/ioctl32.c | 32 |
1 files changed, 9 insertions, 23 deletions
diff --git a/arch/parisc/kernel/ioctl32.c b/arch/parisc/kernel/ioctl32.c index 1d3824b670d1..8cad8f004f00 100644 --- a/arch/parisc/kernel/ioctl32.c +++ b/arch/parisc/kernel/ioctl32.c @@ -104,12 +104,9 @@ static int drm32_version(unsigned int fd, unsigned int cmd, unsigned long arg) } out: - if (kversion.name) - kfree(kversion.name); - if (kversion.date) - kfree(kversion.date); - if (kversion.desc) - kfree(kversion.desc); + kfree(kversion.name); + kfree(kversion.date); + kfree(kversion.desc); return ret; } @@ -166,9 +163,7 @@ static int drm32_getsetunique(unsigned int fd, unsigned int cmd, unsigned long a ret = -EFAULT; } - if (karg.unique != NULL) - kfree(karg.unique); - + kfree(karg.unique); return ret; } @@ -265,7 +260,6 @@ static int drm32_info_bufs(unsigned int fd, unsigned int cmd, unsigned long arg) } kfree(karg.list); - return ret; } @@ -305,7 +299,6 @@ static int drm32_free_bufs(unsigned int fd, unsigned int cmd, unsigned long arg) out: kfree(karg.list); - return ret; } @@ -494,15 +487,10 @@ static int drm32_dma(unsigned int fd, unsigned int cmd, unsigned long arg) } out: - if (karg.send_indices) - kfree(karg.send_indices); - if (karg.send_sizes) - kfree(karg.send_sizes); - if (karg.request_indices) - kfree(karg.request_indices); - if (karg.request_sizes) - kfree(karg.request_sizes); - + kfree(karg.send_indices); + kfree(karg.send_sizes); + kfree(karg.request_indices); + kfree(karg.request_sizes); return ret; } @@ -555,9 +543,7 @@ static int drm32_res_ctx(unsigned int fd, unsigned int cmd, unsigned long arg) ret = -EFAULT; } - if (karg.contexts) - kfree(karg.contexts); - + kfree(karg.contexts); return ret; } |