get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/812138/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 812138,
    "url": "http://patchwork.ozlabs.org/api/patches/812138/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/uboot/patch/20170910132236.14318-3-robdclark@gmail.com/",
    "project": {
        "id": 18,
        "url": "http://patchwork.ozlabs.org/api/projects/18/?format=api",
        "name": "U-Boot",
        "link_name": "uboot",
        "list_id": "u-boot.lists.denx.de",
        "list_email": "u-boot@lists.denx.de",
        "web_url": null,
        "scm_url": null,
        "webscm_url": null,
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20170910132236.14318-3-robdclark@gmail.com>",
    "list_archive_url": null,
    "date": "2017-09-10T13:22:23",
    "name": "[U-Boot,v1,02/12] efi_loader: add stub HII protocols",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "bf3f4071ddae77fa865c5e6aa37004d33764cd72",
    "submitter": {
        "id": 18760,
        "url": "http://patchwork.ozlabs.org/api/people/18760/?format=api",
        "name": "Rob Clark",
        "email": "robdclark@gmail.com"
    },
    "delegate": {
        "id": 3400,
        "url": "http://patchwork.ozlabs.org/api/users/3400/?format=api",
        "username": "agraf",
        "first_name": "Alexander",
        "last_name": "Graf",
        "email": "agraf@suse.de"
    },
    "mbox": "http://patchwork.ozlabs.org/project/uboot/patch/20170910132236.14318-3-robdclark@gmail.com/mbox/",
    "series": [
        {
            "id": 2401,
            "url": "http://patchwork.ozlabs.org/api/series/2401/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/uboot/list/?series=2401",
            "date": "2017-09-10T13:22:21",
            "name": "efi_loader+video: support for Shell.efi",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/2401/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/812138/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/812138/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<u-boot-bounces@lists.denx.de>",
        "X-Original-To": "incoming@patchwork.ozlabs.org",
        "Delivered-To": "patchwork-incoming@bilbo.ozlabs.org",
        "Authentication-Results": [
            "ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=lists.denx.de\n\t(client-ip=81.169.180.215; helo=lists.denx.de;\n\tenvelope-from=u-boot-bounces@lists.denx.de;\n\treceiver=<UNKNOWN>)",
            "ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=gmail.com header.i=@gmail.com\n\theader.b=\"c3sdRb3v\"; dkim-atps=neutral"
        ],
        "Received": [
            "from lists.denx.de (dione.denx.de [81.169.180.215])\n\tby ozlabs.org (Postfix) with ESMTP id 3xqsFS08WHz9s83\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSun, 10 Sep 2017 23:23:23 +1000 (AEST)",
            "by lists.denx.de (Postfix, from userid 105)\n\tid BFDC3C21EA9; Sun, 10 Sep 2017 13:23:05 +0000 (UTC)",
            "from lists.denx.de (localhost [IPv6:::1])\n\tby lists.denx.de (Postfix) with ESMTP id 281EEC21E57;\n\tSun, 10 Sep 2017 13:22:58 +0000 (UTC)",
            "by lists.denx.de (Postfix, from userid 105)\n\tid 0B39DC21F0A; Sun, 10 Sep 2017 13:22:53 +0000 (UTC)",
            "from mail-qk0-f195.google.com (mail-qk0-f195.google.com\n\t[209.85.220.195])\n\tby lists.denx.de (Postfix) with ESMTPS id A51C1C21E97\n\tfor <u-boot@lists.denx.de>; Sun, 10 Sep 2017 13:22:49 +0000 (UTC)",
            "by mail-qk0-f195.google.com with SMTP id r66so3910003qke.4\n\tfor <u-boot@lists.denx.de>; Sun, 10 Sep 2017 06:22:49 -0700 (PDT)",
            "from localhost ([2601:184:4780:aac0:25f8:dd96:a084:785a])\n\tby smtp.gmail.com with ESMTPSA id\n\tp7sm4422690qke.78.2017.09.10.06.22.46\n\t(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);\n\tSun, 10 Sep 2017 06:22:47 -0700 (PDT)"
        ],
        "X-Spam-Checker-Version": "SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de",
        "X-Spam-Level": "",
        "X-Spam-Status": "No, score=-0.0 required=5.0 tests=FREEMAIL_FROM,\n\tRCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,\n\tT_DKIM_INVALID\n\tautolearn=unavailable autolearn_force=no version=3.4.0",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;\n\th=from:to:cc:subject:date:message-id:in-reply-to:references;\n\tbh=RtPQLWKaPJcVpsEQKBXFnRvuG0rJRVtnOnItYqmzEuQ=;\n\tb=c3sdRb3v9rYMrP+6AfuezFgaGOaHzCUybvDA75chpZuhSZP7ZVCaI+WUu0m2jO2J1/\n\tkPCdj7+6g0FaJQV+/0OfiTM2nCgsXf69fM4TLhXEFuWi3DDXoOoAUYVWoyLrcNxKPX9d\n\tyzmwrpSItIcVKTlQf5FAl8A1AERLVSbauAST9XQLg2ToPWNSs6qIHYy5b1sbIBZebwDn\n\toJLmac9A1iBpZITVohmM4GBeigQxrSg64Mrs8MlmgQBrKwYbnwNDI3sIZMnNn7r22u+z\n\tcazjVSc6n0sdZRzfwuRAN50Qx4Ak/EX+QlZ/DZuvMGgFyC0dKzA1Gxhwx6h/SDJKTNVU\n\tOpLA==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n\t:references;\n\tbh=RtPQLWKaPJcVpsEQKBXFnRvuG0rJRVtnOnItYqmzEuQ=;\n\tb=dXGpTmgawxYustKmDjFvJBX2HU0o3a1Oit2wq3Xgf4R0chSVQD/EMJCGaJCanoT9I1\n\twfCjKiGJeNN0UPSLj9ptup9u4MnkvlM+aR6qjzkKOddrGpWk+zz0hygNyf2xh6yFaXVC\n\tA37i4qiaV9AAEo3o7DD6TX/qEWYehImKwpIjT5zz9u4QjeahmKgVj4LZoNMAGY+m9c47\n\tVB+zFELs+g6jrR19MftCBhy4guEbZ6RWtu8ZpS1hY9JiYNaBH2PEnyGSt5rhhkOfP55d\n\t1QMS81dzFwAHNQkYXPh+bJuUyjZsmOgs2u19urKYHFaWnquomLrD0u4n7YnWgj3Qw8fO\n\tAN+w==",
        "X-Gm-Message-State": "AHPjjUgqECY8tz0VYlwHNIwgtyWaPXc3dExpd94zyZ5It+wq3Dg/gC61\n\tG8W9tDYBw6volaB5FJk=",
        "X-Google-Smtp-Source": "AOwi7QDLfvYIj7/SDKKyF8vryzQNiRpcjIulVnNqCU9q1+sPIH0V45elGjYknIh1ELMPyD5mk8qcjA==",
        "X-Received": "by 10.55.104.138 with SMTP id\n\td132mr12032680qkc.151.1505049768178; \n\tSun, 10 Sep 2017 06:22:48 -0700 (PDT)",
        "From": "Rob Clark <robdclark@gmail.com>",
        "To": "U-Boot Mailing List <u-boot@lists.denx.de>",
        "Date": "Sun, 10 Sep 2017 09:22:23 -0400",
        "Message-Id": "<20170910132236.14318-3-robdclark@gmail.com>",
        "X-Mailer": "git-send-email 2.13.5",
        "In-Reply-To": "<20170910132236.14318-1-robdclark@gmail.com>",
        "References": "<20170910132236.14318-1-robdclark@gmail.com>",
        "Cc": "Heinrich Schuchardt <xypron.glpk@gmx.de>, Peter Jones <pjones@redhat.com>,\n\tLeif Lindholm <leif.lindholm@linaro.org>",
        "Subject": "[U-Boot] [PATCH v1 02/12] efi_loader: add stub HII protocols",
        "X-BeenThere": "u-boot@lists.denx.de",
        "X-Mailman-Version": "2.1.18",
        "Precedence": "list",
        "List-Id": "U-Boot discussion <u-boot.lists.denx.de>",
        "List-Unsubscribe": "<https://lists.denx.de/options/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>",
        "List-Archive": "<http://lists.denx.de/pipermail/u-boot/>",
        "List-Post": "<mailto:u-boot@lists.denx.de>",
        "List-Help": "<mailto:u-boot-request@lists.denx.de?subject=help>",
        "List-Subscribe": "<https://lists.denx.de/listinfo/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=subscribe>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=\"utf-8\"",
        "Content-Transfer-Encoding": "base64",
        "Errors-To": "u-boot-bounces@lists.denx.de",
        "Sender": "\"U-Boot\" <u-boot-bounces@lists.denx.de>"
    },
    "content": "From: Leif Lindholm <leif.lindholm@linaro.org>\n\nEfiHiiConfigRoutingProtocolGuid\nEfiHiiDatabaseProtocol\nEfiHiiStringProtocol\n\nSigned-off-by: Leif Lindholm <leif.lindholm@linaro.org>\n---\n include/efi_api.h             | 204 ++++++++++++++++++++++++++++\n include/efi_loader.h          |   6 +\n lib/efi_loader/Makefile       |   2 +-\n lib/efi_loader/efi_boottime.c |   9 ++\n lib/efi_loader/efi_hii.c      | 303 ++++++++++++++++++++++++++++++++++++++++++\n 5 files changed, 523 insertions(+), 1 deletion(-)\n create mode 100644 lib/efi_loader/efi_hii.c",
    "diff": "diff --git a/include/efi_api.h b/include/efi_api.h\nindex 57468dd972..932a3429a8 100644\n--- a/include/efi_api.h\n+++ b/include/efi_api.h\n@@ -536,6 +536,210 @@ struct efi_device_path_utilities_protocol\n \t\tconst struct efi_device_path *device_path);\n };\n \n+#define EFI_HII_CONFIG_ROUTING_PROTOCOL_GUID \\\n+\tEFI_GUID(0x587e72d7, 0xcc50, 0x4f79, \\\n+\t\t 0x82, 0x09, 0xca, 0x29, 0x1f, 0xc1, 0xa1, 0x0f)\n+\n+struct efi_hii_config_routing_protocol\n+{\n+\tefi_status_t(EFIAPI *extract_config)(\n+\t\tconst struct efi_hii_config_routing_protocol *this,\n+\t\tconst efi_string_t request,\n+\t\tefi_string_t *progress,\n+\t\tefi_string_t *results);\n+\tefi_status_t(EFIAPI *export_config)(\n+\t\tconst struct efi_hii_config_routing_protocol *this,\n+\t\tefi_string_t *results);\n+\tefi_status_t(EFIAPI *route_config)(\n+\t\tconst struct efi_hii_config_routing_protocol *this,\n+\t\tconst efi_string_t configuration,\n+\t\tefi_string_t *progress);\n+\tefi_status_t(EFIAPI *block_to_config)(\n+\t\tconst struct efi_hii_config_routing_protocol *this,\n+\t\tconst efi_string_t config_request,\n+\t\tconst uint8_t *block,\n+\t\tconst UINTN block_size,\n+\t\tefi_string_t *config,\n+\t\tefi_string_t *progress);\n+\tefi_status_t(EFIAPI *config_to_block)(\n+\t\tconst struct efi_hii_config_routing_protocol *this,\n+\t\tconst efi_string_t config_resp,\n+\t\tconst uint8_t *block,\n+\t\tconst UINTN *block_size,\n+\t\tefi_string_t *progress);\n+\tefi_status_t(EFIAPI *get_alt_config)(\n+\t\tconst struct efi_hii_config_routing_protocol *this,\n+\t\tconst efi_string_t config_resp,\n+\t\tconst efi_guid_t *guid,\n+\t\tconst efi_string_t name,\n+\t\tconst struct efi_device_path *device_path,\n+\t\tconst efi_string_t alt_cfg_id,\n+\t\tefi_string_t *alt_cfg_resp);\n+};\n+\n+#define EFI_HII_DATABASE_PROTOCOL_GUID\t     \\\n+\tEFI_GUID(0xef9fc172, 0xa1b2, 0x4693, \\\n+\t\t 0xb3, 0x27, 0x6d, 0x32, 0xfc, 0x41, 0x60, 0x42)\n+\n+typedef enum {\n+\tEfiKeyLCtrl, EfiKeyA0, EfiKeyLAlt, EfiKeySpaceBar,\n+\tEfiKeyA2, EfiKeyA3, EfiKeyA4, EfiKeyRCtrl, EfiKeyLeftArrow,\n+\tEfiKeyDownArrow, EfiKeyRightArrow, EfiKeyZero,\n+\tEfiKeyPeriod, EfiKeyEnter, EfiKeyLShift, EfiKeyB0,\n+\tEfiKeyB1, EfiKeyB2, EfiKeyB3, EfiKeyB4, EfiKeyB5, EfiKeyB6,\n+\tEfiKeyB7, EfiKeyB8, EfiKeyB9, EfiKeyB10, EfiKeyRShift,\n+\tEfiKeyUpArrow, EfiKeyOne, EfiKeyTwo, EfiKeyThree,\n+\tEfiKeyCapsLock, EfiKeyC1, EfiKeyC2, EfiKeyC3, EfiKeyC4,\n+\tEfiKeyC5, EfiKeyC6, EfiKeyC7, EfiKeyC8, EfiKeyC9,\n+\tEfiKeyC10, EfiKeyC11, EfiKeyC12, EfiKeyFour, EfiKeyFive,\n+\tEfiKeySix, EfiKeyPlus, EfiKeyTab, EfiKeyD1, EfiKeyD2,\n+\tEfiKeyD3, EfiKeyD4, EfiKeyD5, EfiKeyD6, EfiKeyD7, EfiKeyD8,\n+\tEfiKeyD9, EfiKeyD10, EfiKeyD11, EfiKeyD12, EfiKeyD13,\n+\tEfiKeyDel, EfiKeyEnd, EfiKeyPgDn, EfiKeySeven, EfiKeyEight,\n+\tEfiKeyNine, EfiKeyE0, EfiKeyE1, EfiKeyE2, EfiKeyE3,\n+\tEfiKeyE4, EfiKeyE5, EfiKeyE6, EfiKeyE7, EfiKeyE8, EfiKeyE9,\n+\tEfiKeyE10, EfiKeyE11, EfiKeyE12, EfiKeyBackSpace,\n+\tEfiKeyIns, EfiKeyHome, EfiKeyPgUp, EfiKeyNLck, EfiKeySlash,\n+\tEfiKeyAsterisk, EfiKeyMinus, EfiKeyEsc, EfiKeyF1, EfiKeyF2,\n+\tEfiKeyF3, EfiKeyF4, EfiKeyF5, EfiKeyF6, EfiKeyF7, EfiKeyF8,\n+\tEfiKeyF9, EfiKeyF10, EfiKeyF11, EfiKeyF12, EfiKeyPrint,\n+\tEfiKeySLck, EfiKeyPause\n+} efi_key;\n+\n+struct efi_key_descriptor\n+{\n+\tefi_key key;\n+\tuint16_t unicode;\n+\tuint16_t shifted_unicode;\n+\tuint16_t alt_gr_unicode;\n+\tuint16_t shifted_alt_gr_unicode;\n+\tuint16_t modifier;\n+\tuint16_t affected_attribute;\n+};\n+\n+struct efi_hii_keyboard_layout\n+{\n+\tuint16_t layout_length;\n+\tefi_guid_t guid;\n+\tuint32_t layout_descriptor_string_offset;\n+\tuint8_t descriptor_count;\n+\tstruct efi_key_descriptor descriptors[];\n+};\n+\n+struct efi_hii_package_list_header\n+{\n+\tefi_guid_t package_list_guid;\n+\tuint32_t package_length;\n+};\n+\n+typedef void *efi_hii_handle_t;\n+\n+struct efi_hii_database_protocol\n+{\n+\tefi_status_t(EFIAPI *new_package_list)(\n+\t\tconst struct efi_hii_database_protocol *this,\n+\t\tconst struct efi_hii_package_list_header *package_list,\n+\t\tconst efi_handle_t driver_handle,\n+\t\tefi_hii_handle_t *handle);\n+\tefi_status_t(EFIAPI *remove_package_list)(\n+\t\tconst struct efi_hii_database_protocol *this,\n+\t\tefi_hii_handle_t handle);\n+\tefi_status_t(EFIAPI *update_package_list)(\n+\t\tconst struct efi_hii_database_protocol *this,\n+\t\tefi_hii_handle_t handle,\n+\t\tconst struct efi_hii_package_list_header *package_list);\n+\tefi_status_t(EFIAPI *list_package_lists)(\n+\t\tconst struct efi_hii_database_protocol *this,\n+\t\tuint8_t package_type,\n+\t\tconst efi_guid_t *package_guid,\n+\t\tUINTN *handle_buffer_length,\n+\t\tefi_hii_handle_t *handle);\n+\tefi_status_t(EFIAPI *export_package_lists)(\n+\t\tconst struct efi_hii_database_protocol *this,\n+\t\tefi_hii_handle_t handle,\n+\t\tUINTN *buffer_size,\n+\t\tstruct efi_hii_package_list_header *buffer);\n+\tefi_status_t(EFIAPI *register_package_notify)(\n+\t\tconst struct efi_hii_database_protocol *this,\n+\t\tuint8_t package_type,\n+\t\tconst efi_guid_t *package_guid,\n+\t\tconst void *package_notify_fn,\n+\t\tUINTN notify_type,\n+\t\tefi_handle_t *notify_handle);\n+\tefi_status_t(EFIAPI *unregister_package_notify)(\n+\t\tconst struct efi_hii_database_protocol *this,\n+\t\tefi_handle_t notification_handle\n+\t\t);\n+\tefi_status_t(EFIAPI *find_keyboard_layouts)(\n+\t\tconst struct efi_hii_database_protocol *this,\n+\t\tuint16_t *key_guid_buffer_length,\n+\t\tefi_guid_t *key_guid_buffer);\n+\tefi_status_t(EFIAPI *get_keyboard_layout)(\n+\t\tconst struct efi_hii_database_protocol *this,\n+\t\tefi_guid_t *key_guid,\n+\t\tuint16_t *keyboard_layout_length,\n+\t\tstruct efi_hii_keyboard_layout *keyboard_layout);\n+\tefi_status_t(EFIAPI *set_keyboard_layout)(\n+\t\tconst struct efi_hii_database_protocol *this,\n+\t\tefi_guid_t *key_guid);\n+\tefi_status_t(EFIAPI *get_package_list_handle)(\n+\t\tconst struct efi_hii_database_protocol *this,\n+\t\tefi_hii_handle_t package_list_handle,\n+\t\tefi_handle_t *driver_handle);\n+};\n+\n+#define EFI_HII_STRING_PROTOCOL_GUID \\\n+\tEFI_GUID(0x0fd96974, 0x23aa, 0x4cdc, \\\n+\t\t 0xb9, 0xcb, 0x98, 0xd1, 0x77, 0x50, 0x32, 0x2a)\n+\n+typedef uint32_t efi_hii_font_style_t;\n+typedef uint16_t efi_string_id_t;\n+\n+struct efi_font_info\n+{\n+\tefi_hii_font_style_t font_style;\n+\tuint16_t font_size;\n+\tuint16_t font_name[1];\n+};\n+\n+struct efi_hii_string_protocol\n+{\n+\tefi_status_t(EFIAPI *new_string)(\n+\t\tconst struct efi_hii_string_protocol *this,\n+\t\tefi_hii_handle_t package_list,\n+\t\tefi_string_id_t *string_id,\n+\t\tconst uint8_t *language,\n+\t\tconst uint16_t *language_name,\n+\t\tconst efi_string_t string,\n+\t\tconst struct efi_font_info *string_font_info);\n+\tefi_status_t(EFIAPI *get_string)(\n+\t\tconst struct efi_hii_string_protocol *this,\n+\t\tconst uint8_t *language,\n+\t\tefi_hii_handle_t package_list,\n+\t\tefi_string_id_t string_id,\n+\t\tefi_string_t string,\n+\t\tUINTN *string_size,\n+\t\tstruct efi_font_info **string_font_info);\n+\tefi_status_t(EFIAPI *set_string)(\n+\t\tconst struct efi_hii_string_protocol *this,\n+\t\tefi_hii_handle_t package_list,\n+\t\tefi_string_id_t string_id,\n+\t\tconst uint8_t *language,\n+\t\tconst efi_string_t string,\n+\t\tconst struct efi_font_info *string_font_info);\n+\tefi_status_t(EFIAPI *get_languages)(\n+\t\tconst struct efi_hii_string_protocol *this,\n+\t\tefi_hii_handle_t package_list,\n+\t\tuint8_t *languages,\n+\t\tUINTN *languages_size);\n+\tefi_status_t(EFIAPI *get_secondary_languages)(\n+\t\tconst struct efi_hii_string_protocol *this,\n+\t\tefi_hii_handle_t package_list,\n+\t\tconst uint8_t *primary_language,\n+\t\tuint8_t *secondary_languages,\n+\t\tUINTN *secondary_languages_size);\n+};\n+\n #define EFI_GOP_GUID \\\n \tEFI_GUID(0x9042a9de, 0x23dc, 0x4a38, \\\n \t\t 0x96, 0xfb, 0x7a, 0xde, 0xd0, 0x80, 0x51, 0x6a)\ndiff --git a/include/efi_loader.h b/include/efi_loader.h\nindex c009828db9..a89bb2fcd9 100644\n--- a/include/efi_loader.h\n+++ b/include/efi_loader.h\n@@ -59,6 +59,9 @@ extern struct efi_simple_input_interface efi_con_in;\n extern const struct efi_console_control_protocol efi_console_control;\n extern const struct efi_device_path_to_text_protocol efi_device_path_to_text;\n extern const struct efi_device_path_utilities_protocol efi_device_path_utilities;\n+extern const struct efi_hii_config_routing_protocol efi_hii_config_routing;\n+extern const struct efi_hii_database_protocol efi_hii_database;\n+extern const struct efi_hii_string_protocol efi_hii_string;\n \n uint16_t *efi_dp_str(struct efi_device_path *dp);\n \n@@ -70,6 +73,9 @@ extern const efi_guid_t efi_guid_device_path_to_text_protocol;\n extern const efi_guid_t efi_simple_file_system_protocol_guid;\n extern const efi_guid_t efi_file_info_guid;\n extern const efi_guid_t efi_guid_device_path_utilities_protocol;\n+extern const efi_guid_t efi_guid_hii_config_routing_protocol;\n+extern const efi_guid_t efi_guid_hii_database_protocol;\n+extern const efi_guid_t efi_guid_hii_string_protocol;\n \n extern unsigned int __efi_runtime_start, __efi_runtime_stop;\n extern unsigned int __efi_runtime_rel_start, __efi_runtime_rel_stop;\ndiff --git a/lib/efi_loader/Makefile b/lib/efi_loader/Makefile\nindex f5e69dd078..e8fd6823a3 100644\n--- a/lib/efi_loader/Makefile\n+++ b/lib/efi_loader/Makefile\n@@ -16,7 +16,7 @@ always := $(efiprogs-y)\n obj-$(CONFIG_CMD_BOOTEFI_HELLO) += helloworld_efi.o\n obj-y += efi_image_loader.o efi_boottime.o efi_runtime.o efi_console.o\n obj-y += efi_memory.o efi_device_path_to_text.o efi_device_path.o\n-obj-y += efi_device_path_utilities.o\n+obj-y += efi_device_path_utilities.o efi_hii.o\n obj-y += efi_file.o efi_variable.o efi_bootmgr.o\n obj-$(CONFIG_LCD) += efi_gop.o\n obj-$(CONFIG_DM_VIDEO) += efi_gop.o\ndiff --git a/lib/efi_loader/efi_boottime.c b/lib/efi_loader/efi_boottime.c\nindex 8bb243d673..4d1a16051b 100644\n--- a/lib/efi_loader/efi_boottime.c\n+++ b/lib/efi_loader/efi_boottime.c\n@@ -779,6 +779,15 @@ void efi_setup_loaded_image(struct efi_loaded_image *info, struct efi_object *ob\n \tobj->protocols[4].protocol_interface =\n \t\t(void *)&efi_device_path_utilities;\n \n+\tobj->protocols[5].guid = &efi_guid_hii_string_protocol;\n+\tobj->protocols[5].protocol_interface = (void *)&efi_hii_string;\n+\n+\tobj->protocols[6].guid = &efi_guid_hii_database_protocol;\n+\tobj->protocols[6].protocol_interface = (void *)&efi_hii_database;\n+\n+\tobj->protocols[7].guid = &efi_guid_hii_config_routing_protocol;\n+\tobj->protocols[7].protocol_interface = (void *)&efi_hii_config_routing;\n+\n \tinfo->file_path = file_path;\n \tinfo->device_handle = efi_dp_find_obj(device_path, NULL);\n \ndiff --git a/lib/efi_loader/efi_hii.c b/lib/efi_loader/efi_hii.c\nnew file mode 100644\nindex 0000000000..cc68a28d2b\n--- /dev/null\n+++ b/lib/efi_loader/efi_hii.c\n@@ -0,0 +1,303 @@\n+/*\n+ *  EFI Human Interface Infrastructure ... interface\n+ *\n+ *  Copyright (c) 2017 Leif Lindholm\n+ *\n+ *  SPDX-License-Identifier:     GPL-2.0+\n+ */\n+\n+#include <common.h>\n+#include <efi_loader.h>\n+\n+const efi_guid_t efi_guid_hii_config_routing_protocol =\n+\tEFI_HII_CONFIG_ROUTING_PROTOCOL_GUID;\n+const efi_guid_t efi_guid_hii_database_protocol = EFI_HII_DATABASE_PROTOCOL_GUID;\n+const efi_guid_t efi_guid_hii_string_protocol = EFI_HII_STRING_PROTOCOL_GUID;\n+\n+\n+/*\n+ * EFI_HII_CONFIG_ROUTING_PROTOCOL\n+ */\n+\n+static efi_status_t extract_config(\n+\tconst struct efi_hii_config_routing_protocol *this,\n+\tconst efi_string_t request,\n+\tefi_string_t *progress,\n+\tefi_string_t *results)\n+{\n+\tEFI_ENTRY(\"%p, \\\"%ls\\\", %p, %p\", this, request, progress, results);\n+\treturn EFI_EXIT(EFI_OUT_OF_RESOURCES);\n+}\n+\n+static efi_status_t export_config(\n+\tconst struct efi_hii_config_routing_protocol *this,\n+\tefi_string_t *results)\n+{\n+\tEFI_ENTRY(\"%p, %p\", this, results);\n+\treturn EFI_EXIT(EFI_OUT_OF_RESOURCES);\n+}\n+\n+static efi_status_t route_config(\n+\tconst struct efi_hii_config_routing_protocol *this,\n+\tconst efi_string_t configuration,\n+\tefi_string_t *progress)\n+{\n+\tEFI_ENTRY(\"%p, \\\"%ls\\\", %p\", this, configuration, progress);\n+\treturn EFI_EXIT(EFI_OUT_OF_RESOURCES);\n+}\n+\n+static efi_status_t block_to_config(\n+\tconst struct efi_hii_config_routing_protocol *this,\n+\tconst efi_string_t config_request,\n+\tconst uint8_t *block,\n+\tconst UINTN block_size,\n+\tefi_string_t *config,\n+\tefi_string_t *progress)\n+{\n+\tEFI_ENTRY(\"%p, \\\"%ls\\\", %p, %lu, %p, %p\", this, config_request, block,\n+\t\t  block_size, config, progress);\n+\treturn EFI_EXIT(EFI_OUT_OF_RESOURCES);\n+}\n+\n+static efi_status_t config_to_block(\n+\tconst struct efi_hii_config_routing_protocol *this,\n+\tconst efi_string_t config_resp,\n+\tconst uint8_t *block,\n+\tconst UINTN *block_size,\n+\tefi_string_t *progress)\n+{\n+\tEFI_ENTRY(\"%p, \\\"%ls\\\", %p, %p, %p\", this, config_resp, block,\n+\t\t  block_size, progress);\n+\treturn EFI_EXIT(EFI_OUT_OF_RESOURCES);\n+}\n+\n+static efi_status_t get_alt_config(\n+\tconst struct efi_hii_config_routing_protocol *this,\n+\tconst efi_string_t config_resp,\n+\tconst efi_guid_t *guid,\n+\tconst efi_string_t name,\n+\tconst struct efi_device_path *device_path,\n+\tconst efi_string_t alt_cfg_id,\n+\tefi_string_t *alt_cfg_resp)\n+{\n+\tEFI_ENTRY(\"%p, \\\"%ls\\\", %pUl, \\\"%ls\\\", %p, \\\"%ls\\\", %p\", this,\n+\t\t  config_resp, guid, name, device_path, alt_cfg_id,\n+\t\t  alt_cfg_resp);\n+\treturn EFI_EXIT(EFI_OUT_OF_RESOURCES);\n+}\n+\n+\n+/*\n+ * EFI_HII_DATABASE_PROTOCOL\n+ */\n+\n+static efi_status_t new_package_list(\n+\tconst struct efi_hii_database_protocol *this,\n+\tconst struct efi_hii_package_list_header *package_list,\n+\tconst efi_handle_t driver_handle,\n+\tefi_hii_handle_t *handle)\n+{\n+\t/* Current shell start failure. */\n+\t/* Invoked from MdeModulePkg/Library/UefiHiiLib/HiiLib.c : HiiAddPackages */\n+\t/* (Via autogenerated .c file.) */\n+\tEFI_ENTRY(\"%p, %p, %p, %p\", this, package_list, driver_handle, handle);\n+\treturn EFI_EXIT(EFI_OUT_OF_RESOURCES);\n+}\n+\n+static efi_status_t remove_package_list(\n+\tconst struct efi_hii_database_protocol *this,\n+\tefi_hii_handle_t handle)\n+{\n+\tEFI_ENTRY(\"%p, %p\", this, handle);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+static efi_status_t update_package_list(\n+\tconst struct efi_hii_database_protocol *this,\n+\tefi_hii_handle_t handle,\n+\tconst struct efi_hii_package_list_header *package_list)\n+{\n+\tEFI_ENTRY(\"%p, %p, %p\", this, handle, package_list);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+static efi_status_t list_package_lists(\n+\tconst struct efi_hii_database_protocol *this,\n+\tuint8_t package_type,\n+\tconst efi_guid_t *package_guid,\n+\tUINTN *handle_buffer_length,\n+\tefi_hii_handle_t *handle)\n+{\n+\tEFI_ENTRY(\"%p, %u, %pUl, %p, %p\", this, package_type, package_guid,\n+\t\t  handle_buffer_length, handle);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+static efi_status_t export_package_lists(\n+\tconst struct efi_hii_database_protocol *this,\n+\tefi_hii_handle_t handle,\n+\tUINTN *buffer_size,\n+\tstruct efi_hii_package_list_header *buffer)\n+{\n+\tEFI_ENTRY(\"%p, %p, %p, %p\", this, handle, buffer_size, buffer);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+static efi_status_t register_package_notify(\n+\tconst struct efi_hii_database_protocol *this,\n+\tuint8_t package_type,\n+\tconst efi_guid_t *package_guid,\n+\tconst void *package_notify_fn,\n+\tUINTN notify_type,\n+\tefi_handle_t *notify_handle)\n+{\n+\tEFI_ENTRY(\"%p, %u, %pUl, %p, %lu, %p\", this, package_type,\n+\t\t  package_guid, package_notify_fn, notify_type,\n+\t\t  notify_handle);\n+\treturn EFI_EXIT(EFI_OUT_OF_RESOURCES);\n+}\n+\n+static efi_status_t unregister_package_notify(\n+\tconst struct efi_hii_database_protocol *this,\n+\tefi_handle_t notification_handle)\n+{\n+\tEFI_ENTRY(\"%p, %p\", this, notification_handle);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+static efi_status_t find_keyboard_layouts(\n+\tconst struct efi_hii_database_protocol *this,\n+\tuint16_t *key_guid_buffer_length,\n+\tefi_guid_t *key_guid_buffer)\n+{\n+\tEFI_ENTRY(\"%p, %p, %p\", this, key_guid_buffer_length, key_guid_buffer);\n+\treturn EFI_EXIT(EFI_NOT_FOUND); /* Invalid */\n+}\n+\n+static efi_status_t get_keyboard_layout(\n+\tconst struct efi_hii_database_protocol *this,\n+\tefi_guid_t *key_guid,\n+\tuint16_t *keyboard_layout_length,\n+\tstruct efi_hii_keyboard_layout *keyboard_layout)\n+{\n+\tEFI_ENTRY(\"%p, %pUl, %p, %p\", this, key_guid, keyboard_layout_length,\n+\t\t  keyboard_layout);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+static efi_status_t set_keyboard_layout(\n+\tconst struct efi_hii_database_protocol *this,\n+\tefi_guid_t *key_guid)\n+{\n+\tEFI_ENTRY(\"%p, %pUl\", this, key_guid);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+static efi_status_t get_package_list_handle(\n+\tconst struct efi_hii_database_protocol *this,\n+\tefi_hii_handle_t package_list_handle,\n+\tefi_handle_t *driver_handle)\n+{\n+\tEFI_ENTRY(\"%p, %p, %p\", this, package_list_handle, driver_handle);\n+\treturn EFI_EXIT(EFI_INVALID_PARAMETER);\n+}\n+\n+\n+/*\n+ * EFI_HII_STRING_PROTOCOL\n+ */\n+\n+static efi_status_t new_string(\n+\tconst struct efi_hii_string_protocol *this,\n+\tefi_hii_handle_t package_list,\n+\tefi_string_id_t *string_id,\n+\tconst uint8_t *language,\n+\tconst uint16_t *language_name,\n+\tconst efi_string_t string,\n+\tconst struct efi_font_info *string_font_info)\n+{\n+\tEFI_ENTRY(\"%p, %p, %p, %p, %p, \\\"%ls\\\", %p\", this, package_list,\n+\t\t  string_id, language, language_name, string,\n+\t\t  string_font_info);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+static efi_status_t get_string(\n+\tconst struct efi_hii_string_protocol *this,\n+\tconst uint8_t *language,\n+\tefi_hii_handle_t package_list,\n+\tefi_string_id_t string_id,\n+\tefi_string_t string,\n+\tUINTN *string_size,\n+\tstruct efi_font_info **string_font_info)\n+{\n+\tEFI_ENTRY(\"%p, %p, %p, %u, \\\"%ls\\\", %p, %p\", this, language,\n+\t\t  package_list, string_id, string, string_size,\n+\t\t  string_font_info);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+static efi_status_t set_string(\n+\tconst struct efi_hii_string_protocol *this,\n+\tefi_hii_handle_t package_list,\n+\tefi_string_id_t string_id,\n+\tconst uint8_t *language,\n+\tconst efi_string_t string,\n+\tconst struct efi_font_info *string_font_info)\n+{\n+\tEFI_ENTRY(\"%p, %p, %u, %p, \\\"%ls\\\", %p\", this, package_list, string_id,\n+\t\t  language, string, string_font_info);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+static efi_status_t get_languages(\n+\tconst struct efi_hii_string_protocol *this,\n+\tefi_hii_handle_t package_list,\n+\tuint8_t *languages,\n+\tUINTN *languages_size)\n+{\n+\tEFI_ENTRY(\"%p, %p, %p, %p\", this, package_list, languages,\n+\t\t  languages_size);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+static efi_status_t get_secondary_languages(\n+\tconst struct efi_hii_string_protocol *this,\n+\tefi_hii_handle_t package_list,\n+\tconst uint8_t *primary_language,\n+\tuint8_t *secondary_languages,\n+\tUINTN *secondary_languages_size)\n+{\n+\tEFI_ENTRY(\"%p, %p, %p, %p, %p\", this, package_list, primary_language,\n+\t\t  secondary_languages, secondary_languages_size);\n+\treturn EFI_EXIT(EFI_NOT_FOUND);\n+}\n+\n+const struct efi_hii_config_routing_protocol efi_hii_config_routing = {\n+\t.extract_config = extract_config,\n+\t.export_config = export_config,\n+\t.route_config = route_config,\n+\t.block_to_config = block_to_config,\n+\t.config_to_block = config_to_block,\n+\t.get_alt_config = get_alt_config\n+};\n+const struct efi_hii_database_protocol efi_hii_database = {\n+\t.new_package_list = new_package_list,\n+\t.remove_package_list = remove_package_list,\n+\t.update_package_list = update_package_list,\n+\t.list_package_lists = list_package_lists,\n+\t.export_package_lists = export_package_lists,\n+\t.register_package_notify = register_package_notify,\n+\t.unregister_package_notify = unregister_package_notify,\n+\t.find_keyboard_layouts = find_keyboard_layouts,\n+\t.get_keyboard_layout = get_keyboard_layout,\n+\t.set_keyboard_layout = set_keyboard_layout,\n+\t.get_package_list_handle = get_package_list_handle\n+};\n+const struct efi_hii_string_protocol efi_hii_string = {\n+\t.new_string = new_string,\n+\t.get_string = get_string,\n+\t.set_string = set_string,\n+\t.get_languages = get_languages,\n+\t.get_secondary_languages = get_secondary_languages\n+};\n",
    "prefixes": [
        "U-Boot",
        "v1",
        "02/12"
    ]
}