From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2607:f8b0:400e:c05::244; helo=mail-pg0-x244.google.com; envelope-from=haojian.zhuang@linaro.org; receiver=edk2-devel@lists.01.org Received: from mail-pg0-x244.google.com (mail-pg0-x244.google.com [IPv6:2607:f8b0:400e:c05::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 6148222683917 for ; Thu, 19 Apr 2018 03:42:53 -0700 (PDT) Received: by mail-pg0-x244.google.com with SMTP id b9so2314066pgf.6 for ; Thu, 19 Apr 2018 03:42:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=nWzE/yVjWgb9tMgaDKk+AT5Pjo2wQY9FlSluKJKdKDc=; b=SKWFlTrQ5ARlsU24t1lo9oWx+QtdWKH8L0T7QUCiAgz10Pq9OW+/LbmjFG3IK/JHHz rDNTY8vra/URxIAOj68kUpt6EhLJPmafMOaqEVNR62wWZN8pJzFOTzflS3E1QASh07XN WEzQCQvgXkfZo/SzEYWR6QXTTZwQSYu2nIv4U= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=nWzE/yVjWgb9tMgaDKk+AT5Pjo2wQY9FlSluKJKdKDc=; b=Vzk48B6sKds8Ini0h7DYQTrgpvqMiqYg3c/PHI+CrkdCKrLqfQ13V+laWxALPkAz6J lMPHrQJsisOon7O4kH13iwsKplVMJOc+fNhsFhLogQcOiS9rz/Wf3FWBm6SJRx9sF6Ms +YqAU51JMUSP8etK20dxeFMhTlU+Nft7OsxkRopuScjmETu7LMvjMbYXvI01orPkKCO9 IAyB+B55zF0DSGycc/4ARa3jyn7jGLHbTABX9Ueq3S4j8lwvWgME+cgXOZyF1LaCxWM8 7ewUIMgL6o9IASUATD4ANOAjCkX7SFktBQjoCU4t9Y3HG+Ja82QPIIWFkEwUs8YKzXn5 nnCQ== X-Gm-Message-State: ALQs6tDyssnGeKmPO3ZFkWZIycYuofOP58lDmSoI0TBlfuz1+hwbqV/p jAbbfuhEjSeOF1mOBLg007XDHhi+EPo= X-Google-Smtp-Source: AIpwx4+h+KIqCZHQU1GZpFzE8oCJrTaRIJBafR+k9TBjl/HY4z0iawINSsbvJYkRAl7CHIIv67Qhdg== X-Received: by 10.98.51.69 with SMTP id z66mr5410418pfz.0.1524134572770; Thu, 19 Apr 2018 03:42:52 -0700 (PDT) Received: from localhost.localdomain ([64.64.108.105]) by smtp.gmail.com with ESMTPSA id d4sm8593913pgc.43.2018.04.19.03.42.49 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 19 Apr 2018 03:42:51 -0700 (PDT) From: Haojian Zhuang To: edk2-devel@lists.01.org Cc: Haojian Zhuang , Laszlo Ersek , Leif Lindholm , Ard Biesheuvel Date: Thu, 19 Apr 2018 18:42:39 +0800 Message-Id: <1524134560-1245-2-git-send-email-haojian.zhuang@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1524134560-1245-1-git-send-email-haojian.zhuang@linaro.org> References: <1524134560-1245-1-git-send-email-haojian.zhuang@linaro.org> Subject: [PATCH v3 1/2] EmbeddedPkg: add platform boot manager protocol X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2018 10:42:53 -0000 Create the PlatformBootManagerProtocol that is used to add predefined boot options in platform driver. This interface will be used in ArmPkg/PlatformBootManagerLib. Cc: Laszlo Ersek Cc: Leif Lindholm Cc: Ard Biesheuvel Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Haojian Zhuang --- EmbeddedPkg/EmbeddedPkg.dec | 1 + EmbeddedPkg/Include/Protocol/PlatformBootManager.h | 46 ++++++++++++++++++++++ 2 files changed, 47 insertions(+) create mode 100644 EmbeddedPkg/Include/Protocol/PlatformBootManager.h diff --git a/EmbeddedPkg/EmbeddedPkg.dec b/EmbeddedPkg/EmbeddedPkg.dec index eb135340b173..9cd50738363b 100644 --- a/EmbeddedPkg/EmbeddedPkg.dec +++ b/EmbeddedPkg/EmbeddedPkg.dec @@ -81,6 +81,7 @@ [Protocols.common] gPlatformGpioProtocolGuid = { 0x52ce9845, 0x5af4, 0x43e2, {0xba, 0xfd, 0x23, 0x08, 0x12, 0x54, 0x7a, 0xc2 }} gAndroidBootImgProtocolGuid = { 0x9859bb19, 0x407c, 0x4f8b, {0xbc, 0xe1, 0xf8, 0xda, 0x65, 0x65, 0xf4, 0xa5 }} gPlatformVirtualKeyboardProtocolGuid = { 0x0e3606d2, 0x1dc3, 0x4e6f, { 0xbe, 0x65, 0x39, 0x49, 0x82, 0xa2, 0x65, 0x47 }} + gPlatformBootManagerProtocolGuid = { 0x7197c8a7, 0x6559, 0x4c93, { 0x93, 0xd5, 0x8a, 0x84, 0xf9, 0x88, 0x79, 0x8b }} [Ppis] gEdkiiEmbeddedGpioPpiGuid = { 0x21c3b115, 0x4e0b, 0x470c, { 0x85, 0xc7, 0xe1, 0x05, 0xa5, 0x75, 0xc9, 0x7b }} diff --git a/EmbeddedPkg/Include/Protocol/PlatformBootManager.h b/EmbeddedPkg/Include/Protocol/PlatformBootManager.h new file mode 100644 index 000000000000..8fd63c8b45d6 --- /dev/null +++ b/EmbeddedPkg/Include/Protocol/PlatformBootManager.h @@ -0,0 +1,46 @@ +/** @file + + Copyright (c) 2018, Linaro. All rights reserved.
+ + This program and the accompanying materials + are licensed and made available under the terms and conditions of the BSD License + which accompanies this distribution. The full text of the license may be found at + http://opensource.org/licenses/bsd-license.php + + THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, + WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. + +**/ + +#ifndef __PLATFORM_BOOT_MANAGER_PROTOCOL_H__ +#define __PLATFORM_BOOT_MANAGER_PROTOCOL_H__ + +// +// Protocol interface structure +// +typedef struct _PLATFORM_BOOT_MANAGER_PROTOCOL PLATFORM_BOOT_MANAGER_PROTOCOL; + +// +// Function Prototypes +// + +/* + Get predefined boot options for platform. + + @param[out] BootOptions An array of predefined boot options. + @param[out] BootKeys An array of predefined keys. +*/ +typedef +EFI_STATUS +(EFIAPI *GET_PLATFORM_BOOT_OPTIONS_AND_KEYS) ( + OUT EFI_BOOT_MANAGER_LOAD_OPTION **BootOptions, + OUT EFI_INPUT_KEY **BootKeys + ); + +struct _PLATFORM_BOOT_MANAGER_PROTOCOL { + GET_PLATFORM_BOOT_OPTIONS_AND_KEYS GetPlatformBootOptionsAndKeys; +}; + +extern EFI_GUID gPlatformBootManagerProtocolGuid; + +#endif /* __PLATFORM_BOOT_MANAGER_PROTOCOL_H__ */ -- 2.7.4