From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758811AbZADNTz (ORCPT ); Sun, 4 Jan 2009 08:19:55 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751995AbZADNSO (ORCPT ); Sun, 4 Jan 2009 08:18:14 -0500 Received: from relay1.sgi.com ([192.48.179.29]:54031 "EHLO relay.sgi.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751570AbZADNSJ (ORCPT ); Sun, 4 Jan 2009 08:18:09 -0500 Message-Id: <20090104131800.317064000@polaris-admin.engr.sgi.com> User-Agent: quilt/0.47-1 Date: Sun, 04 Jan 2009 05:18:02 -0800 From: Mike Travis To: Ingo Molnar Cc: Rusty Russell , "H. Peter Anvin" , Thomas Gleixner , Linus Torvalds , Jack Steiner , linux-kernel@vger.kernel.org, Jesse Barnes Subject: [PATCH 03/11] cpumask: update pci_bus_show_cpuaffinity to use new cpumask API References: <20090104131759.865331000@polaris-admin.engr.sgi.com> Content-Disposition: inline; filename=cpumask:update-pci_bus_show_cpuaffinity.patch Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Impact: cleanup, reduce stack usage, use new cpumask API. Replace the local cpumask_t variable with a pointer to the const cpumask that needs to be printed. Signed-off-by: Mike Travis Cc: Jesse Barnes --- drivers/pci/probe.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) --- linux-2.6-for-ingo.orig/drivers/pci/probe.c +++ linux-2.6-for-ingo/drivers/pci/probe.c @@ -51,12 +51,12 @@ static ssize_t pci_bus_show_cpuaffinity( 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;