| 1 |
|
| 2 |
|
| 3 |
#include <gpio.h> |
| 4 |
#include <soc/platform_descriptors.h> |
| 5 |
#include <types.h> |
| 6 |
#include "display_card_type.h" |
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
static const fsp_dxio_descriptor birman_dxio_descriptors[] = { |
| 11 |
{ |
| 12 |
.engine_type = PCIE_ENGINE, |
| 13 |
.port_present = true, |
| 14 |
.start_logical_lane = 0, |
| 15 |
.end_logical_lane = 0, |
| 16 |
.device_number = 2, |
| 17 |
.function_number = 1, |
| 18 |
.link_speed_capability = GEN3, |
| 19 |
.turn_off_unused_lanes = true, |
| 20 |
.link_aspm = 2, |
| 21 |
.link_hotplug = HOTPLUG_ENHANCED, |
| 22 |
.clk_req = CLK_REQ3, |
| 23 |
}, |
| 24 |
{ |
| 25 |
.engine_type = PCIE_ENGINE, |
| 26 |
.port_present = true, |
| 27 |
.start_logical_lane = 1, |
| 28 |
.end_logical_lane = 1, |
| 29 |
.device_number = 2, |
| 30 |
.function_number = 2, |
| 31 |
.link_speed_capability = GEN3, |
| 32 |
.turn_off_unused_lanes = true, |
| 33 |
.link_aspm = 2, |
| 34 |
.link_hotplug = HOTPLUG_ENHANCED, |
| 35 |
.clk_req = CLK_REQ1, |
| 36 |
}, |
| 37 |
{ |
| 38 |
.engine_type = PCIE_ENGINE, |
| 39 |
.port_present = true, |
| 40 |
.start_logical_lane = 2, |
| 41 |
.end_logical_lane = 3, |
| 42 |
.device_number = 2, |
| 43 |
.function_number = 3, |
| 44 |
.link_speed_capability = GEN3, |
| 45 |
.turn_off_unused_lanes = true, |
| 46 |
.link_aspm = 2, |
| 47 |
.link_hotplug = HOTPLUG_ENHANCED, |
| 48 |
.gpio_group_id = GPIO_27, |
| 49 |
.clk_req = CLK_REQ0, |
| 50 |
}, |
| 51 |
}; |
| 52 |
|
| 53 |
static fsp_ddi_descriptor birman_ddi_descriptors[] = { |
| 54 |
{ |
| 55 |
.connector_type = DDI_EDP, |
| 56 |
.aux_index = DDI_AUX1, |
| 57 |
.hdp_index = DDI_HDP1 |
| 58 |
}, |
| 59 |
{ |
| 60 |
.connector_type = DDI_HDMI, |
| 61 |
.aux_index = DDI_AUX2, |
| 62 |
.hdp_index = DDI_HDP2 |
| 63 |
}, |
| 64 |
{ |
| 65 |
.connector_type = DDI_DP_W_TYPEC, |
| 66 |
.aux_index = DDI_AUX3, |
| 67 |
.hdp_index = DDI_HDP3, |
| 68 |
}, |
| 69 |
{ |
| 70 |
.connector_type = DDI_DP_W_TYPEC, |
| 71 |
.aux_index = DDI_AUX4, |
| 72 |
.hdp_index = DDI_HDP4, |
| 73 |
}, |
| 74 |
{ |
| 75 |
.connector_type = DDI_DP_W_TYPEC, |
| 76 |
.aux_index = DDI_AUX5, |
| 77 |
.hdp_index = DDI_HDP5, |
| 78 |
} |
| 79 |
}; |
| 80 |
|
| 81 |
void mainboard_get_dxio_ddi_descriptors( |
| 82 |
const fsp_dxio_descriptor **dxio_descs, size_t *dxio_num, |
| 83 |
const fsp_ddi_descriptor **ddi_descs, size_t *ddi_num) |
| 84 |
{ |
| 85 |
birman_ddi_descriptors[1].connector_type = get_ddi1_type(); |
| 86 |
|
| 87 |
*dxio_descs = birman_dxio_descriptors; |
| 88 |
*dxio_num = ARRAY_SIZE(birman_dxio_descriptors); |
| 89 |
*ddi_descs = birman_ddi_descriptors; |
| 90 |
*ddi_num = ARRAY_SIZE(birman_ddi_descriptors); |
| 91 |
} |