diff options
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/Kconfig | 2 | ||||
-rw-r--r-- | drivers/char/selection.c | 2 | ||||
-rw-r--r-- | drivers/char/sx.c | 8 | ||||
-rw-r--r-- | drivers/char/tpm/tpm_infineon.c | 4 |
4 files changed, 9 insertions, 7 deletions
diff --git a/drivers/char/Kconfig b/drivers/char/Kconfig index f5be8081cd81..735bbe2be51a 100644 --- a/drivers/char/Kconfig +++ b/drivers/char/Kconfig | |||
@@ -761,7 +761,7 @@ source "drivers/char/hw_random/Kconfig" | |||
761 | 761 | ||
762 | config NVRAM | 762 | config NVRAM |
763 | tristate "/dev/nvram support" | 763 | tristate "/dev/nvram support" |
764 | depends on ATARI || X86 || ARM || GENERIC_NVRAM | 764 | depends on ATARI || X86 || (ARM && RTC_DRV_CMOS) || GENERIC_NVRAM |
765 | ---help--- | 765 | ---help--- |
766 | If you say Y here and create a character special file /dev/nvram | 766 | If you say Y here and create a character special file /dev/nvram |
767 | with major number 10 and minor number 144 using mknod ("man mknod"), | 767 | with major number 10 and minor number 144 using mknod ("man mknod"), |
diff --git a/drivers/char/selection.c b/drivers/char/selection.c index f29fbe9b8ed7..cb8ca5698963 100644 --- a/drivers/char/selection.c +++ b/drivers/char/selection.c | |||
@@ -268,7 +268,7 @@ int set_selection(const struct tiocl_selection __user *sel, struct tty_struct *t | |||
268 | 268 | ||
269 | /* Allocate a new buffer before freeing the old one ... */ | 269 | /* Allocate a new buffer before freeing the old one ... */ |
270 | multiplier = use_unicode ? 3 : 1; /* chars can take up to 3 bytes */ | 270 | multiplier = use_unicode ? 3 : 1; /* chars can take up to 3 bytes */ |
271 | bp = kmalloc((sel_end-sel_start)/2*multiplier+1, GFP_KERNEL); | 271 | bp = kmalloc(((sel_end-sel_start)/2+1)*multiplier, GFP_KERNEL); |
272 | if (!bp) { | 272 | if (!bp) { |
273 | printk(KERN_WARNING "selection: kmalloc() failed\n"); | 273 | printk(KERN_WARNING "selection: kmalloc() failed\n"); |
274 | clear_selection(); | 274 | clear_selection(); |
diff --git a/drivers/char/sx.c b/drivers/char/sx.c index b60be7b0decf..f146e90404fa 100644 --- a/drivers/char/sx.c +++ b/drivers/char/sx.c | |||
@@ -1713,8 +1713,8 @@ static long sx_fw_ioctl(struct file *filp, unsigned int cmd, | |||
1713 | for (i = 0; i < SX_NBOARDS; i++) | 1713 | for (i = 0; i < SX_NBOARDS; i++) |
1714 | sx_dprintk(SX_DEBUG_FIRMWARE, "<%x> ", boards[i].flags); | 1714 | sx_dprintk(SX_DEBUG_FIRMWARE, "<%x> ", boards[i].flags); |
1715 | sx_dprintk(SX_DEBUG_FIRMWARE, "\n"); | 1715 | sx_dprintk(SX_DEBUG_FIRMWARE, "\n"); |
1716 | unlock_kernel(); | 1716 | rc = -EIO; |
1717 | return -EIO; | 1717 | goto out; |
1718 | } | 1718 | } |
1719 | 1719 | ||
1720 | switch (cmd) { | 1720 | switch (cmd) { |
@@ -1747,7 +1747,8 @@ static long sx_fw_ioctl(struct file *filp, unsigned int cmd, | |||
1747 | break; | 1747 | break; |
1748 | case SXIO_DO_RAMTEST: | 1748 | case SXIO_DO_RAMTEST: |
1749 | if (sx_initialized) /* Already initialized: better not ramtest the board. */ | 1749 | if (sx_initialized) /* Already initialized: better not ramtest the board. */ |
1750 | return -EPERM; | 1750 | rc = -EPERM; |
1751 | break; | ||
1751 | if (IS_SX_BOARD(board)) { | 1752 | if (IS_SX_BOARD(board)) { |
1752 | rc = do_memtest(board, 0, 0x7000); | 1753 | rc = do_memtest(board, 0, 0x7000); |
1753 | if (!rc) | 1754 | if (!rc) |
@@ -1844,6 +1845,7 @@ static long sx_fw_ioctl(struct file *filp, unsigned int cmd, | |||
1844 | rc = -ENOTTY; | 1845 | rc = -ENOTTY; |
1845 | break; | 1846 | break; |
1846 | } | 1847 | } |
1848 | out: | ||
1847 | unlock_kernel(); | 1849 | unlock_kernel(); |
1848 | func_exit(); | 1850 | func_exit(); |
1849 | return rc; | 1851 | return rc; |
diff --git a/drivers/char/tpm/tpm_infineon.c b/drivers/char/tpm/tpm_infineon.c index 726ee8a0277f..ecba4942fc8e 100644 --- a/drivers/char/tpm/tpm_infineon.c +++ b/drivers/char/tpm/tpm_infineon.c | |||
@@ -4,7 +4,7 @@ | |||
4 | * SLD 9630 TT 1.1 and SLB 9635 TT 1.2 Trusted Platform Module | 4 | * SLD 9630 TT 1.1 and SLB 9635 TT 1.2 Trusted Platform Module |
5 | * Specifications at www.trustedcomputinggroup.org | 5 | * Specifications at www.trustedcomputinggroup.org |
6 | * | 6 | * |
7 | * Copyright (C) 2005, Marcel Selhorst <selhorst@crypto.rub.de> | 7 | * Copyright (C) 2005, Marcel Selhorst <m.selhorst@sirrix.com> |
8 | * Sirrix AG - security technologies, http://www.sirrix.com and | 8 | * Sirrix AG - security technologies, http://www.sirrix.com and |
9 | * Applied Data Security Group, Ruhr-University Bochum, Germany | 9 | * Applied Data Security Group, Ruhr-University Bochum, Germany |
10 | * Project-Homepage: http://www.prosec.rub.de/tpm | 10 | * Project-Homepage: http://www.prosec.rub.de/tpm |
@@ -636,7 +636,7 @@ static void __exit cleanup_inf(void) | |||
636 | module_init(init_inf); | 636 | module_init(init_inf); |
637 | module_exit(cleanup_inf); | 637 | module_exit(cleanup_inf); |
638 | 638 | ||
639 | MODULE_AUTHOR("Marcel Selhorst <selhorst@crypto.rub.de>"); | 639 | MODULE_AUTHOR("Marcel Selhorst <m.selhorst@sirrix.com>"); |
640 | MODULE_DESCRIPTION("Driver for Infineon TPM SLD 9630 TT 1.1 / SLB 9635 TT 1.2"); | 640 | MODULE_DESCRIPTION("Driver for Infineon TPM SLD 9630 TT 1.1 / SLB 9635 TT 1.2"); |
641 | MODULE_VERSION("1.9"); | 641 | MODULE_VERSION("1.9"); |
642 | MODULE_LICENSE("GPL"); | 642 | MODULE_LICENSE("GPL"); |