Received: by 10.192.165.148 with SMTP id m20csp4179042imm; Mon, 30 Apr 2018 13:17:24 -0700 (PDT) X-Google-Smtp-Source: AB8JxZrd2Z9C6zFsS1RJyAUEXN6YGgf4lzJpcdpuDGS65cHtQOSEdkCnjqd0RjI/8F5eEoOCPahv X-Received: by 2002:a65:6023:: with SMTP id p3-v6mr10753621pgu.175.1525119444037; Mon, 30 Apr 2018 13:17:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525119444; cv=none; d=google.com; s=arc-20160816; b=YtRrhSLim6WsxR7oEo5n71/M0NtZep9vWStd4v1hLrXjN6N+RiGcaef2+ctAyqotrd +WW+PqWTrW5zOr0tPfHP0hsX09f++OIb/c1t1vcrK251c+DKRV+X68qggjedgyl0frpH Vkn3dibbdvK0S3iW8GyMVd0NBaz14yHsuY6ze1DWHlzqzXR367HsYFYuHLvVUQEyCTzG yL41jh8kj6qd5R8Vic31DxflAOnxoB5Y6LRHweyzSWUaxWE6z7gvbva+y9jupp6moZjy zaKFTqnZVwiqCySFURRZQnk00u7xY/M3gwsnF6MMHWWE0NSnarZW0niMhLXJXUZPZ85y tnLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from:dmarc-filter :arc-authentication-results; bh=YTS92WL8cGpoOYoSkgefdX29oamHMbC4jphuNa8r/3k=; b=I0n9wtSUXuRj8qhGdmhiMfuDf6HkNkEPbrxVQzFC6GjZL19MIN+gpYK+paMHUn2ZbF o/K1Iu36avWiyLhdlxJ56r+VpQGHZOldopcdsx+Yyah1Tc/vCPaHPkuH6szXV/uWLj85 q79Q5C1nC7j9pWQE43JIOm+4s/cBBvFud1a4yKQuDN66r+mzSmSiGc9YmIzHJRmeNObU ALUgaajiRKd6mt10qa3NtGm2eF08EQqnxpTEd8M0HQFXq9698zXVfb8Dfa2rQ0U4XD0h OGRS1xDS2qcqo5FF1y+09HqHJGvV55nWiKd28lNIAzaOemgwLzOxXaUDVfmw+1l7bDAv VjAQ== ARC-Authentication-Results: i=1; mx.google.com; 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 3-v6si7990514plv.323.2018.04.30.13.17.09; Mon, 30 Apr 2018 13:17:23 -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; 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 S932081AbeD3T1B (ORCPT + 99 others); Mon, 30 Apr 2018 15:27:01 -0400 Received: from mail.kernel.org ([198.145.29.99]:60820 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755785AbeD3T0u (ORCPT ); Mon, 30 Apr 2018 15:26:50 -0400 Received: from localhost (unknown [104.132.1.102]) (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 EA3D822E01; Mon, 30 Apr 2018 19:26:49 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EA3D822E01 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linuxfoundation.org Authentication-Results: mail.kernel.org; spf=fail smtp.mailfrom=gregkh@linuxfoundation.org From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Evan Wang , Victor Gu , Nadav Haklai , Thomas Petazzoni , Lorenzo Pieralisi Subject: [PATCH 4.9 43/61] PCI: aardvark: Fix PCIe Max Read Request Size setting Date: Mon, 30 Apr 2018 12:24:46 -0700 Message-Id: <20180430183955.000933042@linuxfoundation.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180430183951.312721450@linuxfoundation.org> References: <20180430183951.312721450@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.9-stable review patch. If anyone has any objections, please let me know. ------------------ From: Evan Wang commit fc31c4e347c9dad50544d01d5ee98b22c7df88bb upstream. There is an obvious typo issue in the definition of the PCIe maximum read request size: a bit shift is directly used as a value, while it should be used to shift the correct value. Fixes: 8c39d710363c1 ("PCI: aardvark: Add Aardvark PCI host controller driver") Cc: Signed-off-by: Evan Wang Reviewed-by: Victor Gu Reviewed-by: Nadav Haklai [Thomas: tweak commit log.] Signed-off-by: Thomas Petazzoni Signed-off-by: Lorenzo Pieralisi Signed-off-by: Greg Kroah-Hartman --- drivers/pci/host/pci-aardvark.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) --- a/drivers/pci/host/pci-aardvark.c +++ b/drivers/pci/host/pci-aardvark.c @@ -32,6 +32,7 @@ #define PCIE_CORE_DEV_CTRL_STATS_MAX_PAYLOAD_SZ_SHIFT 5 #define PCIE_CORE_DEV_CTRL_STATS_SNOOP_DISABLE (0 << 11) #define PCIE_CORE_DEV_CTRL_STATS_MAX_RD_REQ_SIZE_SHIFT 12 +#define PCIE_CORE_DEV_CTRL_STATS_MAX_RD_REQ_SZ 0x2 #define PCIE_CORE_LINK_CTRL_STAT_REG 0xd0 #define PCIE_CORE_LINK_L0S_ENTRY BIT(0) #define PCIE_CORE_LINK_TRAINING BIT(5) @@ -296,7 +297,8 @@ static void advk_pcie_setup_hw(struct ad reg = PCIE_CORE_DEV_CTRL_STATS_RELAX_ORDER_DISABLE | (7 << PCIE_CORE_DEV_CTRL_STATS_MAX_PAYLOAD_SZ_SHIFT) | PCIE_CORE_DEV_CTRL_STATS_SNOOP_DISABLE | - PCIE_CORE_DEV_CTRL_STATS_MAX_RD_REQ_SIZE_SHIFT; + (PCIE_CORE_DEV_CTRL_STATS_MAX_RD_REQ_SZ << + PCIE_CORE_DEV_CTRL_STATS_MAX_RD_REQ_SIZE_SHIFT); advk_writel(pcie, reg, PCIE_CORE_DEV_CTRL_STATS_REG); /* Program PCIe Control 2 to disable strict ordering */