From patchwork Tue May 22 13:10:27 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Helgaas X-Patchwork-Id: 10418635 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 29B546032A for ; Tue, 22 May 2018 13:11:33 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 17B8128D7A for ; Tue, 22 May 2018 13:11:33 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 123A428DF0; Tue, 22 May 2018 13:11:33 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DECE028E12 for ; Tue, 22 May 2018 13:10:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751369AbeEVNKc (ORCPT ); Tue, 22 May 2018 09:10:32 -0400 Received: from mail.kernel.org ([198.145.29.99]:39272 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751196AbeEVNK3 (ORCPT ); Tue, 22 May 2018 09:10:29 -0400 Received: from localhost (173-24-227-115.client.mchsi.com [173.24.227.115]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id B2CA320853; Tue, 22 May 2018 13:10:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1526994629; bh=ZoNQbCDPGMWwNb8KKayEkuq/R/RaLy7/KuH5B+MOXEI=; h=Subject:From:To:Cc:Date:In-Reply-To:References:From; b=htYjuq3ZM6HTPsRuJdrof7Z0weeMRWP7gvyv3cjcUz8SvXLHD3mf8tQ/ACDBpUlCE 2v/fVP7oByYUmB8uThdbLqFz8HUVZBv2msCZIWFhePjlajvctvM9iNa3GZ4kY6eWXF Zquu3szaq4OvoMoZv84b3/jXKF60NkGZBKFkpEHk= Subject: [PATCH v1 3/3] xtensa/PCI: Use dev_printk() when possible From: Bjorn Helgaas To: linux-pci@vger.kernel.org Cc: Chris Zankel , Max Filippov , linux-xtensa@linux-xtensa.org, linux-kernel@vger.kernel.org Date: Tue, 22 May 2018 08:10:27 -0500 Message-ID: <152699462765.162480.7860807553501499399.stgit@bhelgaas-glaptop.roam.corp.google.com> In-Reply-To: <152699456050.162480.13521209483758803324.stgit@bhelgaas-glaptop.roam.corp.google.com> References: <152699456050.162480.13521209483758803324.stgit@bhelgaas-glaptop.roam.corp.google.com> User-Agent: StGit/0.18 MIME-Version: 1.0 Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Bjorn Helgaas Use the pci_info() and pci_err() wrappers for dev_printk() when possible. Signed-off-by: Bjorn Helgaas --- arch/xtensa/kernel/pci.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/arch/xtensa/kernel/pci.c b/arch/xtensa/kernel/pci.c index e121b555fdb4..21f13e9aabe1 100644 --- a/arch/xtensa/kernel/pci.c +++ b/arch/xtensa/kernel/pci.c @@ -179,8 +179,7 @@ int pcibios_enable_device(struct pci_dev *dev, int mask) for (idx=0; idx<6; idx++) { r = &dev->resource[idx]; if (!r->start && r->end) { - pr_err("PCI: Device %s not available because " - "of resource collisions\n", pci_name(dev)); + pci_err(dev, "can't enable device: resource collisions\n"); return -EINVAL; } if (r->flags & IORESOURCE_IO) @@ -189,8 +188,7 @@ int pcibios_enable_device(struct pci_dev *dev, int mask) cmd |= PCI_COMMAND_MEMORY; } if (cmd != old_cmd) { - pr_info("PCI: Enabling device %s (%04x -> %04x)\n", - pci_name(dev), old_cmd, cmd); + pci_info(dev, "enabling device (%04x -> %04x)\n", old_cmd, cmd); pci_write_config_word(dev, PCI_COMMAND, cmd); }