Lines Matching +full:source +full:- +full:pdos
4 * SPDX-License-Identifier: Apache-2.0
20 /* A Source power role evauates to 1. See usbc_tc.h: TC_ROLE_SOURCE */
22 #error "Unsupported board: Only Source device supported"
32 /** Source Capabilities */
34 /** Number of Source Capabilities */
91 *rp = dpm_data->rp; in port0_policy_cb_get_src_rp()
114 dpm_data->vconn_pol = pol; in port0_policy_cb_vconn_en()
131 * @brief PE calls this function to get the Source Caps that will be sent
135 const uint32_t **pdos, uint32_t *num_pdos) in port0_policy_cb_get_src_caps() argument
139 *pdos = dpm_data->src_caps; in port0_policy_cb_get_src_caps()
140 *num_pdos = dpm_data->src_cap_cnt; in port0_policy_cb_get_src_caps()
156 dpm_data->sink_request.raw_value = request_msg; in port0_policy_cb_check_sink_request()
157 obj_pos = dpm_data->sink_request.fixed.object_pos; in port0_policy_cb_check_sink_request()
159 PD_CONVERT_FIXED_PDO_CURRENT_TO_MA(dpm_data->sink_request.fixed.operating_current); in port0_policy_cb_check_sink_request()
161 if (obj_pos == 0 || obj_pos > dpm_data->src_cap_cnt) { in port0_policy_cb_check_sink_request()
165 pdo.raw_value = dpm_data->src_caps[obj_pos - 1]; in port0_policy_cb_check_sink_request()
167 if (dpm_data->sink_request.fixed.operating_current > pdo.max_current) { in port0_policy_cb_check_sink_request()
171 dpm_data->obj_pos = obj_pos; in port0_policy_cb_check_sink_request()
194 return dpm_data->ps_ready; in port0_policy_cb_is_ps_ready()
214 if (obj_pos == 0 || obj_pos > dpm_data->src_cap_cnt) { in port0_policy_cb_present_contract_is_valid()
218 pdo.raw_value = dpm_data->src_caps[obj_pos - 1]; in port0_policy_cb_present_contract_is_valid()
247 dpm_data->ps_tran_start = true; in port0_notify()
303 vconn_ctrl_set(dpm_data->vconn_pol); in port0_policy_check()
327 /* Register USB-C Callbacks */ in main()
339 /* Register Policy callback to send the source caps to the sink */ in main()
365 /* Start the USB-C Subsystem */ in main()