![]() |
coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
|
#include <bootmode.h>
#include <console/console.h>
#include <device/pci.h>
#include <intelblocks/p2sb.h>
#include <intelblocks/pcr.h>
#include <intelblocks/pmc_ipc.h>
#include <intelblocks/systemagent.h>
#include <intelblocks/tcss.h>
#include <inttypes.h>
#include <security/vboot/vboot_common.h>
#include <soc/pci_devs.h>
#include <soc/pcr_ids.h>
#include <soc/tcss.h>
#include <drivers/intel/pmc_mux/conn/chip.h>
Go to the source code of this file.
Macros | |
#define | __SIMPLE_DEVICE__ |
#define | BIAS_CTRL_VW_INDEX_SHIFT 16 |
#define | BIAS_CTRL_BIT_POS_SHIFT 8 |
#define | WAIT_FOR_DISPLAYPORT_TIMEOUT_MS 1000 |
#define | WAIT_FOR_HPD_TIMEOUT_MS 3000 |
Definition at line 346 of file tcss.c.
References BIAS_CTRL_BIT_POS_SHIFT, BIAS_CTRL_VW_INDEX_SHIFT, gpio_get_pad_cpu_portid(), and gpio_get_vw_info().
Referenced by ioe_tcss_configure_aux_bias_pads_sbi(), and tcss_configure_aux_bias_pads_regbar().
void ioe_tcss_configure_aux_bias_pads_sbi | ( | const struct typec_aux_bias_pads * | pads | ) |
Definition at line 371 of file tcss.c.
References calc_bias_ctrl_reg_value(), ioe_p2sb_sbi_write(), IOM_AUX_BIAS_CTRL_PULLDOWN_OFFSET, IOM_AUX_BIAS_CTRL_PULLUP_OFFSET, MAX_TYPE_C_PORTS, and PID_IOM.
Definition at line 441 of file tcss.c.
References ioe_p2sb_sbi_read(), IOM_CSME_IMR_TBT_STATUS, PID_IOM, and TBT_VALID_AUTHENTICATION.
|
static |
Definition at line 138 of file tcss.c.
References BIOS_DEBUG, pmc_ipc_buffer::buf, CONNECT_REQ, usbc_mux_info::dbg_acc, GET_TCSS_CD_FIELD, PMC_IPC_CONN_REQ_SIZE, PMC_IPC_TCSS_CONN_REQ_RES, usbc_mux_info::polarity, printk, send_pmc_req(), tcss_make_conn_cmd(), usbc_mux_info::ufp, tcss_port_map::usb2_port, and tcss_port_map::usb3_port.
Referenced by tcss_configure_dp_mode().
|
static |
Definition at line 118 of file tcss.c.
References BIOS_DEBUG, pmc_ipc_buffer::buf, CONNECT_REQ, GET_TCSS_CD_FIELD, PMC_IPC_DISC_REQ_SIZE, PMC_IPC_TCSS_DISC_REQ_RES, printk, send_pmc_req(), tcss_make_conn_cmd(), tcss_port_map::usb2_port, and tcss_port_map::usb3_port.
Referenced by tcss_init_mux().
|
static |
Definition at line 189 of file tcss.c.
References pmc_ipc_buffer::buf, usbc_mux_info::hpd_irq, usbc_mux_info::hpd_lvl, HPD_REQ, PMC_IPC_HPD_REQ_SIZE, PMC_IPC_TCSS_HPD_REQ_RES, send_pmc_req(), tcss_make_hpd_mode_cmd(), and tcss_port_map::usb3_port.
Referenced by send_pmc_dp_mode_request().
|
static |
Definition at line 208 of file tcss.c.
References BIOS_DEBUG, pmc_ipc_buffer::buf, usbc_mux_info::cable, usbc_mux_info::dp_pin_mode, DP_REQ, GET_TCSS_ALT_FIELD, MODE, MODE_DP_PIN_A, MODE_DP_PIN_B, MODE_DP_PIN_C, MODE_DP_PIN_D, MODE_DP_PIN_E, MODE_DP_PIN_F, PMC_IPC_ALT_REQ_SIZE, PMC_IPC_DP_MODE, PMC_IPC_TCSS_ALTMODE_REQ_RES, usbc_mux_info::polarity, printk, send_pmc_dp_hpd_request(), send_pmc_req(), tcss_make_alt_mode_cmd_buf_0(), tcss_make_alt_mode_cmd_buf_1(), and tcss_port_map::usb3_port.
Referenced by tcss_configure_dp_mode().
|
static |
Definition at line 69 of file tcss.c.
References BIOS_DEBUG, BIOS_ERR, pmc_ipc_buffer::buf, CONNECT_REQ, PMC_IPC_USBC_CMD_ID, PMC_IPC_USBC_SUBCMD_ID, pmc_make_ipc_cmd(), pmc_send_ipc_cmd(), printk, PRIx32, TCSS_CONN_STATUS_HAS_FAILED, TCSS_CONN_STATUS_IS_FATAL, TCSS_STATUS_HAS_FAILED, and TCSS_STATUS_IS_FATAL.
Referenced by send_pmc_connect_request(), send_pmc_disconnect_request(), send_pmc_dp_hpd_request(), send_pmc_dp_mode_request(), and send_pmc_safe_mode_request().
|
static |
Definition at line 170 of file tcss.c.
References BIOS_DEBUG, pmc_ipc_buffer::buf, GET_TCSS_CD_FIELD, PMC_IPC_SAFE_REQ_SIZE, PMC_IPC_TCSS_SAFE_MODE_REQ_RES, printk, SAFE_REQ, send_pmc_req(), tcss_make_safe_mode_cmd(), and tcss_port_map::usb3_port.
Referenced by tcss_configure_dp_mode().
void tcss_configure | ( | const struct typec_aux_bias_pads | aux_bias_pads[MAX_TYPE_C_PORTS] | ) |
Definition at line 415 of file tcss.c.
References CONFIG, soc_tcss_ops::configure_aux_bias_pads, NULL, tcss_configure_dp_mode(), tcss_get_port_info(), tcss_init_mux(), and tcss_ops.
Referenced by platform_fsp_multi_phase_init_cb().
void tcss_configure_aux_bias_pads_regbar | ( | const struct typec_aux_bias_pads * | pads | ) |
Definition at line 358 of file tcss.c.
References calc_bias_ctrl_reg_value(), IOM_AUX_BIAS_CTRL_PULLDOWN_OFFSET, IOM_AUX_BIAS_CTRL_PULLUP_OFFSET, MAX_TYPE_C_PORTS, PID_IOM, and REGBAR32.
|
static |
Definition at line 288 of file tcss.c.
References BIOS_ERR, BIOS_INFO, BIT, display_init_required(), NULL, ops, printk, send_pmc_connect_request(), send_pmc_dp_mode_request(), send_pmc_safe_mode_request(), usbc_get_ops(), WAIT_FOR_DISPLAYPORT_TIMEOUT_MS, and WAIT_FOR_HPD_TIMEOUT_MS.
Referenced by tcss_configure().
const struct tcss_port_map* tcss_get_port_info | ( | size_t * | num_ports | ) |
Definition at line 384 of file tcss.c.
References ARRAY_SIZE, CONFIG, DEVICE_PATH_GENERIC, DEVICE_PATH_PCI, find_dev_nested_path(), intel_pmc_mux_conn_get_ports(), is_dev_enabled(), MAX_TYPE_C_PORTS, PCH_DEVFN_PMC, pci_root_bus(), device_path::type, tcss_port_map::usb2_port, and tcss_port_map::usb3_port.
Referenced by tcss_configure().
|
static |
Definition at line 279 of file tcss.c.
References BIOS_ERR, printk, and send_pmc_disconnect_request().
Referenced by tcss_configure().
|
static |
Definition at line 37 of file tcss.c.
References m, MODE, and TCSS_ALT_FIELD.
Referenced by send_pmc_dp_mode_request().
|
static |
Definition at line 45 of file tcss.c.
References c, and TCSS_ALT_FIELD.
Referenced by send_pmc_dp_mode_request().
|
static |
Definition at line 25 of file tcss.c.
References TCSS_CD_FIELD.
Referenced by send_pmc_connect_request(), and send_pmc_disconnect_request().
|
static |
Definition at line 60 of file tcss.c.
References TCSS_HPD_FIELD.
Referenced by send_pmc_dp_hpd_request().
|
static |
Definition at line 53 of file tcss.c.
References TCSS_CD_FIELD.
Referenced by send_pmc_safe_mode_request().
Definition at line 436 of file tcss.c.
References IOM_CSME_IMR_TBT_STATUS, PID_IOM, REGBAR32, and TBT_VALID_AUTHENTICATION.