Received: by 10.192.165.148 with SMTP id m20csp4170543imm; Mon, 30 Apr 2018 13:07:02 -0700 (PDT) X-Google-Smtp-Source: AB8JxZr1kKSrjDF/6PCcFRUUa8IMXQl7SEKHXQjqAvfQYXyujFp1Va+r1LJ5JWf/vnRDZeZNGDUP X-Received: by 2002:a17:902:bf41:: with SMTP id u1-v6mr13804538pls.257.1525118822862; Mon, 30 Apr 2018 13:07:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525118822; cv=none; d=google.com; s=arc-20160816; b=LJL0afv/xVxSZ7Kl9hX1KpD9NuunE55Q/bZDhncD3JAQrP4dReZ6kl1dGWaut88yZN D4ZyEmU5sRCNtFWHGNLb1LUJ5Q47a8ycuz1d3VWAY545IH4muxyi34kE3LvKHKp/xBvX HeJcCfaxyQDkxmWAvlwhF1PETshpqtexiVVeh8CTq/iAFAFzm5DQa6rvm5c3nwciYl6w wl/wt1DewGMo7eCMaJx4Y1AVHtcu4UHwhMXkyhbUkGyts1Xy5YyL53nMbNzrh2g6rITJ MCZbrvFahOjY8BDTderrpaih+BZJXKhTvNRpAeO35zRWUzlsl16Hc93oaRLFPD4g4F5f kVvA== 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=+ZmhvW+3D5eGeYgk1QNvHg1FkL+TpwgHGmstgRgiyCw=; b=aGNjz1BFceaXF4rP4Gx8hfgNTvQrecafZUoGLPuNUjanm+/NUVome8p/1W5/cXFd1m ONNh8QAcI0NGvfLrLdZeyn6FtfxbJ2Z800Ag0CqCf+wKDeiq3bVb0zjw35jkEcA697Wa OqaGsbrLPt3d0DtxnUGLPhe9CcN/jlrw9HAsYyuEcL5BNtpEVhZJ+MGnhSoJ+J22y+ur EB9SHxY8o4tcN55c/AqmYCSdskmPZZtUQ2r1hZDzf5z89/R61MyJRU4xwLgoJEr4DpNI +CmKvVSN2sydLJNg4mL2eQQPaU7gYppJ2pkOYX8xA91Jcxy0QTfaWK9/QzlHk+sgMhOl gR/Q== 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 o10-v6si6671408pgq.148.2018.04.30.13.06.48; Mon, 30 Apr 2018 13:07:02 -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 S1756161AbeD3UFc (ORCPT + 99 others); Mon, 30 Apr 2018 16:05:32 -0400 Received: from mail.kernel.org ([198.145.29.99]:34042 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932198AbeD3T1a (ORCPT ); Mon, 30 Apr 2018 15:27:30 -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 B018F22DC1; Mon, 30 Apr 2018 19:27:29 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org B018F22DC1 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.14 63/91] PCI: aardvark: Fix PCIe Max Read Request Size setting Date: Mon, 30 Apr 2018 12:24:45 -0700 Message-Id: <20180430184007.441875556@linuxfoundation.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180430184004.216234025@linuxfoundation.org> References: <20180430184004.216234025@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.14-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) @@ -298,7 +299,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 */