~ubuntu-branches/debian/wheezy/linux-2.6/wheezy

« back to all changes in this revision

Viewing changes to debian/patches/bugfix/all/rtc-rtc-ds1511-world-writable-sysfs-nvram-file.patch

  • Committer: Bazaar Package Importer
  • Author(s): Ben Hutchings, Ben Hutchings, Aurelien Jarno, Martin Michlmayr
  • Date: 2011-04-06 13:53:30 UTC
  • mfrom: (43.1.5 sid)
  • Revision ID: james.westby@ubuntu.com-20110406135330-wjufxhd0tvn3zx4z
Tags: 2.6.38-3
[ Ben Hutchings ]
* [ppc64] Add to linux-tools package architectures (Closes: #620124)
* [amd64] Save cr4 to mmu_cr4_features at boot time (Closes: #620284)
* appletalk: Fix bugs introduced when removing use of BKL
* ALSA: Fix yet another race in disconnection
* cciss: Fix lost command issue
* ath9k: Fix kernel panic in AR2427
* ses: Avoid kernel panic when lun 0 is not mapped
* PCI/ACPI: Report ASPM support to BIOS if not disabled from command line

[ Aurelien Jarno ]
* rtlwifi: fix build when PCI is not enabled.

[ Martin Michlmayr ]
* rtlwifi: Eliminate udelay calls with too large values (Closes: #620204)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
From: Vasiliy Kulikov <segoon@openwall.com>
 
2
Subject: [PATCH 17/20] rtc: rtc-ds1511: world-writable sysfs nvram file
 
3
Date: Fri,  4 Feb 2011 15:24:06 +0300
 
4
 
 
5
Don't allow everybogy to write to NVRAM.
 
6
 
 
7
Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>
 
8
---
 
9
 Compile tested only.
 
10
 
 
11
 drivers/rtc/rtc-ds1511.c |    2 +-
 
12
 1 files changed, 1 insertions(+), 1 deletions(-)
 
13
 
 
14
diff --git a/drivers/rtc/rtc-ds1511.c b/drivers/rtc/rtc-ds1511.c
 
15
index 37268e9..afeb546 100644
 
16
--- a/drivers/rtc/rtc-ds1511.c
 
17
+++ b/drivers/rtc/rtc-ds1511.c
 
18
@@ -485,7 +485,7 @@ ds1511_nvram_write(struct file *filp, struct kobject *kobj,
 
19
 static struct bin_attribute ds1511_nvram_attr = {
 
20
        .attr = {
 
21
                .name = "nvram",
 
22
-               .mode = S_IRUGO | S_IWUGO,
 
23
+               .mode = S_IRUGO | S_IWUSR,
 
24
        },
 
25
        .size = DS1511_RAM_MAX,
 
26
        .read = ds1511_nvram_read,
 
27
-- 
 
28
1.7.0.4
 
29