From nobody Mon Mar 03 16:12:30 2025 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Z63k657pWz5pjlf; Mon, 03 Mar 2025 16:12:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Z63k63rHPz40Kj; Mon, 03 Mar 2025 16:12:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1741018350; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=RYcMZ8JJAfOqoQUem62w/VyAjda7BFW6cO1aVXIfA1g=; b=QmwbtuLAltXVsbVlPWo96z4A9FYNpP2sg1wDrN0mGTm1Klg8AvDh+ABnqVxiUTVzTs3ez5 vEJ0rU2Efjh8h6bqlBoth+fPUUAJr4VKnoyWja8BuODDtTxw3gjm6dYo4fDTbF49QG7cu8 epLa8YoFOGrrR6iTquWzPcBtW/9ZEDIdElwvrtI27lHsp/gJ/BMR9yu/CkepVTi4NtczQ0 ir0b0Zg5/hnHn75USVtVClyUK8aVTq58zQK8ITfiKm30EUxPZk5e8cKCq/nQqn67ECTsIK qz0+H7DQJnR4O/jAZ+9q3nrLM8X3mytqXdw4YwTXMX1YqGvsGADy6zOWVtVvaw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1741018350; a=rsa-sha256; cv=none; b=AVLniSYgt7c8DRMc+LVvLZuASvbI8xFJ67ObiC/uZeiwdu1m4CV1RdC4RW3ikzuSQlrDNQ vPEpXVBCPryz1eM4p8ImRjAC6PBVQn/qDy7y/nKbf2S1n3g6YPXJ+8gDP+AHI97Yv6OPkS 4QSIxO3Peo9DVA2fCRRn2QGlgweyhkylNuIdKF/p4gptwEHfGx9aMSvVvutTZUICIRBJcZ Ac9+MWppZDezits7EgbIOFI6kNVthbzcWupkj4gU5EWwI5pT+pR+czFpm4VAoQzrycevGE ZlbT6dnnHWLSTt9FrkftMgvxHD6ccOoaDSw/Xk5HIAIphYXvjAEnLDrmpiMDxA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1741018350; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=RYcMZ8JJAfOqoQUem62w/VyAjda7BFW6cO1aVXIfA1g=; b=IOlcbAoutDocizrulZBTBEgKcVJCoSnKm/AnXIRlt5f9kiBSxIVyFULOnDkhFBbTOULt4C xsEmeOHMUb66aHLR6v7mTuxVg/Qrx1zdzNi27tXDgdHgKoNlBDCqthX0FBFFM0hpPDdhhB w1WclwzFnTzPfzvsKGe+jvUbNHyW/mjQJ6l1X7dcL04E3gn+4VWr8zm+PLLZia90HV7rtm 4CsPlmtFOQHH2bFJZI2yDBBjBkwxdWhfRBgyxLbbPwVADtBrPSOGfxcnthWviCKJyCTLco fymYqATX4VcYdSOCvJP3m1lVD5O6Ynj+DgPi6GLTPXLvHm6PPmRqGpBIHOHplg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Z63k637J1zv4f; Mon, 03 Mar 2025 16:12:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 523GCUCU007336; Mon, 3 Mar 2025 16:12:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 523GCUpZ007328; Mon, 3 Mar 2025 16:12:30 GMT (envelope-from git) Date: Mon, 3 Mar 2025 16:12:30 GMT Message-Id: <202503031612.523GCUpZ007328@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mitchell Horne Subject: git: 62c0997d4317 - main - efiprot.h: add definitions for RISCV_EFI_BOOT_PROTOCOL List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 62c0997d4317390685afdd35a28396f2a6f0b2a3 Auto-Submitted: auto-generated The branch main has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=62c0997d4317390685afdd35a28396f2a6f0b2a3 commit 62c0997d4317390685afdd35a28396f2a6f0b2a3 Author: Mitchell Horne AuthorDate: 2025-03-03 15:46:56 +0000 Commit: Mitchell Horne CommitDate: 2025-03-03 16:12:15 +0000 efiprot.h: add definitions for RISCV_EFI_BOOT_PROTOCOL It seems like this file was vendored (sorta) originally, but we have not kept it in sync with the original source, if it still exists. Follow the precedent in commit acf82d2659879, and just add the definition to the bottom of the file, keeping its style conventions. Defined here: https://github.com/riscv-non-isa/riscv-uefi Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D48885 --- stand/efi/include/efiprot.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/stand/efi/include/efiprot.h b/stand/efi/include/efiprot.h index be11ea83b3a2..5b8ac2309c8e 100644 --- a/stand/efi/include/efiprot.h +++ b/stand/efi/include/efiprot.h @@ -632,4 +632,31 @@ typedef struct _EFI_COMPONENT_NAME2 { CHAR8 **SupportedLanguages; } EFI_COMPONENT_NAME2; +// +// RISC-V EFI Boot Protocol +// +// https://github.com/riscv-non-isa/riscv-uefi +// + +#define RISCV_EFI_BOOT_PROTOCOL_GUID \ + { 0xccd15fec, 0x6f73, 0x4eec, {0x83, 0x95, 0x3e, 0x69, 0xe4, 0xb9, 0x40, 0xbf} } + +INTERFACE_DECL(_RISCV_EFI_BOOT_PROTOCOL); + +#define RISCV_EFI_BOOT_PROTOCOL_REVISION 0x00010000 +#define RISCV_EFI_BOOT_PROTOCOL_LATEST_VERSION \ + RISCV_EFI_BOOT_PROTOCOL_REVISION + +typedef +EFI_STATUS +(EFIAPI *EFI_GET_BOOT_HARTID) ( + IN struct _RISCV_EFI_BOOT_PROTOCOL *This, + OUT UINTN *BootHartId + ); + +typedef struct _RISCV_EFI_BOOT_PROTOCOL { + UINT64 Revision; + EFI_GET_BOOT_HARTID GetBootHartId; +} RISCV_EFI_BOOT_PROTOCOL; + #endif