From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id EF441C4829E for ; Sun, 18 Feb 2024 10:25:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=EzwwFhCyoiTwzUqL7nC+HJfuIaFh1PFcVXt1P8ZAjl4=; b=Kx3WL8f9i47Rcj XG6WeoTIS2niqFSvNUegiT1PhD36o/XARA5YH4Eswfm2WPWOi9H6NUuQhw9Svn10pNqlwMpzI6RGl Urv49kg+a8JLPwBJjWj/+mWUGkeYJLWfVrOsXxEvnqhv4yhgQANqy/Rskidv95A5vkQdbKZpcqBS8 tqPfMZVft9MZNvOUXKWYQi38r2ZY3SuuHH1M/jXQguBy1/ZS1WmX2bqgqxZWxNpt0YiBozBLK04mW K9kTtbw8+wcSydOjnQNj63zv0GvwllWgLxbUGduFanuej0tqVHdu9eo/k88NJM6RY1T32/GpwO1La 6VLF12YsDcaHFU27pi/g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rbeM6-00000007VLU-0G35; Sun, 18 Feb 2024 10:25:06 +0000 Received: from out-188.mta0.migadu.com ([91.218.175.188]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rbeM1-00000007VKM-1fmE for linux-arm-kernel@lists.infradead.org; Sun, 18 Feb 2024 10:25:03 +0000 Date: Sun, 18 Feb 2024 11:24:49 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=grimler.se; s=key1; t=1708251893; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=5Q6gteFXLuw2xa9qiBWiKUaLv3oz6lEnepe4NxbB9Vs=; b=POmXrPzVyqbX9+lwS3g3MVsM1gkzEC6PGkcdMmTbGjf5yrQqoVeEAEoDS4EJZiuikXJKfd 1vWGINMT2dD/TMkzn6/SakwIOj1swc3zbVfj/gXijUECLRdfA7pjr8CBm/Tb4DkQjDtQYi OW/n+aog7oheGUfApsczc9y54aCsUcc= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Henrik Grimler To: Artur Weber Cc: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Alim Akhtar , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht Subject: Re: [PATCH] ARM: dts: exynos4212-tab3: limit usable memory range Message-ID: <20240218102449.GA7577@grimlerstat.localdomain> References: <20240217-tab3-limit-usable-memory-range-v1-1-49cc9c86a5cc@gmail.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20240217-tab3-limit-usable-memory-range-v1-1-49cc9c86a5cc@gmail.com> X-Migadu-Flow: FLOW_OUT X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240218_022502_239794_CE89E497 X-CRM114-Status: GOOD ( 19.29 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Artur, On Sat, Feb 17, 2024 at 08:02:47PM +0100, Artur Weber wrote: > The stock bootloader on the Samsung Galaxy Tab 3 8.0 provides an > incorrect available memory range over ATAG_MEM. Limit the usable > memory in the DTS to prevent it from doing so, without having to > disable ATAG support. > > Signed-off-by: Artur Weber > --- > arch/arm/boot/dts/samsung/exynos4212-tab3.dtsi | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/arch/arm/boot/dts/samsung/exynos4212-tab3.dtsi b/arch/arm/boot/dts/samsung/exynos4212-tab3.dtsi > index e5254e32aa8f..9bc05961577d 100644 > --- a/arch/arm/boot/dts/samsung/exynos4212-tab3.dtsi > +++ b/arch/arm/boot/dts/samsung/exynos4212-tab3.dtsi > @@ -45,6 +45,12 @@ chosen { > /* Default S-BOOT bootloader loads initramfs here */ > linux,initrd-start = <0x42000000>; > linux,initrd-end = <0x42800000>; > + > + /* > + * Stock bootloader provides incorrect memory size in ATAG_MEM; > + * override it here > + */ > + linux,usable-memory-range = <0x40000000 0x3fc00000>; Maybe it would make sense to set the memory reg to <0x40000000 0x60000000> (1.5 GiB) and move the comment about last 512(/516) MiB being weird/broken here instead. It looks a bit weird that the memory range and usable-memory-range are identical, and device tree should describe hardware, which technically has 1.5 GiB RAM. >From a functional point of view it does not really matter, so in any case: Reviewed-by: Henrik Grimler > }; > > firmware@204f000 { > > --- > base-commit: 0f1dd5e91e2ba3990143645faff2bcce2d99778e > change-id: 20240217-tab3-limit-usable-memory-range-1d1ffa8dc44d > > Best regards, > -- > Artur Weber > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel