From patchwork Wed Apr 1 16:18:03 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 228398 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=-6.8 required=3.0 tests=DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable 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 B5416C2D0F2 for ; Wed, 1 Apr 2020 16:44:38 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 527762063A for ; Wed, 1 Apr 2020 16:44:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1585759478; bh=XzkXl0Dl7CGP+MpppPEwa4ncrlK/dp1qfggSqcK1CCs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=bIrnQ6tghvTC4PjsPp9BSaHB9NuaJSlECKdsz8NEyReeXHJ/4hJaEd5AXwLmikCc3 DtYT4/zYpFGNIxKvg4RxlAaQUUiiyDzm//HA+nZHNbQ0v+EqpNVdxmca44Ew28kLbG AzwbmABF/H0Be2Vkh6WOQv2FwRhWrxCdmVqgZZlE= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389588AbgDAQod (ORCPT ); Wed, 1 Apr 2020 12:44:33 -0400 Received: from mail.kernel.org ([198.145.29.99]:45574 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388617AbgDAQoc (ORCPT ); Wed, 1 Apr 2020 12:44:32 -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 7D21820714; Wed, 1 Apr 2020 16:44:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1585759472; bh=XzkXl0Dl7CGP+MpppPEwa4ncrlK/dp1qfggSqcK1CCs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=mWOhCq2oE8VXUht+Evkxk94D7Ap3i9Qc4ed7NEZ/bNyOjavDWE9IytUfvxIPYpn1u JSQ0oUMHksBZCavbTtyGej165bQOLaSSzTJvOOcwNHIReLIhDb59bnaP8PqqP0Il0T 9VwSxlfMxfnVWSI0HB5JX5uh6IbvB0ZRhs1DkvwI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Roger Quadros , stable@kernel.org, Tony Lindgren Subject: [PATCH 4.14 091/148] ARM: dts: dra7: Add bus_dma_limit for L3 bus Date: Wed, 1 Apr 2020 18:18:03 +0200 Message-Id: <20200401161601.734405571@linuxfoundation.org> X-Mailer: git-send-email 2.26.0 In-Reply-To: <20200401161552.245876366@linuxfoundation.org> References: <20200401161552.245876366@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: Roger Quadros commit cfb5d65f25959f724081bae8445a0241db606af6 upstream. The L3 interconnect's memory map is from 0x0 to 0xffffffff. Out of this, System memory (SDRAM) can be accessed from 0x80000000 to 0xffffffff (2GB) DRA7 does support 4GB of SDRAM but upper 2GB can only be accessed by the MPU subsystem. Add the dma-ranges property to reflect the physical address limit of the L3 bus. Issues ere observed only with SATA on DRA7-EVM with 4GB RAM and CONFIG_ARM_LPAE enabled. This is because the controller supports 64-bit DMA and its driver sets the dma_mask to 64-bit thus resulting in DMA accesses beyond L3 limit of 2G. Setting the correct bus_dma_limit fixes the issue. Signed-off-by: Roger Quadros Cc: stable@kernel.org Signed-off-by: Tony Lindgren Signed-off-by: Greg Kroah-Hartman --- arch/arm/boot/dts/dra7.dtsi | 1 + 1 file changed, 1 insertion(+) --- a/arch/arm/boot/dts/dra7.dtsi +++ b/arch/arm/boot/dts/dra7.dtsi @@ -137,6 +137,7 @@ #address-cells = <1>; #size-cells = <1>; ranges = <0x0 0x0 0x0 0xc0000000>; + dma-ranges = <0x80000000 0x0 0x80000000 0x80000000>; ti,hwmods = "l3_main_1", "l3_main_2"; reg = <0x0 0x44000000 0x0 0x1000000>, <0x0 0x45000000 0x0 0x1000>;