From patchwork Wed Jan 17 10:36:32 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 13522363 Return-Path: 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 1405FC47422 for ; Wed, 17 Jan 2024 10:37:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type:Cc:To:Subject: Message-ID:Date:From:MIME-Version:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=oKb5W4gf2CSzEtc5GH7G/iof+m80y393c6dFp0osCg8=; b=ALlnPH8lvuaZiTJR5nOuXe1uVV Gc/G9D+GGkAkRuaYahNV2sdxzW1RZiWhdjzSJTBWYw5/UrDhbpUEKBRhRya9QY7iakA8ju6p1RYmj 6bdTN36unbH3ey+940csm2/HV+iXMRqQ58N0/Eei2TVcfJ1exOvjiq2OV0HLJ7XuVFEEhtpzeJ2mN pdoMhWw01+AU2AjpImXwSLAlQAfOpke6jflTSABXDjht+mFbanp0zp0wHuC8swyoxVtMuAD57+y/O zIuXsISZ92UhNtq8G8MQjfELN7BCQTakj3tTtZn/H0fyukVPHoYdn6u+yAaB3qklKxV7wKUgPtRX8 L37/gQcg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1rQ3Hy-00FIwq-1V; Wed, 17 Jan 2024 10:36:54 +0000 Received: from mail-yw1-x1135.google.com ([2607:f8b0:4864:20::1135]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1rQ3Hu-00FIvT-0m for linux-rockchip@lists.infradead.org; Wed, 17 Jan 2024 10:36:52 +0000 Received: by mail-yw1-x1135.google.com with SMTP id 00721157ae682-5edfcba97e3so115018717b3.2 for ; Wed, 17 Jan 2024 02:36:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1705487804; x=1706092604; darn=lists.infradead.org; h=cc:to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=wHVIlCkaPGa4y/564Pa5q8rJWghO6c6Z1Y67y4QdS38=; b=h8tCIgwdoGNoChWXoqXZ8jNE9h8OgAZ1RfsOw6YMfc5iqyGcDkhl4HZoLuj0HOq3XA g+xvkkvo9ZlIuJ3y+pm4tyFMOY3zjmdqHhLNtxFnEA/9Q52RnBvb9zQtjmpCZlNDKu6q 3sRXe736fjiwmc/ZSop+0r/lfnXB26SppDy0A= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705487804; x=1706092604; h=cc:to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=wHVIlCkaPGa4y/564Pa5q8rJWghO6c6Z1Y67y4QdS38=; b=eQVKqTnGO99MA3Se+AulX1CMOvHdTxP1uiwAUePqdfyYCfzzl24bkdUc/cUf2YW1A0 +TTHbbNaWt7HK5VkphuoJaSdK5ZvSU5fj8tNaTAz6e87UJnfntRxbQyQ7o/pJWnO7MoA amFonGCapBgaceiwJbKHWPvK6o+1nqXK3RxMi9KgIbUtOe5BLzKIfhxYEmEREryvW/YQ /5CbwKB2PBw6E/OXK28t6fkew8fZfAncnGlpHeHy5jnnamab7Rxwbqiebt3ms/g+J6XI ERWuQziP4ENXDarQF/c7nhftZL1OgECKegDrKgSvn+Grc1e5Wz8DO4FPNwkTE16N/9b2 /pEw== X-Gm-Message-State: AOJu0YyjewlOhyDr13mI6MK8gO1m91XsLu6licqRNtwXXWeFAH16Mu5/ QGaGH2B0MrSUvULguwBw/TxyS6C+ig0Y2XLzYzX4Zs30hk/oag== X-Google-Smtp-Source: AGHT+IESYcELevls4TuD81efGPpDQZ4uQ5PGA/OqtO+wBu2Gp/hRoCbZttZgaS9HTrJM6re0fXfvInqr+eZLmO5BnSA= X-Received: by 2002:a5b:150:0:b0:dbd:afaf:2e2f with SMTP id c16-20020a5b0150000000b00dbdafaf2e2fmr5361958ybp.41.1705487803511; Wed, 17 Jan 2024 02:36:43 -0800 (PST) MIME-Version: 1.0 From: Jagan Teki Date: Wed, 17 Jan 2024 16:06:32 +0530 Message-ID: Subject: Black and White Artifact on BMP (24BPP) logo during boot To: Anatolij Gustschin , Simon Glass , Kever Yang , Andy Yan , Michael Nazzareno Trimarchi , Neil Armstrong , Nikhil M Jain , Andre Przywara Cc: U-Boot-Denx , "open list:ARM/Rockchip SoC..." X-Spam-Note: CRM114 run bypassed due to message size (530814 bytes) X-Spam-Score: -0.2 (/) X-Spam-Report: Spam detection software, running on the system "bombadil.infradead.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Hi All, Artifact occurred only during boot but loading via the bmp command on the u-boot console seems fine. I have observed the contents of bmp hex codes have changed during the function switch after memory to ddr address. (The same cannot happen on downstream u-boot) Content analysis details: (-0.2 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2607:f8b0:4864:20:0:0:0:1135 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org Hi All, Artifact occurred only during boot but loading via the bmp command on the u-boot console seems fine. I have observed the contents of bmp hex codes have changed during the function switch after memory to ddr address. (The same cannot happen on downstream u-boot) So, the contents in splash_display show SAME and the contents in bmp_display show NOTSAME. This issue is reproducing on specifics like - 24-bit BMP (attached). rockchip.bmp: PC bitmap, Windows 98/2000 and newer format, 480 x 270 x 24 - Rockchip 64-bit SoC (32-bit, RK3288 has no issue). - Allwinner 64-bit SoC seems no issues. - Downstream u-boot rockchip has no issues. (with mainline vide drivers not with drm drivers) - Issue observed in boot but loading via bmp command on u-boot console seems no issue. I did check the clock, cache, and memory but none of them showed any clue. I did port clock, mach-rockchip code to rockchip u-boot but none of the cases resulted in the same. Any input on this is appreciated. Thanks, Jagan. diff --git a/common/splash.c b/common/splash.c index 6820db683b..f97edf8732 100644 --- a/common/splash.c +++ b/common/splash.c @@ -175,6 +175,11 @@ int splash_display(void) splash_get_pos(&x, &y); + if (memcmp((void *)addr, bmp_logo_bitmap, len2) == 0) + printf("%s: SAME\n", __func__); + else + printf("%s: NOTSAME\n", __func__); + if (CONFIG_IS_ENABLED(BMP)) ret = bmp_display(addr, x, y); else diff --git a/drivers/video/bmp.c b/drivers/video/bmp.c index bab6fa7265..dc2928ccdb 100644 --- a/drivers/video/bmp.c +++ b/drivers/video/bmp.c @@ -111,10 +111,15 @@ int bmp_display(ulong addr, int x, int y) { struct udevice *dev; int ret; - struct bmp_image *bmp = map_sysmem(addr, 0); void *bmp_alloc_addr = NULL; unsigned long len; + if (memcmp((void *)addr, bmp_logo_bitmap, len2) == 0) + printf("%s: SAME\n", __func__); + else + printf("%s: NOTSAME\n", __func__); + + struct bmp_image *bmp = map_sysmem(addr, 0); if (!((bmp->header.signature[0] == 'B') && (bmp->header.signature[1] == 'M'))) bmp = gunzip_bmp(addr, &len, &bmp_alloc_addr);