通訊協定
韌體
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
GetFirmware
要求
| 名稱 | 類型 |
|---|---|
type |
FirmwareType
|
回應
| 名稱 | 類型 |
|---|---|
payload |
Firmware_GetFirmware_Result
|
InterruptAttributor
定義於 fuchsia.hardware.platform.bus/observability.fidl
提供主機板驅動程式庫指派給各種裝置的中斷相關資訊。
GetInterruptInfo
要求
| 名稱 | 類型 |
|---|---|
payload |
InterruptAttributorGetInterruptInfoRequest
|
回應
| 名稱 | 類型 |
|---|---|
payload |
InterruptAttributor_GetInterruptInfo_Result
|
PlatformBus
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
AddCompositeNodeSpec
新增複合節點規格,其中 |node| 是複合節點的其中一個父項。為此,這個方法會執行幾項操作。這個方法會新增由 |node| 指定的平台裝置節點,做為平台匯流排的子項。此外,系統也會在 |spec| 中新增 fuchsia.driver.framework.ParentSpec,與新加入的平台裝置節點相符。複合繫結規則應包含與 |node| 屬性相符的段落,以便與 CompositeNodeSpec 比對。
要求
| 名稱 | 類型 |
|---|---|
node |
Node
|
spec |
fuchsia.driver.framework/CompositeNodeSpec
|
回應
| 名稱 | 類型 |
|---|---|
payload |
PlatformBus_AddCompositeNodeSpec_Result
|
GetBoardInfo
主機板驅動程式可能會使用這項資訊來取得主機板的相關資訊,以及區分支援的多個主機板。
要求
<EMPTY>
回應
| 名稱 | 類型 |
|---|---|
payload |
PlatformBus_GetBoardInfo_Result
|
NodeAdd
使用 |node| 提供的設定,將新的平台裝置節點新增至匯流排。平台裝置節點會在各自獨立的驅動程式庫代管程序中建立。
要求
| 名稱 | 類型 |
|---|---|
node |
Node
|
回應
| 名稱 | 類型 |
|---|---|
payload |
PlatformBus_NodeAdd_Result
|
RegisterIommu
註冊 iommu。平台匯流排會根據傳入的參數,使用這個函式建立新的核心 iommu 物件。
要求
| 名稱 | 類型 |
|---|---|
iommu_id |
uint32
|
iommu |
Iommu
|
回應
| 名稱 | 類型 |
|---|---|
payload |
PlatformBus_RegisterIommu_Result
|
RegisterSysSuspendCallback
註冊回呼,在平台匯流排暫停時由該匯流排叫用。
要求
| 名稱 | 類型 |
|---|---|
suspend_cb |
client_end:SysSuspend
|
回應
| 名稱 | 類型 |
|---|---|
payload |
PlatformBus_RegisterSysSuspendCallback_Result
|
SetBoardInfo
主機板驅動程式可能會使用這個屬性設定主機板的相關資訊。
要求
| 名稱 | 類型 |
|---|---|
info |
BoardInfo
|
回應
| 名稱 | 類型 |
|---|---|
payload |
PlatformBus_SetBoardInfo_Result
|
SetBootloaderInfo
主機板驅動程式可能會使用這項資訊,設定開機載入程式的相關資訊。
要求
| 名稱 | 類型 |
|---|---|
info |
BootloaderInfo
|
回應
| 名稱 | 類型 |
|---|---|
payload |
PlatformBus_SetBootloaderInfo_Result
|
SysSuspend
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
實作這項通訊協定的伺服器可註冊至平台匯流排,接收平台匯流排暫停原因的回呼。
Callback
當平台匯流排的暫停掛鉤遭到呼叫時,由平台匯流排叫用。
要求
| 名稱 | 類型 |
|---|---|
enable_wake |
bool
|
suspend_reason |
uint8
|
回應
| 名稱 | 類型 |
|---|---|
out_status |
zx/Result
|
STRUCTS
ArmSmmu
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
ARM SMMU
| 欄位 | 類型 | 說明 | 預設 |
|---|---|---|---|
base_address |
uint64
|
SMMU 的基本位址。如果硬體支援多個 SMMU,這個屬性可用於識別要使用哪個 SMMU。 |
無預設值 |
FirmwareBlob 資源
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 欄位 | 類型 | 說明 | 預設 |
|---|---|---|---|
vmo |
handle<vmo>
|
無預設值 | |
length |
uint64
|
無預設值 |
Firmware_GetFirmware_Response 資源
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 欄位 | 類型 | 說明 | 預設 |
|---|---|---|---|
blobs |
vector<FirmwareBlob>
|
無預設值 |
InterruptAttributor_GetInterruptInfo_Response resource
定義於 fuchsia.hardware.platform.bus/observability.fidl
| 欄位 | 類型 | 說明 | 預設 |
|---|---|---|---|
device_name |
string:128
|
板卡驅動程式庫程式為指派中斷的裝置指定的名稱。 |
無預設值 |
component_token |
handle<event>?
|
代表中斷作業所指派驅動程式庫程式元件執行個體的權杖。這項資訊可能會與驅動程式庫架構或元件架構交換,以進一步瞭解元件,例如網址或路徑名稱。 如果驅動程式庫尚未繫結至裝置並控制中斷,則不會顯示。 |
無預設值 |
PlatformBus_AddCompositeNodeSpec_Response
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
<EMPTY>
PlatformBus_GetBoardInfo_Response
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 欄位 | 類型 | 說明 | 預設 |
|---|---|---|---|
info |
TemporaryBoardInfo
|
無預設值 |
PlatformBus_NodeAdd_Response
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
<EMPTY>
PlatformBus_RegisterIommu_Response
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
<EMPTY>
PlatformBus_RegisterSysSuspendCallback_Response
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
<EMPTY>
PlatformBus_SetBoardInfo_Response
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
<EMPTY>
PlatformBus_SetBootloaderInfo_Response
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
<EMPTY>
StubIommu
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
虛設常式 IOMMU
<EMPTY>
TemporaryBoardInfo
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
這原本來自 Banjo fuchsia.hardware.platform.device 程式庫,但會暫時包含在這裡,直到遷移至 FIDL 為止。
| 欄位 | 類型 | 說明 | 預設 |
|---|---|---|---|
vid |
uint32
|
主機板的供應商 ID。 |
無預設值 |
pid |
uint32
|
主機板的產品 ID。 |
無預設值 |
board_name |
string:32
|
開機映像檔平台 ID 記錄中的主機板名稱 (或 x86 平台上的 BIOS)。 |
無預設值 |
board_revision |
uint32
|
主機板專屬修訂版本編號。 |
無預設值 |
UserspaceIrq
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 欄位 | 類型 | 說明 | 預設 |
|---|---|---|---|
irq |
uint32
|
使用者空間 IRQ 編號,由提供該編號的中斷控制器驅動程式庫專用。 |
無預設值 |
controller_id |
InterruptControllerId
|
提供這個中斷要求的控制器專屬 ID。 |
無預設值 |
列舉
FirmwareType flexible
類型:uint32
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 名稱 | 值 | 說明 |
|---|---|---|
DEVICE_TREE |
1 |
|
ACPI |
2 |
|
SMBIOS |
3 |
ZirconInterruptMode strict
類型:uint32
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
建立 Zircon 中斷的模式。與 //zircon/system/public/zircon/types.h 中的 ZX_INTERRUPTMODE* 值同步。
| 名稱 | 值 | 說明 |
|---|---|---|
預設 |
0 |
|
EDGE_LOW |
2 |
|
EDGE_HIGH |
4 |
|
LEVEL_LOW |
6 |
|
LEVEL_HIGH |
8 |
|
EDGE_BOTH |
10 |
TABLES
BoardInfo
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
由主面板驅動程式庫設定的主面板資訊。
| 序數 | 欄位 | 類型 | 說明 |
|---|---|---|---|
1 |
board_name |
string:32
|
開機映像檔平台 ID 記錄或 x86 平台 BIOS 中的主機板名稱。 |
2 |
board_revision |
uint32
|
主機板專屬修訂版本編號。 |
BootMetadata
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
要從系統啟動載入程式透過 ZBI 記錄傳遞的裝置中繼資料。
| 序數 | 欄位 | 類型 | 說明 |
|---|---|---|---|
1 |
zbi_type |
uint32
|
中繼資料類型 (與系統啟動載入程式中繼資料的 |
2 |
zbi_extra |
uint32
|
比對開機載入程式中繼資料的 |
BootloaderInfo
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
由主機板驅動程式庫設定的 Bootloader 資訊。
| 序數 | 欄位 | 類型 | 說明 |
|---|---|---|---|
1 |
vendor |
string:32
|
Bti
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
平台裝置節點的匯流排交易發起端 (bti) 定義。
| 序數 | 欄位 | 類型 | 說明 |
|---|---|---|---|
1 |
iommu_id |
uint32
|
|
2 |
bti_id |
uint32
|
|
3 |
name |
string:128
|
可使用 fuchsia.hardware.platform.device/GetBtiByName 擷取 BTI 的名稱。這個欄位可以留空,但資源只能透過 fuchsia.hardware.platform.device/GetBtiById 擷取。 |
Irq
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 序數 | 欄位 | 類型 | 說明 |
|---|---|---|---|
1 |
irq |
IrqSpec
|
|
2 |
mode |
ZirconInterruptMode
|
用於設定中斷模式的位元旗標。 |
3 |
properties |
vector<fuchsia.driver.framework/NodeProperty2>:64
|
這個插播片段的屬性。 |
4 |
name |
string:128
|
可使用 fuchsia.hardware.platform.device/GetInterruptByName 擷取 irq 的名稱。這個欄位可以留空,但資源只能透過 fuchsia.hardware.platform.device/GetInterruptById 擷取。 |
5 |
wake_vector |
bool
|
如果設為 true,這個中斷就會將裝置從暫停狀態喚醒。 |
中繼資料
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
代表平台裝置中可用的中繼資料。
| 序數 | 欄位 | 類型 | 說明 |
|---|---|---|---|
1 |
id |
string
|
中繼資料 ID。 |
2 |
data |
vector<uint8>
|
中繼資料位元組。 |
Mmio
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
平台裝置節點的 MMIO 資源定義。
| 序數 | 欄位 | 類型 | 說明 |
|---|---|---|---|
1 |
base |
uint64
|
MMIO 區域的實體位址。不需與頁面對齊。 |
2 |
length |
uint64
|
MMIO 區域長度 (以位元組為單位)。不需與頁面對齊。 |
3 |
name |
string:128
|
可使用 fuchsia.hardware.platform.device/GetMmioByName 擷取 Mmio 的名稱。這個欄位可以留空,但這樣一來,就只能使用 fuchsia.hardware.platform.device/GetMmioById 擷取資源。 |
節點
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
將平台裝置節點新增至平台匯流排的引數。
| 序數 | 欄位 | 類型 | 說明 |
|---|---|---|---|
1 |
name |
string:128
|
節點名稱。 |
2 |
vid |
uint32
|
|
3 |
pid |
uint32
|
|
4 |
did |
uint32
|
|
5 |
instance_id |
uint32
|
執行個體 ID。如果非零,則會影響裝置名稱。
|
6 |
mmio |
vector<Mmio>:32
|
MMIO 區域。 |
7 |
irq |
vector<Irq>:64
|
中斷。 |
8 |
bti |
vector<Bti>:10
|
BTIs。 |
9 |
smc |
vector<Smc>:10
|
SMC 呼叫。 |
10 |
metadata |
vector<Metadata>
|
中繼資料 |
11 |
boot_metadata |
vector<BootMetadata>
|
開機中繼資料 (來自 ZBI 項目) |
12 |
properties |
vector<fuchsia.driver.framework/NodeProperty2>:64
|
BIND_PLATFORM_DEV_VID、BIND_PLATFORM_DEV_PID 和 BIND_PLATFORM_DEV_DID 以外的其他節點屬性。 |
13 |
power_config |
vector<fuchsia.hardware.power/PowerElementConfiguration>:32
|
|
14 |
driver_host |
string
|
|
15 |
interrupt_controller_id |
InterruptControllerId
|
中斷控制器 ID (如果這個節點對應至中斷控制器)。如果指定,fuchsia.hardware.interrupt.ControllerRegistry 將提供給這個節點。這個值必須與這個控制器提供的 |
Smc
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
安全監控呼叫 (SMC) 的定義,可從使用者空間發出呼叫。
| 序數 | 欄位 | 類型 | 說明 |
|---|---|---|---|
1 |
service_call_num_base |
uint32
|
裝置可使用服務呼叫號碼 (範圍從 service_call_num_base 到 service_call_num_base + count - 1) 進行 SMC 呼叫。 |
2 |
count |
uint32
|
|
3 |
exclusive |
bool
|
裝置具有這個 smc 範圍的專屬存取權。 |
4 |
name |
string:128
|
可使用 fuchsia.hardware.platform.device/GetSmcByName 擷取 SMC 的名稱。這個欄位可以留空,但這樣一來,就只能使用 fuchsia.hardware.platform.device/GetSmcById 擷取資源。 |
UNIONS
Firmware_GetFirmware_Result strict resource
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
response |
Firmware_GetFirmware_Response
|
|
2 |
err |
zx/Status
|
InterruptAttributorGetInterruptInfoRequest strict
定義於 fuchsia.hardware.platform.bus/observability.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
interrupt_vector |
uint32
|
中斷控制器用來參照這個中斷的向量。 |
2 |
interrupt_koid |
zx/Koid
|
觸發中斷的中斷物件 KOID。 |
InterruptAttributor_GetInterruptInfo_Result strict resource
定義於 fuchsia.hardware.platform.bus/observability.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
response |
InterruptAttributor_GetInterruptInfo_Response
|
|
2 |
err |
zx/Status
|
Iommu 彈性
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
stub_iommu |
StubIommu
|
|
2 |
arm_smmu |
ArmSmmu
|
彈性 IrqSpec
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
irq |
uint32
|
核心提供中斷的 irq 編號。 |
2 |
userspace_irq |
UserspaceIrq
|
使用者空間提供的中斷規格。 |
PlatformBus_AddCompositeNodeSpec_Result strict
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
response |
PlatformBus_AddCompositeNodeSpec_Response
|
|
2 |
err |
zx/Status
|
PlatformBus_GetBoardInfo_Result strict
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
response |
PlatformBus_GetBoardInfo_Response
|
|
2 |
err |
zx/Status
|
PlatformBus_NodeAdd_Result strict
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
response |
PlatformBus_NodeAdd_Response
|
|
2 |
err |
zx/Status
|
PlatformBus_RegisterIommu_Result strict
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
response |
PlatformBus_RegisterIommu_Response
|
|
2 |
err |
zx/Status
|
PlatformBus_RegisterSysSuspendCallback_Result strict
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
response |
PlatformBus_RegisterSysSuspendCallback_Response
|
|
2 |
err |
zx/Status
|
PlatformBus_SetBoardInfo_Result strict
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
response |
PlatformBus_SetBoardInfo_Response
|
|
2 |
err |
zx/Status
|
PlatformBus_SetBootloaderInfo_Result strict
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 序數 | Variant | 類型 | 說明 |
|---|---|---|---|
1 |
response |
PlatformBus_SetBootloaderInfo_Response
|
|
2 |
err |
zx/Status
|
常數
| 名稱 | 值 | 類型 | 說明 |
|---|---|---|---|
| MAX_BTI |
10
|
uint32 |
|
| MAX_INFO_STRING_LENGTH |
32
|
uint32 |
|
| MAX_IRQ |
64
|
uint32 |
|
| MAX_MMIO |
32
|
uint32 |
|
| MAX_POWER_CONFIGS |
32
|
uint32 |
|
| MAX_SMC |
10
|
uint32 |
別名
| 名稱 | 值 | 說明 |
|---|---|---|
| InterruptControllerId |
uint32 |
服務
ObservabilityService
定義於 fuchsia.hardware.platform.bus/observability.fidl
| 名稱 | 類型 | 傳輸 |
|---|---|---|
| interrupt |
fuchsia.hardware.platform.bus/InterruptAttributor
|
版本 |
服務
定義於 fuchsia.hardware.platform.bus/platform-bus.fidl
| 名稱 | 類型 | 傳輸 |
|---|---|---|
| platform_bus |
fuchsia.hardware.platform.bus/PlatformBus
|
駕駛 |
| 韌體 |
fuchsia.hardware.platform.bus/Firmware
|
駕駛 |