Received: by 2002:a05:6a11:4021:0:0:0:0 with SMTP id ky33csp1786556pxb; Fri, 24 Sep 2021 11:49:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz7KK+iSgbB/f7KcWPEK2zzqKa/YGY8MUZFNHZeuIL1tIPPhluXiAi2JlhMgoYB2N7z5Qz3 X-Received: by 2002:a02:11c1:: with SMTP id 184mr10845140jaf.70.1632509370490; Fri, 24 Sep 2021 11:49:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632509370; cv=none; d=google.com; s=arc-20160816; b=egbjEL+u34aleyY03LICcXp/6w6MIzXrcVBbH1EhO1Gq06lno3vPeTQ5EawYliFz3S hxZp0qJgyuALUV3Egcnk95NwL/j2n7QQa/WMF/Fxw9qc/IWUie2MQlm9R9J3zHfHvq3k qu3FcIFpvpJOck+4mMD2q4ehumr+Uf6DhuxPK3nG1AyDWHVmXMbL30xE/YbmsAnozrku /hTd9ayisFMG9opKpI+pybAkRxYE/7urdP7qaeWnYOQzlNiscoRPqbbftU6ZVWUCjoLx 0OC0seMkZGKNnVKMbrsNApywxmPxlLJTOb46Ig1mI6rx3JP+EYwlIkbYxsnFQCZiS+N0 BwsA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=UChjW0Gsum4cQTsPCvCh0aMR/d2uK6Je1No538OrmGE=; b=v6n5M1GefGfahTyw7AJdeG1kaTJUk084snBzsQTaR04hgL71QVHJlQxjFzJm2HOkxy 5W/k+I8CRLsAZuGvCt0hjX/eRgHlKngpUWvqkGPQL+gGUKsaJ2QwpiowzhE1e308Oqpk 7WI0Q3IoFJbh+Z7UvEX8CX7XNV8E7BpjTMlzkr9Ga8U1fq2gc8uxcIeh9e4jgtKuLQyt YO00GSpWSaeCvHV97239kGbtrjXwk2YzD/3IkOXB2k3odznNrl11cVODCo0Nh8h1NBqv elsLHeGMjT8Z0ofgTzROkaytcjmRWo7T1XmoEt2JNhyqw3EjPj07Xac2YA3CFvgITEQS aXFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="ThWu/gbu"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id s85si13303161ios.68.2021.09.24.11.49.16; Fri, 24 Sep 2021 11:49:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="ThWu/gbu"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346359AbhIXNPn (ORCPT + 99 others); Fri, 24 Sep 2021 09:15:43 -0400 Received: from mail.kernel.org ([198.145.29.99]:38620 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346721AbhIXNLf (ORCPT ); Fri, 24 Sep 2021 09:11:35 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 558486159A; Fri, 24 Sep 2021 12:58:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1632488316; bh=BGaO2d5KMqAdaiWzfa1+0RVyVlGMslFN3ltylz4C+zY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ThWu/gbuA71u+vTbWMEaj8div5REetcUbmKzy19K2uuY/Bzt2p3+PjsUgZgoHAWik fuau8bHeSjrk83J7/AAGRbhYe4B3X0XoLa2BOckrZuDbDtkjW5eYQ6tNbnuAfvIKCj KKa4p4cTa8ZPWrD+Z45kK21ipVruyvHwN4etl7SE= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Helge Deller , Guenter Roeck , Sasha Levin Subject: [PATCH 5.10 38/63] parisc: Move pci_dev_is_behind_card_dino to where it is used Date: Fri, 24 Sep 2021 14:44:38 +0200 Message-Id: <20210924124335.582488723@linuxfoundation.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20210924124334.228235870@linuxfoundation.org> References: <20210924124334.228235870@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Guenter Roeck [ Upstream commit 907872baa9f1538eed02ec737b8e89eba6c6e4b9 ] parisc build test images fail to compile with the following error. drivers/parisc/dino.c:160:12: error: 'pci_dev_is_behind_card_dino' defined but not used Move the function just ahead of its only caller to avoid the error. Fixes: 5fa1659105fa ("parisc: Disable HP HSC-PCI Cards to prevent kernel crash") Cc: Helge Deller Signed-off-by: Guenter Roeck Signed-off-by: Helge Deller Signed-off-by: Sasha Levin --- drivers/parisc/dino.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/drivers/parisc/dino.c b/drivers/parisc/dino.c index 889d7ce282eb..952a92504df6 100644 --- a/drivers/parisc/dino.c +++ b/drivers/parisc/dino.c @@ -156,15 +156,6 @@ static inline struct dino_device *DINO_DEV(struct pci_hba_data *hba) return container_of(hba, struct dino_device, hba); } -/* Check if PCI device is behind a Card-mode Dino. */ -static int pci_dev_is_behind_card_dino(struct pci_dev *dev) -{ - struct dino_device *dino_dev; - - dino_dev = DINO_DEV(parisc_walk_tree(dev->bus->bridge)); - return is_card_dino(&dino_dev->hba.dev->id); -} - /* * Dino Configuration Space Accessor Functions */ @@ -447,6 +438,15 @@ static void quirk_cirrus_cardbus(struct pci_dev *dev) DECLARE_PCI_FIXUP_ENABLE(PCI_VENDOR_ID_CIRRUS, PCI_DEVICE_ID_CIRRUS_6832, quirk_cirrus_cardbus ); #ifdef CONFIG_TULIP +/* Check if PCI device is behind a Card-mode Dino. */ +static int pci_dev_is_behind_card_dino(struct pci_dev *dev) +{ + struct dino_device *dino_dev; + + dino_dev = DINO_DEV(parisc_walk_tree(dev->bus->bridge)); + return is_card_dino(&dino_dev->hba.dev->id); +} + static void pci_fixup_tulip(struct pci_dev *dev) { if (!pci_dev_is_behind_card_dino(dev)) -- 2.33.0