1
0
Fork 0

cpumask: update pci_bus_show_cpuaffinity 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>
hifive-unleashed-5.1
Mike Travis 2009-01-04 05:18:02 -08:00 committed by Ingo Molnar
parent 3be83050d0
commit 588235bb53
1 changed files with 4 additions and 4 deletions

View File

@ -51,12 +51,12 @@ static ssize_t pci_bus_show_cpuaffinity(struct device *dev,
char *buf)
{
int ret;
cpumask_t cpumask;
const struct cpumask *cpumask;
cpumask = pcibus_to_cpumask(to_pci_bus(dev));
cpumask = cpumask_of_pcibus(to_pci_bus(dev));
ret = type?
cpulist_scnprintf(buf, PAGE_SIZE-2, &cpumask) :
cpumask_scnprintf(buf, PAGE_SIZE-2, &cpumask);
cpulist_scnprintf(buf, PAGE_SIZE-2, cpumask) :
cpumask_scnprintf(buf, PAGE_SIZE-2, cpumask);
buf[ret++] = '\n';
buf[ret] = '\0';
return ret;