]> git.pld-linux.org Git - packages/kernel.git/blame - linux-2.4-rtc.patch
- enable cluster config on ppc,sparc,amd64,ia64
[packages/kernel.git] / linux-2.4-rtc.patch
CommitLineData
f6e2b709
JB
1diff -urN linux-2.4.23/arch/cris/drivers/ds1302.c linux-2.4.24/arch/cris/drivers/ds1302.c
2--- linux-2.4.23/arch/cris/drivers/ds1302.c 2003-08-25 04:44:39.000000000 -0700
3+++ linux-2.4.24/arch/cris/drivers/ds1302.c 2004-01-05 05:53:56.000000000 -0800
4@@ -346,6 +346,7 @@
5 {
6 struct rtc_time rtc_tm;
7
8+ memset(&rtc_tm, 0, sizeof (struct rtc_time));
9 get_rtc_time(&rtc_tm);
10 if (copy_to_user((struct rtc_time*)arg, &rtc_tm, sizeof(struct rtc_time)))
11 return -EFAULT;
12diff -urN linux-2.4.23/arch/cris/drivers/pcf8563.c linux-2.4.24/arch/cris/drivers/pcf8563.c
13--- linux-2.4.23/arch/cris/drivers/pcf8563.c 2003-08-25 04:44:39.000000000 -0700
14+++ linux-2.4.24/arch/cris/drivers/pcf8563.c 2004-01-05 05:53:56.000000000 -0800
15@@ -220,6 +220,7 @@
16 {
17 struct rtc_time tm;
18
19+ memset(&tm, 0, sizeof (struct rtc_time));
20 get_rtc_time(&tm);
21
22 if (copy_to_user((struct rtc_time *) arg, &tm, sizeof tm)) {
23diff -urN linux-2.4.23/arch/m68k/bvme6000/rtc.c linux-2.4.24/arch/m68k/bvme6000/rtc.c
24--- linux-2.4.23/arch/m68k/bvme6000/rtc.c 2003-06-13 07:51:31.000000000 -0700
25+++ linux-2.4.24/arch/m68k/bvme6000/rtc.c 2004-01-05 05:53:56.000000000 -0800
26@@ -54,6 +54,7 @@
27 /* Ensure clock and real-time-mode-register are accessible */
28 msr = rtc->msr & 0xc0;
29 rtc->msr = 0x40;
30+ memset(&wtime, 0, sizeof(struct rtc_time));
31 do {
32 wtime.tm_sec = BCD2BIN(rtc->bcd_sec);
33 wtime.tm_min = BCD2BIN(rtc->bcd_min);
34diff -urN linux-2.4.23/arch/m68k/mvme16x/rtc.c linux-2.4.24/arch/m68k/mvme16x/rtc.c
35--- linux-2.4.23/arch/m68k/mvme16x/rtc.c 2003-06-13 07:51:31.000000000 -0700
36+++ linux-2.4.24/arch/m68k/mvme16x/rtc.c 2004-01-05 05:53:56.000000000 -0800
37@@ -52,6 +52,7 @@
38 cli();
39 /* Ensure clock and real-time-mode-register are accessible */
40 rtc->ctrl = RTC_READ;
41+ memset(&wtime, 0, sizeof(struct rtc_time));
42 wtime.tm_sec = BCD2BIN(rtc->bcd_sec);
43 wtime.tm_min = BCD2BIN(rtc->bcd_min);
44 wtime.tm_hour = BCD2BIN(rtc->bcd_hr);
45diff -urN linux-2.4.23/arch/ppc64/kernel/rtc.c linux-2.4.24/arch/ppc64/kernel/rtc.c
46--- linux-2.4.23/arch/ppc64/kernel/rtc.c 2003-06-13 07:51:32.000000000 -0700
47+++ linux-2.4.24/arch/ppc64/kernel/rtc.c 2004-01-05 05:53:56.000000000 -0800
48@@ -96,6 +96,7 @@
49 switch (cmd) {
50 case RTC_RD_TIME: /* Read the time/date from RTC */
51 {
52+ memset(&wtime, 0, sizeof(struct rtc_time));
53 ppc_md.get_rtc_time(&wtime);
54 break;
55 }
56diff -urN linux-2.4.23/drivers/acorn/char/i2c.c linux-2.4.24/drivers/acorn/char/i2c.c
57--- linux-2.4.23/drivers/acorn/char/i2c.c 2003-08-25 04:44:40.000000000 -0700
58+++ linux-2.4.24/drivers/acorn/char/i2c.c 2004-01-05 05:53:56.000000000 -0800
59@@ -166,6 +166,7 @@
60 break;
61
62 case RTC_RD_TIME:
63+ memset(&rtctm, 0, sizeof(struct rtc_time));
64 get_rtc_time(&rtc_raw, &year);
65 rtctm.tm_sec = rtc_raw.secs;
66 rtctm.tm_min = rtc_raw.mins;
67diff -urN linux-2.4.23/drivers/char/ds1286.c linux-2.4.24/drivers/char/ds1286.c
68--- linux-2.4.23/drivers/char/ds1286.c 2003-08-25 04:44:41.000000000 -0700
69+++ linux-2.4.24/drivers/char/ds1286.c 2004-01-05 05:53:56.000000000 -0800
70@@ -173,7 +173,7 @@
71 * means "don't care" or "match all". Only the tm_hour,
72 * tm_min, and tm_sec values are filled in.
73 */
74-
75+ memset(&wtime, 0, sizeof(struct rtc_time));
76 ds1286_get_alm_time(&wtime);
77 break;
78 }
79@@ -216,6 +216,7 @@
80 }
81 case RTC_RD_TIME: /* Read the time/date from RTC */
82 {
83+ memset(&wtime, 0, sizeof(struct rtc_time));
84 ds1286_get_time(&wtime);
85 break;
86 }
87diff -urN linux-2.4.23/drivers/char/efirtc.c linux-2.4.24/drivers/char/efirtc.c
88--- linux-2.4.23/drivers/char/efirtc.c 2003-06-13 07:51:32.000000000 -0700
89+++ linux-2.4.24/drivers/char/efirtc.c 2004-01-05 05:53:56.000000000 -0800
90@@ -118,6 +118,7 @@
91 static void
92 convert_from_efi_time(efi_time_t *eft, struct rtc_time *wtime)
93 {
94+ memset(wtime, 0, sizeof(struct rtc_time));
95 wtime->tm_sec = eft->second;
96 wtime->tm_min = eft->minute;
97 wtime->tm_hour = eft->hour;
98diff -urN linux-2.4.23/drivers/char/ip27-rtc.c linux-2.4.24/drivers/char/ip27-rtc.c
99--- linux-2.4.23/drivers/char/ip27-rtc.c 2003-08-25 04:44:41.000000000 -0700
100+++ linux-2.4.24/drivers/char/ip27-rtc.c 2004-01-05 05:53:56.000000000 -0800
101@@ -83,6 +83,7 @@
102 switch (cmd) {
103 case RTC_RD_TIME: /* Read the time/date from RTC */
104 {
105+ memset(&wtime, 0, sizeof(struct rtc_time));
106 get_rtc_time(&wtime);
107 break;
108 }
109diff -urN linux-2.4.23/drivers/char/mips_rtc.c linux-2.4.24/drivers/char/mips_rtc.c
110--- linux-2.4.23/drivers/char/mips_rtc.c 2003-08-25 04:44:41.000000000 -0700
111+++ linux-2.4.24/drivers/char/mips_rtc.c 2004-01-05 05:53:56.000000000 -0800
112@@ -82,6 +82,7 @@
113
114 switch (cmd) {
115 case RTC_RD_TIME: /* Read the time/date from RTC */
116+ memset(&rtc_tm, 0, sizeof(struct rtc_time));
117 curr_time = rtc_get_time();
118 to_tm(curr_time, &rtc_tm);
119 rtc_tm.tm_year -= 1900;
120diff -urN linux-2.4.23/drivers/char/rtc.c linux-2.4.24/drivers/char/rtc.c
121--- linux-2.4.23/drivers/char/rtc.c 2003-11-28 10:26:20.000000000 -0800
122+++ linux-2.4.24/drivers/char/rtc.c 2004-01-05 05:53:56.000000000 -0800
123@@ -362,7 +362,7 @@
124 * means "don't care" or "match all". Only the tm_hour,
125 * tm_min, and tm_sec values are filled in.
126 */
127-
128+ memset(&wtime, 0, sizeof(struct rtc_time));
129 get_rtc_alm_time(&wtime);
130 break;
131 }
132@@ -406,6 +406,7 @@
133 }
134 case RTC_RD_TIME: /* Read the time/date from RTC */
135 {
136+ memset(&wtime, 0, sizeof(struct rtc_time));
137 get_rtc_time(&wtime);
138 break;
139 }
140diff -urN linux-2.4.23/drivers/hil/hp_sdc_rtc.c linux-2.4.24/drivers/hil/hp_sdc_rtc.c
141--- linux-2.4.23/drivers/hil/hp_sdc_rtc.c 2003-06-13 07:51:33.000000000 -0700
142+++ linux-2.4.24/drivers/hil/hp_sdc_rtc.c 2004-01-05 05:53:56.000000000 -0800
143@@ -561,6 +561,7 @@
144 }
145 case RTC_ALM_READ: /* Read the present alarm time */
146 {
147+ memset(&ttime, 0, sizeof(struct timeval));
148 if (hp_sdc_rtc_read_mt(&ttime)) return -EFAULT;
149 break;
150 }
151@@ -609,6 +610,7 @@
152 }
153 case RTC_RD_TIME: /* Read the time/date from RTC */
154 {
155+ memset(&wtime, 0, sizeof(struct rtc_time));
156 if (hp_sdc_rtc_read_bbrtc(&wtime)) return -EFAULT;
157 break;
158 }
159diff -urN linux-2.4.23/drivers/macintosh/rtc.c linux-2.4.24/drivers/macintosh/rtc.c
160--- linux-2.4.23/drivers/macintosh/rtc.c 2002-02-25 11:37:58.000000000 -0800
161+++ linux-2.4.24/drivers/macintosh/rtc.c 2004-01-05 05:53:56.000000000 -0800
162@@ -64,6 +64,7 @@
163 case RTC_RD_TIME:
164 if (ppc_md.get_rtc_time)
165 {
166+ memset(&rtc_tm, 0, sizeof(struct rtc_time));
167 get_rtc_time(&rtc_tm);
168
169 if (copy_to_user((struct rtc_time*)arg, &rtc_tm, sizeof(struct rtc_time)))
170diff -urN linux-2.4.23/drivers/sbus/char/rtc.c linux-2.4.24/drivers/sbus/char/rtc.c
171--- linux-2.4.23/drivers/sbus/char/rtc.c 2001-10-10 23:42:47.000000000 -0700
172+++ linux-2.4.24/drivers/sbus/char/rtc.c 2004-01-05 05:53:56.000000000 -0800
173@@ -89,6 +89,7 @@
174 switch (cmd)
175 {
176 case RTCGET:
177+ memset(&rtc_tm, 0, sizeof(struct rtc_time));
178 get_rtc_time(&rtc_tm);
179
180 if (copy_to_user((struct rtc_time*)arg, &rtc_tm, sizeof(struct rtc_time)))
This page took 0.0773 seconds and 4 git commands to generate.