aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci
diff options
context:
space:
mode:
authorMike Travis <travis@sgi.com>2009-01-04 08:18:01 -0500
committerIngo Molnar <mingo@elte.hu>2009-01-04 09:39:25 -0500
commit3be83050d0143b515c5effe9c9d54edc41f1a2fa (patch)
tree80c60ace39314ff04f209f8299d64420d56f7549 /drivers/pci
parentd3b66bf2e18777e8389742a38efbd06becfa4775 (diff)
cpumask: update local_cpus_show to use new cpumask API
Impact: use new cpumask API to reduce stack usage Replace the local cpumask_t variable with a pointer to the const cpumask that needs to be printed. Signed-off-by: Mike Travis <travis@sgi.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'drivers/pci')
-rw-r--r--drivers/pci/pci-sysfs.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c
index c88485860a0a..e4957e2c92c9 100644
--- a/drivers/pci/pci-sysfs.c
+++ b/drivers/pci/pci-sysfs.c
@@ -70,11 +70,11 @@ static ssize_t broken_parity_status_store(struct device *dev,
70static ssize_t local_cpus_show(struct device *dev, 70static ssize_t local_cpus_show(struct device *dev,
71 struct device_attribute *attr, char *buf) 71 struct device_attribute *attr, char *buf)
72{ 72{
73 cpumask_t mask; 73 const struct cpumask *mask;
74 int len; 74 int len;
75 75
76 mask = pcibus_to_cpumask(to_pci_dev(dev)->bus); 76 mask = cpumask_of_pcibus(to_pci_dev(dev)->bus);
77 len = cpumask_scnprintf(buf, PAGE_SIZE-2, &mask); 77 len = cpumask_scnprintf(buf, PAGE_SIZE-2, mask);
78 buf[len++] = '\n'; 78 buf[len++] = '\n';
79 buf[len] = '\0'; 79 buf[len] = '\0';
80 return len; 80 return len;
@@ -84,11 +84,11 @@ static ssize_t local_cpus_show(struct device *dev,
84static ssize_t local_cpulist_show(struct device *dev, 84static ssize_t local_cpulist_show(struct device *dev,
85 struct device_attribute *attr, char *buf) 85 struct device_attribute *attr, char *buf)
86{ 86{
87 cpumask_t mask; 87 const struct cpumask *mask;
88 int len; 88 int len;
89 89
90 mask = pcibus_to_cpumask(to_pci_dev(dev)->bus); 90 mask = cpumask_of_pcibus(to_pci_dev(dev)->bus);
91 len = cpulist_scnprintf(buf, PAGE_SIZE-2, &mask); 91 len = cpulist_scnprintf(buf, PAGE_SIZE-2, mask);
92 buf[len++] = '\n'; 92 buf[len++] = '\n';
93 buf[len] = '\0'; 93 buf[len] = '\0';
94 return len; 94 return len;