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 27A14C6FD1C for ; Tue, 14 Mar 2023 06:50:36 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 2D9A385DBB; Tue, 14 Mar 2023 07:50:34 +0100 (CET) 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="vZdN4AYO"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id A775485DBB; Tue, 14 Mar 2023 07:50:32 +0100 (CET) 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 AE34785DBC for ; Tue, 14 Mar 2023 07:50:29 +0100 (CET) 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 32E6oNDW121178; Tue, 14 Mar 2023 01:50:23 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1678776623; bh=dYSBnq+pyHOlheVTEsIeZPp5eqGZsUeW+2gl1DONh38=; h=Date:Subject:To:CC:References:From:In-Reply-To; b=vZdN4AYOIU0HaQ2a4TKIzYu8MJ9KUA2NnE3JpCJn6AL/2Hqy+//qg2QcldZsnTY6h 9HBmm0wQcvs0scv6gGDC4fzgDnyAoqc+gPdc4Em0f/lwNbkmKuGyh9TaxhHI5nrUV8 6w2WemsJjHA1Ds4HHC/SZiJ1txdzpzAiecL9ymAw= Received: from DFLE109.ent.ti.com (dfle109.ent.ti.com [10.64.6.30]) by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 32E6oN3A065908 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Tue, 14 Mar 2023 01:50:23 -0500 Received: from DFLE111.ent.ti.com (10.64.6.32) by DFLE109.ent.ti.com (10.64.6.30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.16; Tue, 14 Mar 2023 01:50:22 -0500 Received: from lelv0327.itg.ti.com (10.180.67.183) by DFLE111.ent.ti.com (10.64.6.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.16 via Frontend Transport; Tue, 14 Mar 2023 01:50:22 -0500 Received: from [10.249.132.228] (ileaxei01-snat.itg.ti.com [10.180.69.5]) by lelv0327.itg.ti.com (8.15.2/8.15.2) with ESMTP id 32E6oJ5J097471; Tue, 14 Mar 2023 01:50:20 -0500 Message-ID: <39bb3d90-691b-2133-9be8-f4f27fd9f153@ti.com> Date: Tue, 14 Mar 2023 12:20:14 +0530 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.7.1 Subject: Re: [PATCH 1/9] drivers: video: Kconfig: Necessary configs for video at SPL Content-Language: en-US To: Nikhil M Jain , , CC: , , , References: <20230314045019.5671-1-n-jain1@ti.com> <20230314045019.5671-2-n-jain1@ti.com> From: Devarsh Thakkar In-Reply-To: <20230314045019.5671-2-n-jain1@ti.com> Content-Type: text/plain; charset="UTF-8"; format=flowed 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 Nikhil, Thanks for the patch. On 14/03/23 10:20, Nikhil M Jain wrote: > Add necessary Kconfigs to enable video driver and enable splash screen > at spl stage. > CONFIG_SPL_VIDEO enables all necessary configs enabled by CONFIG_VIDEO > at spl stage. > CONFIG_SPL_SYS_WHITE_ON_BLACK allows displaying on black background at > spl stage. > > These configs are specific to SPL and will allow us to enable the video > driver and splash screen at SPL stage only and not at u-boot proper. > The existing Kconfigs from u-boot proper were not used to make SPL > splash screen independent to them. > > Enable BMP_GZIP at SPL stage when SPL_SPLASH_SCREEN or SPL_CMD_BMP are > defined. > > Signed-off-by: Nikhil M Jain > --- > drivers/video/Kconfig | 30 +++++++++++++++++++++++++++--- > 1 file changed, 27 insertions(+), 3 deletions(-) > > diff --git a/drivers/video/Kconfig b/drivers/video/Kconfig > index 2a76d19cc8..1097e2c623 100644 > --- a/drivers/video/Kconfig > +++ b/drivers/video/Kconfig > @@ -14,7 +14,17 @@ config VIDEO > option compiles in the video uclass and routes all LCD/video access > through this. > > -if VIDEO > +config SPL_VIDEO > + bool "Enable driver model support for LCD/video" > + depends on SPL_DM > + help > + The video subsystem adds a small amount of overhead to the image. > + If this is acceptable and you have a need to use video drivers in > + SPL, enable this option. It might provide a cleaner interface to > + setting up video within SPL, and allows the same drivers to be > + used as U-Boot proper. > + > +if VIDEO || SPL_VIDEO > > config VIDEO_LOGO > bool "Show the U-Boot logo on the display" > @@ -193,6 +203,14 @@ config SYS_WHITE_ON_BLACK > better in low-light situations or to reduce eye strain in some > cases. > My understanding is that for all the common macros under (VIDEO || SPL_VIDEO) (for e.g. like CONFIG_VIDEO_LOGO) code will get compiled in both u-boot proper at SPL even if intended to be enabled for only on of them. For e.g. you enable CONFIG_VIDEO_LOGO with CONFIG_VIDEO set aiming to compiled them only for u-boot proper but corresponding code will also get compiled for u-boot SPL now. Please confirm but If this is true then from my point of view I think we need unique SPL_VIDEO_* macro (which will depend on SPL_VIDEO) for each of the VIDEO_* macros getting used generally or probably all of them. And use CONFIG_IS_ENABLED at all places in video drivers for each of the macros. Lastly you may also have to update relevant docs viz. docs/README.spl and video related docs if any. > +config SPL_SYS_WHITE_ON_BLACK > + bool "Display console as white on a black background" > + help This should depend upon SPL_VIDEO > + Normally the display is black on a white background, Enable this > + option to invert this, i.e. white on a black background at spl stage. > + This can be better in low-light situations or to reduce eye strain in > + some cases. > + > config NO_FB_CLEAR > bool "Skip framebuffer clear" > help > @@ -795,7 +813,13 @@ config SPLASH_SCREEN > image data before it is processed and sent to the frame buffer by > U-Boot. Define your own version to use this feature. > > -if SPLASH_SCREEN > +config SPL_SPLASH_SCREEN > + bool "Show a splash-screen image" Same here. > + help > + If this option is set, the environment is checked for a variable > + "splashimage" at spl stage. > + > +if SPLASH_SCREEN || SPL_SPLASH_SCREEN > If going with above suggested approach then you will need to make unique macros for SPL. Regards Devarsh > config SPLASH_SCREEN_ALIGN > bool "Allow positioning the splash image anywhere on the display" > @@ -863,7 +887,7 @@ endif # SPLASH_SCREEN > > config VIDEO_BMP_GZIP > bool "Gzip compressed BMP image support" > - depends on CMD_BMP || SPLASH_SCREEN > + depends on CMD_BMP || SPLASH_SCREEN || SPL_SPLASH_SCREEN || SPL_CMD_BMP > help > If this option is set, additionally to standard BMP > images, gzipped BMP images can be displayed via the