Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp4081735ybi; Mon, 29 Jul 2019 18:51:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqzIE+F5Aeev9jkmbltChAC8p7zgpGjyE4aGU6SC2U/R4G8zLDCKHyM+Ei/R/vMq49g357MT X-Received: by 2002:a17:902:102c:: with SMTP id b41mr110834953pla.204.1564451505868; Mon, 29 Jul 2019 18:51:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564451505; cv=none; d=google.com; s=arc-20160816; b=vJe9EgteVHH5Ik3q6X4PbVRTM3fWZHHC2zP+R3KW75nkRTUMG2p1qErmTZvBsjNS2o pu75jhLk9IcZ6vdAmJO/flyA8M5GRpXaU3WqmPf++SUthaNBZ+H9+NkLwE3sUdGaM65R 05Pm7mIKz/GHpSZ++eZejL0H2ta0GRvz+36H6zzoMmdvz07R6AEB24Lev/BcOem1iR0d GeYZdtFwmXKnDaKoYbBZeB6xt13Lyjtu5jTXmlvzDe16EK5dkbIkqjOAh1/PRsOUGrm9 8D01FY6ptpQDdbQVHdjquq0mNjXYmBW++YpnNAPGB5irnJ8LocWkjL6UJb/Pp2lsyczT AX6g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=TXYqSscv9Opu79YnaMFvmbKuptk+xwtrhpGLRKbiLxg=; b=FC0Nokf65lwqQqgLirPo5/zZrnsyzMEzKSYQ4yStWL9+SIofoMf6eNH9IpJAay0FUH Ei4sPD/aifkvPxxfw8nBv27lcl8yYZmyCEiq5euSM22AD/mQ+MD0grv3SBfAASlOJtwk z3OXNN1raA56KvK3cU6p5/GLXjL+jCHK6/54YWLPbf8pYrwxyr0LOqwKNyqh0cKs9Xv7 oNUcYi7LMoa/TiXozSnLmzXI4mjphDbuzuNd3qbvdXQfw2XmU2awlCRQbIyhefMqb9Dd NACqFNfzBYMLBwahoMNEv9ygj7w7cWGwcDSDOR9ipGIpwYTm4rBKr9/FkMunUWZMxvtw eq/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=0bXh2NRF; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v7si32915358pfb.132.2019.07.29.18.51.31; Mon, 29 Jul 2019 18:51:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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=@kernel.org header.s=default header.b=0bXh2NRF; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389479AbfG2TmW (ORCPT + 99 others); Mon, 29 Jul 2019 15:42:22 -0400 Received: from mail.kernel.org ([198.145.29.99]:58018 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389316AbfG2TmU (ORCPT ); Mon, 29 Jul 2019 15:42:20 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (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 A18292054F; Mon, 29 Jul 2019 19:42:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1564429339; bh=aXYymebGDijswDt5Qlb5JMim/POmyUbYkuzpcQQJ4I8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=0bXh2NRFgbO8hgSZ1wwm1URL7sWoh662msSalM4YxjXs2hM+Hwck9DEVXBBrv6Lcl MybCw2SKp4zXvNjbAHtwFgYw0B/SiX4qCyf8ZILo4MDqriczavBNdf/9kGxhxnglOg GB7KgoKRN0YUgn/i52jK3Y61fTHT3aKml3s+WBbM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hou Zhiqiang , Lorenzo Pieralisi , Minghuan Lian , Subrahmanya Lingappa , Sasha Levin Subject: [PATCH 4.19 065/113] PCI: mobiveil: Initialize Primary/Secondary/Subordinate bus numbers Date: Mon, 29 Jul 2019 21:22:32 +0200 Message-Id: <20190729190711.053065127@linuxfoundation.org> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190729190655.455345569@linuxfoundation.org> References: <20190729190655.455345569@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [ Upstream commit 6f3ab451aa5c2cbff33197d82fe8489cbd55ad91 ] The reset value of Primary, Secondary and Subordinate bus numbers is zero which is a broken setup. Program a sensible default value for Primary/Secondary/Subordinate bus numbers. Signed-off-by: Hou Zhiqiang Signed-off-by: Lorenzo Pieralisi Reviewed-by: Minghuan Lian Reviewed-by: Subrahmanya Lingappa Signed-off-by: Sasha Levin --- drivers/pci/controller/pcie-mobiveil.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/pci/controller/pcie-mobiveil.c b/drivers/pci/controller/pcie-mobiveil.c index 3e81e68b5ce0..2fe7ebdad2d2 100644 --- a/drivers/pci/controller/pcie-mobiveil.c +++ b/drivers/pci/controller/pcie-mobiveil.c @@ -508,6 +508,12 @@ static int mobiveil_host_init(struct mobiveil_pcie *pcie) return err; } + /* setup bus numbers */ + value = csr_readl(pcie, PCI_PRIMARY_BUS); + value &= 0xff000000; + value |= 0x00ff0100; + csr_writel(pcie, value, PCI_PRIMARY_BUS); + /* * program Bus Master Enable Bit in Command Register in PAB Config * Space -- 2.20.1