From nobody Fri Apr 26 14:18:48 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85678+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85678+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642121472; cv=none; d=zohomail.com; s=zohoarc; b=BgJQcqceTFFq6nUdVdtm4+Nb7hGbxfLcScNaXx834FrrCIaNDSL7zDNHFFgrqRC/x5wL3E2GIol4FfxjzodlpQjHjvn2lvsqCsovVjrBkIVvdbQuvsPwy2Pkdp8DSnmuwF+DhS+Gb5gpD/UcbtO/A9gxj6fHENWqg4697z1hZYI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642121472; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=zpvi0FXaa7lAuqjw0gZher+A8xR8LFviKcMIXVY77NI=; b=PtJqzLalOjzCQzVpGBw4WMMJEEs3Oojek7DC1OOZiMxPrIXiHvjRp0IWlPWKrt34TwD1KWyihpeMXxubjkcMjKGxHYbQbxdD4rkR/YFFTZG+9PX/CltvPVTqfMs20W5IsTrtnohMZXdP+whqqF6gI8VJF8i9Vd3J/AGUYeycrss= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85678+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 16421214721440.8356164543151863; Thu, 13 Jan 2022 16:51:12 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id liOoYY1788612x6aKUanITIt; Thu, 13 Jan 2022 16:51:09 -0800 X-Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.1082.1642121466955476862 for ; Thu, 13 Jan 2022 16:51:08 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10226"; a="241713762" X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="241713762" X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:08 -0800 X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="475564625" X-Received: from guominji-mobl.ccr.corp.intel.com ([10.238.9.87]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:06 -0800 From: "Guomin Jiang" To: devel@edk2.groups.io Cc: GuoMinJ , Guo Dong , Ray Ni , Maurice Ma , Benjamin You Subject: [edk2-devel] [PATCH 01/11] UefiPayloadPkg: Remove All UGA Support Date: Fri, 14 Jan 2022 08:50:34 +0800 Message-Id: <20220114005044.1975-2-guomin.jiang@intel.com> In-Reply-To: <20220114005044.1975-1-guomin.jiang@intel.com> References: <20220114005044.1975-1-guomin.jiang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,guomin.jiang@intel.com X-Gm-Message-State: tLpepx4GB6NJvPyUg4uOi4Qrx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642121469; bh=/Wsajt7cM5aoq+FzuV+pbMYoXCv2j5RHxq97HoSODDI=; h=Cc:Date:From:Reply-To:Subject:To; b=pJoNvl+T1B8diV+t+/zzrkqbcK4p1zlCovBCMXP5K+pl+TWDwrzfJ8H9slYtKAtbl/4 jMdMWo48u++0LAwPRI5vN+ovtTqa5Zt7JN5MNnuoHmzBMUNlNbA7JCb5RzQWJrd4p9j9y qvxUvQZI199U2PlBEbIhOtdrelv2CPCXa2Y= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642121472869100002 Content-Type: text/plain; charset="utf-8" From: GuoMinJ REF: https//bugzilla.tianocore.org/show_bug.cgi?id=3D2368 Remove PcdConOutGopSupport, it is unnecessary any more. Remove All UGA Support in UefiPayloadPkg. Signed-off-by: Guomin Jiang Cc: Guo Dong Cc: Ray Ni Cc: Maurice Ma Cc: Benjamin You Reviewed-by: Guo Dong --- UefiPayloadPkg/UefiPayloadPkg.dsc | 2 -- .../Library/PlatformBootManagerLib/PlatformBootManagerLib.inf | 2 -- .../Library/PlatformBootManagerLib/PlatformBootManager.h | 2 +- 3 files changed, 1 insertion(+), 5 deletions(-) diff --git a/UefiPayloadPkg/UefiPayloadPkg.dsc b/UefiPayloadPkg/UefiPayload= Pkg.dsc index 3d08edfe3164..f99e640baa0c 100644 --- a/UefiPayloadPkg/UefiPayloadPkg.dsc +++ b/UefiPayloadPkg/UefiPayloadPkg.dsc @@ -361,8 +361,6 @@ [LibraryClasses.common.DXE_SMM_DRIVER] ##########################################################################= ###### [PcdsFeatureFlag] gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport|FALSE ## This PCD specified whether ACPI SDT protocol is installed. gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol|TRUE gEfiMdeModulePkgTokenSpaceGuid.PcdHiiOsRuntimeSupport|FALSE diff --git a/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootMana= gerLib.inf b/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootMana= gerLib.inf index 9c4a9da94350..07b5ad0eb424 100644 --- a/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.= inf +++ b/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.= inf @@ -55,7 +55,6 @@ [Guids] [Protocols] gEfiGenericMemTestProtocolGuid ## CONSUMES gEfiGraphicsOutputProtocolGuid ## CONSUMES - gEfiUgaDrawProtocolGuid ## CONSUMES gEfiBootLogoProtocolGuid ## CONSUMES gEfiDxeSmmReadyToLockProtocolGuid gEfiSmmAccess2ProtocolGuid @@ -63,7 +62,6 @@ [Protocols] =20 [Pcd] gEfiMdePkgTokenSpaceGuid.PcdPlatformBootTimeOut - gEfiMdePkgTokenSpaceGuid.PcdUgaConsumeSupport gEfiMdeModulePkgTokenSpaceGuid.PcdConOutRow gEfiMdeModulePkgTokenSpaceGuid.PcdConOutColumn gEfiMdeModulePkgTokenSpaceGuid.PcdConInConnectOnDemand diff --git a/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootMana= ger.h b/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManager.h index 5614aadafb98..082d88caa66d 100644 --- a/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManager.h +++ b/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManager.h @@ -98,7 +98,7 @@ PlatformBootManagerEnableQuietBoot ( Use SystemTable Conout to turn on video based Simple Text Out consoles. = The Simple Text Out screens will now be synced up with all non video output = devices =20 - @retval EFI_SUCCESS UGA devices are back in text mode and synced up. + @retval EFI_SUCCESS Graphic devices are back in text mode and synced= up. =20 **/ EFI_STATUS --=20 2.30.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85678): https://edk2.groups.io/g/devel/message/85678 Mute This Topic: https://groups.io/mt/88411245/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Fri Apr 26 14:18:48 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85679+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85679+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642121472; cv=none; d=zohomail.com; s=zohoarc; b=XWhRJWOHjKxJRuVEu5+F/ftfJtSbKVvQoeRytp3CGD4DRa9HUFIJMpCvZp++VNWb54vOiuH67P7YUBmtiMDUQOlf5xz0bel/TwjLZ03BJz+Sb5l52qwJZowfZ9jQ0JqokOlBd2UXxAtpLwqwca3rbzVnYHb8GwTbUfEKlId7sAE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642121472; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=g5qaPdpUzlZPvQOZtzqAJrGZR1mT5vHTydgoqWFrEss=; b=AWJN17X2KAWohz+z1oXzcc5n2cx1TpHqxpO4834vC9c9Asx+aOLnV+9Lm5B07mOCLwlfUnHfsEy/8cJujkVBdfJEtSD/v4ODgZbGmDyRVkuw07yeWWqntgBSGNTM0oRtsd6oD6mYn5dZIKq3WnjDvNPyj2CYk6ISS4aKPlfFp80= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85679+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1642121472867500.37004696252177; Thu, 13 Jan 2022 16:51:12 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id VEEtYY1788612x9dajlMOV8q; Thu, 13 Jan 2022 16:51:12 -0800 X-Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.1082.1642121466955476862 for ; Thu, 13 Jan 2022 16:51:10 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10226"; a="241713792" X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="241713792" X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:10 -0800 X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="475564626" X-Received: from guominji-mobl.ccr.corp.intel.com ([10.238.9.87]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:08 -0800 From: "Guomin Jiang" To: devel@edk2.groups.io Cc: GuoMinJ , Ard Biesheuvel , Leif Lindholm , Sami Mujawar , Gerd Hoffmann Subject: [edk2-devel] [PATCH 02/11] ArmVirtPkg: Remove All UGA Support Date: Fri, 14 Jan 2022 08:50:35 +0800 Message-Id: <20220114005044.1975-3-guomin.jiang@intel.com> In-Reply-To: <20220114005044.1975-1-guomin.jiang@intel.com> References: <20220114005044.1975-1-guomin.jiang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,guomin.jiang@intel.com X-Gm-Message-State: hq2678SPyRq7Qebk4Ovztj8Xx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642121472; bh=Y8JpuSezmrPhHp2iEyExBvp+3uEU/TiOwgstyQB8dIE=; h=Cc:Date:From:Reply-To:Subject:To; b=AuFlPr6MPKyORalxtbMvWDI+x/O+mHKuhvTvMeqqoZ4lcRYBpeWIWTD93NMzlV6z2U2 kKyq8g607Yzb+D01Szkcn6ZU7ICcOKu36vUlJHthG7R3Ga1g+MG7NN9/6GHID/R120ZK/ B+gi0J4wBCgiC8U+9J2ZhlsqYE6E0nSybVQ= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642121474944100002 Content-Type: text/plain; charset="utf-8" From: GuoMinJ REF: https//bugzilla.tianocore.org/show_bug.cgi?id=3D2368 Remove PcdConOutGopSupport, it is unnecessary any more. Remove All UGA Support in ArmVirtPkg Signed-off-by: Guomin Jiang Cc: Ard Biesheuvel Cc: Leif Lindholm Cc: Sami Mujawar Cc: Gerd Hoffmann Acked-by: Ard Biesheuvel Acked-by: Leif Lindholm --- ArmVirtPkg/ArmVirtQemu.dsc | 5 ----- ArmVirtPkg/ArmVirtQemuKernel.dsc | 5 ----- 2 files changed, 10 deletions(-) diff --git a/ArmVirtPkg/ArmVirtQemu.dsc b/ArmVirtPkg/ArmVirtQemu.dsc index 84c28b0c1df4..d18ad9c26672 100644 --- a/ArmVirtPkg/ArmVirtQemu.dsc +++ b/ArmVirtPkg/ArmVirtQemu.dsc @@ -124,11 +124,6 @@ [PcdsFeatureFlag.common] gUefiOvmfPkgTokenSpaceGuid.PcdQemuBootOrderPciTranslation|TRUE gUefiOvmfPkgTokenSpaceGuid.PcdQemuBootOrderMmioTranslation|TRUE =20 - ## If TRUE, Graphics Output Protocol will be installed on virtual handle= created by ConsplitterDxe. - # It could be set FALSE to save size. - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport|FALSE - gEfiMdeModulePkgTokenSpaceGuid.PcdTurnOffUsbLegacySupport|TRUE =20 gArmVirtTokenSpaceGuid.PcdTpm2SupportEnabled|$(TPM2_ENABLE) diff --git a/ArmVirtPkg/ArmVirtQemuKernel.dsc b/ArmVirtPkg/ArmVirtQemuKerne= l.dsc index 8e82c5050f6b..c8af8cefc2c5 100644 --- a/ArmVirtPkg/ArmVirtQemuKernel.dsc +++ b/ArmVirtPkg/ArmVirtQemuKernel.dsc @@ -107,11 +107,6 @@ [PcdsFeatureFlag.common] gUefiOvmfPkgTokenSpaceGuid.PcdQemuBootOrderPciTranslation|TRUE gUefiOvmfPkgTokenSpaceGuid.PcdQemuBootOrderMmioTranslation|TRUE =20 - ## If TRUE, Graphics Output Protocol will be installed on virtual handle= created by ConsplitterDxe. - # It could be set FALSE to save size. - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport|FALSE - gEfiMdeModulePkgTokenSpaceGuid.PcdTurnOffUsbLegacySupport|TRUE =20 [PcdsFixedAtBuild.common] --=20 2.30.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85679): https://edk2.groups.io/g/devel/message/85679 Mute This Topic: https://groups.io/mt/88411246/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Fri Apr 26 14:18:48 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85680+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85680+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642121473; cv=none; d=zohomail.com; s=zohoarc; b=alsUEhYXlkFp3iZng68Dv7lACQnT7mGRIBErx8lQpm4uOrtvPSBlvkt7Kvhs4+XiznXxoUHuIJLjuuLGeV3JopJIHmo8azhaae+GZjqdO5dYdXsLbjOEuWVbLHXRMNMIdO3Hy7Tfl9yqIhVYK9B9VcFTWcckcLuj1RQmgfZ6ja4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642121473; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=Tdp+vumyMlKe2h10JyuqufElO8JEzR0vxRxzrs0CCMQ=; b=Rq1/wwtRikZUlR+hyTgQayo8FfJ6B7CNYIne677T1zOD030iRDo29CJQGIqnk5Lh7s5b/3gzZPzzdIu2mJdW3JDeRd1v2t7J02oeagQRDB2RbK2FDSsMqdtHgtD+Uk/44MqBuDeb1qCuj+CndKcXTEK5JmZ98Vfsq3wlouMoqB4= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85680+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1642121473408127.67050392156068; Thu, 13 Jan 2022 16:51:13 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id El2TYY1788612xk2dHlNiZtD; Thu, 13 Jan 2022 16:51:13 -0800 X-Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.1082.1642121466955476862 for ; Thu, 13 Jan 2022 16:51:12 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10226"; a="241713806" X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="241713806" X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:11 -0800 X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="475564638" X-Received: from guominji-mobl.ccr.corp.intel.com ([10.238.9.87]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:10 -0800 From: "Guomin Jiang" To: devel@edk2.groups.io Cc: GuoMinJ , Leif Lindholm , Ard Biesheuvel Subject: [edk2-devel] [PATCH 03/11] ArmPkg: Remove All UGA Support Date: Fri, 14 Jan 2022 08:50:36 +0800 Message-Id: <20220114005044.1975-4-guomin.jiang@intel.com> In-Reply-To: <20220114005044.1975-1-guomin.jiang@intel.com> References: <20220114005044.1975-1-guomin.jiang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,guomin.jiang@intel.com X-Gm-Message-State: a6DuXhyp4rdZIa3jzjpGew6Tx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642121473; bh=oWpvvKRqsn6LhJPSfWaOoP5aVq3yJhMk75LRQzPYogc=; h=Cc:Date:From:Reply-To:Subject:To; b=WHGr5waNVKqkIY/oIZD2Y5MhITlJtjFw9gR2G416k6bDflP+EiimFM7npV2znaq3vyh Hh+d9W953O16g+WP0mceKTSHlhfjGLwrAAEtQiOa+yRB7t4QdnaeMg+1Q9nyguoEd/nIf yb7Pj5oX40bPRI7BT+XOWBOJgaVIzHBKgJs= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642121475148100006 Content-Type: text/plain; charset="utf-8" From: GuoMinJ REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2368 Remove All UGA Support in ArmPkg. Signed-off-by: Guomin Jiang Cc: Leif Lindholm Cc: Ard Biesheuvel --- .../Library/PlatformBootManagerLib/PlatformBootManagerLib.inf | 3 --- ArmPkg/Library/PlatformBootManagerLib/PlatformBm.h | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/ArmPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.i= nf b/ArmPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf index 86751b45f82b..9270fd3e30d6 100644 --- a/ArmPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf +++ b/ArmPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf @@ -51,9 +51,6 @@ [LibraryClasses] UefiLib UefiRuntimeServicesTableLib =20 -[FeaturePcd] - gEfiMdePkgTokenSpaceGuid.PcdUgaConsumeSupport - [FixedPcd] gEfiMdeModulePkgTokenSpaceGuid.PcdEmuVariableNvModeEnable gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVersionString diff --git a/ArmPkg/Library/PlatformBootManagerLib/PlatformBm.h b/ArmPkg/Li= brary/PlatformBootManagerLib/PlatformBm.h index a40a2ff5cb4f..bab86495c1e6 100644 --- a/ArmPkg/Library/PlatformBootManagerLib/PlatformBm.h +++ b/ArmPkg/Library/PlatformBootManagerLib/PlatformBm.h @@ -43,7 +43,7 @@ EnableQuietBoot ( Simple Text Out screens will now be synced up with all non video output devices =20 - @retval EFI_SUCCESS UGA devices are back in text mode and synced up. + @retval EFI_SUCCESS Graphic devices are back in text mode and synced= up. **/ EFI_STATUS DisableQuietBoot ( --=20 2.30.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85680): https://edk2.groups.io/g/devel/message/85680 Mute This Topic: https://groups.io/mt/88411248/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Fri Apr 26 14:18:48 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85681+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85681+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642121475; cv=none; d=zohomail.com; s=zohoarc; b=KZe0UNGz/kaGk0Wce6tmMpNnT1TM8PQUF1BcJWxngvodJEkkoTIwn3eejMOnAbsgrqpJBwgfS351nNLjsFianXMLMuzukphVJ15eObS0AfHS79Q+BMeKAjB4shIYa5AH1rvp0sPa1Y02hdr/LOxjAMnM3eKAOYYknYNsRhLwsnU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642121475; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=iSLJ7Xb2/nxVQjrpRAEBWe391Or4DzsE13+uhH/H+Ng=; b=EVAoPOKyDrNKTYUVeWR/UetzVkEx5V0YNPRASJolTHLdSxRqqhX2sCd1Ss1v82NmZ1xLsRnaqSgPXq8wigEikgXeGr4rPvfnvLYbmwy+O4RlqYYGqvU9kykrgsBuLF+9UnU3HLXqusBa0s5uRve5E8GZKzavicsrviaaQZtJFCg= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85681+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1642121475055255.13473073581326; Thu, 13 Jan 2022 16:51:15 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id 2BApYY1788612xbT4ZbIP7Km; Thu, 13 Jan 2022 16:51:14 -0800 X-Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.1082.1642121466955476862 for ; Thu, 13 Jan 2022 16:51:14 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10226"; a="241713824" X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="241713824" X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:13 -0800 X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="475564677" X-Received: from guominji-mobl.ccr.corp.intel.com ([10.238.9.87]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:12 -0800 From: "Guomin Jiang" To: devel@edk2.groups.io Cc: GuoMinJ , Andrew Fish , Ray Ni Subject: [edk2-devel] [PATCH 04/11] EmulatorPkg: Remove All UGA Support Date: Fri, 14 Jan 2022 08:50:37 +0800 Message-Id: <20220114005044.1975-5-guomin.jiang@intel.com> In-Reply-To: <20220114005044.1975-1-guomin.jiang@intel.com> References: <20220114005044.1975-1-guomin.jiang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,guomin.jiang@intel.com X-Gm-Message-State: GYNZN31l3nJYFBHlwTZYjwCHx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642121474; bh=+3qpSnofZw5rI+QV8mpY9RnbTvoloaEeEu1oYWNpfFc=; h=Cc:Date:From:Reply-To:Subject:To; b=LY9wVIt68pZGKZZVOEnnFMmNK3vXlJT+B4Rb2AIJd+wBKTwNsX3BC+5myo+cDFsLfr6 EnYvhCVNUtKRoIIDrp4p+Umr+P43AsDxSkVeegD3MS+XEFXwHeaKnPBPuCaEDYqck5MeR FXC9wztsiCWqBv4TxggfE0nRjteDlw4xOoY= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642121477279100011 Content-Type: text/plain; charset="utf-8" From: GuoMinJ REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2368 Remove All UGA Support in EmulatorPkg. Signed-off-by: Guomin Jiang Cc: Andrew Fish Cc: Ray Ni --- EmulatorPkg/EmuGopDxe/Gop.h | 10 +-- EmulatorPkg/Include/Protocol/EmuFileSystem.h | 24 +++--- .../Include/Protocol/EmuGraphicsWindow.h | 18 ++-- .../Library/PlatformBmLib/PlatformBm.h | 4 +- EmulatorPkg/Unix/Host/Gasket.h | 12 +-- EmulatorPkg/Unix/Host/Host.h | 3 +- EmulatorPkg/EmuGopDxe/GopScreen.c | 16 ++-- .../Library/PlatformBmLib/PlatformBmData.c | 6 +- EmulatorPkg/Unix/Host/X11GraphicsWindow.c | 82 +++++++++---------- EmulatorPkg/Win/Host/WinGopScreen.c | 10 +-- EmulatorPkg/Unix/Host/Ia32/Gasket.S | 2 +- EmulatorPkg/Unix/Host/X64/Gasket.S | 2 +- 12 files changed, 93 insertions(+), 96 deletions(-) diff --git a/EmulatorPkg/EmuGopDxe/Gop.h b/EmulatorPkg/EmuGopDxe/Gop.h index 7f7dc4e8eb9f..099449f5007f 100644 --- a/EmulatorPkg/EmuGopDxe/Gop.h +++ b/EmulatorPkg/EmuGopDxe/Gop.h @@ -1,13 +1,13 @@ /*++ @file =20 -Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
Portions copyright (c) 2010,Apple Inc. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ =20 -#ifndef __UGA_H_ -#define __UGA_H_ +#ifndef GOP_H_ +#define GOP_H_ =20 #include =20 @@ -60,8 +60,6 @@ typedef struct { extern EFI_DRIVER_BINDING_PROTOCOL gEmuGopDriverBinding; extern EFI_COMPONENT_NAME_PROTOCOL gEmuGopComponentName; =20 -#define EMU_UGA_CLASS_NAME L"EmuGopWindow" - #define GOP_PRIVATE_DATA_SIGNATURE SIGNATURE_32 ('G', 'o', 'p', 'N') typedef struct { UINT64 Signature; @@ -83,7 +81,7 @@ typedef struct { GOP_MODE_DATA *ModeData; =20 // - // UGA Private Data knowing when to start hardware + // Private Data knowing when to start hardware // BOOLEAN HardwareNeedsStarting; =20 diff --git a/EmulatorPkg/Include/Protocol/EmuFileSystem.h b/EmulatorPkg/Inc= lude/Protocol/EmuFileSystem.h index 15de43ac022e..d0c0dee26bff 100644 --- a/EmulatorPkg/Include/Protocol/EmuFileSystem.h +++ b/EmulatorPkg/Include/Protocol/EmuFileSystem.h @@ -7,19 +7,19 @@ =20 UEFI 2.0 can boot from any valid EFI image contained in a SimpleFileSyst= em. =20 -Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
Portions copyright (c) 2011, Apple Inc. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ =20 -#ifndef _EMU_UGA_IO_H_ -#define _EMU_UGA_IO_H_ +#ifndef EMU_GRAPHICS_WINDOW_H_ +#define EMU_GRAPHICS_WINDOW_H_ =20 #include #include #include -#include +#include =20 #define EMU_GRAPHICS_WINDOW_PROTOCOL_GUID \ { 0x30FD316A, 0x6728, 0x2E41, { 0xA6, 0x90, 0x0D, 0x13, 0x33, 0xD8, 0xCA,= 0xC1 } } @@ -29,13 +29,13 @@ typedef struct _EMU_GRAPHICS_WINDOW_PROTOCOL EMU_GRAPHI= CS_WINDOW_PROTOCOL; typedef EFI_STATUS (EFIAPI *EMU_GRAPHICS_WINDOWS_CLOSE)( - EMU_GRAPHICS_WINDOW_PROTOCOL *Uga + EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindows ); =20 typedef EFI_STATUS (EFIAPI *EMU_GRAPHICS_WINDOWS_SIZE)( - EMU_GRAPHICS_WINDOW_PROTOCOL *Uga, + EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindows, UINT32 Width, UINT32 Height ); @@ -43,13 +43,13 @@ EFI_STATUS typedef EFI_STATUS (EFIAPI *EMU_GRAPHICS_WINDOWS_CHECK_KEY)( - EMU_GRAPHICS_WINDOW_PROTOCOL *Uga + EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindows ); =20 typedef EFI_STATUS (EFIAPI *EMU_GRAPHICS_WINDOWS_GET_KEY)( - EMU_GRAPHICS_WINDOW_PROTOCOL *Uga, + EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindows, EFI_KEY_DATA *key ); =20 @@ -88,10 +88,10 @@ typedef struct { typedef EFI_STATUS (EFIAPI *EMU_GRAPHICS_WINDOWS_BLT)( - IN EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindows, - IN EFI_UGA_PIXEL *BltBuffer OPTIONAL, - IN EFI_UGA_BLT_OPERATION BltOperation, - IN EMU_GRAPHICS_WINDOWS__BLT_ARGS *Args + IN EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindows, + IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer OPTIONAL, + IN EFI_GRAPHICS_OUTPUT_BLT_OPERATION BltOperation, + IN EMU_GRAPHICS_WINDOWS__BLT_ARGS *Args ); =20 typedef diff --git a/EmulatorPkg/Include/Protocol/EmuGraphicsWindow.h b/EmulatorPkg= /Include/Protocol/EmuGraphicsWindow.h index 7c495b25eb1b..ed7b71611f90 100644 --- a/EmulatorPkg/Include/Protocol/EmuGraphicsWindow.h +++ b/EmulatorPkg/Include/Protocol/EmuGraphicsWindow.h @@ -6,13 +6,13 @@ SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ =20 -#ifndef _EMU_UGA_IO_H_ -#define _EMU_UGA_IO_H_ +#ifndef EMU_GRAPHICS_WINDOW_H_ +#define EMU_GRAPHICS_WINDOW_H_ =20 #include #include #include -#include +#include =20 #define EMU_GRAPHICS_WINDOW_PROTOCOL_GUID \ { 0x30FD316A, 0x6728, 0x2E41, { 0xA6, 0x90, 0x0D, 0x13, 0x33, 0xD8, 0xCA,= 0xC1 } } @@ -22,13 +22,13 @@ typedef struct _EMU_GRAPHICS_WINDOW_PROTOCOL EMU_GRAPHI= CS_WINDOW_PROTOCOL; typedef EFI_STATUS (EFIAPI *EMU_GRAPHICS_WINDOWS_CLOSE)( - EMU_GRAPHICS_WINDOW_PROTOCOL *Uga + EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindow ); =20 typedef EFI_STATUS (EFIAPI *EMU_GRAPHICS_WINDOWS_SIZE)( - EMU_GRAPHICS_WINDOW_PROTOCOL *Uga, + EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindow, UINT32 Width, UINT32 Height ); @@ -36,13 +36,13 @@ EFI_STATUS typedef EFI_STATUS (EFIAPI *EMU_GRAPHICS_WINDOWS_CHECK_KEY)( - EMU_GRAPHICS_WINDOW_PROTOCOL *Uga + EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindow ); =20 typedef EFI_STATUS (EFIAPI *EMU_GRAPHICS_WINDOWS_GET_KEY)( - EMU_GRAPHICS_WINDOW_PROTOCOL *Uga, + EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindow, EFI_KEY_DATA *key ); =20 @@ -83,8 +83,8 @@ typedef EFI_STATUS (EFIAPI *EMU_GRAPHICS_WINDOWS_BLT)( IN EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindows, - IN EFI_UGA_PIXEL *BltBuffer OPTIONAL, - IN EFI_UGA_BLT_OPERATION BltOperation, + IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer OPTIONAL, + IN EFI_GRAPHICS_OUTPUT_BLT_OPERATION BltOperation, IN EMU_GRAPHICS_WINDOWS__BLT_ARGS *Args ); =20 diff --git a/EmulatorPkg/Library/PlatformBmLib/PlatformBm.h b/EmulatorPkg/L= ibrary/PlatformBmLib/PlatformBm.h index b89ffd77e4de..673bfba577b8 100644 --- a/EmulatorPkg/Library/PlatformBmLib/PlatformBm.h +++ b/EmulatorPkg/Library/PlatformBmLib/PlatformBm.h @@ -1,6 +1,6 @@ /*++ @file =20 -Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
Portions copyright (c) 2011, Apple Inc. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent =20 @@ -60,7 +60,7 @@ typedef struct { EMU_VENDOR_DEVICE_PATH_NODE EmuBus; EMU_VENDOR_DEVICE_PATH_NODE EmuGraphicsWindow; EFI_DEVICE_PATH_PROTOCOL End; -} EMU_PLATFORM_UGA_DEVICE_PATH; +} EMU_PLATFORM_GRAPHICS_WINDOW_DEVICE_PATH; =20 // // Platform BDS Functions diff --git a/EmulatorPkg/Unix/Host/Gasket.h b/EmulatorPkg/Unix/Host/Gasket.h index 6dafc903cfce..7c52e7f121d6 100644 --- a/EmulatorPkg/Unix/Host/Gasket.h +++ b/EmulatorPkg/Unix/Host/Gasket.h @@ -1,7 +1,7 @@ /** @file =20 Copyright (c) 2008 - 2011, Apple Inc. All rights reserved.
- Copyright (c) 2011 - 2019, Intel Corporation. All rights reserved.
+ Copyright (c) 2011 - 2021, Intel Corporation. All rights reserved.
=20 SPDX-License-Identifier: BSD-2-Clause-Patent =20 @@ -200,7 +200,7 @@ ReverseGasketUint64Uint64 ( ); =20 // -// Gasket functions for EFI_EMU_UGA_IO_PROTOCOL +// Gasket functions for EFI_EMU_GRAPHICS_WINDOW_PROTOCOL // =20 EFI_STATUS @@ -243,10 +243,10 @@ GasketX11RegisterKeyNotify ( EFI_STATUS EFIAPI GasketX11Blt ( - IN EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindows, - IN EFI_UGA_PIXEL *BltBuffer OPTIONAL, - IN EFI_UGA_BLT_OPERATION BltOperation, - IN EMU_GRAPHICS_WINDOWS__BLT_ARGS *Args + IN EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsWindows, + IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer OPTIONAL, + IN EFI_GRAPHICS_OUTPUT_BLT_OPERATION BltOperation, + IN EMU_GRAPHICS_WINDOWS__BLT_ARGS *Args ); =20 EFI_STATUS diff --git a/EmulatorPkg/Unix/Host/Host.h b/EmulatorPkg/Unix/Host/Host.h index 0c81cdfc01f5..a1ac4207bef9 100644 --- a/EmulatorPkg/Unix/Host/Host.h +++ b/EmulatorPkg/Unix/Host/Host.h @@ -1,6 +1,6 @@ /*++ @file =20 -Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
Portions copyright (c) 2008 - 2011, Apple Inc. All rights reserved.
=20 SPDX-License-Identifier: BSD-2-Clause-Patent @@ -106,7 +106,6 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #include #include #include -#include #include =20 #include diff --git a/EmulatorPkg/EmuGopDxe/GopScreen.c b/EmulatorPkg/EmuGopDxe/GopS= creen.c index 41f748bc6402..e8030a50ce23 100644 --- a/EmulatorPkg/EmuGopDxe/GopScreen.c +++ b/EmulatorPkg/EmuGopDxe/GopScreen.c @@ -1,6 +1,6 @@ /*++ @file =20 -Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
Portions copyright (c) 2010 - 2011, Apple Inc. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent =20 @@ -10,7 +10,7 @@ Module Name: =20 Abstract: =20 - This file produces the graphics abstration of UGA. It is called by + This file produces the graphics abstration of GOP. It is called by EmuGopDriver.c file which deals with the EFI 1.1 driver model. This file just does graphics. =20 @@ -208,7 +208,7 @@ EmuGopBlt ( // the number of bytes in each row can be computed. // if (Delta =3D=3D 0) { - Delta =3D Width * sizeof (EFI_UGA_PIXEL); + Delta =3D Width * sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL); } =20 // @@ -219,8 +219,8 @@ EmuGopBlt ( OriginalTPL =3D gBS->RaiseTPL (TPL_NOTIFY); =20 // - // Pack UGA Draw protocol parameters to EMU_GRAPHICS_WINDOWS__BLT_ARGS s= tructure to adapt to - // GopBlt() API of Unix UGA IO protocol. + // Pack GOP protocol parameters to EMU_GRAPHICS_WINDOWS__BLT_ARGS struct= ure to adapt to + // GopBlt() API of GOP protocol. // GopBltArgs.DestinationX =3D DestinationX; GopBltArgs.DestinationY =3D DestinationY; @@ -231,8 +231,8 @@ EmuGopBlt ( GopBltArgs.Delta =3D Delta; Status =3D Private->EmuGraphicsWindow->Blt ( Private->EmuGrap= hicsWindow, - (EFI_UGA_PIXEL *= )BltBuffer, - (EFI_UGA_BLT_OPE= RATION)BltOperation, + BltBuffer, + BltOperation, &GopBltArgs ); =20 @@ -383,7 +383,7 @@ ShutdownGopEvent ( =20 Routine Description: =20 - This is the UGA screen's callback notification function for exit-boot-se= rvices. + This is the screen's callback notification function for exit-boot-servic= es. All we do here is call EmuGopDestructor(). =20 Arguments: diff --git a/EmulatorPkg/Library/PlatformBmLib/PlatformBmData.c b/EmulatorP= kg/Library/PlatformBmLib/PlatformBmData.c index efb03def37eb..b69c4728d1a7 100644 --- a/EmulatorPkg/Library/PlatformBmLib/PlatformBmData.c +++ b/EmulatorPkg/Library/PlatformBmLib/PlatformBmData.c @@ -1,6 +1,6 @@ /*++ @file =20 -Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2022, Intel Corporation. All rights reserved.
Portions copyright (c) 2011, Apple Inc. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent =20 @@ -8,7 +8,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent =20 #include "PlatformBm.h" =20 -EMU_PLATFORM_UGA_DEVICE_PATH gGopDevicePath =3D { +EMU_PLATFORM_GRAPHICS_WINDOW_DEVICE_PATH gGopDevicePath =3D { { { { @@ -40,7 +40,7 @@ EMU_PLATFORM_UGA_DEVICE_PATH gGopDevicePath =3D { gEndEntire }; =20 -EMU_PLATFORM_UGA_DEVICE_PATH gGopDevicePath2 =3D { +EMU_PLATFORM_GRAPHICS_WINDOW_DEVICE_PATH gGopDevicePath2 =3D { { { { diff --git a/EmulatorPkg/Unix/Host/X11GraphicsWindow.c b/EmulatorPkg/Unix/H= ost/X11GraphicsWindow.c index a30cc19dbe0a..b3880e198855 100644 --- a/EmulatorPkg/Unix/Host/X11GraphicsWindow.c +++ b/EmulatorPkg/Unix/Host/X11GraphicsWindow.c @@ -1,6 +1,6 @@ /*++ @file =20 -Copyright (c) 2004 - 2019, Intel Corporation. All rights reserved.
+Copyright (c) 2004 - 2022, Intel Corporation. All rights reserved.
Portions copyright (c) 2008 - 2011, Apple Inc. All rights reserved.
=20 SPDX-License-Identifier: BSD-2-Clause-Patent @@ -700,8 +700,8 @@ HandleEvents ( =20 unsigned long X11PixelToColor ( - IN GRAPHICS_IO_PRIVATE *Drv, - IN EFI_UGA_PIXEL pixel + IN GRAPHICS_IO_PRIVATE *Drv, + IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL pixel ) { return ((pixel.Red >> Drv->r.csize) << Drv->r.shift) @@ -709,15 +709,15 @@ X11PixelToColor ( | ((pixel.Blue >> Drv->b.csize) << Drv->b.shift); } =20 -EFI_UGA_PIXEL +EFI_GRAPHICS_OUTPUT_BLT_PIXEL X11ColorToPixel ( IN GRAPHICS_IO_PRIVATE *Drv, IN unsigned long val ) { - EFI_UGA_PIXEL Pixel; + EFI_GRAPHICS_OUTPUT_BLT_PIXEL Pixel; =20 - memset (&Pixel, 0, sizeof (EFI_UGA_PIXEL)); + memset (&Pixel, 0, sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL)); =20 // Truncation not an issue since X11 and EFI are both using 8 bits per c= olor Pixel.Red =3D (val >> Drv->r.shift) << Drv->r.csize; @@ -782,7 +782,7 @@ X11KeySetState ( if ((Drv->KeyState.KeyToggleState & EFI_CAPS_LOCK_ACTIVE) =3D=3D 0) { // // We could create an XKeyEvent and send a XK_Caps_Lock to - // the UGA/GOP Window + // the GOP Window // } } @@ -812,32 +812,32 @@ X11RegisterKeyNotify ( =20 EFI_STATUS X11Blt ( - IN EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsIo, - IN EFI_UGA_PIXEL *BltBuffer OPTIONAL, - IN EFI_UGA_BLT_OPERATION BltOperation, - IN EMU_GRAPHICS_WINDOWS__BLT_ARGS *Args + IN EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsIo, + IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer OPTIONAL, + IN EFI_GRAPHICS_OUTPUT_BLT_OPERATION BltOperation, + IN EMU_GRAPHICS_WINDOWS__BLT_ARGS *Args ) { - GRAPHICS_IO_PRIVATE *Private; - UINTN DstY; - UINTN SrcY; - UINTN DstX; - UINTN SrcX; - UINTN Index; - EFI_UGA_PIXEL *Blt; - UINT8 *Dst; - UINT8 *Src; - UINTN Nbr; - unsigned long Color; - XEvent ev; + GRAPHICS_IO_PRIVATE *Private; + UINTN DstY; + UINTN SrcY; + UINTN DstX; + UINTN SrcX; + UINTN Index; + EFI_GRAPHICS_OUTPUT_BLT_PIXEL *Blt; + UINT8 *Dst; + UINT8 *Src; + UINTN Nbr; + unsigned long Color; + XEvent ev; =20 Private =3D (GRAPHICS_IO_PRIVATE *)GraphicsIo; =20 // // Check bounds // - if ( (BltOperation =3D=3D EfiUgaVideoToBltBuffer) - || (BltOperation =3D=3D EfiUgaVideoToVideo)) + if ( (BltOperation =3D=3D EfiBltVideoToBltBuffer) + || (BltOperation =3D=3D EfiBltVideoToVideo)) { // // Source is Video. @@ -851,9 +851,9 @@ X11Blt ( } } =20 - if ( (BltOperation =3D=3D EfiUgaBltBufferToVideo) - || (BltOperation =3D=3D EfiUgaVideoToVideo) - || (BltOperation =3D=3D EfiUgaVideoFill)) + if ( (BltOperation =3D=3D EfiBltBufferToVideo) + || (BltOperation =3D=3D EfiBltVideoToVideo) + || (BltOperation =3D=3D EfiBltVideoFill)) { // // Destination is Video @@ -868,32 +868,32 @@ X11Blt ( } =20 switch (BltOperation) { - case EfiUgaVideoToBltBuffer: - Blt =3D (EFI_UGA_PIXEL *)((UINT8 *)BltBuffer + (Args->Desti= nationY * Args->Delta) + Args->DestinationX * sizeof (EFI_UGA_PIXEL)); - Args->Delta -=3D Args->Width * sizeof (EFI_UGA_PIXEL); + case EfiBltVideoToBltBuffer: + Blt =3D (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)((UINT8 *)BltBuffe= r + (Args->DestinationY * Args->Delta) + Args->DestinationX * sizeof (EFI_G= RAPHICS_OUTPUT_BLT_PIXEL)); + Args->Delta -=3D Args->Width * sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL= ); for (SrcY =3D Args->SourceY; SrcY < (Args->Height + Args->SourceY); = SrcY++) { for (SrcX =3D Args->SourceX; SrcX < (Args->Width + Args->SourceX);= SrcX++) { *Blt++ =3D X11ColorToPixel (Private, XGetPixel (Private->image, = SrcX, SrcY)); } =20 - Blt =3D (EFI_UGA_PIXEL *)((UINT8 *)Blt + Args->Delta); + Blt =3D (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)((UINT8 *)Blt + Args->Del= ta); } =20 break; - case EfiUgaBltBufferToVideo: - Blt =3D (EFI_UGA_PIXEL *)((UINT8 *)BltBuffer + (Args->Sourc= eY * Args->Delta) + Args->SourceX * sizeof (EFI_UGA_PIXEL)); - Args->Delta -=3D Args->Width * sizeof (EFI_UGA_PIXEL); + case EfiBltBufferToVideo: + Blt =3D (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)((UINT8 *)BltBuffe= r + (Args->SourceY * Args->Delta) + Args->SourceX * sizeof (EFI_GRAPHICS_OU= TPUT_BLT_PIXEL)); + Args->Delta -=3D Args->Width * sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL= ); for (DstY =3D Args->DestinationY; DstY < (Args->Height + Args->Desti= nationY); DstY++) { for (DstX =3D Args->DestinationX; DstX < (Args->Width + Args->Dest= inationX); DstX++) { XPutPixel (Private->image, DstX, DstY, X11PixelToColor (Private,= *Blt)); Blt++; } =20 - Blt =3D (EFI_UGA_PIXEL *)((UINT8 *)Blt + Args->Delta); + Blt =3D (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)((UINT8 *)Blt + Args->Del= ta); } =20 break; - case EfiUgaVideoToVideo: + case EfiBltVideoToVideo: Dst =3D Private->image_data + (Args->DestinationX << Private->pixel_= shift) + Args->DestinationY * Private->line_bytes; Src =3D Private->image_data + (Args->SourceX << Private->pixel_shift) @@ -920,7 +920,7 @@ X11Blt ( } =20 break; - case EfiUgaVideoFill: + case EfiBltVideoFill: Color =3D X11PixelToColor (Private, *BltBuffer); for (DstY =3D Args->DestinationY; DstY < (Args->Height + Args->Desti= nationY); DstY++) { for (DstX =3D Args->DestinationX; DstX < (Args->Width + Args->Dest= inationX); DstX++) { @@ -937,7 +937,7 @@ X11Blt ( // Refresh screen. // switch (BltOperation) { - case EfiUgaVideoToVideo: + case EfiBltVideoToVideo: XCopyArea ( Private->display, Private->win, @@ -960,7 +960,7 @@ X11Blt ( } =20 break; - case EfiUgaVideoFill: + case EfiBltVideoFill: Color =3D X11PixelToColor (Private, *BltBuffer); XSetForeground (Private->display, Private->gc, Color); XFillRectangle ( @@ -974,7 +974,7 @@ X11Blt ( ); XFlush (Private->display); break; - case EfiUgaBltBufferToVideo: + case EfiBltBufferToVideo: Redraw (Private, Args->DestinationX, Args->DestinationY, Args->Width= , Args->Height); break; default: diff --git a/EmulatorPkg/Win/Host/WinGopScreen.c b/EmulatorPkg/Win/Host/Win= GopScreen.c index 661573d7771c..17da6feefd5d 100644 --- a/EmulatorPkg/Win/Host/WinGopScreen.c +++ b/EmulatorPkg/Win/Host/WinGopScreen.c @@ -1,6 +1,6 @@ /** @file =20 -Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 Module Name: @@ -396,10 +396,10 @@ WinNtWndSize ( // TODO: Delta - add argument and description to function comment EFI_STATUS WinNtWndBlt ( - IN EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsIo, - IN EFI_UGA_PIXEL *BltBuffer OPTIONAL, - IN EFI_UGA_BLT_OPERATION BltOperation, - IN EMU_GRAPHICS_WINDOWS__BLT_ARGS *Args + IN EMU_GRAPHICS_WINDOW_PROTOCOL *GraphicsIo, + IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer OPTIONAL, + IN EFI_GRAPHICS_OUTPUT_BLT_OPERATION BltOperation, + IN EMU_GRAPHICS_WINDOWS__BLT_ARGS *Args ) { RETURN_STATUS RStatus; diff --git a/EmulatorPkg/Unix/Host/Ia32/Gasket.S b/EmulatorPkg/Unix/Host/Ia= 32/Gasket.S index 36197ff26028..6fcdd265cf30 100644 --- a/EmulatorPkg/Unix/Host/Ia32/Gasket.S +++ b/EmulatorPkg/Unix/Host/Ia32/Gasket.S @@ -371,7 +371,7 @@ ASM_PFX(GasketSecEmuThunkAddress): ret =20 // -// Gasket functions for EFI_EMU_UGA_IO_PROTOCOL +// Gasket functions for EFI_EMU_GRAPHICS_WINDOW_PROTOCOL // =20 ASM_GLOBAL ASM_PFX(GasketX11Size) diff --git a/EmulatorPkg/Unix/Host/X64/Gasket.S b/EmulatorPkg/Unix/Host/X64= /Gasket.S index 030faa8e4c36..1b4614ab618d 100644 --- a/EmulatorPkg/Unix/Host/X64/Gasket.S +++ b/EmulatorPkg/Unix/Host/X64/Gasket.S @@ -427,7 +427,7 @@ ASM_PFX(GasketSecEmuThunkAddress): ret =20 // -// Gasket functions for EFI_EMU_UGA_IO_PROTOCOL +// Gasket functions for EFI_EMU_GRAPHICS_WINDOW_PROTOCOL // =20 ASM_GLOBAL ASM_PFX(GasketX11Size) --=20 2.30.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85681): https://edk2.groups.io/g/devel/message/85681 Mute This Topic: https://groups.io/mt/88411249/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Fri Apr 26 14:18:48 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85682+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85682+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642121476; cv=none; d=zohomail.com; s=zohoarc; b=LH89vn7WOoduRCnWrmvfsBKNz4nu4PoGskud4Ee9OTC/wWgLK+rUMJOwqxYL4zyfz4mnUI+IwFi9op6ecqgNrxU3ftxZR2jaiJzfEAxYur0M2r0lBmZdeMH/+I7sI0b2m7rgWSrIFSt1NcEql2qAtGXuv8JjEn2C+lS01QOMhsk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642121476; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=GKzNPRiS2zvbUKjkdoN/I2M3OndTsMocsUhhEZQ5rnw=; b=eVyuggC/kwuKY7CQ7eWOkIjDuQkK0JkCRv8wrVFTHiynIaqA6FGZsr7X2+1y7oQj1NCPk35O33bBsR7YyXoW/WppYEstINV5ioB7Yd3/nAnKiWuN+D8Vfl6mummck/rmCTeFLPt0PGqcDyCZ5FgolZhcv1O24siyRdO2zNwg2GM= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85682+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1642121476881339.74046280317407; Thu, 13 Jan 2022 16:51:16 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id 08VkYY1788612xBSbCMqU1O6; Thu, 13 Jan 2022 16:51:16 -0800 X-Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.1082.1642121466955476862 for ; Thu, 13 Jan 2022 16:51:16 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10226"; a="241713837" X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="241713837" X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:15 -0800 X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="475564684" X-Received: from guominji-mobl.ccr.corp.intel.com ([10.238.9.87]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:13 -0800 From: "Guomin Jiang" To: devel@edk2.groups.io Cc: GuoMinJ , Ray Ni , Zhichao Gao Subject: [edk2-devel] [PATCH 05/11] ShellPkg: Remove All UGA Support Date: Fri, 14 Jan 2022 08:50:38 +0800 Message-Id: <20220114005044.1975-6-guomin.jiang@intel.com> In-Reply-To: <20220114005044.1975-1-guomin.jiang@intel.com> References: <20220114005044.1975-1-guomin.jiang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,guomin.jiang@intel.com X-Gm-Message-State: VgEYkTolNlE47nAfIH01HR14x1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642121476; bh=r8OzN4iHfy9OqqJIA9g4W8XR8Ix/0c5PfY+9OOZNHz0=; h=Cc:Date:From:Reply-To:Subject:To; b=YzkwdwxhdeG8587zN4sehz3DrG1tWc01EGrXKMEJCE/FzO+/Rpt9lQ48k8ECduiOcZE n9fdmKHBUGPXWYoMYAKLYrggE1iR4hu1je4ywJdP2VfauW8sTLEPdrkoCLYEspAnm+Arp aJBSfL3sudgMDklZC9/G4wewmsJ9TuHyGK8= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642121477442100016 Content-Type: text/plain; charset="utf-8" From: GuoMinJ REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2368 Remove All UGA Support in ShellPkg. Signed-off-by: Guomin Jiang Cc: Ray Ni Cc: Zhichao Gao --- .../Library/UefiHandleParsingLib/UefiHandleParsingLib.inf | 4 +--- ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h | 4 +--- ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c | 4 +--- .../Library/UefiHandleParsingLib/UefiHandleParsingLib.uni | 4 +--- 4 files changed, 4 insertions(+), 12 deletions(-) diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf index 0d483805e712..97fed1a50859 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf @@ -1,6 +1,6 @@ ## @file # Provides interface to advanced shell functionality for parsing both han= dle and protocol database. -# Copyright (c) 2010 - 2018, Intel Corporation. All rights reserved.
+# Copyright (c) 2010 - 2021, Intel Corporation. All rights reserved.
# (C) Copyright 2013-2015 Hewlett-Packard Development Company, L.P.
# (C) Copyright 2015-2021 Hewlett Packard Enterprise Development LP
# @@ -129,8 +129,6 @@ [Protocols] gEfiHiiConfigAccessProtocolGuid ## UNDEFINED gEfiFormBrowser2ProtocolGuid ## UNDEFINED gEfiDeviceIoProtocolGuid ## UNDEFINED - gEfiUgaDrawProtocolGuid ## UNDEFINED - gEfiUgaIoProtocolGuid ## UNDEFINED gEfiDriverConfigurationProtocolGuid ## UNDEFINED gEfiDriverConfiguration2ProtocolGuid ## UNDEFINED gEfiSimpleTextInputExProtocolGuid ## UNDEFINED diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h b= /ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h index 6be0d78c4c5a..ab66ed141757 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h @@ -1,7 +1,7 @@ /** @file Provides interface to advanced shell functionality for parsing both hand= le and protocol database. =20 - Copyright (c) 2011 - 2018, Intel Corporation. All rights reserved.
+ Copyright (c) 2011 - 2021, Intel Corporation. All rights reserved.
(C) Copyright 2016 Hewlett Packard Enterprise Development LP
(C) Copyright 2013-2016 Hewlett-Packard Development Company, L.P.
SPDX-License-Identifier: BSD-2-Clause-Patent @@ -94,8 +94,6 @@ #include #include #include -#include -#include #include #include #include diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c b= /ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c index aa0115bdd498..d67ca16b5ece 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c @@ -1,7 +1,7 @@ /** @file Provides interface to advanced shell functionality for parsing both hand= le and protocol database. =20 - Copyright (c) 2010 - 2017, Intel Corporation. All rights reserved.
+ Copyright (c) 2010 - 2021, Intel Corporation. All rights reserved.
(C) Copyright 2013-2015 Hewlett-Packard Development Company, L.P.
(C) Copyright 2015-2021 Hewlett Packard Enterprise Development LP
SPDX-License-Identifier: BSD-2-Clause-Patent @@ -2238,8 +2238,6 @@ STATIC CONST GUID_INFO_BLOCK mGuidStringList[] =3D { { STRING_TOKEN (STR_SHELL_ENV2), &gEfiShellEnvironment2Guid, = NULL }, { STRING_TOKEN (STR_SHELL_ENV), &gEfiShellEnvironment2Guid, = NULL }, { STRING_TOKEN (STR_DEVICE_IO), &gEfiDeviceIoProtocolGuid, = NULL }, - { STRING_TOKEN (STR_UGA_DRAW), &gEfiUgaDrawProtocolGuid, = NULL }, - { STRING_TOKEN (STR_UGA_IO), &gEfiUgaIoProtocolGuid, = NULL }, { STRING_TOKEN (STR_ESP), &gEfiPartTypeSystemPartGuid, = NULL }, { STRING_TOKEN (STR_GPT_NBR), &gEfiPartTypeLegacyMbrGuid, = NULL }, { STRING_TOKEN (STR_DRIVER_CONFIG), &gEfiDriverConfigurationProtoc= olGuid, NULL }, diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni index aa3396cea94d..1ecc99ba03fe 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni @@ -1,6 +1,6 @@ // /** // -// Copyright (c) 2010 - 2017, Intel Corporation. All rights reserved.
+// Copyright (c) 2010 - 2021, Intel Corporation. All rights reserved.
// (C) Copyright 2013-2015 Hewlett-Packard Development Company, L.P.
// (C) Copyright 2015-2021 Hewlett Packard Enterprise Development LP
// SPDX-License-Identifier: BSD-2-Clause-Patent @@ -161,8 +161,6 @@ #string STR_SHELL_ALIAS #language en-US "ShellAlias" #string STR_DEVICE_IO #language en-US "DeviceIO" #string STR_TCP #language en-US "TCP" -#string STR_UGA_DRAW #language en-US "UGADraw" -#string STR_UGA_IO #language en-US "UGAIO" #string STR_ESP #language en-US "EFISystemPartition" #string STR_GPT_NBR #language en-US "LegacyMBR" #string STR_DRIVER_CONFIG #language en-US "DriverConfiguration" --=20 2.30.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85682): https://edk2.groups.io/g/devel/message/85682 Mute This Topic: https://groups.io/mt/88411250/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Fri Apr 26 14:18:48 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85683+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85683+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642121480; cv=none; d=zohomail.com; s=zohoarc; b=TJmECOC4HG6IS+5MuZuvaG2qMADi5czB95vR08DX1erH0vSElQlWvkp4MA2XRFQS5UoHS+8D4/zTO/1315AiUdWG7M+9+4ryOGZwn1SNxXTulh6nCyvd6JALY0EiWqpfRgcgVwWBFJ15ZiIp4vfkrrSdjItbyRsANteVWyt7NHc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642121480; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=uBjUn3adqebR7Q89eHHbTOCTvXUDzC7Wk3NyxfQpYFY=; b=SAydFV0CJPbzjxUmyCLzSgPxJCrO97VwkfjZB9seKb8OgKzAO2VscugYulHa2qdpLR36V5BDskhEvGeN96plV5ud+LzLVNEbDflf0xFuHrvTcDAQF9R9Z3RnEApY0WA7Uz+vRotNS7m6iAtnXb3LQpQXgTNG8xmxhcfCt49ICp0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85683+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1642121480056630.4020952222204; Thu, 13 Jan 2022 16:51:20 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id xxlOYY1788612xn8Kf6Uzgkv; Thu, 13 Jan 2022 16:51:19 -0800 X-Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.1082.1642121466955476862 for ; Thu, 13 Jan 2022 16:51:19 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10226"; a="241713857" X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="241713857" X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:18 -0800 X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="475564713" X-Received: from guominji-mobl.ccr.corp.intel.com ([10.238.9.87]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:16 -0800 From: "Guomin Jiang" To: devel@edk2.groups.io Cc: GuoMinJ , Ard Biesheuvel , Jiewen Yao , Jordan Justen , Gerd Hoffmann , Anthony Perard , Julien Grall Subject: [edk2-devel] [PATCH 06/11] OvmfPkg: Remove All UGA Support Date: Fri, 14 Jan 2022 08:50:39 +0800 Message-Id: <20220114005044.1975-7-guomin.jiang@intel.com> In-Reply-To: <20220114005044.1975-1-guomin.jiang@intel.com> References: <20220114005044.1975-1-guomin.jiang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,guomin.jiang@intel.com X-Gm-Message-State: 01hf5MB0MMILSPvj6didwZS0x1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642121479; bh=U1k7qp6q703q5aSYAmC0R3QKo0xZmZoZ2qON96WJp3E=; h=Cc:Date:From:Reply-To:Subject:To; b=l5xMKeImwiWRj8dKrZQjb2XgZ775NaAl3ivL+aMhhlS9eMSu7DTo6mzhc9MTQrFXtdD aghCKUC/BsdVFLRn0YCddIkynbpEmg0vHBTo4kJWcJc8uf9sLkvPMjdLmKOnKdZOrtv21 m4Z18yTw7a1kIBiJf5n5w/+Fji4A0YBISEE= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642121481648100001 Content-Type: text/plain; charset="utf-8" From: GuoMinJ REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2368 Delete PcdConOutGopSupport, it is unnecessary any more. Signed-off-by: Guomin Jiang Cc: Ard Biesheuvel Cc: Jiewen Yao Cc: Jordan Justen Cc: Gerd Hoffmann Cc: Anthony Perard Cc: Julien Grall --- OvmfPkg/AmdSev/AmdSevX64.dsc | 2 -- OvmfPkg/Bhyve/BhyveX64.dsc | 2 -- OvmfPkg/Microvm/MicrovmX64.dsc | 2 -- OvmfPkg/OvmfPkgIa32.dsc | 2 -- OvmfPkg/OvmfPkgIa32X64.dsc | 2 -- OvmfPkg/OvmfPkgX64.dsc | 2 -- OvmfPkg/OvmfXen.dsc | 2 -- 7 files changed, 14 deletions(-) diff --git a/OvmfPkg/AmdSev/AmdSevX64.dsc b/OvmfPkg/AmdSev/AmdSevX64.dsc index 04ae61cf69d8..bf649cc3796a 100644 --- a/OvmfPkg/AmdSev/AmdSevX64.dsc +++ b/OvmfPkg/AmdSev/AmdSevX64.dsc @@ -423,8 +423,6 @@ [PcdsFeatureFlag] gEfiMdeModulePkgTokenSpaceGuid.PcdHiiOsRuntimeSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSupportUefiDecompress|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode|FALSE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol|TRUE =20 [PcdsFixedAtBuild] diff --git a/OvmfPkg/Bhyve/BhyveX64.dsc b/OvmfPkg/Bhyve/BhyveX64.dsc index 5fa08bebd73c..df417365aab3 100644 --- a/OvmfPkg/Bhyve/BhyveX64.dsc +++ b/OvmfPkg/Bhyve/BhyveX64.dsc @@ -412,8 +412,6 @@ [PcdsFeatureFlag] gEfiMdeModulePkgTokenSpaceGuid.PcdHiiOsRuntimeSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSupportUefiDecompress|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode|FALSE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol|TRUE =20 [PcdsFixedAtBuild] diff --git a/OvmfPkg/Microvm/MicrovmX64.dsc b/OvmfPkg/Microvm/MicrovmX64.dsc index 1c2e600febee..6a66f4fbf6d9 100644 --- a/OvmfPkg/Microvm/MicrovmX64.dsc +++ b/OvmfPkg/Microvm/MicrovmX64.dsc @@ -435,8 +435,6 @@ [PcdsFeatureFlag] gEfiMdeModulePkgTokenSpaceGuid.PcdHiiOsRuntimeSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSupportUefiDecompress|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode|FALSE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol|TRUE =20 [PcdsFixedAtBuild] diff --git a/OvmfPkg/OvmfPkgIa32.dsc b/OvmfPkg/OvmfPkgIa32.dsc index 085cc7ece15d..28ef361f5316 100644 --- a/OvmfPkg/OvmfPkgIa32.dsc +++ b/OvmfPkg/OvmfPkgIa32.dsc @@ -454,8 +454,6 @@ [PcdsFeatureFlag] gEfiMdeModulePkgTokenSpaceGuid.PcdHiiOsRuntimeSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSupportUefiDecompress|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode|FALSE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol|TRUE !ifdef $(CSM_ENABLE) gUefiOvmfPkgTokenSpaceGuid.PcdCsmEnable|TRUE diff --git a/OvmfPkg/OvmfPkgIa32X64.dsc b/OvmfPkg/OvmfPkgIa32X64.dsc index 0ce122ddb50c..f93675fcfba3 100644 --- a/OvmfPkg/OvmfPkgIa32X64.dsc +++ b/OvmfPkg/OvmfPkgIa32X64.dsc @@ -458,8 +458,6 @@ [PcdsFeatureFlag] gEfiMdeModulePkgTokenSpaceGuid.PcdHiiOsRuntimeSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSupportUefiDecompress|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol|TRUE !ifdef $(CSM_ENABLE) gUefiOvmfPkgTokenSpaceGuid.PcdCsmEnable|TRUE diff --git a/OvmfPkg/OvmfPkgX64.dsc b/OvmfPkg/OvmfPkgX64.dsc index 4589adff388d..79740c04457f 100644 --- a/OvmfPkg/OvmfPkgX64.dsc +++ b/OvmfPkg/OvmfPkgX64.dsc @@ -459,8 +459,6 @@ [PcdsFeatureFlag] gEfiMdeModulePkgTokenSpaceGuid.PcdHiiOsRuntimeSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSupportUefiDecompress|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode|FALSE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol|TRUE !ifdef $(CSM_ENABLE) gUefiOvmfPkgTokenSpaceGuid.PcdCsmEnable|TRUE diff --git a/OvmfPkg/OvmfXen.dsc b/OvmfPkg/OvmfXen.dsc index de0d30bfb807..83114e7f7ee8 100644 --- a/OvmfPkg/OvmfXen.dsc +++ b/OvmfPkg/OvmfXen.dsc @@ -353,8 +353,6 @@ [PcdsFeatureFlag] gEfiMdeModulePkgTokenSpaceGuid.PcdHiiOsRuntimeSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSupportUefiDecompress|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode|FALSE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport|FALSE gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol|TRUE !ifdef $(CSM_ENABLE) gUefiOvmfPkgTokenSpaceGuid.PcdCsmEnable|TRUE --=20 2.30.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85683): https://edk2.groups.io/g/devel/message/85683 Mute This Topic: https://groups.io/mt/88411251/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Fri Apr 26 14:18:48 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85684+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85684+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642121483; cv=none; d=zohomail.com; s=zohoarc; b=MvRRBcHZ6uYpIgZvzRTXq1Fsjv6fWOquV8HgtO3eHDo9CEOYc6j69ZgPaXUV5WWJxqgYLLNvClcukqz2sA/QfXDU4VHAUQ8qmzJW3uzWOFt9ETAWehuBUSljgHA7D2SQiHZw3gRyEfu12A69z6aJzowoppVz1U7Srw/eIB7H5yw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642121483; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=TUhNLeDw5ulrug/SMrJvcsbhbQdKljpnKt2Q/dSIgCE=; b=QuRTKWJlnqJeOisQ/7PNYBSD0Qs36QdTIbVDUQFVN4kFBhpXrC7t4FkvTMcL7KzJovs3Oa7ULewWMPDNxIQOeWVPp9vJ4L5pb8hMiZoeT8xh5mCFw7B8kgy9RHJUM36UAP9agfoznRRCH4J4DNYqEU0QiSy/wQCCDxKxS6oyScI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85684+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1642121483015727.9448848673144; Thu, 13 Jan 2022 16:51:23 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id Sud1YY1788612xUn0cjkafBM; Thu, 13 Jan 2022 16:51:22 -0800 X-Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.1082.1642121466955476862 for ; Thu, 13 Jan 2022 16:51:22 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10226"; a="241713871" X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="241713871" X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:21 -0800 X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="475564727" X-Received: from guominji-mobl.ccr.corp.intel.com ([10.238.9.87]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:19 -0800 From: "Guomin Jiang" To: devel@edk2.groups.io Cc: GuoMinJ , Jian J Wang , Liming Gao , Zhichao Gao , Ray Ni Subject: [edk2-devel] [PATCH 07/11] MdeModulePkg/ConSplitterDxe: Remove All UGA Support Date: Fri, 14 Jan 2022 08:50:40 +0800 Message-Id: <20220114005044.1975-8-guomin.jiang@intel.com> In-Reply-To: <20220114005044.1975-1-guomin.jiang@intel.com> References: <20220114005044.1975-1-guomin.jiang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,guomin.jiang@intel.com X-Gm-Message-State: wAIYHO9BybKOD8k7rSDaUJR6x1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642121482; bh=0Kb40Mqi5vxkCMJTB/eWtMhdzNU5T+hKY0bxEazGFDY=; h=Cc:Date:From:Reply-To:Subject:To; b=R84hRojItA1o9oA4x0nypbZEKJLDy+XSU7Hc8FTyRte2RG4PRQvzx+10ntMGaj7n+0v rYX/zUXA/vZu+63DKLrUNgKqyqKakzfX0+QvZwGZmO9byfNpXjKrFL9oK8YyJA1XgSn36 PJyg0S+9cNbqQmjbD1twbc0xZRSBKD8wL3k= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642121484144100001 Content-Type: text/plain; charset="utf-8" From: GuoMinJ REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2368 Remove the PcdConOutGopSupport, it is unnecessary any more. Remove All UGA Support in ConSplitterDxe component. Signed-off-by: Guomin Jiang Cc: Jian J Wang Cc: Liming Gao Cc: Zhichao Gao Cc: Ray Ni --- .../Console/ConSplitterDxe/ConSplitterDxe.inf | 17 +- .../Console/ConSplitterDxe/ConSplitter.h | 138 +----- .../Console/ConSplitterDxe/ConSplitter.c | 405 +++--------------- .../ConSplitterDxe/ConSplitterGraphics.c | 310 +------------- .../Console/ConSplitterDxe/ConSplitterDxe.uni | 12 +- 5 files changed, 80 insertions(+), 802 deletions(-) diff --git a/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.i= nf b/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf index 9aa1dade752a..c0c57193b04d 100644 --- a/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf +++ b/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf @@ -3,14 +3,9 @@ # # This driver acts as a virtual console, takes over the console I/O contro= l from selected # standard console devices, and transmits console I/O to related console d= evice drivers. -# Consplitter could install Graphics Output protocol and/or UGA Draw proto= col in system -# table according PCD settings(PcdConOutGopSupport, and PcdConOutUgaSuppor= t). It always -# consumes Graphics Output protocol which is produced by display device, a= nd consumes UGA Draw -# protocol which is produced by display device according to PcdUgaConsumeS= upport value. -# Note: If only UGA Draw protocol is installed in system, PcdUgaConsumeSup= port should be -# set to TRUE. +# It always consumes Graphics Output protocol which is produced by display= device # -# Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
+# Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
# # SPDX-License-Identifier: BSD-2-Clause-Patent # @@ -92,14 +87,6 @@ [Protocols] ## SOMETIMES_PRODUCES ## SOMETIMES_CONSUMES gEfiGraphicsOutputProtocolGuid - ## SOMETIMES_PRODUCES - ## SOMETIMES_CONSUMES - gEfiUgaDrawProtocolGuid - -[FeaturePcd] - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport ## CONSUMES - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport ## CONSUMES - gEfiMdePkgTokenSpaceGuid.PcdUgaConsumeSupport ## CONSUMES =20 [Pcd] ## SOMETIMES_PRODUCES diff --git a/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitter.h b/= MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitter.h index a1fe74726058..ec74415a2fb1 100644 --- a/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitter.h +++ b/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitter.h @@ -1,7 +1,7 @@ /** @file Private data structures for the Console Splitter driver =20 -Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ @@ -21,7 +21,6 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #include #include #include -#include =20 #include #include @@ -182,7 +181,6 @@ typedef struct { =20 typedef struct { EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *TextOut; } TEXT_OUT_AND_GOP_DATA; =20 @@ -195,16 +193,9 @@ typedef struct { EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL TextOut; EFI_SIMPLE_TEXT_OUTPUT_MODE TextOutMode; =20 - EFI_UGA_DRAW_PROTOCOL UgaDraw; - UINT32 UgaHorizontalResolution; - UINT32 UgaVerticalResolution; - UINT32 UgaColorDepth; - UINT32 UgaRefreshRate; - EFI_GRAPHICS_OUTPUT_PROTOCOL GraphicsOutput; EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *GraphicsOutputModeBuffer; UINTN CurrentNumberOfGraphicsOutput; - UINTN CurrentNumberOfUgaDraw; =20 UINTN CurrentNumberOfConsoles; TEXT_OUT_AND_GOP_DATA *TextOutList; @@ -230,13 +221,6 @@ typedef struct { TEXT_OUT_SPLITTER_PRIVATE_DATA_SIGNATURE \ ) =20 -#define UGA_DRAW_SPLITTER_PRIVATE_DATA_FROM_THIS(a) \ - CR ((a), \ - TEXT_OUT_SPLITTER_PRIVATE_DATA, \ - UgaDraw, \ - TEXT_OUT_SPLITTER_PRIVATE_DATA_SIGNATURE \ - ) - #define CONSOLE_CONTROL_SPLITTER_PRIVATE_DATA_FROM_THIS(a) \ CR ((a), \ TEXT_OUT_SPLITTER_PRIVATE_DATA, \ @@ -254,7 +238,7 @@ typedef struct { Installs driver module protocols and. Creates virtual device handles for= ConIn, ConOut, and StdErr. Installs Simple Text In protocol, Simple Text In Ex = protocol, Simple Pointer protocol, Absolute Pointer protocol on those virtual hand= lers. - Installs Graphics Output protocol and/or UGA Draw protocol if needed. + Installs Graphics Output protocol if needed. =20 @param[in] ImageHandle The firmware allocated handle for the EFI imag= e. @param[in] SystemTable A pointer to the EFI System Table. @@ -1202,7 +1186,6 @@ ConSplitterSimplePointerDeleteDevice ( @param Private Text Out Splitter pointer. @param TextOut Simple Text Output protocol pointer. @param GraphicsOutput Graphics Output protocol pointer. - @param UgaDraw UGA Draw protocol pointer. =20 @retval EFI_SUCCESS Text Output Device added successfully. @retval EFI_OUT_OF_RESOURCES Could not grow the buffer size. @@ -1212,8 +1195,7 @@ EFI_STATUS ConSplitterTextOutAddDevice ( IN TEXT_OUT_SPLITTER_PRIVATE_DATA *Private, IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *TextOut, - IN EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput, - IN EFI_UGA_DRAW_PROTOCOL *UgaDraw + IN EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput ); =20 /** @@ -1848,119 +1830,7 @@ ConSplitterGraphicsOutputBlt ( IN UINTN DestinationY, IN UINTN Width, IN UINTN Height, - IN UINTN Delta OPTIONAL - ); - -/** - Return the current video mode information. - - @param This The EFI_UGA_DRAW_PROTOCOL instance. - @param HorizontalResolution The size of video screen in pixels in the = X dimension. - @param VerticalResolution The size of video screen in pixels in the = Y dimension. - @param ColorDepth Number of bits per pixel, currently define= d to be 32. - @param RefreshRate The refresh rate of the monitor in Hertz. - - @retval EFI_SUCCESS Mode information returned. - @retval EFI_NOT_STARTED Video display is not initialized. Call Set= Mode () - @retval EFI_INVALID_PARAMETER One of the input args was NULL. - -**/ -EFI_STATUS -EFIAPI -ConSplitterUgaDrawGetMode ( - IN EFI_UGA_DRAW_PROTOCOL *This, - OUT UINT32 *HorizontalResolution, - OUT UINT32 *VerticalResolution, - OUT UINT32 *ColorDepth, - OUT UINT32 *RefreshRate - ); - -/** - Set the current video mode information. - - @param This The EFI_UGA_DRAW_PROTOCOL instance. - @param HorizontalResolution The size of video screen in pixels in the X= dimension. - @param VerticalResolution The size of video screen in pixels in the Y= dimension. - @param ColorDepth Number of bits per pixel, currently defined= to be 32. - @param RefreshRate The refresh rate of the monitor in Hertz. - - @retval EFI_SUCCESS Mode information returned. - @retval EFI_NOT_STARTED Video display is not initialized. Call SetM= ode () - @retval EFI_OUT_OF_RESOURCES Out of resources. - -**/ -EFI_STATUS -EFIAPI -ConSplitterUgaDrawSetMode ( - IN EFI_UGA_DRAW_PROTOCOL *This, - IN UINT32 HorizontalResolution, - IN UINT32 VerticalResolution, - IN UINT32 ColorDepth, - IN UINT32 RefreshRate - ); - -/** - Blt a rectangle of pixels on the graphics screen. - - The following table defines actions for BltOperations. - - EfiUgaVideoFill: - Write data from the BltBuffer pixel (SourceX, SourceY) - directly to every pixel of the video display rectangle - (DestinationX, DestinationY) - (DestinationX + Width, DestinationY + Height). - Only one pixel will be used from the BltBuffer. Delta is NOT used. - EfiUgaVideoToBltBuffer: - Read data from the video display rectangle - (SourceX, SourceY) (SourceX + Width, SourceY + Height) and place it in - the BltBuffer rectangle (DestinationX, DestinationY ) - (DestinationX + Width, DestinationY + Height). If DestinationX or - DestinationY is not zero then Delta must be set to the length in bytes - of a row in the BltBuffer. - EfiUgaBltBufferToVideo: - Write data from the BltBuffer rectangle - (SourceX, SourceY) (SourceX + Width, SourceY + Height) directly to the - video display rectangle (DestinationX, DestinationY) - (DestinationX + Width, DestinationY + Height). If SourceX or SourceY is - not zero then Delta must be set to the length in bytes of a row in the - BltBuffer. - EfiUgaVideoToVideo: - Copy from the video display rectangle - (SourceX, SourceY) (SourceX + Width, SourceY + Height) . - to the video display rectangle (DestinationX, DestinationY) - (DestinationX + Width, DestinationY + Height). - The BltBuffer and Delta are not used in this mode. - - @param This Protocol instance pointer. - @param BltBuffer Buffer containing data to blit into video buffer.= This - buffer has a size of Width*Height*sizeof(EFI_UGA_= PIXEL) - @param BltOperation Operation to perform on BlitBuffer and video memo= ry - @param SourceX X coordinate of source for the BltBuffer. - @param SourceY Y coordinate of source for the BltBuffer. - @param DestinationX X coordinate of destination for the BltBuffer. - @param DestinationY Y coordinate of destination for the BltBuffer. - @param Width Width of rectangle in BltBuffer in pixels. - @param Height Hight of rectangle in BltBuffer in pixels. - @param Delta OPTIONAL - - @retval EFI_SUCCESS The Blt operation completed. - @retval EFI_INVALID_PARAMETER BltOperation is not valid. - @retval EFI_DEVICE_ERROR A hardware error occurred writting to the= video buffer. - -**/ -EFI_STATUS -EFIAPI -ConSplitterUgaDrawBlt ( - IN EFI_UGA_DRAW_PROTOCOL *This, - IN EFI_UGA_PIXEL *BltBuffer OPTIONAL, - IN EFI_UGA_BLT_OPERATION BltOperation, - IN UINTN SourceX, - IN UINTN SourceY, - IN UINTN DestinationX, - IN UINTN DestinationY, - IN UINTN Width, - IN UINTN Height, - IN UINTN Delta OPTIONAL + IN UINTN Delta OPTIONAL ); =20 /** diff --git a/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitter.c b/= MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitter.c index 8b5e62e3a883..2eda16cf6f12 100644 --- a/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitter.c +++ b/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitter.c @@ -16,7 +16,7 @@ never removed. Such design ensures system function well during none cons= ole device situation. =20 -Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
(C) Copyright 2016 Hewlett Packard Enterprise Development LP
SPDX-License-Identifier: BSD-2-Clause-Patent =20 @@ -107,15 +107,6 @@ GLOBAL_REMOVE_IF_UNREFERENCED TEXT_IN_SPLITTER_PRIVATE= _DATA mConIn =3D { FALSE }; =20 -// -// Uga Draw Protocol Private Data template -// -GLOBAL_REMOVE_IF_UNREFERENCED EFI_UGA_DRAW_PROTOCOL mUgaDrawProtocolTempl= ate =3D { - ConSplitterUgaDrawGetMode, - ConSplitterUgaDrawSetMode, - ConSplitterUgaDrawBlt -}; - // // Graphics Output Protocol Private Data template // @@ -153,16 +144,6 @@ GLOBAL_REMOVE_IF_UNREFERENCED TEXT_OUT_SPLITTER_PRIVAT= E_DATA mConOut =3D { FALSE, }, =20 - { - NULL, - NULL, - NULL - }, - 0, - 0, - 0, - 0, - { NULL, NULL, @@ -171,7 +152,6 @@ GLOBAL_REMOVE_IF_UNREFERENCED TEXT_OUT_SPLITTER_PRIVATE= _DATA mConOut =3D { }, (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *)NULL, 0, - 0, =20 0, (TEXT_OUT_AND_GOP_DATA *)NULL, @@ -209,16 +189,6 @@ GLOBAL_REMOVE_IF_UNREFERENCED TEXT_OUT_SPLITTER_PRIVAT= E_DATA mStdErr =3D { FALSE, }, =20 - { - NULL, - NULL, - NULL - }, - 0, - 0, - 0, - 0, - { NULL, NULL, @@ -227,7 +197,6 @@ GLOBAL_REMOVE_IF_UNREFERENCED TEXT_OUT_SPLITTER_PRIVATE= _DATA mStdErr =3D { }, (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *)NULL, 0, - 0, =20 0, (TEXT_OUT_AND_GOP_DATA *)NULL, @@ -422,7 +391,7 @@ ToggleStateSyncReInitialization ( Installs driver module protocols and. Creates virtual device handles for= ConIn, ConOut, and StdErr. Installs Simple Text In protocol, Simple Text In Ex = protocol, Simple Pointer protocol, Absolute Pointer protocol on those virtual hand= lers. - Installs Graphics Output protocol and/or UGA Draw protocol if needed. + Installs Graphics Output protocol if need. =20 @param[in] ImageHandle The firmware allocated handle for the EFI imag= e. @param[in] SystemTable A pointer to the EFI System Table. @@ -493,14 +462,6 @@ ConSplitterDriverEntry ( ); ASSERT_EFI_ERROR (Status); =20 - // - // Either Graphics Output protocol or UGA Draw protocol must be supporte= d. - // - ASSERT ( - FeaturePcdGet (PcdConOutGopSupport) || - FeaturePcdGet (PcdConOutUgaSupport) - ); - // // The driver creates virtual handles for ConIn, ConOut, StdErr. // The virtual handles will always exist even if no console exist in the @@ -757,13 +718,7 @@ ConSplitterTextOutConstructor ( // // Copy protocols template // - if (FeaturePcdGet (PcdConOutUgaSupport)) { - CopyMem (&ConOutPrivate->UgaDraw, &mUgaDrawProtocolTemplate, sizeof (E= FI_UGA_DRAW_PROTOCOL)); - } - - if (FeaturePcdGet (PcdConOutGopSupport)) { - CopyMem (&ConOutPrivate->GraphicsOutput, &mGraphicsOutputProtocolTempl= ate, sizeof (EFI_GRAPHICS_OUTPUT_PROTOCOL)); - } + CopyMem (&ConOutPrivate->GraphicsOutput, &mGraphicsOutputProtocolTemplat= e, sizeof (EFI_GRAPHICS_OUTPUT_PROTOCOL)); =20 // // Initialize console output splitter's private data. @@ -806,56 +761,47 @@ ConSplitterTextOutConstructor ( ConOutPrivate->TextOutQueryData[0].Rows =3D 25; TextOutSetMode (ConOutPrivate, 0); =20 - if (FeaturePcdGet (PcdConOutUgaSupport)) { - // - // Setup the UgaDraw to 800 x 600 x 32 bits per pixel, 60Hz. - // - ConSplitterUgaDrawSetMode (&ConOutPrivate->UgaDraw, 800, 600, 32, 60); + // + // Setup resource for mode information in Graphics Output Protocol inter= face + // + if ((ConOutPrivate->GraphicsOutput.Mode =3D AllocateZeroPool (sizeof (EF= I_GRAPHICS_OUTPUT_PROTOCOL_MODE))) =3D=3D NULL) { + return EFI_OUT_OF_RESOURCES; } =20 - if (FeaturePcdGet (PcdConOutGopSupport)) { - // - // Setup resource for mode information in Graphics Output Protocol int= erface - // - if ((ConOutPrivate->GraphicsOutput.Mode =3D AllocateZeroPool (sizeof (= EFI_GRAPHICS_OUTPUT_PROTOCOL_MODE))) =3D=3D NULL) { - return EFI_OUT_OF_RESOURCES; - } - - if ((ConOutPrivate->GraphicsOutput.Mode->Info =3D AllocateZeroPool (si= zeof (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION))) =3D=3D NULL) { - return EFI_OUT_OF_RESOURCES; - } + if ((ConOutPrivate->GraphicsOutput.Mode->Info =3D AllocateZeroPool (size= of (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION))) =3D=3D NULL) { + return EFI_OUT_OF_RESOURCES; + } =20 - // - // Setup the DevNullGraphicsOutput to 800 x 600 x 32 bits per pixel - // DevNull will be updated to user-defined mode after driver has start= ed. - // - if ((ConOutPrivate->GraphicsOutputModeBuffer =3D AllocateZeroPool (siz= eof (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION))) =3D=3D NULL) { - return EFI_OUT_OF_RESOURCES; - } + // + // Setup the DevNullGraphicsOutput to 800 x 600 x 32 bits per pixel + // DevNull will be updated to user-defined mode after driver has started. + // + if ((ConOutPrivate->GraphicsOutputModeBuffer =3D AllocateZeroPool (sizeo= f (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION))) =3D=3D NULL) { + return EFI_OUT_OF_RESOURCES; + } =20 - Info =3D &ConOutPrivate->GraphicsOutputModeBuffe= r[0]; - Info->Version =3D 0; - Info->HorizontalResolution =3D 800; - Info->VerticalResolution =3D 600; - Info->PixelFormat =3D PixelBltOnly; - Info->PixelsPerScanLine =3D 800; - CopyMem (ConOutPrivate->GraphicsOutput.Mode->Info, Info, sizeof (EFI_G= RAPHICS_OUTPUT_MODE_INFORMATION)); - ConOutPrivate->GraphicsOutput.Mode->SizeOfInfo =3D sizeof (EFI_GRAPHIC= S_OUTPUT_MODE_INFORMATION); + Info =3D &ConOutPrivate->GraphicsOutputModeBuffer[= 0]; + Info->Version =3D 0; + Info->HorizontalResolution =3D 800; + Info->VerticalResolution =3D 600; + Info->PixelFormat =3D PixelBltOnly; + Info->PixelsPerScanLine =3D 800; + CopyMem (ConOutPrivate->GraphicsOutput.Mode->Info, Info, sizeof (EFI_GRA= PHICS_OUTPUT_MODE_INFORMATION)); + ConOutPrivate->GraphicsOutput.Mode->SizeOfInfo =3D sizeof (EFI_GRAPHICS_= OUTPUT_MODE_INFORMATION); =20 - // - // Initialize the following items, theset items remain unchanged in Gr= aphicsOutput->SetMode() - // GraphicsOutputMode->FrameBufferBase, GraphicsOutputMode->FrameBuffe= rSize - // - ConOutPrivate->GraphicsOutput.Mode->FrameBufferBase =3D (EFI_PHYSICAL_= ADDRESS)(UINTN)NULL; - ConOutPrivate->GraphicsOutput.Mode->FrameBufferSize =3D 0; + // + // Initialize the following items, theset items remain unchanged in Grap= hicsOutput->SetMode() + // GraphicsOutputMode->FrameBufferBase, GraphicsOutputMode->FrameBufferS= ize + // + ConOutPrivate->GraphicsOutput.Mode->FrameBufferBase =3D (EFI_PHYSICAL_AD= DRESS)(UINTN)NULL; + ConOutPrivate->GraphicsOutput.Mode->FrameBufferSize =3D 0; =20 - ConOutPrivate->GraphicsOutput.Mode->MaxMode =3D 1; - // - // Initial current mode to unknown state, and then set to mode 0 - // - ConOutPrivate->GraphicsOutput.Mode->Mode =3D 0xffff; - ConOutPrivate->GraphicsOutput.SetMode (&ConOutPrivate->GraphicsOutput,= 0); - } + ConOutPrivate->GraphicsOutput.Mode->MaxMode =3D 1; + // + // Initial current mode to unknown state, and then set to mode 0 + // + ConOutPrivate->GraphicsOutput.Mode->Mode =3D 0xffff; + ConOutPrivate->GraphicsOutput.SetMode (&ConOutPrivate->GraphicsOutput, 0= ); =20 return EFI_SUCCESS; } @@ -1332,12 +1278,9 @@ ConSplitterConOutDriverBindingStart ( IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath ) { - EFI_STATUS Status; - EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *TextOut; - EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; - UINTN SizeOfInfo; - EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *Info; + EFI_STATUS Status; + EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *TextOut; + EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; =20 // // Start ConSplitter on ControllerHandle, and create the virtual @@ -1356,7 +1299,6 @@ ConSplitterConOutDriverBindingStart ( } =20 GraphicsOutput =3D NULL; - UgaDraw =3D NULL; // // Try to Open Graphics Output protocol // @@ -1369,20 +1311,6 @@ ConSplitterConOutDriverBindingStart ( EFI_OPEN_PROTOCOL_GET_PROTOCOL ); =20 - if (EFI_ERROR (Status) && FeaturePcdGet (PcdUgaConsumeSupport)) { - // - // Open UGA DRAW protocol - // - gBS->OpenProtocol ( - ControllerHandle, - &gEfiUgaDrawProtocolGuid, - (VOID **)&UgaDraw, - This->DriverBindingHandle, - mConOut.VirtualHandle, - EFI_OPEN_PROTOCOL_GET_PROTOCOL - ); - } - // // When new console device is added, the new mode will be set later, // so put current mode back to init state. @@ -1393,38 +1321,9 @@ ConSplitterConOutDriverBindingStart ( // If both ConOut and StdErr incorporate the same Text Out device, // their MaxMode and QueryData should be the intersection of both. // - Status =3D ConSplitterTextOutAddDevice (&mConOut, TextOut, GraphicsOutpu= t, UgaDraw); + Status =3D ConSplitterTextOutAddDevice (&mConOut, TextOut, GraphicsOutpu= t); ConSplitterTextOutSetAttribute (&mConOut.TextOut, EFI_TEXT_ATTR (EFI_LIG= HTGRAY, EFI_BLACK)); =20 - if (FeaturePcdGet (PcdConOutUgaSupport)) { - // - // Get the UGA mode data of ConOut from the current mode - // - if (GraphicsOutput !=3D NULL) { - Status =3D GraphicsOutput->QueryMode (GraphicsOutput, GraphicsOutput= ->Mode->Mode, &SizeOfInfo, &Info); - if (EFI_ERROR (Status)) { - return Status; - } - - ASSERT (SizeOfInfo <=3D sizeof (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION= )); - - mConOut.UgaHorizontalResolution =3D Info->HorizontalResolution; - mConOut.UgaVerticalResolution =3D Info->VerticalResolution; - mConOut.UgaColorDepth =3D 32; - mConOut.UgaRefreshRate =3D 60; - - FreePool (Info); - } else if (UgaDraw !=3D NULL) { - Status =3D UgaDraw->GetMode ( - UgaDraw, - &mConOut.UgaHorizontalResolution, - &mConOut.UgaVerticalResolution, - &mConOut.UgaColorDepth, - &mConOut.UgaRefreshRate - ); - } - } - return Status; } =20 @@ -1477,7 +1376,7 @@ ConSplitterStdErrDriverBindingStart ( // If both ConOut and StdErr incorporate the same Text Out device, // their MaxMode and QueryData should be the intersection of both. // - Status =3D ConSplitterTextOutAddDevice (&mStdErr, TextOut, NULL, NULL); + Status =3D ConSplitterTextOutAddDevice (&mStdErr, TextOut, NULL); ConSplitterTextOutSetAttribute (&mStdErr.TextOut, EFI_TEXT_ATTR (EFI_LIG= HTGRAY, EFI_BLACK)); =20 return Status; @@ -2737,7 +2636,6 @@ ConSplitterGetIntersectionBetweenConOutAndStrErr ( =20 @param Private Text Out Splitter pointer. @param GraphicsOutput Graphics Output protocol pointer. - @param UgaDraw UGA Draw protocol pointer. =20 @retval EFI_SUCCESS Output mode added successfully. @retval other Failed to add output mode. @@ -2746,8 +2644,7 @@ ConSplitterGetIntersectionBetweenConOutAndStrErr ( EFI_STATUS ConSplitterAddGraphicsOutputMode ( IN TEXT_OUT_SPLITTER_PRIVATE_DATA *Private, - IN EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput, - IN EFI_UGA_DRAW_PROTOCOL *UgaDraw + IN EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput ) { EFI_STATUS Status; @@ -2762,12 +2659,8 @@ ConSplitterAddGraphicsOutputMode ( UINTN NumberIndex; BOOLEAN Match; BOOLEAN AlreadyExist; - UINT32 UgaHorizontalResolution; - UINT32 UgaVerticalResolution; - UINT32 UgaColorDepth; - UINT32 UgaRefreshRate; =20 - ASSERT (GraphicsOutput !=3D NULL || UgaDraw !=3D NULL); + ASSERT (GraphicsOutput !=3D NULL); =20 CurrentGraphicsOutputMode =3D Private->GraphicsOutput.Mode; =20 @@ -2775,15 +2668,6 @@ ConSplitterAddGraphicsOutputMode ( CurrentIndex =3D 0; Status =3D EFI_SUCCESS; =20 - if (Private->CurrentNumberOfUgaDraw !=3D 0) { - // - // If any UGA device has already been added, then there is no need to - // calculate intersection of display mode of different GOP/UGA device, - // since only one display mode will be exported (i.e. user-defined mod= e) - // - goto Done; - } - if (GraphicsOutput !=3D NULL) { if (Private->CurrentNumberOfGraphicsOutput =3D=3D 0) { // @@ -2937,51 +2821,12 @@ ConSplitterAddGraphicsOutputMode ( } } } - } else if (UgaDraw !=3D NULL) { - // - // Graphics console driver can ensure the same mode for all GOP devices - // so we can get the current mode from this video device - // - UgaDraw->GetMode ( - UgaDraw, - &UgaHorizontalResolution, - &UgaVerticalResolution, - &UgaColorDepth, - &UgaRefreshRate - ); - - CurrentGraphicsOutputMode->MaxMode =3D 1; - Info =3D CurrentGraphicsOutputMo= de->Info; - Info->Version =3D 0; - Info->HorizontalResolution =3D UgaHorizontalResolution; - Info->VerticalResolution =3D UgaVerticalResolution; - Info->PixelFormat =3D PixelBltOnly; - Info->PixelsPerScanLine =3D UgaHorizontalResolution; - CurrentGraphicsOutputMode->SizeOfInfo =3D sizeof (EFI_GRAPHICS_OU= TPUT_MODE_INFORMATION); - CurrentGraphicsOutputMode->FrameBufferBase =3D (EFI_PHYSICAL_ADDRESS)(= UINTN)NULL; - CurrentGraphicsOutputMode->FrameBufferSize =3D 0; - - // - // Update the private mode buffer - // - CopyMem (&Private->GraphicsOutputModeBuffer[0], Info, sizeof (EFI_GRAP= HICS_OUTPUT_MODE_INFORMATION)); - - // - // Only mode 0 is available to be set - // - CurrentIndex =3D 0; } =20 -Done: - if (GraphicsOutput !=3D NULL) { Private->CurrentNumberOfGraphicsOutput++; } =20 - if (UgaDraw !=3D NULL) { - Private->CurrentNumberOfUgaDraw++; - } - // // Force GraphicsOutput mode to be set, // @@ -3130,7 +2975,6 @@ ConsplitterSetConsoleOutMode ( @param Private Text Out Splitter pointer. @param TextOut Simple Text Output protocol pointer. @param GraphicsOutput Graphics Output protocol pointer. - @param UgaDraw UGA Draw protocol pointer. =20 @retval EFI_SUCCESS Text Output Device added successfully. @retval EFI_OUT_OF_RESOURCES Could not grow the buffer size. @@ -3140,21 +2984,14 @@ EFI_STATUS ConSplitterTextOutAddDevice ( IN TEXT_OUT_SPLITTER_PRIVATE_DATA *Private, IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *TextOut, - IN EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput, - IN EFI_UGA_DRAW_PROTOCOL *UgaDraw + IN EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput ) { - EFI_STATUS Status; - UINTN CurrentNumOfConsoles; - INT32 MaxMode; - UINT32 UgaHorizontalResolution; - UINT32 UgaVerticalResolution; - UINT32 UgaColorDepth; - UINT32 UgaRefreshRate; - TEXT_OUT_AND_GOP_DATA *TextAndGop; - UINTN SizeOfInfo; - EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *Info; - EFI_STATUS DeviceStatus; + EFI_STATUS Status; + UINTN CurrentNumOfConsoles; + INT32 MaxMode; + TEXT_OUT_AND_GOP_DATA *TextAndGop; + EFI_STATUS DeviceStatus; =20 Status =3D EFI_SUCCESS; CurrentNumOfConsoles =3D Private->CurrentNumberOfConsoles; @@ -3186,7 +3023,6 @@ ConSplitterTextOutAddDevice ( =20 TextAndGop->TextOut =3D TextOut; TextAndGop->GraphicsOutput =3D GraphicsOutput; - TextAndGop->UgaDraw =3D UgaDraw; =20 if (CurrentNumOfConsoles =3D=3D 0) { // @@ -3215,101 +3051,21 @@ ConSplitterTextOutAddDevice ( // // This device display mode will be added into Graphics Ouput modes. // - if ((GraphicsOutput !=3D NULL) || (UgaDraw !=3D NULL)) { - DeviceStatus =3D ConSplitterAddGraphicsOutputMode (Private, GraphicsOu= tput, UgaDraw); + if (GraphicsOutput !=3D NULL) { + DeviceStatus =3D ConSplitterAddGraphicsOutputMode (Private, GraphicsOu= tput); } =20 - if (FeaturePcdGet (PcdConOutUgaSupport)) { + if (!EFI_ERROR (DeviceStatus)) { // - // If UGA is produced by Consplitter + // Graphics Output Protocol is installed + // on virtual handle. // - if (GraphicsOutput !=3D NULL) { - Status =3D GraphicsOutput->QueryMode (GraphicsOutput, GraphicsOutput= ->Mode->Mode, &SizeOfInfo, &Info); - if (EFI_ERROR (Status)) { - return Status; - } - - ASSERT (SizeOfInfo <=3D sizeof (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION= )); - - UgaHorizontalResolution =3D Info->HorizontalResolution; - UgaVerticalResolution =3D Info->VerticalResolution; - - FreePool (Info); - } else if (UgaDraw !=3D NULL) { - Status =3D UgaDraw->GetMode ( - UgaDraw, - &UgaHorizontalResolution, - &UgaVerticalResolution, - &UgaColorDepth, - &UgaRefreshRate - ); - if (!EFI_ERROR (Status) && EFI_ERROR (DeviceStatus)) { - // - // if GetMode is successfully and UGA device hasn't been set, set = it - // - Status =3D ConSplitterUgaDrawSetMode ( - &Private->UgaDraw, - UgaHorizontalResolution, - UgaVerticalResolution, - UgaColorDepth, - UgaRefreshRate - ); - } - - // - // If GetMode/SetMode is failed, set to 800x600 mode - // - if (EFI_ERROR (Status)) { - Status =3D ConSplitterUgaDrawSetMode ( - &Private->UgaDraw, - 800, - 600, - 32, - 60 - ); - } - } - } - - if (((!EFI_ERROR (DeviceStatus)) || (!EFI_ERROR (Status))) && - ((Private->CurrentNumberOfGraphicsOutput + Private->CurrentNumberOfU= gaDraw) =3D=3D 1)) - { - if (!FeaturePcdGet (PcdConOutGopSupport)) { - // - // If Graphics Outpurt protocol not supported, UGA Draw protocol is = installed - // on the virtual handle. - // - Status =3D gBS->InstallMultipleProtocolInterfaces ( - &mConOut.VirtualHandle, - &gEfiUgaDrawProtocolGuid, - &mConOut.UgaDraw, - NULL - ); - } else if (!FeaturePcdGet (PcdConOutUgaSupport)) { - // - // If UGA Draw protocol not supported, Graphics Output Protocol is i= nstalled - // on virtual handle. - // - Status =3D gBS->InstallMultipleProtocolInterfaces ( - &mConOut.VirtualHandle, - &gEfiGraphicsOutputProtocolGuid, - &mConOut.GraphicsOutput, - NULL - ); - } else { - // - // Boot Graphics Output protocol and UGA Draw protocol are supported, - // both they will be installed on virtual handle. - // - Status =3D gBS->InstallMultipleProtocolInterfaces ( - &mConOut.VirtualHandle, - &gEfiGraphicsOutputProtocolGuid, - &mConOut.GraphicsOutput, - &gEfiUgaDrawProtocolGuid, - &mConOut.UgaDraw, - NULL - ); - } + Status =3D gBS->InstallMultipleProtocolInterfaces ( + &mConOut.VirtualHandle, + &gEfiGraphicsOutputProtocolGuid, + &mConOut.GraphicsOutput, + NULL + ); } =20 // @@ -3353,10 +3109,6 @@ ConSplitterTextOutDeleteDevice ( TextOutList =3D Private->TextOutList; while (Index >=3D 0) { if (TextOutList->TextOut =3D=3D TextOut) { - if (TextOutList->UgaDraw !=3D NULL) { - Private->CurrentNumberOfUgaDraw--; - } - if (TextOutList->GraphicsOutput !=3D NULL) { Private->CurrentNumberOfGraphicsOutput--; } @@ -3377,33 +3129,16 @@ ConSplitterTextOutDeleteDevice ( return EFI_NOT_FOUND; } =20 - if ((Private->CurrentNumberOfGraphicsOutput =3D=3D 0) && (Private->Curre= ntNumberOfUgaDraw =3D=3D 0)) { + if (Private->CurrentNumberOfGraphicsOutput =3D=3D 0) { // - // If there is not any physical GOP and UGA device in system, - // Consplitter GOP or UGA protocol will be uninstalled + // If there is not any physical GOP in system, + // Consplitter GOP protocol will be uninstalled // - if (!FeaturePcdGet (PcdConOutGopSupport)) { - Status =3D gBS->UninstallProtocolInterface ( - Private->VirtualHandle, - &gEfiUgaDrawProtocolGuid, - &Private->UgaDraw - ); - } else if (!FeaturePcdGet (PcdConOutUgaSupport)) { - Status =3D gBS->UninstallProtocolInterface ( - Private->VirtualHandle, - &gEfiGraphicsOutputProtocolGuid, - &Private->GraphicsOutput - ); - } else { - Status =3D gBS->UninstallMultipleProtocolInterfaces ( - Private->VirtualHandle, - &gEfiUgaDrawProtocolGuid, - &Private->UgaDraw, - &gEfiGraphicsOutputProtocolGuid, - &Private->GraphicsOutput, - NULL - ); - } + Status =3D gBS->UninstallProtocolInterface ( + Private->VirtualHandle, + &gEfiGraphicsOutputProtocolGuid, + &Private->GraphicsOutput + ); } =20 if (CurrentNumOfConsoles =3D=3D 0) { diff --git a/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterGraph= ics.c b/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterGraphics.c index 64ad567a6d7d..a37a6b0e4bd8 100644 --- a/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterGraphics.c +++ b/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterGraphics.c @@ -1,7 +1,7 @@ /** @file Support for Graphics output spliter. =20 -Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 =20 @@ -117,7 +117,6 @@ ConSplitterGraphicsOutputSetMode ( UINTN NumberIndex; UINTN SizeOfInfo; EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *Info; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; =20 if (ModeNumber >=3D This->Mode->MaxMode) { return EFI_UNSUPPORTED; @@ -157,20 +156,6 @@ ConSplitterGraphicsOutputSetMode ( if (EFI_ERROR (Status)) { ReturnStatus =3D Status; } - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - UgaDraw =3D Private->TextOutList[Index].UgaDraw; - if (UgaDraw !=3D NULL) { - Status =3D UgaDraw->SetMode ( - UgaDraw, - Mode->HorizontalResolution, - Mode->VerticalResolution, - 32, - 60 - ); - if (EFI_ERROR (Status)) { - ReturnStatus =3D Status; - } - } } } =20 @@ -261,7 +246,6 @@ ConSplitterGraphicsOutputBlt ( TEXT_OUT_SPLITTER_PRIVATE_DATA *Private; UINTN Index; EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; =20 if ((This =3D=3D NULL) || (((UINTN)BltOperation) >=3D EfiGraphicsOutputB= ltOperationMax)) { return EFI_INVALID_PARAMETER; @@ -298,298 +282,6 @@ ConSplitterGraphicsOutputBlt ( return EFI_SUCCESS; } } - - UgaDraw =3D Private->TextOutList[Index].UgaDraw; - if ((UgaDraw !=3D NULL) && FeaturePcdGet (PcdUgaConsumeSupport)) { - Status =3D UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)BltBuffer, - (EFI_UGA_BLT_OPERATION)BltOperation, - SourceX, - SourceY, - DestinationX, - DestinationY, - Width, - Height, - Delta - ); - if (EFI_ERROR (Status)) { - ReturnStatus =3D Status; - } else if (BltOperation =3D=3D EfiBltVideoToBltBuffer) { - // - // Only need to read the data into buffer one time - // - return EFI_SUCCESS; - } - } - } - - return ReturnStatus; -} - -/** - Return the current video mode information. - - @param This The EFI_UGA_DRAW_PROTOCOL instance. - @param HorizontalResolution The size of video screen in pixels in the = X dimension. - @param VerticalResolution The size of video screen in pixels in the = Y dimension. - @param ColorDepth Number of bits per pixel, currently define= d to be 32. - @param RefreshRate The refresh rate of the monitor in Hertz. - - @retval EFI_SUCCESS Mode information returned. - @retval EFI_NOT_STARTED Video display is not initialized. Call Set= Mode () - @retval EFI_INVALID_PARAMETER One of the input args was NULL. - -**/ -EFI_STATUS -EFIAPI -ConSplitterUgaDrawGetMode ( - IN EFI_UGA_DRAW_PROTOCOL *This, - OUT UINT32 *HorizontalResolution, - OUT UINT32 *VerticalResolution, - OUT UINT32 *ColorDepth, - OUT UINT32 *RefreshRate - ) -{ - TEXT_OUT_SPLITTER_PRIVATE_DATA *Private; - - if ((HorizontalResolution =3D=3D NULL) || - (VerticalResolution =3D=3D NULL) || - (RefreshRate =3D=3D NULL) || - (ColorDepth =3D=3D NULL)) - { - return EFI_INVALID_PARAMETER; - } - - // - // retrieve private data - // - Private =3D UGA_DRAW_SPLITTER_PRIVATE_DATA_FROM_THIS (This); - - *HorizontalResolution =3D Private->UgaHorizontalResolution; - *VerticalResolution =3D Private->UgaVerticalResolution; - *ColorDepth =3D Private->UgaColorDepth; - *RefreshRate =3D Private->UgaRefreshRate; - - return EFI_SUCCESS; -} - -/** - Set the current video mode information. - - @param This The EFI_UGA_DRAW_PROTOCOL instance. - @param HorizontalResolution The size of video screen in pixels in the X= dimension. - @param VerticalResolution The size of video screen in pixels in the Y= dimension. - @param ColorDepth Number of bits per pixel, currently defined= to be 32. - @param RefreshRate The refresh rate of the monitor in Hertz. - - @retval EFI_SUCCESS Mode information returned. - @retval EFI_NOT_STARTED Video display is not initialized. Call SetM= ode () - @retval EFI_OUT_OF_RESOURCES Out of resources. - -**/ -EFI_STATUS -EFIAPI -ConSplitterUgaDrawSetMode ( - IN EFI_UGA_DRAW_PROTOCOL *This, - IN UINT32 HorizontalResolution, - IN UINT32 VerticalResolution, - IN UINT32 ColorDepth, - IN UINT32 RefreshRate - ) -{ - EFI_STATUS Status; - TEXT_OUT_SPLITTER_PRIVATE_DATA *Private; - UINTN Index; - EFI_STATUS ReturnStatus; - EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - UINTN NumberIndex; - UINTN SizeOfInfo; - EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *Info; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; - - Private =3D UGA_DRAW_SPLITTER_PRIVATE_DATA_FROM_THIS (This); - - ReturnStatus =3D EFI_SUCCESS; - - // - // Update the Mode data - // - Private->UgaHorizontalResolution =3D HorizontalResolution; - Private->UgaVerticalResolution =3D VerticalResolution; - Private->UgaColorDepth =3D ColorDepth; - Private->UgaRefreshRate =3D RefreshRate; - - // - // return the worst status met - // - for (Index =3D 0; Index < Private->CurrentNumberOfConsoles; Index++) { - GraphicsOutput =3D Private->TextOutList[Index].GraphicsOutput; - if (GraphicsOutput !=3D NULL) { - // - // Find corresponding ModeNumber of this GraphicsOutput instance - // - for (NumberIndex =3D 0; NumberIndex < GraphicsOutput->Mode->MaxMode;= NumberIndex++) { - Status =3D GraphicsOutput->QueryMode (GraphicsOutput, (UINT32)Numb= erIndex, &SizeOfInfo, &Info); - if (EFI_ERROR (Status)) { - return Status; - } - - if ((Info->HorizontalResolution =3D=3D HorizontalResolution) && (I= nfo->VerticalResolution =3D=3D VerticalResolution)) { - FreePool (Info); - break; - } - - FreePool (Info); - } - - Status =3D GraphicsOutput->SetMode (GraphicsOutput, (UINT32)NumberIn= dex); - if (EFI_ERROR (Status)) { - ReturnStatus =3D Status; - } - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - UgaDraw =3D Private->TextOutList[Index].UgaDraw; - if (UgaDraw !=3D NULL) { - Status =3D UgaDraw->SetMode ( - UgaDraw, - HorizontalResolution, - VerticalResolution, - ColorDepth, - RefreshRate - ); - if (EFI_ERROR (Status)) { - ReturnStatus =3D Status; - } - } - } - } - - return ReturnStatus; -} - -/** - Blt a rectangle of pixels on the graphics screen. - - The following table defines actions for BltOperations. - - EfiUgaVideoFill: - Write data from the BltBuffer pixel (SourceX, SourceY) - directly to every pixel of the video display rectangle - (DestinationX, DestinationY) - (DestinationX + Width, DestinationY + Height). - Only one pixel will be used from the BltBuffer. Delta is NOT used. - EfiUgaVideoToBltBuffer: - Read data from the video display rectangle - (SourceX, SourceY) (SourceX + Width, SourceY + Height) and place it in - the BltBuffer rectangle (DestinationX, DestinationY ) - (DestinationX + Width, DestinationY + Height). If DestinationX or - DestinationY is not zero then Delta must be set to the length in bytes - of a row in the BltBuffer. - EfiUgaBltBufferToVideo: - Write data from the BltBuffer rectangle - (SourceX, SourceY) (SourceX + Width, SourceY + Height) directly to the - video display rectangle (DestinationX, DestinationY) - (DestinationX + Width, DestinationY + Height). If SourceX or SourceY is - not zero then Delta must be set to the length in bytes of a row in the - BltBuffer. - EfiUgaVideoToVideo: - Copy from the video display rectangle - (SourceX, SourceY) (SourceX + Width, SourceY + Height) . - to the video display rectangle (DestinationX, DestinationY) - (DestinationX + Width, DestinationY + Height). - The BltBuffer and Delta are not used in this mode. - - @param This Protocol instance pointer. - @param BltBuffer Buffer containing data to blit into video buffer.= This - buffer has a size of Width*Height*sizeof(EFI_UGA_= PIXEL) - @param BltOperation Operation to perform on BlitBuffer and video memo= ry - @param SourceX X coordinate of source for the BltBuffer. - @param SourceY Y coordinate of source for the BltBuffer. - @param DestinationX X coordinate of destination for the BltBuffer. - @param DestinationY Y coordinate of destination for the BltBuffer. - @param Width Width of rectangle in BltBuffer in pixels. - @param Height Hight of rectangle in BltBuffer in pixels. - @param Delta OPTIONAL - - @retval EFI_SUCCESS The Blt operation completed. - @retval EFI_INVALID_PARAMETER BltOperation is not valid. - @retval EFI_DEVICE_ERROR A hardware error occurred writting to the= video buffer. - -**/ -EFI_STATUS -EFIAPI -ConSplitterUgaDrawBlt ( - IN EFI_UGA_DRAW_PROTOCOL *This, - IN EFI_UGA_PIXEL *BltBuffer OPTIONAL, - IN EFI_UGA_BLT_OPERATION BltOperation, - IN UINTN SourceX, - IN UINTN SourceY, - IN UINTN DestinationX, - IN UINTN DestinationY, - IN UINTN Width, - IN UINTN Height, - IN UINTN Delta OPTIONAL - ) -{ - EFI_STATUS Status; - TEXT_OUT_SPLITTER_PRIVATE_DATA *Private; - UINTN Index; - EFI_STATUS ReturnStatus; - EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - - Private =3D UGA_DRAW_SPLITTER_PRIVATE_DATA_FROM_THIS (This); - - ReturnStatus =3D EFI_SUCCESS; - // - // return the worst status met - // - for (Index =3D 0; Index < Private->CurrentNumberOfConsoles; Index++) { - GraphicsOutput =3D Private->TextOutList[Index].GraphicsOutput; - if (GraphicsOutput !=3D NULL) { - Status =3D GraphicsOutput->Blt ( - GraphicsOutput, - (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)BltBuffe= r, - (EFI_GRAPHICS_OUTPUT_BLT_OPERATION)BltOpe= ration, - SourceX, - SourceY, - DestinationX, - DestinationY, - Width, - Height, - Delta - ); - if (EFI_ERROR (Status)) { - ReturnStatus =3D Status; - } else if (BltOperation =3D=3D EfiUgaVideoToBltBuffer) { - // - // Only need to read the data into buffer one time - // - return EFI_SUCCESS; - } - } - - if ((Private->TextOutList[Index].UgaDraw !=3D NULL) && FeaturePcdGet (= PcdUgaConsumeSupport)) { - Status =3D Private->TextOutList[Index].UgaDraw->Blt ( - Private->TextOutList= [Index].UgaDraw, - BltBuffer, - BltOperation, - SourceX, - SourceY, - DestinationX, - DestinationY, - Width, - Height, - Delta - ); - if (EFI_ERROR (Status)) { - ReturnStatus =3D Status; - } else if (BltOperation =3D=3D EfiUgaVideoToBltBuffer) { - // - // Only need to read the data into buffer one time - // - return EFI_SUCCESS; - } - } } =20 return ReturnStatus; diff --git a/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.u= ni b/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.uni index 13c25b2a4ffc..f1324e93a5f2 100644 --- a/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.uni +++ b/MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.uni @@ -3,14 +3,9 @@ // // This driver acts as a virtual console, takes over the console I/O contr= ol from selected // standard console devices, and transmits console I/O to related console = device drivers. -// Consplitter could install Graphics Output protocol and/or UGA Draw prot= ocol in system -// table according PCD settings(PcdConOutGopSupport, and PcdConOutUgaSuppo= rt). It always -// consumes Graphics Output protocol which is produced by display device, = and consumes UGA Draw -// protocol which is produced by display device according to PcdUgaConsume= Support value. -// Note: If only UGA Draw protocol is installed in system, PcdUgaConsumeSu= pport should be -// set to TRUE. +// It always consumes Graphics Output protocol which is produced by displa= y device // -// Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.
+// Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
// // SPDX-License-Identifier: BSD-2-Clause-Patent // @@ -19,5 +14,4 @@ =20 #string STR_MODULE_ABSTRACT #language en-US "Provides multi co= nsole support" =20 -#string STR_MODULE_DESCRIPTION #language en-US "This driver acts = as a virtual console, takes over the console I/O control from selected stan= dard console devices, and transmits console I/O to related console device d= rivers. Consplitter could install Graphics Output protocol and/or UGA Draw = protocol in system table according PCD settings(PcdConOutGopSupport, and Pc= dConOutUgaSupport). It always consumes Graphics Output protocol, which is p= roduced by display device, and consumes UGA Draw protocol, which is produce= d by display device according to PcdUgaConsumeSupport value. Note: If only = UGA Draw protocol is installed in system, PcdUgaConsumeSupport should be se= t to TRUE." - +#string STR_MODULE_DESCRIPTION #language en-US "This driver acts = as a virtual console, takes over the console I/O control from selected stan= dard console devices, and transmits console I/O to related console device d= rivers. It always consumes Graphics Output protocol, which is produced by d= isplay device." --=20 2.30.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85684): https://edk2.groups.io/g/devel/message/85684 Mute This Topic: https://groups.io/mt/88411252/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Fri Apr 26 14:18:48 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85685+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85685+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642121487; cv=none; d=zohomail.com; s=zohoarc; b=IqAC3DpIn2HIk0WjJRY5RSIcpkj1RM79gDc+9KW20/zJ84JRR7YODAcOYG4QD7t53fGintKjObyAWlksrcK4bAJAo54kS8S6cp7rvXf+m46MX+FPmtif4LUlWHkYqxU5lkH5L3foqSULDflFq7Hw5pzU4Tm09rrqHZYT4pQH9CA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642121487; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=WlzVOAhpokXZL6TtJ0sLbGBpAtOdX2A28HnXDu28vOI=; b=l3WGTscka6fK4cpD8Iv/AeiI88UCyMKcI2vNmsOCJdOAjq+CpNMvlnYVVKR7YC1dSn+oMEO8tJUfBwWxnmcZYusih2Yekwjc89sT/HKi9VkLo4TWva+NBppp5NOLyum4UhztK0RSfxSC4IaGdd2Bur4ePs3jkfSZHfRcegf7h74= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85685+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1642121487299121.53251891173863; Thu, 13 Jan 2022 16:51:27 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id GfuzYY1788612xFSA8WmJuwS; Thu, 13 Jan 2022 16:51:27 -0800 X-Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.1082.1642121466955476862 for ; Thu, 13 Jan 2022 16:51:26 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10226"; a="241713886" X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="241713886" X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:25 -0800 X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="475564770" X-Received: from guominji-mobl.ccr.corp.intel.com ([10.238.9.87]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:21 -0800 From: "Guomin Jiang" To: devel@edk2.groups.io Cc: GuoMinJ , Jian J Wang , Liming Gao , Zhichao Gao , Ray Ni , Dandan Bi , Eric Dong Subject: [edk2-devel] [PATCH 08/11] MdeModulePkg/GraphicsConsoleDxe: Remove All UGA Support Date: Fri, 14 Jan 2022 08:50:41 +0800 Message-Id: <20220114005044.1975-9-guomin.jiang@intel.com> In-Reply-To: <20220114005044.1975-1-guomin.jiang@intel.com> References: <20220114005044.1975-1-guomin.jiang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,guomin.jiang@intel.com X-Gm-Message-State: c21hXr2rGffNMYfk1tp7VPXJx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642121487; bh=cortruKuwtXWkd6BKg31Ksv1leeCNCGS0to3WxrtURQ=; h=Cc:Date:From:Reply-To:Subject:To; b=Xw0sOdTPRCKIGGF/5yrt6tciTrx6aBcXt3rXnAcZtDHMPaOkIP0Eg3o9LjDQQaWHtZo onQID6Cqe8cOvPguZnaCzSXt82VMwUG/f3tWAOVlXBTyW5p0ZBaG0YEO9t+UvCa1EFIyr ygqwnhs8+7DaHjP/6nV48jXxQn9GZoa+DHk= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642121488849100003 Content-Type: text/plain; charset="utf-8" From: GuoMinJ REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2368 Remove All UGA Support in GraphicsConsoleDxe, remove comment about UGA in HiiDatabaseDxe. Signed-off-by: Guomin Jiang Cc: Jian J Wang Cc: Liming Gao Cc: Zhichao Gao Cc: Ray Ni Cc: Dandan Bi Cc: Eric Dong --- .../GraphicsConsoleDxe/GraphicsConsoleDxe.inf | 8 +- .../GraphicsConsoleDxe/GraphicsConsole.h | 21 +- .../GraphicsConsoleDxe/GraphicsConsole.c | 302 +----------------- MdeModulePkg/Universal/HiiDatabaseDxe/Image.c | 4 +- .../GraphicsConsoleDxe/GraphicsConsoleDxe.uni | 6 +- 5 files changed, 24 insertions(+), 317 deletions(-) diff --git a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsCons= oleDxe.inf b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsCons= oleDxe.inf index bcfd306eee13..67c6e878efbb 100644 --- a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.= inf +++ b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.= inf @@ -2,9 +2,9 @@ # Console support on graphic devices. # # This driver will install Simple Text Output protocol by consuming Graph= ices Output -# protocol or UGA Draw protocol on graphic devices. +# protocol on graphic devices. # -# Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
+# Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
# SPDX-License-Identifier: BSD-2-Clause-Patent # # @@ -53,15 +53,11 @@ [Protocols] gEfiDevicePathProtocolGuid ## TO_START gEfiSimpleTextOutProtocolGuid ## BY_START gEfiGraphicsOutputProtocolGuid ## TO_START - gEfiUgaDrawProtocolGuid ## TO_START gEfiHiiFontProtocolGuid ## TO_START ## TO_START ## NOTIFY gEfiHiiDatabaseProtocolGuid =20 -[FeaturePcd] - gEfiMdePkgTokenSpaceGuid.PcdUgaConsumeSupport ## CONSUMES - [Pcd] gEfiMdeModulePkgTokenSpaceGuid.PcdVideoHorizontalResolution ## SOMETIMES= _CONSUMES gEfiMdeModulePkgTokenSpaceGuid.PcdVideoVerticalResolution ## SOMETIMES= _CONSUMES diff --git a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsCons= ole.h b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.h index e4abad40f49a..ab700f31aa97 100644 --- a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.h +++ b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.h @@ -1,7 +1,7 @@ /** @file Header file for GraphicsConsole driver. =20 -Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ @@ -12,7 +12,6 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #include #include #include -#include #include #include #include @@ -59,7 +58,6 @@ typedef struct { typedef struct { UINTN Signature; EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL SimpleTextOutput; EFI_SIMPLE_TEXT_OUTPUT_MODE SimpleTextOutputMode; GRAPHICS_CONSOLE_MODE_DATA *ModeData; @@ -417,9 +415,8 @@ GraphicsConsoleConOutEnableCursor ( /** Test to see if Graphics Console could be supported on the Controller. =20 - Graphics Console could be supported if Graphics Output Protocol or UGADr= aw - Protocol exists on the Controller. (UGA Draw Protocol could be skipped - if PcdUgaConsumeSupport is set to FALSE.) + Graphics Console could be supported if Graphics Output Protocol + exists on the Controller. =20 @param This Protocol instance pointer. @param Controller Handle of device to test. @@ -439,9 +436,8 @@ GraphicsConsoleControllerDriverSupported ( ); =20 /** - Start this driver on Controller by opening Graphics Output protocol or - UGA Draw protocol, and installing Simple Text Out protocol on Controller. - (UGA Draw protocol could be skipped if PcdUgaConsumeSupport is set to FA= LSE.) + Start this driver on Controller by opening Graphics Output protocol + and installing Simple Text Out protocol on Controller. =20 @param This Protocol instance pointer. @param Controller Handle of device to bind driver to @@ -462,9 +458,7 @@ GraphicsConsoleControllerDriverStart ( =20 /** Stop this driver on Controller by removing Simple Text Out protocol - and closing the Graphics Output Protocol or UGA Draw protocol on Control= ler. - (UGA Draw protocol could be skipped if PcdUgaConsumeSupport is set to FA= LSE.) - + and closing the Graphics Output Protocol on Controller. =20 @param This Protocol instance pointer. @param Controller Handle of device to stop driver on @@ -526,8 +520,7 @@ GetTextColors ( @param Count The count of Unicode string. =20 @retval EFI_OUT_OF_RESOURCES If no memory resource to use. - @retval EFI_UNSUPPORTED If no Graphics Output protocol and UGA Draw - protocol exist. + @retval EFI_UNSUPPORTED If no Graphics Output protocol exist. @retval EFI_SUCCESS Drawing Unicode string implemented success= fully. =20 **/ diff --git a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsCons= ole.c b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c index 8f0cba9fcde9..65196e16d8f4 100644 --- a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c +++ b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c @@ -1,7 +1,7 @@ /** @file This is the main routine for initializing the Graphics Console support r= outines. =20 -Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ @@ -14,7 +14,6 @@ SPDX-License-Identifier: BSD-2-Clause-Patent GRAPHICS_CONSOLE_DEV mGraphicsConsoleDevTemplate =3D { GRAPHICS_CONSOLE_DEV_SIGNATURE, (EFI_GRAPHICS_OUTPUT_PROTOCOL *)NULL, - (EFI_UGA_DRAW_PROTOCOL *)NULL, { GraphicsConsoleConOutReset, GraphicsConsoleConOutOutputString, @@ -101,9 +100,8 @@ EFI_DRIVER_BINDING_PROTOCOL gGraphicsConsoleDriverBind= ing =3D { /** Test to see if Graphics Console could be supported on the Controller. =20 - Graphics Console could be supported if Graphics Output Protocol or UGA D= raw - Protocol exists on the Controller. (UGA Draw Protocol could be skipped - if PcdUgaConsumeSupport is set to FALSE.) + Graphics Console could be supported if Graphics Output Protocol + exists on the Controller. =20 @param This Protocol instance pointer. @param Controller Handle of device to test. @@ -124,11 +122,9 @@ GraphicsConsoleControllerDriverSupported ( { EFI_STATUS Status; EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; EFI_DEVICE_PATH_PROTOCOL *DevicePath; =20 GraphicsOutput =3D NULL; - UgaDraw =3D NULL; // // Open the IO Abstraction(s) needed to perform the supported test // @@ -140,21 +136,6 @@ GraphicsConsoleControllerDriverSupported ( Controller, EFI_OPEN_PROTOCOL_BY_DRIVER ); - - if (EFI_ERROR (Status) && FeaturePcdGet (PcdUgaConsumeSupport)) { - // - // Open Graphics Output Protocol failed, try to open UGA Draw Protocol - // - Status =3D gBS->OpenProtocol ( - Controller, - &gEfiUgaDrawProtocolGuid, - (VOID **)&UgaDraw, - This->DriverBindingHandle, - Controller, - EFI_OPEN_PROTOCOL_BY_DRIVER - ); - } - if (EFI_ERROR (Status)) { return Status; } @@ -199,13 +180,6 @@ GraphicsConsoleControllerDriverSupported ( This->DriverBindingHandle, Controller ); - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - gBS->CloseProtocol ( - Controller, - &gEfiUgaDrawProtocolGuid, - This->DriverBindingHandle, - Controller - ); } =20 return Status; @@ -366,9 +340,8 @@ InitializeGraphicsConsoleTextMode ( } =20 /** - Start this driver on Controller by opening Graphics Output protocol or - UGA Draw protocol, and installing Simple Text Out protocol on Controller. - (UGA Draw protocol could be skipped if PcdUgaConsumeSupport is set to FA= LSE.) + Start this driver on Controller by opening Graphics Output protocol + and installing Simple Text Out protocol on Controller. =20 @param This Protocol instance pointer. @param Controller Handle of device to bind driver to @@ -391,8 +364,6 @@ GraphicsConsoleControllerDriverStart ( GRAPHICS_CONSOLE_DEV *Private; UINT32 HorizontalResolution; UINT32 VerticalResolution; - UINT32 ColorDepth; - UINT32 RefreshRate; UINT32 ModeIndex; UINTN MaxMode; UINT32 ModeNumber; @@ -429,18 +400,6 @@ GraphicsConsoleControllerDriverStart ( Controller, EFI_OPEN_PROTOCOL_BY_DRIVER ); - - if (EFI_ERROR (Status) && FeaturePcdGet (PcdUgaConsumeSupport)) { - Status =3D gBS->OpenProtocol ( - Controller, - &gEfiUgaDrawProtocolGuid, - (VOID **)&Private->UgaDraw, - This->DriverBindingHandle, - Controller, - EFI_OPEN_PROTOCOL_BY_DRIVER - ); - } - if (EFI_ERROR (Status)) { goto Error; } @@ -531,43 +490,6 @@ GraphicsConsoleControllerDriverStart ( goto Error; } } - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - // - // At first try to set user-defined resolution - // - ColorDepth =3D 32; - RefreshRate =3D 60; - Status =3D Private->UgaDraw->SetMode ( - Private->UgaDraw, - HorizontalResolution, - VerticalResolution, - ColorDepth, - RefreshRate - ); - if (EFI_ERROR (Status)) { - // - // Try to set 800*600 which is required by UEFI/EFI spec - // - Status =3D Private->UgaDraw->SetMode ( - Private->UgaDraw, - 800, - 600, - ColorDepth, - RefreshRate - ); - if (EFI_ERROR (Status)) { - Status =3D Private->UgaDraw->GetMode ( - Private->UgaDraw, - &HorizontalResolution, - &VerticalResolution, - &ColorDepth, - &RefreshRate - ); - if (EFI_ERROR (Status)) { - goto Error; - } - } - } } =20 DEBUG ((DEBUG_INFO, "GraphicsConsole video resolution %d x %d\n", Horizo= ntalResolution, VerticalResolution)); @@ -635,7 +557,7 @@ GraphicsConsoleControllerDriverStart ( Error: if (EFI_ERROR (Status)) { // - // Close the GOP and UGA Draw Protocol + // Close the GOP // if (Private->GraphicsOutput !=3D NULL) { gBS->CloseProtocol ( @@ -644,13 +566,6 @@ GraphicsConsoleControllerDriverStart ( This->DriverBindingHandle, Controller ); - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - gBS->CloseProtocol ( - Controller, - &gEfiUgaDrawProtocolGuid, - This->DriverBindingHandle, - Controller - ); } =20 if (Private->LineBuffer !=3D NULL) { @@ -672,9 +587,7 @@ GraphicsConsoleControllerDriverStart ( =20 /** Stop this driver on Controller by removing Simple Text Out protocol - and closing the Graphics Output Protocol or UGA Draw protocol on Control= ler. - (UGA Draw protocol could be skipped if PcdUgaConsumeSupport is set to FA= LSE.) - + and closing the Graphics Output Protocol on Controller. =20 @param This Protocol instance pointer. @param Controller Handle of device to stop driver on @@ -723,7 +636,7 @@ GraphicsConsoleControllerDriverStop ( =20 if (!EFI_ERROR (Status)) { // - // Close the GOP or UGA IO Protocol + // Close the GOP Protocol // if (Private->GraphicsOutput !=3D NULL) { gBS->CloseProtocol ( @@ -732,13 +645,6 @@ GraphicsConsoleControllerDriverStop ( This->DriverBindingHandle, Controller ); - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - gBS->CloseProtocol ( - Controller, - &gEfiUgaDrawProtocolGuid, - This->DriverBindingHandle, - Controller - ); } =20 if (Private->LineBuffer !=3D NULL) { @@ -930,7 +836,6 @@ GraphicsConsoleConOutOutputString ( { GRAPHICS_CONSOLE_DEV *Private; EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; INTN Mode; UINTN MaxColumn; UINTN MaxRow; @@ -964,7 +869,6 @@ GraphicsConsoleConOutOutputString ( Mode =3D This->Mode->Mode; Private =3D GRAPHICS_CONSOLE_CON_OUT_DEV_FROM_THIS (This); GraphicsOutput =3D Private->GraphicsOutput; - UgaDraw =3D Private->UgaDraw; =20 MaxColumn =3D Private->ModeData[Mode].Columns; MaxRow =3D Private->ModeData[Mode].Rows; @@ -1052,38 +956,6 @@ GraphicsConsoleConOutOutputString ( EFI_GLYPH_HEIGHT, Delta ); - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - // - // Scroll Screen Up One Row - // - UgaDraw->Blt ( - UgaDraw, - NULL, - EfiUgaVideoToVideo, - DeltaX, - DeltaY + EFI_GLYPH_HEIGHT, - DeltaX, - DeltaY, - Width, - Height, - Delta - ); - - // - // Print Blank Line at last line - // - UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)(UINTN)&Background, - EfiUgaVideoFill, - 0, - 0, - DeltaX, - DeltaY + Height, - Width, - EFI_GLYPH_HEIGHT, - Delta - ); } } else { This->Mode->CursorRow++; @@ -1317,19 +1189,13 @@ GraphicsConsoleConOutSetMode ( GRAPHICS_CONSOLE_DEV *Private; GRAPHICS_CONSOLE_MODE_DATA *ModeData; EFI_GRAPHICS_OUTPUT_BLT_PIXEL *NewLineBuffer; - UINT32 HorizontalResolution; - UINT32 VerticalResolution; EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; - UINT32 ColorDepth; - UINT32 RefreshRate; EFI_TPL OldTpl; =20 OldTpl =3D gBS->RaiseTPL (TPL_NOTIFY); =20 Private =3D GRAPHICS_CONSOLE_CON_OUT_DEV_FROM_THIS (This); GraphicsOutput =3D Private->GraphicsOutput; - UgaDraw =3D Private->UgaDraw; =20 // // Make sure the requested mode number is supported @@ -1363,7 +1229,7 @@ GraphicsConsoleConOutSetMode ( } =20 // - // Otherwise, the size of the text console and/or the GOP/UGA mode wil= l be changed, + // Otherwise, the size of the text console and/or the GOP mode will be= changed, // so erase the cursor, and free the LineBuffer for the current mode // FlushCursor (This); @@ -1419,51 +1285,6 @@ GraphicsConsoleConOutSetMode ( 0 ); } - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - // - // Get the current UGA Draw mode information - // - Status =3D UgaDraw->GetMode ( - UgaDraw, - &HorizontalResolution, - &VerticalResolution, - &ColorDepth, - &RefreshRate - ); - if (EFI_ERROR (Status) || (HorizontalResolution !=3D ModeData->GopWidt= h) || (VerticalResolution !=3D ModeData->GopHeight)) { - // - // Either no graphics mode is currently set, or it is set to the wro= ng resolution, so set the new graphics mode - // - Status =3D UgaDraw->SetMode ( - UgaDraw, - ModeData->GopWidth, - ModeData->GopHeight, - 32, - 60 - ); - if (EFI_ERROR (Status)) { - // - // The mode set operation failed - // - goto Done; - } - } else { - // - // The current graphics mode is correct, so simply clear the entire = display - // - Status =3D UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)(UINTN)&mGraphicsEfiColors[0], - EfiUgaVideoFill, - 0, - 0, - 0, - 0, - ModeData->GopWidth, - ModeData->GopHeight, - 0 - ); - } } =20 // @@ -1555,7 +1376,6 @@ GraphicsConsoleConOutClearScreen ( GRAPHICS_CONSOLE_DEV *Private; GRAPHICS_CONSOLE_MODE_DATA *ModeData; EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; EFI_GRAPHICS_OUTPUT_BLT_PIXEL Foreground; EFI_GRAPHICS_OUTPUT_BLT_PIXEL Background; EFI_TPL OldTpl; @@ -1571,7 +1391,6 @@ GraphicsConsoleConOutClearScreen ( =20 Private =3D GRAPHICS_CONSOLE_CON_OUT_DEV_FROM_THIS (This); GraphicsOutput =3D Private->GraphicsOutput; - UgaDraw =3D Private->UgaDraw; ModeData =3D &(Private->ModeData[This->Mode->Mode]); =20 GetTextColors (This, &Foreground, &Background); @@ -1588,19 +1407,6 @@ GraphicsConsoleConOutClearScreen ( ModeData->GopHeight, 0 ); - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - Status =3D UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)(UINTN)&Background, - EfiUgaVideoFill, - 0, - 0, - 0, - 0, - ModeData->GopWidth, - ModeData->GopHeight, - 0 - ); } else { Status =3D EFI_UNSUPPORTED; } @@ -1761,7 +1567,7 @@ GetTextColors ( @param Count The count of Unicode string. =20 @retval EFI_OUT_OF_RESOURCES If no memory resource to use. - @retval EFI_UNSUPPORTED If no Graphics Output protocol and UGA Draw + @retval EFI_UNSUPPORTED If no Graphics Output protocol protocol exist. @retval EFI_SUCCESS Drawing Unicode string implemented success= fully. =20 @@ -1778,9 +1584,6 @@ DrawUnicodeWeightAtCursorN ( EFI_IMAGE_OUTPUT *Blt; EFI_STRING String; EFI_FONT_DISPLAY_INFO *FontInfo; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; - EFI_HII_ROW_INFO *RowInfoArray; - UINTN RowInfoArraySize; =20 Private =3D GRAPHICS_CONSOLE_CON_OUT_DEV_FROM_THIS (This); Blt =3D (EFI_IMAGE_OUTPUT *)AllocateZeroPool (sizeof (EFI_IMAGE_OUTP= UT)); @@ -1832,63 +1635,6 @@ DrawUnicodeWeightAtCursorN ( NULL, NULL ); - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - // - // If Graphics Output protocol cannot be found and PcdUgaConsumeSuppor= t enabled, - // using UGA Draw protocol to draw. - // - ASSERT (Private->UgaDraw !=3D NULL); - - UgaDraw =3D Private->UgaDraw; - - Blt->Image.Bitmap =3D AllocateZeroPool (Blt->Width * Blt->Height * siz= eof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL)); - if (Blt->Image.Bitmap =3D=3D NULL) { - FreePool (Blt); - FreePool (String); - return EFI_OUT_OF_RESOURCES; - } - - RowInfoArray =3D NULL; - // - // StringToImage only support blt'ing image to device using GOP proto= col. If GOP is not supported in this platform, - // we ask StringToImage to print the string to blt buffer, then blt t= o device using UgaDraw. - // - Status =3D mHiiFont->StringToImage ( - mHiiFont, - EFI_HII_IGNORE_IF_NO_GLYPH | EFI_HII_IGNORE_LINE_= BREAK, - String, - FontInfo, - &Blt, - This->Mode->CursorColumn * EFI_GLYPH_WIDTH + Priv= ate->ModeData[This->Mode->Mode].DeltaX, - This->Mode->CursorRow * EFI_GLYPH_HEIGHT + Privat= e->ModeData[This->Mode->Mode].DeltaY, - &RowInfoArray, - &RowInfoArraySize, - NULL - ); - - if (!EFI_ERROR (Status)) { - // - // Line breaks are handled by caller of DrawUnicodeWeightAtCursorN, = so the updated parameter RowInfoArraySize by StringToImage will - // always be 1 or 0 (if there is no valid Unicode Char can be printe= d). ASSERT here to make sure. - // - ASSERT (RowInfoArraySize <=3D 1); - - Status =3D UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)Blt->Image.Bitmap, - EfiUgaBltBufferToVideo, - This->Mode->CursorColumn * EFI_GLYPH_WIDTH + Pr= ivate->ModeData[This->Mode->Mode].DeltaX, - (This->Mode->CursorRow) * EFI_GLYPH_HEIGHT + Pri= vate->ModeData[This->Mode->Mode].DeltaY, - This->Mode->CursorColumn * EFI_GLYPH_WIDTH + Pr= ivate->ModeData[This->Mode->Mode].DeltaX, - (This->Mode->CursorRow) * EFI_GLYPH_HEIGHT + Pri= vate->ModeData[This->Mode->Mode].DeltaY, - RowInfoArray[0].LineWidth, - RowInfoArray[0].LineHeight, - Blt->Width * sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIX= EL) - ); - } - - FreePool (RowInfoArray); - FreePool (Blt->Image.Bitmap); } else { Status =3D EFI_UNSUPPORTED; } @@ -1931,7 +1677,6 @@ FlushCursor ( INTN GlyphX; INTN GlyphY; EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; EFI_GRAPHICS_OUTPUT_BLT_PIXEL_UNION Foreground; EFI_GRAPHICS_OUTPUT_BLT_PIXEL_UNION Background; EFI_GRAPHICS_OUTPUT_BLT_PIXEL_UNION BltChar[EFI_GLYPH_HEIGHT][EFI_GLYPH= _WIDTH]; @@ -1946,7 +1691,6 @@ FlushCursor ( =20 Private =3D GRAPHICS_CONSOLE_CON_OUT_DEV_FROM_THIS (This); GraphicsOutput =3D Private->GraphicsOutput; - UgaDraw =3D Private->UgaDraw; =20 // // In this driver, only narrow character was supported. @@ -1969,19 +1713,6 @@ FlushCursor ( EFI_GLYPH_HEIGHT, EFI_GLYPH_WIDTH * sizeof (EFI_GRAPHICS_OUTPUT_BLT_PI= XEL) ); - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)(UINTN)BltChar, - EfiUgaVideoToBltBuffer, - GlyphX, - GlyphY, - 0, - 0, - EFI_GLYPH_WIDTH, - EFI_GLYPH_HEIGHT, - EFI_GLYPH_WIDTH * sizeof (EFI_UGA_PIXEL) - ); } =20 GetTextColors (This, &Foreground.Pixel, &Background.Pixel); @@ -2010,19 +1741,6 @@ FlushCursor ( EFI_GLYPH_HEIGHT, EFI_GLYPH_WIDTH * sizeof (EFI_GRAPHICS_OUTPUT_BLT_PI= XEL) ); - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)(UINTN)BltChar, - EfiUgaBltBufferToVideo, - 0, - 0, - GlyphX, - GlyphY, - EFI_GLYPH_WIDTH, - EFI_GLYPH_HEIGHT, - EFI_GLYPH_WIDTH * sizeof (EFI_UGA_PIXEL) - ); } =20 return EFI_SUCCESS; diff --git a/MdeModulePkg/Universal/HiiDatabaseDxe/Image.c b/MdeModulePkg/U= niversal/HiiDatabaseDxe/Image.c index b5b962596968..cd4e009291dc 100644 --- a/MdeModulePkg/Universal/HiiDatabaseDxe/Image.c +++ b/MdeModulePkg/Universal/HiiDatabaseDxe/Image.c @@ -2,7 +2,7 @@ Implementation for EFI_HII_IMAGE_PROTOCOL. =20 =20 -Copyright (c) 2007 - 2019, Intel Corporation. All rights reserved.
+Copyright (c) 2007 - 2021, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ @@ -1401,7 +1401,7 @@ HiiDrawImage ( // if ((Flags & EFI_HII_DIRECT_TO_SCREEN) =3D=3D EFI_HII_DIRECT_TO_SCREEN= ) { // - // Caller should make sure the current UGA console is grarphic mode. + // Caller should make sure the current console is grarphic mode. // =20 // diff --git a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsCons= oleDxe.uni b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsCons= oleDxe.uni index aec5d57f9038..0dc88a1ca45f 100644 --- a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.= uni +++ b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.= uni @@ -2,9 +2,9 @@ // Console support on graphic devices. // // This driver will install Simple Text Output protocol by consuming Graph= ices Output -// protocol or UGA Draw protocol on graphic devices. +// protocol on graphic devices. // -// Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.
+// Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
// // SPDX-License-Identifier: BSD-2-Clause-Patent // @@ -14,5 +14,5 @@ #string STR_MODULE_ABSTRACT #language en-US "Console support o= n graphic devices" =20 #string STR_MODULE_DESCRIPTION #language en-US "This driver will = install SimpleTextOutputProtocol by consuming GraphicesOutput\n" - "Protocol or UgaDr= awProtocol on graphics devices." + "Protocol on graph= ics devices." =20 --=20 2.30.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85685): https://edk2.groups.io/g/devel/message/85685 Mute This Topic: https://groups.io/mt/88411253/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Fri Apr 26 14:18:48 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85686+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85686+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642121489; cv=none; d=zohomail.com; s=zohoarc; b=I7+RTJ+hVuyTH7tvur6AItVQego9qdybpp4fxFEggx40Er/Bg5UouCqb0vEuSfDLtKBmW0J8a6X+SgYpMKQHyQPL++OICiYwaDeHqVoejUC1Ed82olQJWoaelzSwhbOkF4Rjl/rw03r0yCD8+ihbLUHFXKVh/3cByat3Hcx7xbI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642121489; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=fSAXPQFT/d/o/uFuA11Qc5W9gKB4h7ciia9JSGaWSNg=; b=dlRC838Csx1tthX6/PbAU2fubiRfQfGjf/0eceY17DW1FUtuDYnvYvOeakDwFyGX/qWDDjICSIDjvveHgcSaJKNAG4gSFi/Yb4gzt/gQBI2pFpjRcSk5SooVw8bAHN+YDIbkvO3C9X8N4+95UjulvN4rhMkmkyf//pVo0SHnlmU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85686+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1642121489558959.8077459862974; Thu, 13 Jan 2022 16:51:29 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id dwoSYY1788612x1yyeE21F4q; Thu, 13 Jan 2022 16:51:29 -0800 X-Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.1082.1642121466955476862 for ; Thu, 13 Jan 2022 16:51:28 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10226"; a="241713906" X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="241713906" X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:28 -0800 X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="475564790" X-Received: from guominji-mobl.ccr.corp.intel.com ([10.238.9.87]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:26 -0800 From: "Guomin Jiang" To: devel@edk2.groups.io Cc: GuoMinJ , Jian J Wang , Liming Gao , Zhichao Gao , Ray Ni , Hao A Wu Subject: [edk2-devel] [PATCH 09/11] MdeModulePkg: Remove All UGA Support Date: Fri, 14 Jan 2022 08:50:42 +0800 Message-Id: <20220114005044.1975-10-guomin.jiang@intel.com> In-Reply-To: <20220114005044.1975-1-guomin.jiang@intel.com> References: <20220114005044.1975-1-guomin.jiang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,guomin.jiang@intel.com X-Gm-Message-State: UDFE40FEwpclFxbnqZT3yfnKx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642121489; bh=SjC0m/9cPfASUawSVPjtT2yKpKovltpQSu8/bs2CL/0=; h=Cc:Date:From:Reply-To:Subject:To; b=beJfj6wKNywCClgPACzUJMvkNW2OZHWCHn1RJTGW10bbdI9dD8aQD6VBe96T6nyCz3E 6Y0j5Y1I5pYXFA7O9lWGzk6LUEaYVMYfNx0xf340EY1zwOvacrb6XsgXTaYcFXr6bYdti O9si6SvGJ4V/BaBzaUSf64Ov7LGpZ9EOfgU= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642121490871100007 Content-Type: text/plain; charset="utf-8" From: GuoMinJ REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2368 Remove All UGA Support in MdeModulePkg, first remove from library. Remove the PcdConOutGopSupport definition. Signed-off-by: Guomin Jiang Cc: Jian J Wang Cc: Liming Gao Cc: Zhichao Gao Cc: Ray Ni Cc: Hao A Wu --- MdeModulePkg/MdeModulePkg.dec | 14 -- .../Library/BootLogoLib/BootLogoLib.inf | 4 - MdeModulePkg/Include/Library/BootLogoLib.h | 4 +- MdeModulePkg/Bus/Pci/PciBusDxe/PciBus.c | 4 +- .../Library/BootLogoLib/BootLogoLib.c | 228 +++++------------- MdeModulePkg/MdeModulePkg.uni | 12 - 6 files changed, 60 insertions(+), 206 deletions(-) diff --git a/MdeModulePkg/MdeModulePkg.dec b/MdeModulePkg/MdeModulePkg.dec index 463e889e9a68..21e037269cce 100644 --- a/MdeModulePkg/MdeModulePkg.dec +++ b/MdeModulePkg/MdeModulePkg.dec @@ -726,20 +726,6 @@ [PcdsFeatureFlag] # @Prompt Enable Unicode Collation 2 support. gEfiMdeModulePkgTokenSpaceGuid.PcdUnicodeCollation2Support|TRUE|BOOLEAN|= 0x00010041 =20 - ## Indicates if Graphics Output Protocol will be installed on virtual ha= ndle created by ConsplitterDxe. - # It could be set FALSE to save size.

- # TRUE - Installs Graphics Output Protocol on virtual handle created = by ConsplitterDxe.
- # FALSE - Does not install Graphics Output Protocol on virtual handle = created by ConsplitterDxe.
- # @Prompt Enable ConOut GOP support. - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutGopSupport|TRUE|BOOLEAN|0x000100= 42 - - ## Indicates if UGA Draw Protocol will be installed on virtual handle cr= eated by ConsplitterDxe. - # It could be set FALSE to save size.

- # TRUE - Installs UGA Draw Protocol on virtual handle created by Cons= plitterDxe.
- # FALSE - Does not install UGA Draw Protocol on virtual handle created= by ConsplitterDxe.
- # @Prompt Enable ConOut UGA support. - gEfiMdeModulePkgTokenSpaceGuid.PcdConOutUgaSupport|TRUE|BOOLEAN|0x000100= 43 - ## Indicates PeiCore will first search TE section from the PEIM to load = the image, or PE32 section, when PeiCore dispatches a PEI module. # This PCD is used to tune PEI phase performance to reduce the search i= mage time. # It can be set according to the generated image section type.

diff --git a/MdeModulePkg/Library/BootLogoLib/BootLogoLib.inf b/MdeModulePk= g/Library/BootLogoLib/BootLogoLib.inf index 7d50f2dfa3ab..03fd70451bc6 100644 --- a/MdeModulePkg/Library/BootLogoLib/BootLogoLib.inf +++ b/MdeModulePkg/Library/BootLogoLib/BootLogoLib.inf @@ -42,11 +42,7 @@ [LibraryClasses] =20 [Protocols] gEfiGraphicsOutputProtocolGuid ## SOMETIMES_CONSUMES - gEfiUgaDrawProtocolGuid |PcdUgaConsumeSupport ## SOMETIMES_CONSUMES gEfiBootLogoProtocolGuid ## SOMETIMES_CONSUMES gEdkiiBootLogo2ProtocolGuid ## SOMETIMES_CONSUMES gEfiUserManagerProtocolGuid ## CONSUMES gEdkiiPlatformLogoProtocolGuid ## CONSUMES - -[FeaturePcd] - gEfiMdePkgTokenSpaceGuid.PcdUgaConsumeSupport ## CONSUMES diff --git a/MdeModulePkg/Include/Library/BootLogoLib.h b/MdeModulePkg/Incl= ude/Library/BootLogoLib.h index 2d6209a2789b..a774a7392590 100644 --- a/MdeModulePkg/Include/Library/BootLogoLib.h +++ b/MdeModulePkg/Include/Library/BootLogoLib.h @@ -2,7 +2,7 @@ This library is only intended to be used by PlatformBootManagerLib to show progress bar and LOGO. =20 -Copyright (c) 2011 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2011 - 2021, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ @@ -26,7 +26,7 @@ BootLogoEnableLogo ( Use SystemTable ConOut to turn on video based Simple Text Out consoles. = The Simple Text Out screens will now be synced up with all non-video output = devices. =20 - @retval EFI_SUCCESS UGA devices are back in text mode and synced up. + @retval EFI_SUCCESS Graphic device are back in text mode and synced = up. =20 **/ EFI_STATUS diff --git a/MdeModulePkg/Bus/Pci/PciBusDxe/PciBus.c b/MdeModulePkg/Bus/Pci= /PciBusDxe/PciBus.c index 337b2090d98e..c4e45c2d3de9 100644 --- a/MdeModulePkg/Bus/Pci/PciBusDxe/PciBus.c +++ b/MdeModulePkg/Bus/Pci/PciBusDxe/PciBus.c @@ -8,7 +8,7 @@ PCI Root Bridges. So it means platform needs install PCI Root Bridge IO = protocol for each PCI Root Bus and install PCI Host Bridge Resource Allocation Protocol. =20 -Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2021, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ @@ -49,7 +49,7 @@ GLOBAL_REMOVE_IF_UNREFERENCED EFI_PCI_HOTPLUG_REQUEST_PRO= TOCOL mPciHotPlugReque Installs driver module protocols and. Creates virtual device handles for= ConIn, ConOut, and StdErr. Installs Simple Text In protocol, Simple Text In Ex = protocol, Simple Pointer protocol, Absolute Pointer protocol on those virtual hand= lers. - Installs Graphics Output protocol and/or UGA Draw protocol if needed. + Installs Graphics Output protocol if needed. =20 @param[in] ImageHandle The firmware allocated handle for the EFI imag= e. @param[in] SystemTable A pointer to the EFI System Table. diff --git a/MdeModulePkg/Library/BootLogoLib/BootLogoLib.c b/MdeModulePkg/= Library/BootLogoLib/BootLogoLib.c index 478ec2d40e2b..3c3191d7e881 100644 --- a/MdeModulePkg/Library/BootLogoLib/BootLogoLib.c +++ b/MdeModulePkg/Library/BootLogoLib/BootLogoLib.c @@ -2,7 +2,7 @@ This library is only intended to be used by PlatformBootManagerLib to show progress bar and LOGO. =20 -Copyright (c) 2011 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2011 - 2021, Intel Corporation. All rights reserved.
Copyright (c) 2016, Microsoft Corporation
SPDX-License-Identifier: BSD-2-Clause-Patent =20 @@ -12,7 +12,6 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #include #include #include -#include #include #include #include @@ -47,9 +46,6 @@ BootLogoEnableLogo ( UINT32 Instance; EFI_IMAGE_INPUT Image; EFI_GRAPHICS_OUTPUT_BLT_PIXEL *Blt; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; - UINT32 ColorDepth; - UINT32 RefreshRate; EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; EFI_BOOT_LOGO_PROTOCOL *BootLogo; EDKII_BOOT_LOGO2_PROTOCOL *BootLogo2; @@ -68,21 +64,10 @@ BootLogoEnableLogo ( return EFI_UNSUPPORTED; } =20 - UgaDraw =3D NULL; // // Try to open GOP first // Status =3D gBS->HandleProtocol (gST->ConsoleOutHandle, &gEfiGraphicsOutp= utProtocolGuid, (VOID **)&GraphicsOutput); - if (EFI_ERROR (Status) && FeaturePcdGet (PcdUgaConsumeSupport)) { - GraphicsOutput =3D NULL; - // - // Open GOP failed, try to open UGA - // - Status =3D gBS->HandleProtocol (gST->ConsoleOutHandle, &gEfiUgaDrawPro= tocolGuid, (VOID **)&UgaDraw); - if (EFI_ERROR (Status)) { - UgaDraw =3D NULL; - } - } =20 if (EFI_ERROR (Status)) { return EFI_UNSUPPORTED; @@ -109,16 +94,8 @@ BootLogoEnableLogo ( // gST->ConOut->EnableCursor (gST->ConOut, FALSE); =20 - if (GraphicsOutput !=3D NULL) { - SizeOfX =3D GraphicsOutput->Mode->Info->HorizontalResolution; - SizeOfY =3D GraphicsOutput->Mode->Info->VerticalResolution; - } else { - ASSERT (UgaDraw !=3D NULL); - Status =3D UgaDraw->GetMode (UgaDraw, &SizeOfX, &SizeOfY, &ColorDepth,= &RefreshRate); - if (EFI_ERROR (Status)) { - return EFI_UNSUPPORTED; - } - } + SizeOfX =3D GraphicsOutput->Mode->Info->HorizontalResolution; + SizeOfY =3D GraphicsOutput->Mode->Info->VerticalResolution; =20 Blt =3D NULL; NumberOfLogos =3D 0; @@ -206,34 +183,18 @@ BootLogoEnableLogo ( DestY +=3D OffsetY; =20 if ((DestX >=3D 0) && (DestY >=3D 0)) { - if (GraphicsOutput !=3D NULL) { - Status =3D GraphicsOutput->Blt ( - GraphicsOutput, - Blt, - EfiBltBufferToVideo, - 0, - 0, - (UINTN)DestX, - (UINTN)DestY, - Image.Width, - Image.Height, - Image.Width * sizeof (EFI_GRAPHICS_OUTP= UT_BLT_PIXEL) - ); - } else { - ASSERT (UgaDraw !=3D NULL); - Status =3D UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)Blt, - EfiUgaBltBufferToVideo, - 0, - 0, - (UINTN)DestX, - (UINTN)DestY, - Image.Width, - Image.Height, - Image.Width * sizeof (EFI_UGA_PIXEL) - ); - } + Status =3D GraphicsOutput->Blt ( + GraphicsOutput, + Blt, + EfiBltBufferToVideo, + 0, + 0, + (UINTN)DestX, + (UINTN)DestY, + Image.Width, + Image.Height, + Image.Width * sizeof (EFI_GRAPHICS_OUTPUT= _BLT_PIXEL) + ); =20 // // Report displayed Logo information. @@ -307,33 +268,18 @@ BootLogoEnableLogo ( return EFI_OUT_OF_RESOURCES; } =20 - if (GraphicsOutput !=3D NULL) { - Status =3D GraphicsOutput->Blt ( - GraphicsOutput, - LogoBlt, - EfiBltVideoToBltBuffer, - LogoDestX, - LogoDestY, - 0, - 0, - LogoWidth, - LogoHeight, - LogoWidth * sizeof (EFI_GRAPHICS_OUTPUT_B= LT_PIXEL) - ); - } else { - Status =3D UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)LogoBlt, - EfiUgaVideoToBltBuffer, - LogoDestX, - LogoDestY, - 0, - 0, - LogoWidth, - LogoHeight, - LogoWidth * sizeof (EFI_UGA_PIXEL) - ); - } + Status =3D GraphicsOutput->Blt ( + GraphicsOutput, + LogoBlt, + EfiBltVideoToBltBuffer, + LogoDestX, + LogoDestY, + 0, + 0, + LogoWidth, + LogoHeight, + LogoWidth * sizeof (EFI_GRAPHICS_OUTPUT_BLT= _PIXEL) + ); } =20 if (!EFI_ERROR (Status)) { @@ -368,7 +314,7 @@ BootLogoEnableLogo ( Use SystemTable Conout to turn on video based Simple Text Out consoles. = The Simple Text Out screens will now be synced up with all non video output = devices =20 - @retval EFI_SUCCESS UGA devices are back in text mode and synced up. + @retval EFI_SUCCESS Graphic devices are back in text mode and synced= up. =20 **/ EFI_STATUS @@ -411,11 +357,8 @@ BootLogoUpdateProgress ( { EFI_STATUS Status; EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; UINT32 SizeOfX; UINT32 SizeOfY; - UINT32 ColorDepth; - UINT32 RefreshRate; EFI_GRAPHICS_OUTPUT_BLT_PIXEL Color; UINTN BlockHeight; UINTN BlockWidth; @@ -428,40 +371,14 @@ BootLogoUpdateProgress ( return EFI_INVALID_PARAMETER; } =20 - UgaDraw =3D NULL; - Status =3D gBS->HandleProtocol (gST->ConsoleOutHandle, &gEfiGraphicsOut= putProtocolGuid, (VOID **)&GraphicsOutput); - if (EFI_ERROR (Status) && FeaturePcdGet (PcdUgaConsumeSupport)) { - GraphicsOutput =3D NULL; - - Status =3D gBS->HandleProtocol (gST->ConsoleOutHandle, &gEfiUgaDrawPro= tocolGuid, (VOID **)&UgaDraw); - if (EFI_ERROR (Status)) { - UgaDraw =3D NULL; - } - } + Status =3D gBS->HandleProtocol (gST->ConsoleOutHandle, &gEfiGraphicsOutp= utProtocolGuid, (VOID **)&GraphicsOutput); =20 if (EFI_ERROR (Status)) { return EFI_UNSUPPORTED; } =20 - SizeOfX =3D 0; - SizeOfY =3D 0; - if (GraphicsOutput !=3D NULL) { - SizeOfX =3D GraphicsOutput->Mode->Info->HorizontalResolution; - SizeOfY =3D GraphicsOutput->Mode->Info->VerticalResolution; - } else if (UgaDraw !=3D NULL) { - Status =3D UgaDraw->GetMode ( - UgaDraw, - &SizeOfX, - &SizeOfY, - &ColorDepth, - &RefreshRate - ); - if (EFI_ERROR (Status)) { - return EFI_UNSUPPORTED; - } - } else { - return EFI_UNSUPPORTED; - } + SizeOfX =3D GraphicsOutput->Mode->Info->HorizontalResolution; + SizeOfY =3D GraphicsOutput->Mode->Info->VerticalResolution; =20 BlockWidth =3D SizeOfX / 100; BlockHeight =3D SizeOfY / 50; @@ -477,35 +394,18 @@ BootLogoUpdateProgress ( // SetMem (&Color, sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL), 0x0); =20 - if (GraphicsOutput !=3D NULL) { - Status =3D GraphicsOutput->Blt ( - GraphicsOutput, - &Color, - EfiBltVideoFill, - 0, - 0, - 0, - PosY - EFI_GLYPH_HEIGHT - 1, - SizeOfX, - SizeOfY - (PosY - EFI_GLYPH_HEIGHT - 1), - SizeOfX * sizeof (EFI_GRAPHICS_OUTPUT_BLT= _PIXEL) - ); - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - Status =3D UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)&Color, - EfiUgaVideoFill, - 0, - 0, - 0, - PosY - EFI_GLYPH_HEIGHT - 1, - SizeOfX, - SizeOfY - (PosY - EFI_GLYPH_HEIGHT - 1), - SizeOfX * sizeof (EFI_UGA_PIXEL) - ); - } else { - return EFI_UNSUPPORTED; - } + Status =3D GraphicsOutput->Blt ( + GraphicsOutput, + &Color, + EfiBltVideoFill, + 0, + 0, + 0, + PosY - EFI_GLYPH_HEIGHT - 1, + SizeOfX, + SizeOfY - (PosY - EFI_GLYPH_HEIGHT - 1), + SizeOfX * sizeof (EFI_GRAPHICS_OUTPUT_BLT_P= IXEL) + ); } =20 // @@ -513,35 +413,19 @@ BootLogoUpdateProgress ( // for (Index =3D PreviousValue; Index < BlockNum; Index++) { PosX =3D Index * BlockWidth; - if (GraphicsOutput !=3D NULL) { - Status =3D GraphicsOutput->Blt ( - GraphicsOutput, - &ProgressColor, - EfiBltVideoFill, - 0, - 0, - PosX, - PosY, - BlockWidth - 1, - BlockHeight, - (BlockWidth) * sizeof (EFI_GRAPHICS_OUTPU= T_BLT_PIXEL) - ); - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - Status =3D UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)&ProgressColor, - EfiUgaVideoFill, - 0, - 0, - PosX, - PosY, - BlockWidth - 1, - BlockHeight, - (BlockWidth) * sizeof (EFI_UGA_PIXEL) - ); - } else { - return EFI_UNSUPPORTED; - } + + Status =3D GraphicsOutput->Blt ( + GraphicsOutput, + &ProgressColor, + EfiBltVideoFill, + 0, + 0, + PosX, + PosY, + BlockWidth - 1, + BlockHeight, + (BlockWidth) * sizeof (EFI_GRAPHICS_OUTPUT_= BLT_PIXEL) + ); } =20 PrintXY ( diff --git a/MdeModulePkg/MdeModulePkg.uni b/MdeModulePkg/MdeModulePkg.uni index 27889a728058..c8f42b668731 100644 --- a/MdeModulePkg/MdeModulePkg.uni +++ b/MdeModulePkg/MdeModulePkg.uni @@ -703,18 +703,6 @@ = "TRUE - Installs Unicode Collation 2 Protocol.
\n" = "FALSE - Does not install Unicode Collation 2 Protocol.<= BR>" =20 -#string STR_gEfiMdeModulePkgTokenSpaceGuid_PcdConOutGopSupport_PROMPT #la= nguage en-US "Enable ConOut GOP support" - -#string STR_gEfiMdeModulePkgTokenSpaceGuid_PcdConOutGopSupport_HELP #lang= uage en-US "Indicates if Graphics Output Protocol will be installed on virt= ual handle created by ConsplitterDxe. It could be set FALSE to save size.
\n" - = "TRUE - Installs Graphics Output Protocol on virtual handle cre= ated by ConsplitterDxe.
\n" - = "FALSE - Does not install Graphics Output Protocol on virtual ha= ndle created by ConsplitterDxe.
" - -#string STR_gEfiMdeModulePkgTokenSpaceGuid_PcdConOutUgaSupport_PROMPT #la= nguage en-US "Enable ConOut UGA support" - -#string STR_gEfiMdeModulePkgTokenSpaceGuid_PcdConOutUgaSupport_HELP #lang= uage en-US "Indicates if UGA Draw Protocol will be installed on virtual han= dle created by ConsplitterDxe. It could be set FALSE to save size.

\= n" - = "TRUE - Installs UGA Draw Protocol on virtual handle created by= ConsplitterDxe.
\n" - = "FALSE - Does not install UGA Draw Protocol on virtual handle cr= eated by ConsplitterDxe.
" - #string STR_gEfiMdeModulePkgTokenSpaceGuid_PcdPeiCoreImageLoaderSearchTeSe= ctionFirst_PROMPT #language en-US "PeiCore search TE section first" =20 #string STR_gEfiMdeModulePkgTokenSpaceGuid_PcdPeiCoreImageLoaderSearchTeSe= ctionFirst_HELP #language en-US "Indicates PeiCore will first search TE se= ction from the PEIM to load the image, or PE32 section, when PeiCore dispat= ches a PEI module. This PCD is used to tune PEI phase performance to reduce= the search image time. It can be set according to the generated image sect= ion type.

\n" --=20 2.30.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85686): https://edk2.groups.io/g/devel/message/85686 Mute This Topic: https://groups.io/mt/88411254/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Fri Apr 26 14:18:48 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85687+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85687+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642121491; cv=none; d=zohomail.com; s=zohoarc; b=IySy1slcqFsoMZ5XfFvJC1mzao7RMQsWN4/SYx1UJtdSjPzuXMZ7fUFAP9hltbBdHKQun9l1m/KfdybxJ+qyd9GdUOM0Og0IPf8L7CzufIEj/QoCw0mXHkglEic6WVAFCCwTknAvML3RjuQ9Egd0AI/xA/ijI9hiGQ1HUritv6I= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642121491; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=BS9A7a/zW94BBbyibGpcv3S7raqaDoi9iDzQ7YubjK4=; b=Dca7sX/VY/lt4R8GISIufOuDBrZPqW2mDxqd1J/Mos5CQkdTH+VD7tGdjuO+BoyiM67eIQMv7qgtMfyQ7oGQXvYqNPinV73Dngu4uc+e3Nz6NBnt3zkT1mhr+4Jz7WJlJvRRFh1cyuLrhH8k50SZXtQ9whfoD4szVq9f+QGbtu0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85687+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 164212149149925.763614734432167; Thu, 13 Jan 2022 16:51:31 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id b20KYY1788612xrgOqgpJhLM; Thu, 13 Jan 2022 16:51:31 -0800 X-Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.1082.1642121466955476862 for ; Thu, 13 Jan 2022 16:51:30 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10226"; a="241713917" X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="241713917" X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:30 -0800 X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="475564798" X-Received: from guominji-mobl.ccr.corp.intel.com ([10.238.9.87]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:28 -0800 From: "Guomin Jiang" To: devel@edk2.groups.io Cc: GuoMinJ , Bob Feng , Liming Gao , Yuwei Chen Subject: [edk2-devel] [PATCH 10/11] BaseTools: Remove All UGA Support Date: Fri, 14 Jan 2022 08:50:43 +0800 Message-Id: <20220114005044.1975-11-guomin.jiang@intel.com> In-Reply-To: <20220114005044.1975-1-guomin.jiang@intel.com> References: <20220114005044.1975-1-guomin.jiang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,guomin.jiang@intel.com X-Gm-Message-State: 8ubahaKuBVXTiXN3RmNXGK9Yx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642121491; bh=eRykGm2jryAmGkVbQ6EcknFcwIZocnlAVHQmljmTBxI=; h=Cc:Date:From:Reply-To:Subject:To; b=Jf++OG91oe9QE6wRH1vSxnPbJ8m7j9KgqJtdfkNPJLhTu4T9Uo2jYyKhHwhF5Br+ZPA uJCqvtfbVdCf7d/jA4MMoXVkvSsfM0qyTesb3OTXbzFwKTM8iqRox/RddtVAuRvlOfoDF x4GpKV0UZx068HPI4nooMrnQ7sxJJjymdcs= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642121493245100002 Content-Type: text/plain; charset="utf-8" From: GuoMinJ REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2368 Remove all UGA support in BaseTools package. Signed-off-by: Guomin Jiang Cc: Bob Feng Cc: Liming Gao Cc: Yuwei Chen --- .../Source/C/Include/Protocol/HiiFramework.h | 53 +----- BaseTools/Source/C/Include/Protocol/UgaDraw.h | 161 ------------------ 2 files changed, 1 insertion(+), 213 deletions(-) delete mode 100644 BaseTools/Source/C/Include/Protocol/UgaDraw.h diff --git a/BaseTools/Source/C/Include/Protocol/HiiFramework.h b/BaseTools= /Source/C/Include/Protocol/HiiFramework.h index 448350967bbf..8cd2cb80c01c 100644 --- a/BaseTools/Source/C/Include/Protocol/HiiFramework.h +++ b/BaseTools/Source/C/Include/Protocol/HiiFramework.h @@ -6,7 +6,7 @@ @par Revision Reference: This protocol is defined in HII spec 0.92. =20 - Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.
+ Copyright (c) 2007 - 2021, Intel Corporation. All rights reserved.
=20 SPDX-License-Identifier: BSD-2-Clause-Patent =20 @@ -28,20 +28,6 @@ 0xd7ad636e, 0xb997, 0x459b, {0xbf, 0x3f, 0x88, 0x46, 0x89, 0x79, 0x80,= 0xe1} \ } =20 -// BugBug: -//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++= ++++ -// If UGA goes away we need to put this some place. I'm not sure where? -// -//typedef struct { -// UINT8 Blue; -// UINT8 Green; -// UINT8 Red; -// UINT8 Reserved; -//} EFI_UGA_PIXEL; - -//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++= ++++ -// - typedef struct _EFI_HII_PROTOCOL EFI_HII_PROTOCOL; =20 // @@ -575,39 +561,6 @@ EFI_STATUS IN OUT UINT32 *InternalStatus ); =20 -/** - Translates a glyph into the format required for input to the Universal - Graphics Adapter (UGA) Block Transfer (BLT) routines. - - @param This A pointer to the EFI_HII_PROTOCOL instance. - @param GlyphBuffer A pointer to the buffer that contains glyp= h data. - @param Foreground The foreground setting requested to be use= d for the - generated BltBuffer data. - @param Background The background setting requested to be use= d for the - generated BltBuffer data. - @param Count The entry in the BltBuffer upon which to a= ct. - @param Width The width in bits of the glyph being conve= rted. - @param Height The height in bits of the glyph being conv= erted - @param BltBuffer A pointer to the buffer that contains the = data that is - ready to be used by the UGA BLT routines. - - @retval EFI_SUCCESS It worked. - @retval EFI_NOT_FOUND A glyph for a character was not found. - -**/ -typedef -EFI_STATUS -(EFIAPI *EFI_HII_GLYPH_TO_BLT) ( - IN EFI_HII_PROTOCOL *This, - IN UINT8 *GlyphBuffer, - IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL Foreground, - IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL Background, - IN UINTN Count, - IN UINTN Width, - IN UINTN Height, - IN OUT EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer - ); - /** Allows a new string to be added to an already existing string package. =20 @@ -878,9 +831,6 @@ EFI_STATUS @param GetGlyph Translates a Unicode character into the corresponding font glyph. =20 - @param GlyphToBlt - Converts a glyph value into a format that is ready for a UGA BLT command. - @param NewString Allows a new string to be added to an already existing string package. =20 @@ -924,7 +874,6 @@ struct _EFI_HII_PROTOCOL { =20 EFI_HII_TEST_STRING TestString; EFI_HII_GET_GLYPH GetGlyph; - EFI_HII_GLYPH_TO_BLT GlyphToBlt; =20 EFI_HII_NEW_STRING NewString; EFI_HII_GET_PRI_LANGUAGES GetPrimaryLanguages; diff --git a/BaseTools/Source/C/Include/Protocol/UgaDraw.h b/BaseTools/Sour= ce/C/Include/Protocol/UgaDraw.h deleted file mode 100644 index 412b000aeb6b..000000000000 --- a/BaseTools/Source/C/Include/Protocol/UgaDraw.h +++ /dev/null @@ -1,161 +0,0 @@ -/** @file - UGA Draw protocol from the EFI 1.1 specification. - - Abstraction of a very simple graphics device. - - Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
- - SPDX-License-Identifier: BSD-2-Clause-Patent - -**/ - -#ifndef __UGA_DRAW_H__ -#define __UGA_DRAW_H__ - -#define EFI_UGA_DRAW_PROTOCOL_GUID \ - { \ - 0x982c298b, 0xf4fa, 0x41cb, {0xb8, 0x38, 0x77, 0xaa, 0x68, 0x8f, 0xb8,= 0x39 } \ - } - -typedef struct _EFI_UGA_DRAW_PROTOCOL EFI_UGA_DRAW_PROTOCOL; - -/** - Return the current video mode information. - - @param This Protocol instance pointer. - @param HorizontalResolution Current video horizontal resolution in pix= els - @param VerticalResolution Current video vertical resolution in pixels - @param ColorDepth Current video color depth in bits per pixel - @param RefreshRate Current video refresh rate in Hz. - - @retval EFI_SUCCESS Mode information returned. - @retval EFI_NOT_STARTED Video display is not initialized. Call Set= Mode () - @retval EFI_INVALID_PARAMETER One of the input args was NULL. - -**/ -typedef -EFI_STATUS -(EFIAPI *EFI_UGA_DRAW_PROTOCOL_GET_MODE) ( - IN EFI_UGA_DRAW_PROTOCOL *This, - OUT UINT32 *HorizontalResolution, - OUT UINT32 *VerticalResolution, - OUT UINT32 *ColorDepth, - OUT UINT32 *RefreshRate - ) -; - -/** - Return the current video mode information. - - @param This Protocol instance pointer. - @param HorizontalResolution Current video horizontal resolution in pixe= ls - @param VerticalResolution Current video vertical resolution in pixels - @param ColorDepth Current video color depth in bits per pixel - @param RefreshRate Current video refresh rate in Hz. - - @retval EFI_SUCCESS Mode information returned. - @retval EFI_NOT_STARTED Video display is not initialized. Call SetM= ode () - -**/ -typedef -EFI_STATUS -(EFIAPI *EFI_UGA_DRAW_PROTOCOL_SET_MODE) ( - IN EFI_UGA_DRAW_PROTOCOL *This, - IN UINT32 HorizontalResolution, - IN UINT32 VerticalResolution, - IN UINT32 ColorDepth, - IN UINT32 RefreshRate - ) -; - -typedef struct { - UINT8 Blue; - UINT8 Green; - UINT8 Red; - UINT8 Reserved; -} EFI_UGA_PIXEL; - -typedef union { - EFI_UGA_PIXEL Pixel; - UINT32 Raw; -} EFI_UGA_PIXEL_UNION; - -typedef enum { - EfiUgaVideoFill, - EfiUgaVideoToBltBuffer, - EfiUgaBltBufferToVideo, - EfiUgaVideoToVideo, - EfiUgaBltMax -} EFI_UGA_BLT_OPERATION; - -/** - Type specifying a pointer to a function to perform an UGA Blt operation. - - The following table defines actions for BltOperations: - - EfiUgaVideoFill - Write data from the BltBuffer pixel (SourceX= , SourceY) - directly to every pixel of the video display rectangle - (DestinationX, DestinationY) (DestinationX + Width, DestinationY + H= eight). - Only one pixel will be used from the BltBuffer. Delta is NOT used. - - EfiUgaVideoToBltBuffer - Read data from the video display recta= ngle - (SourceX, SourceY) (SourceX + Width, SourceY + Height) and place it = in - the BltBuffer rectangle (DestinationX, DestinationY ) - (DestinationX + Width, DestinationY + Height). If DestinationX or - DestinationY is not zero then Delta must be set to the length in byt= es - of a row in the BltBuffer. - - EfiUgaBltBufferToVideo - Write data from the BltBuffer rectang= le - (SourceX, SourceY) (SourceX + Width, SourceY + Height) directly to t= he - video display rectangle (DestinationX, DestinationY) - (DestinationX + Width, DestinationY + Height). If SourceX or SourceY= is - not zero then Delta must be set to the length in bytes of a row in t= he - BltBuffer. - - EfiUgaVideoToVideo - Copy from the video display rectangle (Sou= rceX, SourceY) - (SourceX + Width, SourceY + Height) .to the video display rectangle - (DestinationX, DestinationY) (DestinationX + Width, DestinationY + He= ight). - The BltBuffer and Delta are not used in this mode. - - - @param[in] This - Protocol instance pointer. - @param[in] BltBuffer - Buffer containing data to blit into video b= uffer. This - buffer has a size of Width*Height*sizeof(EF= I_UGA_PIXEL) - @param[in] BltOperation - Operation to perform on BlitBuffer and vide= o memory - @param[in] SourceX - X coordinate of source for the BltBuffer. - @param[in] SourceY - Y coordinate of source for the BltBuffer. - @param[in] DestinationX - X coordinate of destination for the BltBuff= er. - @param[in] DestinationY - Y coordinate of destination for the BltBuff= er. - @param[in] Width - Width of rectangle in BltBuffer in pixels. - @param[in] Height - Height of rectangle in BltBuffer in pixels. - @param[in] Delta - OPTIONAL - - @retval EFI_SUCCESS - The Blt operation completed. - @retval EFI_INVALID_PARAMETER - BltOperation is not valid. - @retval EFI_DEVICE_ERROR - A hardware error occurred writing to t= he video buffer. - ---*/ -typedef -EFI_STATUS -(EFIAPI *EFI_UGA_DRAW_PROTOCOL_BLT) ( - IN EFI_UGA_DRAW_PROTOCOL * This, - IN EFI_UGA_PIXEL * BltBuffer, OPTIONAL - IN EFI_UGA_BLT_OPERATION BltOperation, - IN UINTN SourceX, - IN UINTN SourceY, - IN UINTN DestinationX, - IN UINTN DestinationY, - IN UINTN Width, - IN UINTN Height, - IN UINTN Delta OPTIONAL - ); - -struct _EFI_UGA_DRAW_PROTOCOL { - EFI_UGA_DRAW_PROTOCOL_GET_MODE GetMode; - EFI_UGA_DRAW_PROTOCOL_SET_MODE SetMode; - EFI_UGA_DRAW_PROTOCOL_BLT Blt; -}; - -extern EFI_GUID gEfiUgaDrawProtocolGuid; - -#endif --=20 2.30.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85687): https://edk2.groups.io/g/devel/message/85687 Mute This Topic: https://groups.io/mt/88411255/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Fri Apr 26 14:18:48 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85688+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85688+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642121493; cv=none; d=zohomail.com; s=zohoarc; b=KWUBaUpy9mE7SWnxBAkUH8kqnE+VZArsVAGuHyi5Cta2V8zqrrzZ7b/AmoGD75TMwD5ILGK6WxBrp6m3GXzoW5cn2TBxSMPnI6MpagMlTT42LgM8lRxsEoTtAfStmO3Lpqtni5uUiCk1W/GYMD3c5NQLjvkgIe/lIFoc/A82F7s= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642121493; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=/n6qrkuEZd+mAjazTUUYe7LkqzpKhVQvzy8MsqZFnrU=; b=TF8rWEFt2v3CfoQf32mLLep0eLzMyaGFn/lREn4ohfn28k5lKcmSXL/TU4MouQv+yaa/PE1wYBz4exPASAVUsoPNLBjpQqHDi1M5EUU/NcckXemSPdCak6Nxfn8EF1FTs9XrYr4SM9LJ/2apDYAWcxRfIXfDc3pk+FsdmAkXJN0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85688+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1642121493611730.2886517203744; Thu, 13 Jan 2022 16:51:33 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id W40UYY1788612xtsPerdrvBi; Thu, 13 Jan 2022 16:51:33 -0800 X-Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.1082.1642121466955476862 for ; Thu, 13 Jan 2022 16:51:32 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10226"; a="241713939" X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="241713939" X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:32 -0800 X-IronPort-AV: E=Sophos;i="5.88,287,1635231600"; d="scan'208";a="475564829" X-Received: from guominji-mobl.ccr.corp.intel.com ([10.238.9.87]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2022 16:51:30 -0800 From: "Guomin Jiang" To: devel@edk2.groups.io Cc: GuoMinJ , Michael D Kinney , Liming Gao , Zhiguang Liu Subject: [edk2-devel] [PATCH 11/11] MdePkg: Remove All UGA Support Date: Fri, 14 Jan 2022 08:50:44 +0800 Message-Id: <20220114005044.1975-12-guomin.jiang@intel.com> In-Reply-To: <20220114005044.1975-1-guomin.jiang@intel.com> References: <20220114005044.1975-1-guomin.jiang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,guomin.jiang@intel.com X-Gm-Message-State: MX44RG5uoxbqsJJW9V2SsoEVx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642121493; bh=LUI15dCNHMauE/3e7ZemA2NIGBKp885kak2AWu9vBOY=; h=Cc:Date:From:Reply-To:Subject:To; b=JaTd53Y2ox3is0uTxtS8WqJVy6Shfrzczp627VohQnEJTh+JNTmJLOt32sZ4L0GTayK WsMGnSbeM0AxaKtqFV7WxOnBN6jOsLRXYvG0mZ/J2cbJ62JoSkUPJ6rMwYUVqGOgjsZhd AZ86BXOv2wFqap1IRqjf42qbvuYyVGCaRQc= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642121495416100001 Content-Type: text/plain; charset="utf-8" From: GuoMinJ REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2368 Remove All UGA Support in MdePkg. Signed-off-by: Guomin Jiang Cc: Michael D Kinney Cc: Liming Gao Cc: Zhiguang Liu --- MdePkg/MdePkg.dec | 12 -- MdePkg/MdePkg.dsc | 3 - MdePkg/Library/UefiLib/UefiLib.inf | 2 - MdePkg/Include/Protocol/UgaDraw.h | 159 ------------------- MdePkg/Include/Protocol/UgaIo.h | 189 ----------------------- MdePkg/Library/UefiLib/UefiLibInternal.h | 1 - MdePkg/Library/UefiLib/UefiLibPrint.c | 89 ----------- MdePkg/MdePkg.uni | 6 - 8 files changed, 461 deletions(-) delete mode 100644 MdePkg/Include/Protocol/UgaDraw.h delete mode 100644 MdePkg/Include/Protocol/UgaIo.h diff --git a/MdePkg/MdePkg.dec b/MdePkg/MdePkg.dec index 59b405928bf8..9960c44754bc 100644 --- a/MdePkg/MdePkg.dec +++ b/MdePkg/MdePkg.dec @@ -1446,12 +1446,6 @@ [Protocols] ## Include/Protocol/EdidOverride.h gEfiEdidOverrideProtocolGuid =3D { 0x48ECB431, 0xFB72, 0x45C0, { 0xA9,= 0x22, 0xF4, 0x58, 0xFE, 0x04, 0x0B, 0xD5 }} =20 - ## Include/Protocol/UgaIo.h - gEfiUgaIoProtocolGuid =3D { 0x61A4D49E, 0x6F68, 0x4F1B, { 0xB9,= 0x22, 0xA8, 0x6E, 0xED, 0x0B, 0x07, 0xA2 }} - - ## Include/Protocol/UgaDraw.h - gEfiUgaDrawProtocolGuid =3D { 0x982C298B, 0xF4FA, 0x41CB, { 0xB8,= 0x38, 0x77, 0xAA, 0x68, 0x8F, 0xB8, 0x39 }} - ## Include/Protocol/LoadedImage.h gEfiLoadedImageProtocolGuid =3D { 0x5B1B31A1, 0x9562, 0x11D2, { 0x8E,= 0x3F, 0x00, 0xA0, 0xC9, 0x69, 0x72, 0x3B }} =20 @@ -1942,12 +1936,6 @@ [PcdsFeatureFlag] # @Prompt Deprecate Global Variable LangCodes. gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultLangDeprecate|FALSE|BOOLE= AN|0x00000012 =20 - ## Indicates if UGA Draw Protocol is still consumed.

- # TRUE - Consume UGA Draw protocol.
- # FALSE - Does not consume UGA Draw protocol.
- # @Prompt Consume UGA Draw Protocol. - gEfiMdePkgTokenSpaceGuid.PcdUgaConsumeSupport|TRUE|BOOLEAN|0x00000027 - ## Indicates if a check will be made to see if a specified node is a mem= ber of linked list # in the following BaseLib functions: GetNextNode(), IsNull(), IsNodeAt= End(), SwapListEntries().

# TRUE - Verify a specified node is a member of linked list.
diff --git a/MdePkg/MdePkg.dsc b/MdePkg/MdePkg.dsc index a94959169b2f..939e1a7b5299 100644 --- a/MdePkg/MdePkg.dsc +++ b/MdePkg/MdePkg.dsc @@ -23,9 +23,6 @@ [Defines] =20 !include MdePkg/MdeLibs.dsc.inc =20 -[PcdsFeatureFlag] - gEfiMdePkgTokenSpaceGuid.PcdUgaConsumeSupport|TRUE - [PcdsFixedAtBuild] gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x0f gEfiMdePkgTokenSpaceGuid.PcdDebugPrintErrorLevel|0x80000000 diff --git a/MdePkg/Library/UefiLib/UefiLib.inf b/MdePkg/Library/UefiLib/Ue= fiLib.inf index 01ed92092da2..9f3863787833 100644 --- a/MdePkg/Library/UefiLib/UefiLib.inf +++ b/MdePkg/Library/UefiLib/UefiLib.inf @@ -67,7 +67,6 @@ [Protocols] gEfiGraphicsOutputProtocolGuid ## SOMETIMES_CONSUMES gEfiHiiFontProtocolGuid ## SOMETIMES_CONSUMES gEfiSimpleFileSystemProtocolGuid ## SOMETIMES_CONSUMES - gEfiUgaDrawProtocolGuid | gEfiMdePkgTokenSpaceGuid.PcdUgaConsumeSupport = ## SOMETIMES_CONSUMES # Consumes if gEfiGraphicsOutputProto= colGuid uninstalled gEfiComponentNameProtocolGuid | NOT gEfiMdePkgTokenSpaceGuid.PcdCompone= ntNameDisable ## SOMETIMES_PRODUCES # User chooses to produce it gEfiComponentName2ProtocolGuid | NOT gEfiMdePkgTokenSpaceGuid.PcdCompone= ntName2Disable ## SOMETIMES_PRODUCES # User chooses to produce it gEfiDriverConfigurationProtocolGuid ## SOMETI= MES_PRODUCES # User chooses to produce it @@ -84,5 +83,4 @@ [FeaturePcd] gEfiMdePkgTokenSpaceGuid.PcdComponentNameDisable ## CONSUMES gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnostics2Disable ## CONSUMES gEfiMdePkgTokenSpaceGuid.PcdComponentName2Disable ## CONSUMES - gEfiMdePkgTokenSpaceGuid.PcdUgaConsumeSupport ## CONSUMES =20 diff --git a/MdePkg/Include/Protocol/UgaDraw.h b/MdePkg/Include/Protocol/Ug= aDraw.h deleted file mode 100644 index 8d33bf873cad..000000000000 --- a/MdePkg/Include/Protocol/UgaDraw.h +++ /dev/null @@ -1,159 +0,0 @@ -/** @file - UGA Draw protocol from the EFI 1.10 specification. - - Abstraction of a very simple graphics device. - - Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
- SPDX-License-Identifier: BSD-2-Clause-Patent - -**/ - -#ifndef __UGA_DRAW_H__ -#define __UGA_DRAW_H__ - -#define EFI_UGA_DRAW_PROTOCOL_GUID \ - { \ - 0x982c298b, 0xf4fa, 0x41cb, {0xb8, 0x38, 0x77, 0xaa, 0x68, 0x8f, 0xb8,= 0x39 } \ - } - -typedef struct _EFI_UGA_DRAW_PROTOCOL EFI_UGA_DRAW_PROTOCOL; - -/** - Return the current video mode information. - - @param This The EFI_UGA_DRAW_PROTOCOL instance. - @param HorizontalResolution The size of video screen in pixels in the = X dimension. - @param VerticalResolution The size of video screen in pixels in the = Y dimension. - @param ColorDepth Number of bits per pixel, currently define= d to be 32. - @param RefreshRate The refresh rate of the monitor in Hertz. - - @retval EFI_SUCCESS Mode information returned. - @retval EFI_NOT_STARTED Video display is not initialized. Call Set= Mode () - @retval EFI_INVALID_PARAMETER One of the input args was NULL. - -**/ -typedef -EFI_STATUS -(EFIAPI *EFI_UGA_DRAW_PROTOCOL_GET_MODE)( - IN EFI_UGA_DRAW_PROTOCOL *This, - OUT UINT32 *HorizontalResolution, - OUT UINT32 *VerticalResolution, - OUT UINT32 *ColorDepth, - OUT UINT32 *RefreshRate - ); - -/** - Set the current video mode information. - - @param This The EFI_UGA_DRAW_PROTOCOL instance. - @param HorizontalResolution The size of video screen in pixels in the X= dimension. - @param VerticalResolution The size of video screen in pixels in the Y= dimension. - @param ColorDepth Number of bits per pixel, currently defined= to be 32. - @param RefreshRate The refresh rate of the monitor in Hertz. - - @retval EFI_SUCCESS Mode information returned. - @retval EFI_NOT_STARTED Video display is not initialized. Call SetM= ode () - -**/ -typedef -EFI_STATUS -(EFIAPI *EFI_UGA_DRAW_PROTOCOL_SET_MODE)( - IN EFI_UGA_DRAW_PROTOCOL *This, - IN UINT32 HorizontalResolution, - IN UINT32 VerticalResolution, - IN UINT32 ColorDepth, - IN UINT32 RefreshRate - ); - -typedef struct { - UINT8 Blue; - UINT8 Green; - UINT8 Red; - UINT8 Reserved; -} EFI_UGA_PIXEL; - -typedef union { - EFI_UGA_PIXEL Pixel; - UINT32 Raw; -} EFI_UGA_PIXEL_UNION; - -/// -/// Enumration value for actions of Blt operations. -/// -typedef enum { - EfiUgaVideoFill, ///< Write data from the BltBuffer pixel (Sou= rceX, SourceY) - ///< directly to every pixel of the video disp= lay rectangle - ///< (DestinationX, DestinationY) (Destination= X + Width, DestinationY + Height). - ///< Only one pixel will be used from the BltB= uffer. Delta is NOT used. - - EfiUgaVideoToBltBuffer, ///< Read data from the video display rectangle - ///< (SourceX, SourceY) (SourceX + Width, Sour= ceY + Height) and place it in - ///< the BltBuffer rectangle (DestinationX, De= stinationY ) - ///< (DestinationX + Width, DestinationY + Hei= ght). If DestinationX or - ///< DestinationY is not zero then Delta must = be set to the length in bytes - ///< of a row in the BltBuffer. - - EfiUgaBltBufferToVideo, ///< Write data from the BltBuffer rectangle - ///< (SourceX, SourceY) (SourceX + Width, Sour= ceY + Height) directly to the - ///< video display rectangle (DestinationX, De= stinationY) - ///< (DestinationX + Width, DestinationY + Hei= ght). If SourceX or SourceY is - ///< not zero then Delta must be set to the le= ngth in bytes of a row in the - ///< BltBuffer. - - EfiUgaVideoToVideo, ///< Copy from the video display rectangle (So= urceX, SourceY) - ///< (SourceX + Width, SourceY + Height) .to t= he video display rectangle - ///< (DestinationX, DestinationY) (Destination= X + Width, DestinationY + Height). - ///< The BltBuffer and Delta are not used in = this mode. - - EfiUgaBltMax ///< Maxmimum value for enumration value of Bl= t operation. If a Blt operation - ///< larger or equal to this enumration value,= it is invalid. -} EFI_UGA_BLT_OPERATION; - -/** - Blt a rectangle of pixels on the graphics screen. - - @param[in] This - Protocol instance pointer. - @param[in] BltBuffer - Buffer containing data to blit into video b= uffer. This - buffer has a size of Width*Height*sizeof(EF= I_UGA_PIXEL) - @param[in] BltOperation - Operation to perform on BlitBuffer and vide= o memory - @param[in] SourceX - X coordinate of source for the BltBuffer. - @param[in] SourceY - Y coordinate of source for the BltBuffer. - @param[in] DestinationX - X coordinate of destination for the BltBuff= er. - @param[in] DestinationY - Y coordinate of destination for the BltBuff= er. - @param[in] Width - Width of rectangle in BltBuffer in pixels. - @param[in] Height - Hight of rectangle in BltBuffer in pixels. - @param[in] Delta - OPTIONAL - - @retval EFI_SUCCESS - The Blt operation completed. - @retval EFI_INVALID_PARAMETER - BltOperation is not valid. - @retval EFI_DEVICE_ERROR - A hardware error occurred writting to = the video buffer. - -**/ -typedef -EFI_STATUS -(EFIAPI *EFI_UGA_DRAW_PROTOCOL_BLT)( - IN EFI_UGA_DRAW_PROTOCOL *This, - IN EFI_UGA_PIXEL *BltBuffer OPTIONAL, - IN EFI_UGA_BLT_OPERATION BltOperation, - IN UINTN SourceX, - IN UINTN SourceY, - IN UINTN DestinationX, - IN UINTN DestinationY, - IN UINTN Width, - IN UINTN Height, - IN UINTN Delta OPTIONAL - ); - -/// -/// This protocol provides a basic abstraction to set video modes and -/// copy pixels to and from the graphics controller's frame buffer. -/// -struct _EFI_UGA_DRAW_PROTOCOL { - EFI_UGA_DRAW_PROTOCOL_GET_MODE GetMode; - EFI_UGA_DRAW_PROTOCOL_SET_MODE SetMode; - EFI_UGA_DRAW_PROTOCOL_BLT Blt; -}; - -extern EFI_GUID gEfiUgaDrawProtocolGuid; - -#endif diff --git a/MdePkg/Include/Protocol/UgaIo.h b/MdePkg/Include/Protocol/UgaI= o.h deleted file mode 100644 index ffc5b3abe9fa..000000000000 --- a/MdePkg/Include/Protocol/UgaIo.h +++ /dev/null @@ -1,189 +0,0 @@ -/** @file - UGA IO protocol from the EFI 1.10 specification. - - Abstraction of a very simple graphics device. - - Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
- SPDX-License-Identifier: BSD-2-Clause-Patent - -**/ - -#ifndef __UGA_IO_H__ -#define __UGA_IO_H__ - -#define EFI_UGA_IO_PROTOCOL_GUID \ - { 0x61a4d49e, 0x6f68, 0x4f1b, { 0xb9, 0x22, 0xa8, 0x6e, 0xed, 0xb, 0x7, = 0xa2 } } - -typedef struct _EFI_UGA_IO_PROTOCOL EFI_UGA_IO_PROTOCOL; - -typedef UINT32 UGA_STATUS; - -typedef enum { - UgaDtParentBus =3D 1, - UgaDtGraphicsController, - UgaDtOutputController, - UgaDtOutputPort, - UgaDtOther -} UGA_DEVICE_TYPE, *PUGA_DEVICE_TYPE; - -typedef UINT32 UGA_DEVICE_ID, *PUGA_DEVICE_ID; - -typedef struct { - UGA_DEVICE_TYPE deviceType; - UGA_DEVICE_ID deviceId; - UINT32 ui32DeviceContextSize; - UINT32 ui32SharedContextSize; -} UGA_DEVICE_DATA, *PUGA_DEVICE_DATA; - -typedef struct _UGA_DEVICE { - VOID *pvDeviceContext; - VOID *pvSharedContext; - VOID *pvRunTimeContext; - struct _UGA_DEVICE *pParentDevice; - VOID *pvBusIoServices; - VOID *pvStdIoServices; - UGA_DEVICE_DATA deviceData; -} UGA_DEVICE, *PUGA_DEVICE; - -typedef enum { - UgaIoGetVersion =3D 1, - UgaIoGetChildDevice, - UgaIoStartDevice, - UgaIoStopDevice, - UgaIoFlushDevice, - UgaIoResetDevice, - UgaIoGetDeviceState, - UgaIoSetDeviceState, - UgaIoSetPowerState, - UgaIoGetMemoryConfiguration, - UgaIoSetVideoMode, - UgaIoCopyRectangle, - UgaIoGetEdidSegment, - UgaIoDeviceChannelOpen, - UgaIoDeviceChannelClose, - UgaIoDeviceChannelRead, - UgaIoDeviceChannelWrite, - UgaIoGetPersistentDataSize, - UgaIoGetPersistentData, - UgaIoSetPersistentData, - UgaIoGetDevicePropertySize, - UgaIoGetDeviceProperty, - UgaIoBtPrivateInterface -} UGA_IO_REQUEST_CODE, *PUGA_IO_REQUEST_CODE; - -typedef struct { - IN UGA_IO_REQUEST_CODE ioRequestCode; - IN VOID *pvInBuffer; - IN UINT64 ui64InBufferSize; - OUT VOID *pvOutBuffer; - IN UINT64 ui64OutBufferSize; - OUT UINT64 ui64BytesReturned; -} UGA_IO_REQUEST, *PUGA_IO_REQUEST; - -/** - Dynamically allocate storage for a child UGA_DEVICE. - - @param[in] This The EFI_UGA_IO_PROTOCOL instance. - @param[in] ParentDevice ParentDevice specifies a pointer to the p= arent device of Device. - @param[in] DeviceData A pointer to UGA_DEVICE_DATA returned fro= m a call to DispatchService() - with a UGA_DEVICE of Parent and an IoRequ= est of type UgaIoGetChildDevice. - @param[in] RunTimeContext Context to associate with Device. - @param[out] Device The Device returns a dynamically allocate= d child UGA_DEVICE object - for ParentDevice. The caller is responsib= le for deleting Device. - - - @retval EFI_SUCCESS Device was returned. - @retval EFI_INVALID_PARAMETER One of the arguments was not valid. - @retval EFI_DEVICE_ERROR The device had an error and could not com= plete the request. - -**/ -typedef -EFI_STATUS -(EFIAPI *EFI_UGA_IO_PROTOCOL_CREATE_DEVICE)( - IN EFI_UGA_IO_PROTOCOL *This, - IN UGA_DEVICE *ParentDevice, - IN UGA_DEVICE_DATA *DeviceData, - IN VOID *RunTimeContext, - OUT UGA_DEVICE **Device - ); - -/** - Delete a dynamically allocated child UGA_DEVICE object that was allocate= d via CreateDevice(). - - @param[in] This The EFI_UGA_IO_PROTOCOL instance. Type EF= I_UGA_IO_PROTOCOL is - defined in Section 10.7. - @param[in] Device The Device points to a UGA_DEVICE object = that was dynamically - allocated via a CreateDevice() call. - - - @retval EFI_SUCCESS Device was returned. - @retval EFI_INVALID_PARAMETER The Device was not allocated via CreateDe= vice(). - -**/ -typedef -EFI_STATUS -(EFIAPI *EFI_UGA_IO_PROTOCOL_DELETE_DEVICE)( - IN EFI_UGA_IO_PROTOCOL *This, - IN UGA_DEVICE *Device - ); - -/** - This is the main UGA service dispatch routine for all UGA_IO_REQUEST s. - - @param pDevice pDevice specifies a pointer to a device object associated= with a - device enumerated by a pIoRequest->ioRequestCode of type - UgaIoGetChildDevice. The root device for the EFI_UGA_IO_P= ROTOCOL - is represented by pDevice being set to NULL. - - @param pIoRequest - pIoRequest points to a caller allocated buffer that conta= ins data - defined by pIoRequest->ioRequestCode. See Related Definit= ions for - a definition of UGA_IO_REQUEST_CODE s and their associate= d data - structures. - - @return UGA_STATUS - -**/ -typedef UGA_STATUS -(EFIAPI *PUGA_FW_SERVICE_DISPATCH)( - IN PUGA_DEVICE pDevice, - IN OUT PUGA_IO_REQUEST pIoRequest - ); - -/// -/// Provides a basic abstraction to send I/O requests to the graphics devi= ce and any of its children. -/// -struct _EFI_UGA_IO_PROTOCOL { - EFI_UGA_IO_PROTOCOL_CREATE_DEVICE CreateDevice; - EFI_UGA_IO_PROTOCOL_DELETE_DEVICE DeleteDevice; - PUGA_FW_SERVICE_DISPATCH DispatchService; -}; - -extern EFI_GUID gEfiUgaIoProtocolGuid; - -// -// Data structure that is stored in the EFI Configuration Table with the -// EFI_UGA_IO_PROTOCOL_GUID. The option ROMs listed in this table may have -// EBC UGA drivers. -// -typedef struct { - UINT32 Version; - UINT32 HeaderSize; - UINT32 SizeOfEntries; - UINT32 NumberOfEntries; -} EFI_DRIVER_OS_HANDOFF_HEADER; - -typedef enum { - EfiUgaDriverFromPciRom, - EfiUgaDriverFromSystem, - EfiDriverHandoffMax -} EFI_DRIVER_HANOFF_ENUM; - -typedef struct { - EFI_DRIVER_HANOFF_ENUM Type; - EFI_DEVICE_PATH_PROTOCOL *DevicePath; - VOID *PciRomImage; - UINT64 PciRomSize; -} EFI_DRIVER_OS_HANDOFF; - -#endif diff --git a/MdePkg/Library/UefiLib/UefiLibInternal.h b/MdePkg/Library/Uefi= Lib/UefiLibInternal.h index 4365282cf213..b98f66e110c9 100644 --- a/MdePkg/Library/UefiLib/UefiLibInternal.h +++ b/MdePkg/Library/UefiLib/UefiLibInternal.h @@ -18,7 +18,6 @@ #include #include #include -#include #include =20 #include diff --git a/MdePkg/Library/UefiLib/UefiLibPrint.c b/MdePkg/Library/UefiLib= /UefiLibPrint.c index 39edeb7283dd..2189ef87b4f0 100644 --- a/MdePkg/Library/UefiLib/UefiLibPrint.c +++ b/MdePkg/Library/UefiLib/UefiLibPrint.c @@ -344,20 +344,14 @@ InternalPrintGraphic ( EFI_STATUS Status; UINT32 HorizontalResolution; UINT32 VerticalResolution; - UINT32 ColorDepth; - UINT32 RefreshRate; EFI_HII_FONT_PROTOCOL *HiiFont; EFI_IMAGE_OUTPUT *Blt; EFI_FONT_DISPLAY_INFO FontInfo; EFI_HII_ROW_INFO *RowInfoArray; UINTN RowInfoArraySize; EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput; - EFI_UGA_DRAW_PROTOCOL *UgaDraw; EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *Sto; EFI_HANDLE ConsoleHandle; - UINTN Width; - UINTN Height; - UINTN Delta; =20 HorizontalResolution =3D 0; VerticalResolution =3D 0; @@ -374,20 +368,6 @@ InternalPrintGraphic ( (VOID **)&GraphicsOutput ); =20 - UgaDraw =3D NULL; - if (EFI_ERROR (Status) && FeaturePcdGet (PcdUgaConsumeSupport)) { - // - // If no GOP available, try to open UGA Draw protocol if supported. - // - GraphicsOutput =3D NULL; - - Status =3D gBS->HandleProtocol ( - ConsoleHandle, - &gEfiUgaDrawProtocolGuid, - (VOID **)&UgaDraw - ); - } - if (EFI_ERROR (Status)) { goto Error; } @@ -405,8 +385,6 @@ InternalPrintGraphic ( if (GraphicsOutput !=3D NULL) { HorizontalResolution =3D GraphicsOutput->Mode->Info->HorizontalResolut= ion; VerticalResolution =3D GraphicsOutput->Mode->Info->VerticalResolutio= n; - } else if ((UgaDraw !=3D NULL) && FeaturePcdGet (PcdUgaConsumeSupport)) { - UgaDraw->GetMode (UgaDraw, &HorizontalResolution, &VerticalResolution,= &ColorDepth, &RefreshRate); } else { goto Error; } @@ -466,73 +444,6 @@ InternalPrintGraphic ( if (EFI_ERROR (Status)) { goto Error; } - } else if (FeaturePcdGet (PcdUgaConsumeSupport)) { - ASSERT (UgaDraw !=3D NULL); - - // - // Ensure Width * Height * sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL) does= n't overflow. - // - if (Blt->Width > DivU64x32 (MAX_UINTN, Blt->Height * sizeof (EFI_GRAPH= ICS_OUTPUT_BLT_PIXEL))) { - goto Error; - } - - Blt->Image.Bitmap =3D AllocateZeroPool ((UINT32)Blt->Width * Blt->Heig= ht * sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL)); - ASSERT (Blt->Image.Bitmap !=3D NULL); - - // - // StringToImage only support blt'ing image to device using GOP proto= col. If GOP is not supported in this platform, - // we ask StringToImage to print the string to blt buffer, then blt t= o device using UgaDraw. - // - Status =3D HiiFont->StringToImage ( - HiiFont, - EFI_HII_IGNORE_IF_NO_GLYPH | EFI_HII_OUT_FLAG_CLIP= | - EFI_HII_OUT_FLAG_CLIP_CLEAN_X | EFI_HII_OUT_FLAG_C= LIP_CLEAN_Y | - EFI_HII_IGNORE_LINE_BREAK, - Buffer, - &FontInfo, - &Blt, - PointX, - PointY, - &RowInfoArray, - &RowInfoArraySize, - NULL - ); - - if (!EFI_ERROR (Status)) { - ASSERT (RowInfoArray !=3D NULL); - // - // Explicit Line break characters are ignored, so the updated parame= ter RowInfoArraySize by StringToImage will - // always be 1 or 0 (if there is no valid Unicode Char can be printe= d). ASSERT here to make sure. - // - ASSERT (RowInfoArraySize <=3D 1); - - if (RowInfoArraySize !=3D 0) { - Width =3D RowInfoArray[0].LineWidth; - Height =3D RowInfoArray[0].LineHeight; - Delta =3D Blt->Width * sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL); - } else { - Width =3D 0; - Height =3D 0; - Delta =3D 0; - } - - Status =3D UgaDraw->Blt ( - UgaDraw, - (EFI_UGA_PIXEL *)Blt->Image.Bitmap, - EfiUgaBltBufferToVideo, - PointX, - PointY, - PointX, - PointY, - Width, - Height, - Delta - ); - } else { - goto Error; - } - - FreePool (Blt->Image.Bitmap); } else { goto Error; } diff --git a/MdePkg/MdePkg.uni b/MdePkg/MdePkg.uni index 5c1fa24065c7..7b00a396848c 100644 --- a/MdePkg/MdePkg.uni +++ b/MdePkg/MdePkg.uni @@ -373,12 +373,6 @@ = "TRUE - Deprecate global variable LangCodes.
\n" = "FALSE - Does not deprecate global variable LangCodes.=
" =20 -#string STR_gEfiMdePkgTokenSpaceGuid_PcdUgaConsumeSupport_PROMPT #languag= e en-US "Consume UGA Draw Protocol" - -#string STR_gEfiMdePkgTokenSpaceGuid_PcdUgaConsumeSupport_HELP #language = en-US "Indicates if UGA Draw Protocol is still consumed.

\n" - = "TRUE - Consume UGA Draw protocol.
\n" - = "FALSE - Does not consume UGA Draw protocol.
" - #string STR_gEfiMdePkgTokenSpaceGuid_PcdVerifyNodeInList_PROMPT #language= en-US "Verify Node In List" =20 #string STR_gEfiMdePkgTokenSpaceGuid_PcdVerifyNodeInList_HELP #language e= n-US "Indicates if a check will be made to see if a specified node is a mem= ber of linked list in the following BaseLib functions: GetNextNode(), IsNul= l(), IsNodeAtEnd(), SwapListEntries().

\n" --=20 2.30.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85688): https://edk2.groups.io/g/devel/message/85688 Mute This Topic: https://groups.io/mt/88411256/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-