From patchwork Mon Jan 14 11:15:04 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kishon Vijay Abraham I X-Patchwork-Id: 155445 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp3537136jaa; Mon, 14 Jan 2019 03:17:12 -0800 (PST) X-Google-Smtp-Source: ALg8bN4iXOEXvw4mRnAejxXPIzxnwMpgfckyhZ4mAMPzhmxK7Hmi16+u/F12M2HQt8tjcQtNS+e5 X-Received: by 2002:a17:902:b592:: with SMTP id a18mr24969398pls.293.1547464632356; Mon, 14 Jan 2019 03:17:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1547464632; cv=none; d=google.com; s=arc-20160816; b=HSdt1ptf0G65vPOh9wCH4h+Tiyo2FiktRMRrXpCejv4srFQ5YzrpYroyBL+do6rxsh UNO33IdZUXMY7CJHvmMDp4RW8Co6XXsEFRkxaPg3gRyZ2l5PzMWPgYqjuxcXFXMBjUUF g7awusiJqOCHIeGPiwbZSJzdY2t6CgXN39QcyIq3fq7zOAKJn3jqUEugIjL548CP7/KC w3819nvMTAZkPHYftLyFaEV0FNkPp0bZQWX3Nd0iXVfSG5uQK+7w55y8OkWVLJGEgNH0 hZMEExKK6kmHLJwCeS9+xtIP63RrO8cXB+n605Fa3jueIzuuHHV7XPDkNwZnIZC/obdP 0YCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=7BZqM5lihQv/21d7TmC8rclZDArMN5iGSCdWQmZG2ac=; b=M9t+Frdu72shE8YI8y8wPZYR3yzCgALLiieJ/0xOvhADMHIqGtPgD4IvIL23N8cur+ EXPKgoXva2hiAv6+KKE4g48B8f7GLqDO3UM2rCtIMNo5ObeWB77Xo/joLQoJ6im23l+p CPxtFFaBCuiWPy463pFVfppjs/mjvdnBHJ2Rjz/Yzxca0PpYVbyuIMZJOAfuLC+j1lWL kfmyUT6BdJyjcw6bZeeiyc0zpa3cEesbyK16nQ7mxX5g3fVbeLWgw1H1jdoVzkbAVjex iufVg39EH/PQZBVvnBQ5Vee/6hWSvWewcYOhDYKgJiyWB6bwsIzM9OR9bzFXDqIEAPF2 tQvg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=GIfksZU0; spf=pass (google.com: best guess record for domain of linux-omap-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-omap-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s5si113260plr.211.2019.01.14.03.17.12; Mon, 14 Jan 2019 03:17:12 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-omap-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=GIfksZU0; spf=pass (google.com: best guess record for domain of linux-omap-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-omap-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726717AbfANLRL (ORCPT + 5 others); Mon, 14 Jan 2019 06:17:11 -0500 Received: from fllv0016.ext.ti.com ([198.47.19.142]:46942 "EHLO fllv0016.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726561AbfANLRK (ORCPT ); Mon, 14 Jan 2019 06:17:10 -0500 Received: from fllv0035.itg.ti.com ([10.64.41.0]) by fllv0016.ext.ti.com (8.15.2/8.15.2) with ESMTP id x0EBG7v4065534; Mon, 14 Jan 2019 05:16:07 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1547464567; bh=7BZqM5lihQv/21d7TmC8rclZDArMN5iGSCdWQmZG2ac=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=GIfksZU0asNRdI/5vQsV4tUZexlZKhQB4LfC/1SQ3pNhNql+KyuYm9n/aPAIWmw+/ Cae7oVjCA4PP68r6h8tlYCqxO54dCGj5yuwbEiPZgfN5j6JVvNcBL0ATZsc5ceYj4j pdTHAvjSH7nMSWJuVrQsNFmMguGJa3atG+1y2+/0= Received: from DFLE101.ent.ti.com (dfle101.ent.ti.com [10.64.6.22]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id x0EBG66f100457 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 14 Jan 2019 05:16:06 -0600 Received: from DFLE108.ent.ti.com (10.64.6.29) by DFLE101.ent.ti.com (10.64.6.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1591.10; Mon, 14 Jan 2019 05:16:06 -0600 Received: from dflp32.itg.ti.com (10.64.6.15) by DFLE108.ent.ti.com (10.64.6.29) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.1591.10 via Frontend Transport; Mon, 14 Jan 2019 05:16:06 -0600 Received: from a0393678ub.india.ti.com (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp32.itg.ti.com (8.14.3/8.13.8) with ESMTP id x0EBFd1Y011560; Mon, 14 Jan 2019 05:16:03 -0600 From: Kishon Vijay Abraham I To: Kishon Vijay Abraham I , Lorenzo Pieralisi , Gustavo Pimentel , Alan Douglas , Shawn Lin , Heiko Stuebner CC: Bjorn Helgaas , Jingoo Han , , , , , Subject: [PATCH v2 06/15] PCI: cadence: Populate ->get_features() cdns_pcie_epc_ops Date: Mon, 14 Jan 2019 16:45:04 +0530 Message-ID: <20190114111513.21618-7-kishon@ti.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190114111513.21618-1-kishon@ti.com> References: <20190114111513.21618-1-kishon@ti.com> MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org Populate ->get_features() dw_pcie_ep_ops to return the EPC features supported by Cadence PCIe endpoint controller. Signed-off-by: Kishon Vijay Abraham I --- drivers/pci/controller/pcie-cadence-ep.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) -- 2.17.1 diff --git a/drivers/pci/controller/pcie-cadence-ep.c b/drivers/pci/controller/pcie-cadence-ep.c index c3a088910f48..14c2545bb17e 100644 --- a/drivers/pci/controller/pcie-cadence-ep.c +++ b/drivers/pci/controller/pcie-cadence-ep.c @@ -411,6 +411,18 @@ static int cdns_pcie_ep_start(struct pci_epc *epc) return 0; } +static const struct pci_epc_features cdns_pcie_epc_features = { + .linkup_notifier = false, + .msi_capable = true, + .msix_capable = false, +}; + +static const struct pci_epc_features* +cdns_pcie_ep_get_features(struct pci_epc *epc, u8 func_no) +{ + return &cdns_pcie_epc_features; +} + static const struct pci_epc_ops cdns_pcie_epc_ops = { .write_header = cdns_pcie_ep_write_header, .set_bar = cdns_pcie_ep_set_bar, @@ -421,6 +433,7 @@ static const struct pci_epc_ops cdns_pcie_epc_ops = { .get_msi = cdns_pcie_ep_get_msi, .raise_irq = cdns_pcie_ep_raise_irq, .start = cdns_pcie_ep_start, + .get_features = cdns_pcie_ep_get_features, }; static const struct of_device_id cdns_pcie_ep_of_match[] = {