diff options
author | Dave Jiang <djiang@mvista.com> | 2007-07-19 04:49:54 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-07-19 13:04:54 -0400 |
commit | 4de78c6877ec21142582ac19453c2d453d1ea298 (patch) | |
tree | 784a1e007bea40744b93d4e0a09131e107fb6522 /drivers/edac/edac_mc_sysfs.c | |
parent | 66ee2f940ac8ab25f0c43a1e717d25dc46bfe74d (diff) |
drivers/edac: mod PCI poll names
Fixup poll values for MC and PCI.
Also make mc function names unique to mc.
Signed-off-by: Dave Jiang <djiang@mvista.com>
Signed-off-by: Douglas Thompson <dougthompson@xmissin.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/edac/edac_mc_sysfs.c')
-rw-r--r-- | drivers/edac/edac_mc_sysfs.c | 76 |
1 files changed, 44 insertions, 32 deletions
diff --git a/drivers/edac/edac_mc_sysfs.c b/drivers/edac/edac_mc_sysfs.c index 6b2217b741fb..7f8240f40db0 100644 --- a/drivers/edac/edac_mc_sysfs.c +++ b/drivers/edac/edac_mc_sysfs.c | |||
@@ -16,47 +16,44 @@ | |||
16 | #include "edac_module.h" | 16 | #include "edac_module.h" |
17 | 17 | ||
18 | /* MC EDAC Controls, setable by module parameter, and sysfs */ | 18 | /* MC EDAC Controls, setable by module parameter, and sysfs */ |
19 | static int log_ue = 1; | 19 | static int edac_mc_log_ue = 1; |
20 | static int log_ce = 1; | 20 | static int edac_mc_log_ce = 1; |
21 | static int panic_on_ue; | 21 | static int edac_mc_panic_on_ue = 0; |
22 | static int poll_msec = 1000; | 22 | static int edac_mc_poll_msec = 1000; |
23 | 23 | ||
24 | /* Getter functions for above */ | 24 | /* Getter functions for above */ |
25 | int edac_get_log_ue(void) | 25 | int edac_mc_get_log_ue(void) |
26 | { | 26 | { |
27 | return log_ue; | 27 | return edac_mc_log_ue; |
28 | } | 28 | } |
29 | 29 | ||
30 | int edac_get_log_ce(void) | 30 | int edac_mc_get_log_ce(void) |
31 | { | 31 | { |
32 | return log_ce; | 32 | return edac_mc_log_ce; |
33 | } | 33 | } |
34 | 34 | ||
35 | int edac_get_panic_on_ue(void) | 35 | int edac_mc_get_panic_on_ue(void) |
36 | { | 36 | { |
37 | return panic_on_ue; | 37 | return edac_mc_panic_on_ue; |
38 | } | 38 | } |
39 | 39 | ||
40 | /* this is temporary */ | 40 | /* this is temporary */ |
41 | int edac_mc_get_poll_msec(void) | 41 | int edac_mc_get_poll_msec(void) |
42 | { | 42 | { |
43 | return edac_get_poll_msec(); | 43 | return edac_mc_poll_msec; |
44 | } | ||
45 | |||
46 | int edac_get_poll_msec(void) | ||
47 | { | ||
48 | return poll_msec; | ||
49 | } | 44 | } |
50 | 45 | ||
51 | /* Parameter declarations for above */ | 46 | /* Parameter declarations for above */ |
52 | module_param(panic_on_ue, int, 0644); | 47 | module_param(edac_mc_panic_on_ue, int, 0644); |
53 | MODULE_PARM_DESC(panic_on_ue, "Panic on uncorrected error: 0=off 1=on"); | 48 | MODULE_PARM_DESC(edac_mc_panic_on_ue, "Panic on uncorrected error: 0=off 1=on"); |
54 | module_param(log_ue, int, 0644); | 49 | module_param(edac_mc_log_ue, int, 0644); |
55 | MODULE_PARM_DESC(log_ue, "Log uncorrectable error to console: 0=off 1=on"); | 50 | MODULE_PARM_DESC(edac_mc_log_ue, |
56 | module_param(log_ce, int, 0644); | 51 | "Log uncorrectable error to console: 0=off 1=on"); |
57 | MODULE_PARM_DESC(log_ce, "Log correctable error to console: 0=off 1=on"); | 52 | module_param(edac_mc_log_ce, int, 0644); |
58 | module_param(poll_msec, int, 0644); | 53 | MODULE_PARM_DESC(edac_mc_log_ce, |
59 | MODULE_PARM_DESC(poll_msec, "Polling period in milliseconds"); | 54 | "Log correctable error to console: 0=off 1=on"); |
55 | module_param(edac_mc_poll_msec, int, 0644); | ||
56 | MODULE_PARM_DESC(edac_mc_poll_msec, "Polling period in milliseconds"); | ||
60 | 57 | ||
61 | 58 | ||
62 | /* | 59 | /* |
@@ -187,17 +184,32 @@ static struct memctrl_dev_attribute attr_##_name = { \ | |||
187 | }; | 184 | }; |
188 | 185 | ||
189 | /* csrow<id> control files */ | 186 | /* csrow<id> control files */ |
190 | MEMCTRL_ATTR(panic_on_ue,S_IRUGO|S_IWUSR,memctrl_int_show,memctrl_int_store); | 187 | MEMCTRL_ATTR(edac_mc_panic_on_ue, |
191 | MEMCTRL_ATTR(log_ue,S_IRUGO|S_IWUSR,memctrl_int_show,memctrl_int_store); | 188 | S_IRUGO | S_IWUSR, |
192 | MEMCTRL_ATTR(log_ce,S_IRUGO|S_IWUSR,memctrl_int_show,memctrl_int_store); | 189 | memctrl_int_show, |
193 | MEMCTRL_ATTR(poll_msec,S_IRUGO|S_IWUSR,memctrl_int_show,memctrl_int_store); | 190 | memctrl_int_store); |
191 | |||
192 | MEMCTRL_ATTR(edac_mc_log_ue, | ||
193 | S_IRUGO|S_IWUSR, | ||
194 | memctrl_int_show, | ||
195 | memctrl_int_store); | ||
196 | |||
197 | MEMCTRL_ATTR(edac_mc_log_ce, | ||
198 | S_IRUGO|S_IWUSR, | ||
199 | memctrl_int_show, | ||
200 | memctrl_int_store); | ||
201 | |||
202 | MEMCTRL_ATTR(edac_mc_poll_msec, | ||
203 | S_IRUGO|S_IWUSR, | ||
204 | memctrl_int_show, | ||
205 | memctrl_int_store); | ||
194 | 206 | ||
195 | /* Base Attributes of the memory ECC object */ | 207 | /* Base Attributes of the memory ECC object */ |
196 | static struct memctrl_dev_attribute *memctrl_attr[] = { | 208 | static struct memctrl_dev_attribute *memctrl_attr[] = { |
197 | &attr_panic_on_ue, | 209 | &attr_edac_mc_panic_on_ue, |
198 | &attr_log_ue, | 210 | &attr_edac_mc_log_ue, |
199 | &attr_log_ce, | 211 | &attr_edac_mc_log_ce, |
200 | &attr_poll_msec, | 212 | &attr_edac_mc_poll_msec, |
201 | NULL, | 213 | NULL, |
202 | }; | 214 | }; |
203 | 215 | ||