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: 10058839 X-Patchwork-Delegate: agross@codeaurora.org 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 2E60D6023A for ; Wed, 15 Nov 2017 04:57:05 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 22BFC29D34 for ; Wed, 15 Nov 2017 04:57:05 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1775029DB7; Wed, 15 Nov 2017 04:57:05 +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=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham 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 B9C2029D34 for ; Wed, 15 Nov 2017 04:57:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753556AbdKOE5D (ORCPT ); Tue, 14 Nov 2017 23:57:03 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:38750 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752233AbdKOE5C (ORCPT ); Tue, 14 Nov 2017 23:57:02 -0500 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 0DBB060852; 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 Cc: Bjorn Helgaas , Dongdong Liu , Gabriele Paoloni , Thomas Gleixner , Greg Kroah-Hartman , linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Oza Pawandeep 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> Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.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;