From patchwork Wed Nov 15 04:56:45 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Oza Pawandeep X-Patchwork-Id: 10058855 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 848886023A for ; Wed, 15 Nov 2017 04:57:56 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7752729D71 for ; Wed, 15 Nov 2017 04:57:56 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6B6C729DB7; Wed, 15 Nov 2017 04:57:56 +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 F0AEC29D71 for ; Wed, 15 Nov 2017 04:57:55 +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=w/ZD7Q9h57tWPwfeSnTgoZVe15a7Iu8xgN68dYDQC5g=; b=gcaTNR/RIFlzANHKx/35fmA1ga QBwvBL04AD7zQzGhP1hsb5goUzLrNheWbsmu2V8aON39kn22cPvbcnYJ+NZajS+ggyZpNZn8FEN6U mJAYHAmE3fQo2LDe0LDSucSyMMXtcQ6PCAPMSnbFwYjRcgSO0nICNLDnpy5qxB/ppr4oAYCqjwP1N 01DRdBLh8xipThasQW1XxfCAcvj0/ZETJyRI1VwhcCxRIVLqPvQ0ij/hfvT77B0iLFy8/XsyuTc6D XKFXyGa/Q5dHxYUDsJLGkhKjmrYIwELMATTthVp/Sof3x4AQIHAGzg87Q1bH3DuybmoqklNvga6NZ NiJ0uA7w==; 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 1eEpli-0000BR-9y; Wed, 15 Nov 2017 04:57:46 +0000 Received: from smtp.codeaurora.org ([198.145.29.96]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1eEplI-00008L-I3 for linux-arm-kernel@lists.infradead.org; Wed, 15 Nov 2017 04:57:22 +0000 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 0106B6084D; Wed, 15 Nov 2017 04:57:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1510721822; bh=KTJLS1gbh26GzdEpupC4Rh/gynGJnPbNEKSLwIayTI0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=DodAZ+06BbG7ZxNPlX6Y+SAVz6l8thlm1jmuc/YdbgCX71S6rDlejg2zATS1GDui7 +dfOM7411s8tvo++7R1NaI2ejfuoMeBxfz3vcQB+NnsJI78wUPhi4ODNICGoEPL/R6 cG/7ECXb8DEg/I35j/uWkMLMElUhDA1Eqz+4olIA= Received: from blr-ubuntu-poza.qualcomm.com (blr-bdr-fw-01_globalnat_allzones-outside.qualcomm.com [103.229.18.19]) (using TLSv1.1 with cipher ECDHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: poza@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 592886081A; Wed, 15 Nov 2017 04:56:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1510721821; bh=KTJLS1gbh26GzdEpupC4Rh/gynGJnPbNEKSLwIayTI0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=meu2eFqCLwZ1iQLO6p7OgPhyZXGAK7fTc7CijnP68liMAPjL8eNviHqb5U7AYnwa9 ZmYUHnWn38rZHarFZ+TCCRY2ZBBkzl9owiLoJq3o/fkK4Jnjgsf3qgXCXuO/dihk1+ znD+hFEHcKcCnntn3eluhdAdHy24pJvGtaH0+pcc= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 592886081A 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=poza@codeaurora.org From: Oza Pawandeep To: linux-pci@vger.kernel.org, okaya@codeaurora.org, timur@codeaurora.org Subject: [PATCH v2 1/4] PCI: Add port service list node for pci_dev. Date: Wed, 15 Nov 2017 10:26:45 +0530 Message-Id: <1510721808-27164-2-git-send-email-poza@codeaurora.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1510721808-27164-1-git-send-email-poza@codeaurora.org> References: <1510721808-27164-1-git-send-email-poza@codeaurora.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20171114_205720_672778_67649E2F X-CRM114-Status: UNSURE ( 9.29 ) X-CRM114-Notice: Please train this message. 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: Oza Pawandeep , Gabriele Paoloni , Greg Kroah-Hartman , Dongdong Liu , linux-arm-msm@vger.kernel.org, Bjorn Helgaas , Thomas Gleixner , 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 This patch adds the list node to keep track of services registered to pci port driver. Signed-off-by: Oza Pawandeep diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c index 14e0ea1..f772979 100644 --- a/drivers/pci/probe.c +++ b/drivers/pci/probe.c @@ -1931,6 +1931,7 @@ struct pci_dev *pci_alloc_dev(struct pci_bus *bus) return NULL; INIT_LIST_HEAD(&dev->bus_list); + INIT_LIST_HEAD(&dev->service_list); dev->dev.type = &pci_dev_type; dev->bus = pci_bus_get(bus); diff --git a/include/linux/pci.h b/include/linux/pci.h index 96c9498..eb86a4b 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -408,6 +408,8 @@ struct pci_dev { struct bin_attribute *res_attr[DEVICE_COUNT_RESOURCE]; /* sysfs file for resources */ struct bin_attribute *res_attr_wc[DEVICE_COUNT_RESOURCE]; /* sysfs file for WC mapping of resources */ + struct list_head service_list; /* node in per-service list */ + #ifdef CONFIG_PCIE_PTM unsigned int ptm_root:1; unsigned int ptm_enabled:1;