From patchwork Wed Nov 22 22:49:18 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sinan Kaya X-Patchwork-Id: 10071885 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 45A526038F for ; Wed, 22 Nov 2017 23:06:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 373BB288FA for ; Wed, 22 Nov 2017 23:06:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2C1A2298EC; Wed, 22 Nov 2017 23:06:54 +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=-4.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id B18BA288FA for ; Wed, 22 Nov 2017 23:06:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=FMq3u3z6GKxgYgbqcRka7ES+iAI1qfELprqPnxMaaQw=; b=noC8bN4gp9hdV01r/FIwf3TTJy bLrGdrMhrFoKmSNtSYQSiFsC8W96rcZjPbLiCURjB0puEOMmfBHGkoYUvfA7JqkiZ/MudfH/54oNc dEBWJr31/qJ7w9fC/dW5rQmB6CP1vMKJPjISl3IfSNSBBk2r171Shxbe+QLJfXRNRUq/q4NR9BKwg 6ZckOJ0kfm46saqVs0wxUsYNp9Ug36FLmsWLJ05EtrjtK9Z1ErwEUb+i72T/2d83D45vGg5QPuOqY ELJFEar5G35hi/stjMm0Z6+TDLFXMM3OaRXnPI05ASdTV880lMzZf/Pt1v3ryllkDrogkF/XMmz6o AfiYhoDA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1eHe6W-0003Fk-Ui; Wed, 22 Nov 2017 23:06:53 +0000 Received: from casper.infradead.org ([2001:8b0:10b:1236::1]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1eHe6F-0002bS-CQ for linux-arm-kernel@bombadil.infradead.org; Wed, 22 Nov 2017 23:06:35 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=tj8IRdijj5xAdfLrdn30+2eDLURdQZDJI80ybWY4XTE=; b=un+bCamriL6CW6qAdtG6/08qZ u2IQVJae4uhRXipNQCGC7f+nltbiJz9RktSCz50o4nWOURZl5Js9qROC3aHk/sLsub5e48IPD3T4O no/l3vda1sxS77Zf0vxV8cNeOh4LiXPF6RGqIxZgS/inoxqeMJawaAOrPoh/efLzAi0+5ldT42a87 xqiMwiJUFFoy1JlfYgIqsVhxB0QjxCWi5HKIPXEqb9ImO4IpSENMOJWXLriQ8ztPlRNd0vZUvnWA7 nN3lA3AOSRHHzMI6AKv2XICJ/XqfoGq0vImCA5USwFGHAWLzAjMteDM2keSEdqYVPorDap/Ly82fp SRsofmRfg==; Received: from smtp.codeaurora.org ([198.145.29.96]) by casper.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1eHdrF-00026L-Ta for linux-arm-kernel@lists.infradead.org; Wed, 22 Nov 2017 22:51:09 +0000 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id EDA0460B77; Wed, 22 Nov 2017 22:50:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1511391046; bh=zq+IGKnenHHC8g+QgxKT48+ZgLPJfN3i5x7l/qpNq5M=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=hSbVEewMMP7PIFtJep7q+Sj/ZojOjsWqgH5jBCP6b1WXi671rP73R2c7XRaC/iD/7 xgSzVqG1/B5O1e5UXsnTD2Q0mWia1ZADkVJj7Fco/LQGEaASC/3oF6RDShqGLYvDfc i/nmhCr9apSmJkUv/mZvEMI67kW+K+bboiJCcyUg= Received: from drakthul.qualcomm.com (global_nat1_iad_fw.qualcomm.com [129.46.232.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: okaya@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 1266360AF9; Wed, 22 Nov 2017 22:50:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1511391041; bh=zq+IGKnenHHC8g+QgxKT48+ZgLPJfN3i5x7l/qpNq5M=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=J1NWxliAUQc5PcgI4lo79b9nTervlMCN2Ny1wCV52pTl18pA9J0IT4VBGkO88Uf54 MGLJltkb0HmaN4MQxZhx/rCRx98FQEk7gg1QzE93fzMB/2Dw9E/z5eVYql1hQVmkGN PSQ3l5DH4Ibr3FVcK4hZEe1deE97a5JIqRPr+svE= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 1266360AF9 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=okaya@codeaurora.org From: Sinan Kaya To: linux-pci@vger.kernel.org, timur@codeaurora.org Subject: [PATCH V2 23/29] staging: rts5208: deprecate pci_get_bus_and_slot() Date: Wed, 22 Nov 2017 17:49:18 -0500 Message-Id: <1511390964-9979-24-git-send-email-okaya@codeaurora.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1511390964-9979-1-git-send-email-okaya@codeaurora.org> References: <1511390964-9979-1-git-send-email-okaya@codeaurora.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20171122_225106_309657_F5D8BFEE X-CRM114-Status: GOOD ( 12.60 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "open list:STAGING SUBSYSTEM" , "Martin K. Petersen" , Greg Kroah-Hartman , linux-arm-msm@vger.kernel.org, open list , Sinan Kaya , Hannes Reinecke , Gaurav Pathak , Colin Ian King , linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as where a PCI device is present. This restricts the device drivers to be reused for other domain numbers. Getting ready to remove pci_get_bus_and_slot() function in favor of pci_get_domain_bus_and_slot(). Remove unused rtsx_read_pci_cfg_byte() function. Signed-off-by: Sinan Kaya --- drivers/staging/rts5208/rtsx.c | 17 ----------------- drivers/staging/rts5208/rtsx.h | 2 -- 2 files changed, 19 deletions(-) diff --git a/drivers/staging/rts5208/rtsx.c b/drivers/staging/rts5208/rtsx.c index 89e2cfe..70e0b86 100644 --- a/drivers/staging/rts5208/rtsx.c +++ b/drivers/staging/rts5208/rtsx.c @@ -275,23 +275,6 @@ static int rtsx_acquire_irq(struct rtsx_dev *dev) return 0; } -int rtsx_read_pci_cfg_byte(u8 bus, u8 dev, u8 func, u8 offset, u8 *val) -{ - struct pci_dev *pdev; - u8 data; - u8 devfn = (dev << 3) | func; - - pdev = pci_get_bus_and_slot(bus, devfn); - if (!pdev) - return -1; - - pci_read_config_byte(pdev, offset, &data); - if (val) - *val = data; - - return 0; -} - #ifdef CONFIG_PM /* * power management diff --git a/drivers/staging/rts5208/rtsx.h b/drivers/staging/rts5208/rtsx.h index 575e573..62e467c 100644 --- a/drivers/staging/rts5208/rtsx.h +++ b/drivers/staging/rts5208/rtsx.h @@ -174,8 +174,6 @@ static inline void get_current_time(u8 *timeval_buf, int buf_len) /* struct scsi_cmnd transfer buffer access utilities */ enum xfer_buf_dir {TO_XFER_BUF, FROM_XFER_BUF}; -int rtsx_read_pci_cfg_byte(u8 bus, u8 dev, u8 func, u8 offset, u8 *val); - #define _MSG_TRACE #include "trace.h"