From patchwork Fri Jan 24 09:23:19 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 233099 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.8 required=3.0 tests=DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7C126C2D0DB for ; Fri, 24 Jan 2020 10:09:31 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 4FF6720709 for ; Fri, 24 Jan 2020 10:09:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1579860571; bh=WbL5FrtL+GKODvfT5Wqg3jR04ZlK0I6T0T3zcFvSMDg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=dcHSeHkeh3AT7moS7/dNvvQ+Va5Z/1Az+G6o4t0P+FmEMQA7aPw3BWzgeiNmGIRhS MjmauAV2PlTAILdioKGWDhv5FUXybJhVfD0YgpO2t66ioAWyUGFyErEcu0FmwN57Rx pOmR6Yl8LH+FWTWGrNY1c+Ar1T3iPYPuQFtQmQIw= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389622AbgAXKJa (ORCPT ); Fri, 24 Jan 2020 05:09:30 -0500 Received: from mail.kernel.org ([198.145.29.99]:46450 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389250AbgAXKJ3 (ORCPT ); Fri, 24 Jan 2020 05:09:29 -0500 Received: from localhost (unknown [145.15.244.15]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2753820709; Fri, 24 Jan 2020 10:09:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1579860568; bh=WbL5FrtL+GKODvfT5Wqg3jR04ZlK0I6T0T3zcFvSMDg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=w/UWCUfyR2q/mOxGlBA5lJo8+JcvsZYwKbMAbF9BfULXUufMPFID3nxZgm7TAT6VW 7koPnzqmCX80p6cDC16Ui46h1Vz8nNppXW8qHeL3c7EmHe3tLno7kkfIcjNJUTi4vC YQcmMeQQ0FOXSI9yPe5NpLzYMykH+NST2Xt5CGz4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jitendra Bhivare , Ray Jui , Lorenzo Pieralisi , Andy Gospodarek , Sasha Levin Subject: [PATCH 4.19 029/639] PCI: iproc: Remove PAXC slot check to allow VF support Date: Fri, 24 Jan 2020 10:23:19 +0100 Message-Id: <20200124093051.009814605@linuxfoundation.org> X-Mailer: git-send-email 2.25.0 In-Reply-To: <20200124093047.008739095@linuxfoundation.org> References: <20200124093047.008739095@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Jitendra Bhivare [ Upstream commit 4da6b4480766e5bc9c4d7bc14bf1d0939a1a5fa7 ] Fix previous incorrect logic that limits PAXC slot number to zero only. In order for SRIOV/VF to work, we need to allow the slot number to be greater than zero. Fixes: 46560388c476c ("PCI: iproc: Allow multiple devices except on PAXC") Signed-off-by: Jitendra Bhivare Signed-off-by: Ray Jui Signed-off-by: Lorenzo Pieralisi Reviewed-by: Andy Gospodarek Signed-off-by: Sasha Levin --- drivers/pci/controller/pcie-iproc.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/drivers/pci/controller/pcie-iproc.c b/drivers/pci/controller/pcie-iproc.c index 3160e9342a2fb..c20fd6bd68fd8 100644 --- a/drivers/pci/controller/pcie-iproc.c +++ b/drivers/pci/controller/pcie-iproc.c @@ -630,14 +630,6 @@ static void __iomem *iproc_pcie_map_cfg_bus(struct iproc_pcie *pcie, return (pcie->base + offset); } - /* - * PAXC is connected to an internally emulated EP within the SoC. It - * allows only one device. - */ - if (pcie->ep_is_internal) - if (slot > 0) - return NULL; - return iproc_pcie_map_ep_cfg_reg(pcie, busno, slot, fn, where); }