From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out2-smtp.messagingengine.com (out2-smtp.messagingengine.com [66.111.4.26]) by mx.groups.io with SMTP id smtpd.web10.65226.1674181507002036693 for ; Thu, 19 Jan 2023 18:25:07 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="signature has expired" header.i=@bsdio.com header.s=fm1 header.b=jHMCLZNW; spf=pass (domain: bsdio.com, ip: 66.111.4.26, mailfrom: rebecca@bsdio.com) Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 46D265C00EC; Thu, 19 Jan 2023 21:25:06 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Thu, 19 Jan 2023 21:25:06 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdio.com; h=cc :cc:content-transfer-encoding:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to; s=fm1; t=1674181506; x= 1674267906; bh=tTyEc3WlaVkAB0xEMQryJuEKDZ5KVrInl3yp/TdstJ0=; b=j HMCLZNWNvMmbVnnJqA8ilGhFsY25yZSBctDzvELI9Iuy3mnZcJjnavySnuFPZjC0 iu5vTuqfj/bkSXiwP+aqGBmntplZwfn+rG2x6DtDcAMS2PPPYnPbEGOu/cp0eKIv sC0Nl3+A2JSp240bRHUq215fSjaYZ0nCwCH4KIlcA8zEebXWPjjLOmr1ULG4C9ZH 58oXfJtV4Y31n635iCnVCIItK42aBVq6f3YvWB+HGGN4D0hA86tVJZfjCDAQlqM5 adaF0kSH+uW3IgGNQegdQwUWkY8naHeo2+ILMA4DSiX7cuVE2s4OBqwlL8i6tIwA ARENv+Sksj0v+uodvNyNA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1674181506; x= 1674267906; bh=tTyEc3WlaVkAB0xEMQryJuEKDZ5KVrInl3yp/TdstJ0=; b=q +xaTgd3xKJV2mGZOvu2bewi6i/rghrb9lqnHzF2o3hcMYOyYbo5kJ4OYdBrhV7i2 gCqAX5xWqAVfFDbSQVNIONy6WZKqrANm3AFr6AW4K0Pb3UPyVWSVdrpNVUIN1Vew b8OuBcA2BShf0qys3P7X08jZnaJa6WkOCdrAgGL9BCd/CG7x4hBQBBPzrLAISI1e XQGlSLe+SRy88LF905ICngdI4uwb0RTLO4cy1df9dvx0Y/SlkCPSUOQj3R6GuotJ pyyhp3ETUQepEFn0xQNOxsFc8GbDFJ4yN21psLx2wMH74OB2J27VQ/Zd4vx63xZs WOyoJoZVceG6ieC5ttbuw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrudduuddggeeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepkfffgggfuffvvehfhfgjtgfgsehtkeertddtfeejnecuhfhrohhmpeftvggs vggttggrucevrhgrnhcuoehrvggsvggttggrsegsshguihhordgtohhmqeenucggtffrrg htthgvrhhnpeetgeejgfefffelfedtleehfeeuhfeutdffueduhfejteduvdekveekteef vdelkeenucffohhmrghinhepghhrohhuphhsrdhiohenucevlhhushhtvghrufhiiigvpe dtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehrvggsvggttggrsegsshguihhordgtohhm X-ME-Proxy: Feedback-ID: i5b994698:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 19 Jan 2023 21:25:05 -0500 (EST) Message-ID: Date: Thu, 19 Jan 2023 19:25:03 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.2 Subject: Re: [edk2-devel] [PATCH v3 1/1] ShellPkg: Export default shell delay as PCD To: devel@edk2.groups.io, quic_tpilar@quicinc.com Cc: Ray Ni , Zhichao Gao References: <20230103170229.328712-1-tomas@quicinc.com> From: "Rebecca Cran" In-Reply-To: Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Could someone review this please? -- Rebecca Cran On 1/10/23 05:09, Tomas Pilar (tpilar) wrote: > Hi, > > Any chance you could review this change? It's fairly simple. > > Cheers, > Tom > > On 03/01/2023 17:02, Tomas Pilar (tpilar) wrote: >> From: Tomas Pilar >> >> Create PcdShellDefaultDelay to configure the default >> delay the shell provides for the user at the start time >> if the user wishes to cancel the execution of a potential >> startup script. >> >> The shell application already allows the user to override >> the delay default value by specifying the -delay cmdline >> argument. This however cannot be used when loading the >> shell application using direct boot or when integrating >> the shell into the platform firmware build. >> >> Thus, a PCD can be easily configurerd by the developer >> either at build time, or even at runtime. >> >> Cc: Ray Ni >> Cc: Zhichao Gao >> Signed-off-by: Tomas Pilar >> --- >>   ShellPkg/ShellPkg.dec                | 4 ++++ >>   ShellPkg/Application/Shell/Shell.inf | 1 + >>   ShellPkg/Application/Shell/Shell.c   | 2 +- >>   3 files changed, 6 insertions(+), 1 deletion(-) >> >> diff --git a/ShellPkg/ShellPkg.dec b/ShellPkg/ShellPkg.dec >> index 7b2d1230bd2c..2ebea0a2615f 100644 >> --- a/ShellPkg/ShellPkg.dec >> +++ b/ShellPkg/ShellPkg.dec >> @@ -136,3 +136,7 @@ [PcdsFixedAtBuild, PcdsPatchableInModule, >> PcdsDynamic, PcdsDynamicEx] >>     # Up to this many bytes of vendor specific data will be used. >> Default is 0 >>     # (disabled). >> gEfiShellPkgTokenSpaceGuid.PcdShellVendorExtendedDecode|0|UINT32|0x00000013 >> + >> +  ## Controls the default delay the shell will offer to the user at the >> +  # start to check if the user wishes to cancel the script autostart >> + gEfiShellPkgTokenSpaceGuid.PcdShellDefaultDelay|5|UINT32|0x00000015 >> diff --git a/ShellPkg/Application/Shell/Shell.inf >> b/ShellPkg/Application/Shell/Shell.inf >> index 4c32960a9687..f1e41de133d1 100644 >> --- a/ShellPkg/Application/Shell/Shell.inf >> +++ b/ShellPkg/Application/Shell/Shell.inf >> @@ -103,3 +103,4 @@ [Pcd] >>     gEfiShellPkgTokenSpaceGuid.PcdShellForceConsole           ## >> CONSUMES >>     gEfiShellPkgTokenSpaceGuid.PcdShellSupplier               ## >> CONSUMES >>     gEfiShellPkgTokenSpaceGuid.PcdShellMaxHistoryCommandCount ## >> CONSUMES >> +  gEfiShellPkgTokenSpaceGuid.PcdShellDefaultDelay           ## CONSUMES >> diff --git a/ShellPkg/Application/Shell/Shell.c >> b/ShellPkg/Application/Shell/Shell.c >> index df00adfdfa5b..0ae6e14a34bf 100644 >> --- a/ShellPkg/Application/Shell/Shell.c >> +++ b/ShellPkg/Application/Shell/Shell.c >> @@ -990,7 +990,7 @@ ProcessCommandLine ( >>     ShellInfoObject.ShellInitSettings.BitUnion.Bits.Delay = FALSE; >>     ShellInfoObject.ShellInitSettings.BitUnion.Bits.Exit = FALSE; >>     ShellInfoObject.ShellInitSettings.BitUnion.Bits.NoNest = FALSE; >> -  ShellInfoObject.ShellInitSettings.Delay = 5; >> +  ShellInfoObject.ShellInitSettings.Delay = PcdGet32 >> (PcdShellDefaultDelay); >>       // >>     // Start LoopVar at 0 to parse only optional arguments at Argv[0] > > > > > >