Lines Matching +full:qemu +full:- +full:user +full:- +full:static

1 /*-
2 * SPDX-License-Identifier: BSD-2-Clause-FreeBSD
32 #define TPM_PPI_QEMU_NAME "qemu"
55 static int
64 if ((addr & (size - 1)) != 0) { in tpm_ppi_mem_handler()
71 off = addr - TPM_PPI_ADDRESS; in tpm_ppi_mem_handler()
88 static struct mem_range ppi_mmio = {
89 .name = "ppi-mmio",
96 static int
117 fwcfg->ppi_address = htole32(TPM_PPI_ADDRESS); in tpm_ppi_init()
118 fwcfg->tpm_version = 2; in tpm_ppi_init()
119 fwcfg->ppi_version = 1; in tpm_ppi_init()
152 static void
169 static int
176 * According to qemu the Windows ACPI parser has a bug that DerefOf is in tpm_ppi_write_dsdt_regions()
177 * broken for SYSTEM_MEMORY. Due to that bug, qemu uses a dynamic in tpm_ppi_write_dsdt_regions()
219 static int
226 "If(LEqual(Arg0, ToUUID(\"3DDDFAA6-361B-4EB4-A424-8D10089D1653\"))) /* UUID */"); in tpm_ppi_write_dsdt_dsm()
229 * Function 0 - _DSM Query Function in tpm_ppi_write_dsdt_dsm()
233 * Buffer - Index field of supported functions in tpm_ppi_write_dsdt_dsm()
243 * Function 1 - Get Physical Presence Interface Version in tpm_ppi_write_dsdt_dsm()
247 * String - Supported Physical Presence Interface revision in tpm_ppi_write_dsdt_dsm()
254 * Function 2 - Submit TPM Operation Request to Pre-OS Environment in tpm_ppi_write_dsdt_dsm()
257 * Integer - Operation Value of the Request in tpm_ppi_write_dsdt_dsm()
259 * Integer - Function Return Code in tpm_ppi_write_dsdt_dsm()
260 * 0 - Success in tpm_ppi_write_dsdt_dsm()
261 * 1 - Operation Value of the Request Not Supported in tpm_ppi_write_dsdt_dsm()
262 * 2 - General Failure in tpm_ppi_write_dsdt_dsm()
277 * Function 3 - Get Pending TPM Operation Request By the OS in tpm_ppi_write_dsdt_dsm()
282 * Integer 1 - Function Return Code in tpm_ppi_write_dsdt_dsm()
283 * 0 - Success in tpm_ppi_write_dsdt_dsm()
284 * 1 - General Failure in tpm_ppi_write_dsdt_dsm()
285 * Integer 2 - Pending operation requested by the OS in tpm_ppi_write_dsdt_dsm()
286 * 0 - None in tpm_ppi_write_dsdt_dsm()
287 * >0 - Operation Value of the Pending Request in tpm_ppi_write_dsdt_dsm()
288 * Integer 3 - Optional argument to pending operation requested by in tpm_ppi_write_dsdt_dsm()
290 * 0 - None in tpm_ppi_write_dsdt_dsm()
291 * >0 - Argument of the Pending Request in tpm_ppi_write_dsdt_dsm()
308 * Function 4 - Get Platform-Specific Action to Transition to Pre-OS in tpm_ppi_write_dsdt_dsm()
313 * Integer - Action that the OS should take to transition to the in tpm_ppi_write_dsdt_dsm()
314 * pre-OS environment for execution of a requested operation in tpm_ppi_write_dsdt_dsm()
315 * 0 - None in tpm_ppi_write_dsdt_dsm()
316 * 1 - Shutdown in tpm_ppi_write_dsdt_dsm()
317 * 2 - Reboot in tpm_ppi_write_dsdt_dsm()
318 * 3 - OS Vendor-specific in tpm_ppi_write_dsdt_dsm()
325 * Function 5 - Return TPM Operation Response to OS Environment in tpm_ppi_write_dsdt_dsm()
330 * Integer 1 - Function Return Code in tpm_ppi_write_dsdt_dsm()
331 * 0 - Success in tpm_ppi_write_dsdt_dsm()
332 * 1 - General Failure in tpm_ppi_write_dsdt_dsm()
333 * Integer 2 - Most recent operation request in tpm_ppi_write_dsdt_dsm()
334 * 0 - None in tpm_ppi_write_dsdt_dsm()
335 * >0 - Operation value of the most recent request in tpm_ppi_write_dsdt_dsm()
336 * Integer 3 - Response to the most recent operation request in tpm_ppi_write_dsdt_dsm()
337 * 0 - Success in tpm_ppi_write_dsdt_dsm()
338 * 0x00000001..0x000000FF - Corresponding TPM error code in tpm_ppi_write_dsdt_dsm()
339 * 0xFFFFFFF0 - User Abort or timeout of dialog in tpm_ppi_write_dsdt_dsm()
340 * 0xFFFFFFF1 - firmware failure in tpm_ppi_write_dsdt_dsm()
349 * Function 6 - Submit preferred user language in tpm_ppi_write_dsdt_dsm()
353 * String - Preferred language code in tpm_ppi_write_dsdt_dsm()
356 * 3 - Not implemented in tpm_ppi_write_dsdt_dsm()
363 * Function 7 - Submit TPM Operation Request to Pre-OS Environment 2 in tpm_ppi_write_dsdt_dsm()
366 * Integer 1 - Operation Value of the Request in tpm_ppi_write_dsdt_dsm()
367 * Integer 2 - Argument for Operation in tpm_ppi_write_dsdt_dsm()
369 * Integer - Function Return Code in tpm_ppi_write_dsdt_dsm()
370 * 0 - Success in tpm_ppi_write_dsdt_dsm()
371 * 1 - Not Implemented in tpm_ppi_write_dsdt_dsm()
372 * 2 - General Failure in tpm_ppi_write_dsdt_dsm()
373 * 3 - Operation blocked by current firmware settings in tpm_ppi_write_dsdt_dsm()
400 * Function 8 - Get User Confirmation Status for Operation in tpm_ppi_write_dsdt_dsm()
403 * Integer - Operation Value that may need user confirmation in tpm_ppi_write_dsdt_dsm()
405 * Integer - Function Return Code in tpm_ppi_write_dsdt_dsm()
406 * 0 - Not implemented in tpm_ppi_write_dsdt_dsm()
407 * 1 - Firmware only in tpm_ppi_write_dsdt_dsm()
408 * 2 - Blocked for OS by firmware configuration in tpm_ppi_write_dsdt_dsm()
409 * 3 - Allowed and physically present user required in tpm_ppi_write_dsdt_dsm()
410 * 4 - Allowed and physically present user not required in tpm_ppi_write_dsdt_dsm()
431 "If(LEqual(Arg0, ToUUID(\"376054ED-CC13-4675-901C-4756D7F2D45D\"))) /* UUID */"); in tpm_ppi_write_dsdt_dsm()
434 * Function 0 - _DSM Query Function in tpm_ppi_write_dsdt_dsm()
438 * Buffer - Index field of supported functions in tpm_ppi_write_dsdt_dsm()
448 * Function 1 - Memory Clear in tpm_ppi_write_dsdt_dsm()
451 * Integer - Operation Value of the Request in tpm_ppi_write_dsdt_dsm()
453 * Integer - Function Return Code in tpm_ppi_write_dsdt_dsm()
454 * 0 - Success in tpm_ppi_write_dsdt_dsm()
455 * 1 - General Failure in tpm_ppi_write_dsdt_dsm()
468 static struct tpm_ppi tpm_ppi_qemu = {