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 phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id BD11BC001DE for ; Tue, 25 Jul 2023 09:22:27 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id AE35B86828; Tue, 25 Jul 2023 11:22:25 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=ti.com header.i=@ti.com header.b="s605XZIq"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 0272286828; Tue, 25 Jul 2023 11:22:23 +0200 (CEST) Received: from fllv0015.ext.ti.com (fllv0015.ext.ti.com [198.47.19.141]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 4E23686808 for ; Tue, 25 Jul 2023 11:21:59 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=devarsht@ti.com Received: from lelv0266.itg.ti.com ([10.180.67.225]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id 36P9Lkr9113124; Tue, 25 Jul 2023 04:21:46 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1690276906; bh=+yUXUMs0EUkIAQVOjD/KLLoWav0HdbkQD3CeEroFOy8=; h=Date:Subject:To:CC:References:From:In-Reply-To; b=s605XZIqZMcFsdYJ3ZYHplrbN1jGYPZICYgson1WiANbnDMvEOPFw8h/c5mMizGMF PhmQDGMdO14rtT056KKvel0+gZ8EOjlxG6w7FzFwMUri05pmDrvPw+q/ccF5jhaOoM mjcNorRFR6JTpmjZMsECyUFbcKmUOdBHducFMXgc= Received: from DLEE105.ent.ti.com (dlee105.ent.ti.com [157.170.170.35]) by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 36P9LkNR024432 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Tue, 25 Jul 2023 04:21:46 -0500 Received: from DLEE101.ent.ti.com (157.170.170.31) by DLEE105.ent.ti.com (157.170.170.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Tue, 25 Jul 2023 04:21:45 -0500 Received: from lelv0326.itg.ti.com (10.180.67.84) by DLEE101.ent.ti.com (157.170.170.31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Tue, 25 Jul 2023 04:21:45 -0500 Received: from [172.24.227.6] (ileaxei01-snat2.itg.ti.com [10.180.69.6]) by lelv0326.itg.ti.com (8.15.2/8.15.2) with ESMTP id 36P9LgID008156; Tue, 25 Jul 2023 04:21:43 -0500 Message-ID: Date: Tue, 25 Jul 2023 14:51:42 +0530 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Subject: Re: [PATCH 5/9] board_f: Fix corruption of relocaddr Content-Language: en-US To: Simon Glass , U-Boot Mailing List CC: Bin Meng , Michal Suchanek , Nikhil M Jain , Ovidiu Panait , =?UTF-8?Q?Pali_Roh=c3=a1r?= , Rasmus Villemoes , Stefan Roese References: <20230724145210.304917-1-sjg@chromium.org> <20230724145210.304917-5-sjg@chromium.org> From: Devarsh Thakkar In-Reply-To: <20230724145210.304917-5-sjg@chromium.org> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean Hi Simon, On 24/07/23 20:22, Simon Glass wrote: > When the video framebuffer comes from the bloblist, we should not change > relocaddr to this address, since it interfers with the normal memory > allocation. > > This fixes a boot loop in qemu-x86_64 > > Signed-off-by: Simon Glass > Fixes: 5bc610a7d9d ("common: board_f: Pass frame buffer info from SPL to u-boot") > --- > > common/board_f.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/common/board_f.c b/common/board_f.c > index 7d2c380e91e2..5c8646b22283 100644 > --- a/common/board_f.c > +++ b/common/board_f.c > @@ -419,7 +419,6 @@ static int reserve_video(void) > if (!ho) > return log_msg_ret("blf", -ENOENT); > video_reserve_from_bloblist(ho); > - gd->relocaddr = ho->fb; I think this change was done as relocaddr pointer was required to be updated to move after frame-buffer reserved area to ensure that any further memory reservations done using gd->relocaddr (for e.g. in reserve_trace/uboot/malloc) don't overlap with frame-buffer reserved area passed from blob, so I think removing this line may cause further memory reservations to overlap with reserved framebuffer. Could you please confirm? Regards Devarsh > } else if (CONFIG_IS_ENABLED(VIDEO)) { > ulong addr; > int ret;