coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
|
#include <console/console.h>
#include <delay.h>
#include <device/i2c_simple.h>
#include <edid.h>
#include <gpio.h>
#include <string.h>
#include <types.h>
#include "anx7625.h"
Go to the source code of this file.
Macros | |
#define | ANXERROR(format, ...) printk(BIOS_ERR, "%s: " format, __func__, ##__VA_ARGS__) |
#define | ANXINFO(format, ...) printk(BIOS_INFO, "%s: " format, __func__, ##__VA_ARGS__) |
#define | ANXDEBUG(format, ...) printk(BIOS_DEBUG, "%s: " format, __func__, ##__VA_ARGS__) |
#define | FLASH_LOAD_STA 0x05 |
#define | FLASH_LOAD_STA_CHK (1 << 7) |
#define ANXDEBUG | ( | format, | |
... | |||
) | printk(BIOS_DEBUG, "%s: " format, __func__, ##__VA_ARGS__) |
|
static |
Definition at line 410 of file anx7625.c.
References anx7625_dsi_video_config(), anx7625_reg_write(), anx7625_swap_dsi_lane3(), anx7625_write_and(), anx7625_write_or(), ANXERROR, mdelay(), MIPI_CLK_DET_DET_BYPASS, MIPI_CLK_HS_MANUAL_PD_EN, MIPI_CLK_MISS_CTRL, MIPI_CLK_RT_MANUAL_PD_EN, MIPI_DIGITAL_PLL_18, MIPI_DIGITAL_PLL_6, MIPI_DPI_SELECT, MIPI_HS_PWD_CLK, MIPI_HS_RT_CLK, MIPI_LANE_CTRL_10, MIPI_M_NUM_READY, MIPI_N_NUM_READY, MIPI_PD_CLK, MIPI_PD_LPTX_CH_MANUAL_PD_EN, MIPI_PHY_CONTROL_3, MIPI_TIME_HS_PRPR, MIPI_VIDEO_STABLE_CNT, RX_P1_ADDR, SELECT_DSI, and val.
Referenced by anx7625_dsi_config().
|
static |
Definition at line 201 of file anx7625.c.
References anx7625_reduction_of_a_fraction(), ANXERROR, ANXINFO, m, PLL_OUT_FREQ_ABS_MAX, PLL_OUT_FREQ_ABS_MIN, PLL_OUT_FREQ_MIN, POST_DIVIDER_MAX, POST_DIVIDER_MIN, and XTAL_FRQ.
Referenced by anx7625_dsi_video_config().
Definition at line 698 of file anx7625.c.
References anx7625_reg_write(), ANXERROR, ANXINFO, AP_AV_STATUS, AP_DISABLE_PD, and RX_P0_ADDR.
Referenced by anx7625_power_on_init().
Definition at line 845 of file anx7625.c.
References ANXERROR, decode_edid(), EDID_CONFORMANT, FOUR_BLOCK_SIZE, ONE_BLOCK_SIZE, and sp_tx_edid_read().
Referenced by bridge_anx7625_get_edid(), configure_display(), and get_panel_description().
Definition at line 828 of file anx7625.c.
References anx7625_dsi_config(), anx7625_parse_edid(), ANXERROR, and ANXINFO.
Referenced by bridge_anx7625_post_power_on(), and configure_display().
|
static |
Definition at line 472 of file anx7625.c.
References anx7625_api_dsi_config(), anx7625_write_and(), anx7625_write_or(), ANXERROR, ANXINFO, AP_AV_STATUS, AP_MIPI_MUTE, AP_MIPI_RX_EN, DSC_EN, R_DSC_CTRL_0, and RX_P0_ADDR.
Referenced by anx7625_dp_start().
|
static |
Definition at line 301 of file anx7625.c.
References ACTIVE_LINES_H, ACTIVE_LINES_L, anx7625_calculate_m_n(), anx7625_odfc_config(), anx7625_reg_write(), anx7625_write_and(), anx7625_write_or(), ANXERROR, ANXINFO, display_timing::hactive, display_timing::hback_porch, display_timing::hfront_porch, HORIZONTAL_ACTIVE_PIXELS_H, HORIZONTAL_ACTIVE_PIXELS_L, HORIZONTAL_BACK_PORCH_H, HORIZONTAL_BACK_PORCH_L, HORIZONTAL_FRONT_PORCH_H, HORIZONTAL_FRONT_PORCH_L, HORIZONTAL_SYNC_WIDTH_H, HORIZONTAL_SYNC_WIDTH_L, HORIZONTAL_TOTAL_PIXELS_H, HORIZONTAL_TOTAL_PIXELS_L, display_timing::hsync_len, htotal, display_timing::k_val, m, MIPI_DIGITAL_ADJ_1, MIPI_LANE_CTRL_0, MIPI_PLL_M_NUM_15_8, MIPI_PLL_M_NUM_23_16, MIPI_PLL_M_NUM_7_0, MIPI_PLL_N_NUM_15_8, MIPI_PLL_N_NUM_23_16, MIPI_PLL_N_NUM_7_0, PIXEL_CLOCK_H, PIXEL_CLOCK_L, display_timing::pixelclock, RX_P0_ADDR, RX_P1_ADDR, RX_P2_ADDR, display_timing::vactive, display_timing::vback_porch, VERTICAL_BACK_PORCH, VERTICAL_FRONT_PORCH, VERTICAL_SYNC_WIDTH, display_timing::vfront_porch, and display_timing::vsync_len.
Referenced by anx7625_api_dsi_config().
|
static |
Definition at line 770 of file anx7625.c.
References anx7625_reg_read(), anx7625_start_dp_work(), ANXERROR, ANXINFO, HPD_STATUS, RX_P0_ADDR, and SYSTEM_STSTUS.
Referenced by anx7625_init().
int anx7625_init | ( | uint8_t | bus | ) |
Definition at line 866 of file anx7625.c.
References anx7625_hpd_change_detect(), anx7625_power_on_init(), ANXERROR, mdelay(), and retry.
Referenced by bridge_anx7625_get_edid(), configure_display(), and get_panel_description().
Definition at line 269 of file anx7625.c.
References anx7625_write_and(), anx7625_write_or(), ANXERROR, MIPI_DIGITAL_PLL_16, MIPI_DIGITAL_PLL_7, MIPI_DIGITAL_PLL_8, MIPI_FREF_D_IND, MIPI_PLL_RESET_N, MIPI_PLL_VCO_TUNE_REG_VAL, REF_CLK_27000kHz, and RX_P1_ADDR.
Referenced by anx7625_dsi_video_config().
|
static |
Definition at line 789 of file anx7625.c.
References ANXINFO, edid_mode::ha, display_timing::hactive, display_timing::hback_porch, edid_mode::hbl, edid_mode::hborder, display_timing::hfront_porch, edid_mode::hso, edid_mode::hspw, display_timing::hsync_len, display_timing::k_val, edid::manufacturer_name, edid::mode, edid_mode::pixel_clock, display_timing::pixelclock, strncmp(), edid_mode::va, display_timing::vactive, display_timing::vback_porch, edid_mode::vbl, edid_mode::vborder, display_timing::vfront_porch, edid_mode::vso, edid_mode::vspw, and display_timing::vsync_len.
Referenced by anx7625_dp_start().
|
static |
Definition at line 718 of file anx7625.c.
References anx7625_disable_pd_protocol(), anx7625_reg_read(), anx7625_reg_write(), ANXERROR, ANXINFO, FLASH_LOAD_STA, FLASH_LOAD_STA_CHK, mdelay(), OCM_FW_REVERSION, OCM_FW_VERSION, OCM_LOADING_TIME, RX_P0_ADDR, val, version, XTAL_FRQ_27M, and XTAL_FRQ_SEL.
Referenced by anx7625_init().
Definition at line 171 of file anx7625.c.
References gcd(), and MAX_UNSIGNED_24BIT.
Referenced by anx7625_calculate_m_n().
|
static |
Definition at line 79 of file anx7625.c.
References ANXERROR, buf, i2c_access_workaround(), and i2c_read_bytes().
Referenced by edid_read(), and segments_edid_read().
Definition at line 65 of file anx7625.c.
References ANXERROR, i2c_access_workaround(), i2c_readb(), offset, and val.
Referenced by anx7625_hpd_change_detect(), anx7625_power_on_init(), anx7625_start_dp_work(), anx7625_swap_dsi_lane3(), anx7625_write_and(), anx7625_write_or(), sp_tx_get_edid_block(), and wait_aux_op_finish().
|
static |
Definition at line 94 of file anx7625.c.
References ANXERROR, i2c_access_workaround(), and i2c_writeb().
Referenced by anx7625_api_dsi_config(), anx7625_disable_pd_protocol(), anx7625_dsi_video_config(), anx7625_power_on_init(), anx7625_swap_dsi_lane3(), anx7625_write_and(), anx7625_write_or(), segments_edid_read(), sp_tx_aux_rd(), sp_tx_aux_wr(), and sp_tx_edid_read().
Definition at line 748 of file anx7625.c.
References anx7625_reg_read(), anx7625_write_and(), anx7625_write_or(), ANXINFO, RX_P1_ADDR, and val.
Referenced by anx7625_hpd_change_detect().
|
static |
Definition at line 394 of file anx7625.c.
References anx7625_reg_read(), anx7625_reg_write(), ANXERROR, MIPI_SWAP, MIPI_SWAP_CH3, RX_P1_ADDR, and val.
Referenced by anx7625_api_dsi_config().
Definition at line 121 of file anx7625.c.
References anx7625_reg_read(), anx7625_reg_write(), mask, offset, and val.
Referenced by anx7625_api_dsi_config(), anx7625_dsi_config(), anx7625_dsi_video_config(), anx7625_odfc_config(), anx7625_start_dp_work(), sp_tx_edid_read(), and sp_tx_rst_aux().
Definition at line 108 of file anx7625.c.
References anx7625_reg_read(), anx7625_reg_write(), mask, offset, and val.
Referenced by anx7625_api_dsi_config(), anx7625_dsi_config(), anx7625_dsi_video_config(), anx7625_odfc_config(), anx7625_start_dp_work(), sp_tx_aux_rd(), sp_tx_aux_wr(), and sp_tx_rst_aux().
Definition at line 553 of file anx7625.c.
References anx7625_reg_block_read(), ANXERROR, AP_AUX_BUFF_START, MAX_DPCD_BUFFER_SIZE, offset, RX_P0_ADDR, sp_tx_aux_rd(), sp_tx_aux_wr(), and sp_tx_rst_aux().
Referenced by sp_tx_edid_read().
Definition at line 155 of file anx7625.c.
Referenced by anx7625_reduction_of_a_fraction().
Definition at line 25 of file anx7625.c.
References ANXERROR, i2c_writeb(), offset, RSVD_00_ADDR, RSVD_39_ADDR, RSVD_60_ADDR, RSVD_7F_ADDR, RSVD_D1_ADDR, RX_P0_ADDR, RX_P1_ADDR, TCPC_INTERFACE_ADDR, TX_P0_ADDR, and TX_P1_ADDR.
Referenced by anx7625_reg_block_read(), anx7625_reg_read(), and anx7625_reg_write().
|
static |
Definition at line 577 of file anx7625.c.
References anx7625_reg_block_read(), anx7625_reg_write(), ANXERROR, AP_AUX_ADDR_7_0, AP_AUX_BUFF_START, AP_AUX_COMMAND, AP_AUX_CTRL_ADDRONLY, AP_AUX_CTRL_OP_EN, AP_AUX_CTRL_STATUS, buf, MAX_DPCD_BUFFER_SIZE, offset, RX_P0_ADDR, sp_tx_aux_rd(), sp_tx_aux_wr(), sp_tx_rst_aux(), and wait_aux_op_finish().
Referenced by sp_tx_edid_read().
Definition at line 521 of file anx7625.c.
References anx7625_reg_write(), anx7625_write_or(), AP_AUX_COMMAND, AP_AUX_CTRL_OP_EN, AP_AUX_CTRL_STATUS, RX_P0_ADDR, and wait_aux_op_finish().
Referenced by edid_read(), segments_edid_read(), and sp_tx_get_edid_block().
Definition at line 510 of file anx7625.c.
References anx7625_reg_write(), anx7625_write_or(), AP_AUX_BUFF_START, AP_AUX_COMMAND, AP_AUX_CTRL_OP_EN, AP_AUX_CTRL_STATUS, offset, RX_P0_ADDR, and wait_aux_op_finish().
Referenced by edid_read(), segments_edid_read(), and sp_tx_get_edid_block().
Definition at line 619 of file anx7625.c.
References anx7625_reg_write(), anx7625_write_and(), ANXERROR, AP_AUX_ADDR_15_8, AP_AUX_ADDR_19_16, AP_AUX_ADDR_7_0, count, die(), edid_read(), MAX_DPCD_BUFFER_SIZE, memcpy(), offset, RX_P0_ADDR, segments_edid_read(), sp_tx_get_edid_block(), and sp_tx_rst_aux().
Referenced by anx7625_dp_get_edid().
|
static |
Definition at line 531 of file anx7625.c.
References anx7625_reg_read(), ANXERROR, ANXINFO, AP_AUX_BUFF_START, RX_P0_ADDR, sp_tx_aux_rd(), sp_tx_aux_wr(), and val.
Referenced by sp_tx_edid_read().
|
static |
Definition at line 501 of file anx7625.c.
References anx7625_write_and(), anx7625_write_or(), AUX_RST, RST_CTRL2, and TX_P2_ADDR.
Referenced by edid_read(), segments_edid_read(), and sp_tx_edid_read().
|
static |
Definition at line 134 of file anx7625.c.
References anx7625_reg_read(), ANXDEBUG, ANXERROR, AP_AUX_CTRL_OP_EN, AP_AUX_CTRL_STATUS, mdelay(), retry, RX_P0_ADDR, and val.
Referenced by segments_edid_read(), sp_tx_aux_rd(), and sp_tx_aux_wr().