blob: 3fd50ea6beba398bb5289d57cd1c66c915f0604b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
/* SPDX-License-Identifier: GPL-2.0-only */
#include <amdblocks/psp.h>
#include <console/console.h>
#include <types.h>
#include "psp_def.h"
void psp_set_tpm_irq_gpio(unsigned int gpio)
{
int cmd_status;
struct mbox_cmd_dtpm_config_buffer buffer = {
.header = {
.size = sizeof(buffer)
},
.request_type = DTPM_REQUEST_CONFIG,
.config = {
.gpio = gpio
}
};
printk(BIOS_DEBUG, "PSP: Setting TPM GPIO to %u...", gpio);
cmd_status = send_psp_command(MBOX_BIOS_CMD_I2C_TPM_ARBITRATION, &buffer);
psp_print_cmd_status(cmd_status, &buffer.header);
}
|