diff options
Diffstat (limited to 'drivers/staging/dgap/dgap_driver.c')
-rw-r--r-- | drivers/staging/dgap/dgap_driver.c | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/drivers/staging/dgap/dgap_driver.c b/drivers/staging/dgap/dgap_driver.c index 40ef785..4c1515e 100644 --- a/drivers/staging/dgap/dgap_driver.c +++ b/drivers/staging/dgap/dgap_driver.c @@ -32,16 +32,12 @@ #include <linux/kernel.h> -#include <linux/version.h> #include <linux/module.h> #include <linux/pci.h> #include <linux/delay.h> /* For udelay */ #include <linux/slab.h> #include <asm/uaccess.h> /* For copy_from_user/copy_to_user */ - -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39) #include <linux/sched.h> -#endif #include "dgap_driver.h" #include "dgap_pci.h" @@ -420,8 +416,7 @@ void dgap_cleanup_module(void) unregister_chrdev(DIGI_DGAP_MAJOR, "dgap"); } - if (dgap_config_buf) - kfree(dgap_config_buf); + kfree(dgap_config_buf); for (i = 0; i < dgap_NumBoards; ++i) { dgap_remove_ports_sysfiles(dgap_Board[i]); @@ -488,10 +483,8 @@ static void dgap_cleanup_board(struct board_t *brd) } } - if (brd->flipbuf) - kfree(brd->flipbuf); - if (brd->flipflagbuf) - kfree(brd->flipflagbuf); + kfree(brd->flipbuf); + kfree(brd->flipflagbuf); dgap_Board[brd->boardnum] = NULL; |