Lines Matching +full:retimer +full:- +full:switch
1 // SPDX-License-Identifier: GPL-2.0
89 return -EOPNOTSUPP; in usb4_native_switch_op()
114 const struct tb_cm_ops *cm_ops = sw->tb->cm_ops; in __usb4_switch_op()
117 return -EINVAL; in __usb4_switch_op()
124 if (cm_ops->usb4_switch_op) { in __usb4_switch_op()
127 ret = cm_ops->usb4_switch_op(sw, opcode, metadata, status, in __usb4_switch_op()
130 if (ret != -EOPNOTSUPP) in __usb4_switch_op()
159 * usb4_switch_check_wakes() - Check for wakes and notify PM core about them
188 if (!port->cap_usb4) in usb4_switch_check_wakes()
192 port->cap_usb4 + PORT_CS_18, 1)) in usb4_switch_check_wakes()
203 usb4 = port->usb4; in usb4_switch_check_wakes()
204 if (device_may_wakeup(&usb4->dev) && wakeup_usb4) in usb4_switch_check_wakes()
205 pm_wakeup_event(&usb4->dev, 0); in usb4_switch_check_wakes()
211 pm_wakeup_event(&sw->dev, 0); in usb4_switch_check_wakes()
218 if (!port->cap_usb4) in link_is_usb4()
222 port->cap_usb4 + PORT_CS_18, 1)) in link_is_usb4()
229 * usb4_switch_setup() - Additional setup for USB4 device
234 * enabled (e.g the parent switch also supports them). If USB tunneling
236 * switch upstream) then the internal xHCI controller is enabled
258 sw->link_usb4 = link_is_usb4(down); in usb4_switch_setup()
259 tb_sw_dbg(sw, "link: %s\n", sw->link_usb4 ? "USB4" : "TBT"); in usb4_switch_setup()
271 if (tb_acpi_may_tunnel_usb3() && sw->link_usb4 && in usb4_switch_setup()
300 * usb4_switch_configuration_valid() - Set tunneling configuration to be valid
333 * usb4_switch_read_uid() - Read UID from USB4 router
337 * Reads 64-bit UID from USB4 router config space.
362 return status ? -EIO : 0; in usb4_switch_drom_read_block()
366 * usb4_switch_drom_read() - Read arbitrary bytes from USB4 router DROM
373 * should always work but for hosts it may return %-EOPNOTSUPP in which
384 * usb4_switch_lane_bonding_possible() - Are conditions met for lane bonding
397 ret = tb_port_read(up, &val, TB_CFG_PORT, up->cap_usb4 + PORT_CS_18, 1); in usb4_switch_lane_bonding_possible()
405 * usb4_switch_set_wake() - Enabled/disable wake
429 if (!port->cap_usb4) in usb4_switch_set_wake()
433 port->cap_usb4 + PORT_CS_19, 1); in usb4_switch_set_wake()
443 bool wakeup = runtime || device_may_wakeup(&port->usb4->dev); in usb4_switch_set_wake()
454 port->cap_usb4 + PORT_CS_19, 1); in usb4_switch_set_wake()
485 * usb4_switch_set_sleep() - Prepare the router to enter sleep
512 * usb4_switch_nvm_sector_size() - Return router NVM sector size
517 * %-EOPNOTSUPP.
531 return status == 0x2 ? -EOPNOTSUPP : -EIO; in usb4_switch_nvm_sector_size()
554 return status ? -EIO : 0; in usb4_switch_nvm_read_block()
558 * usb4_switch_nvm_read() - Read arbitrary bytes from router NVM
565 * %-EOPNOTSUPP.
575 * usb4_switch_nvm_set_offset() - Set NVM write offset
599 return status ? -EIO : 0; in usb4_switch_nvm_set_offset()
614 return status ? -EIO : 0; in usb4_switch_nvm_write_next_block()
618 * usb4_switch_nvm_write() - Write to the router NVM
625 * write is not supported returns %-EOPNOTSUPP.
641 * usb4_switch_nvm_authenticate() - Authenticate new NVM
658 switch (ret) { in usb4_switch_nvm_authenticate()
663 case -EACCES: in usb4_switch_nvm_authenticate()
664 case -ENOTCONN: in usb4_switch_nvm_authenticate()
665 case -ETIMEDOUT: in usb4_switch_nvm_authenticate()
674 * usb4_switch_nvm_authenticate_status() - Read status of last NVM authenticate
687 const struct tb_cm_ops *cm_ops = sw->tb->cm_ops; in usb4_switch_nvm_authenticate_status()
692 if (cm_ops->usb4_switch_nvm_authenticate_status) { in usb4_switch_nvm_authenticate_status()
693 ret = cm_ops->usb4_switch_nvm_authenticate_status(sw, status); in usb4_switch_nvm_authenticate_status()
694 if (ret != -EOPNOTSUPP) in usb4_switch_nvm_authenticate_status()
706 return -EBUSY; in usb4_switch_nvm_authenticate_status()
708 return -EOPNOTSUPP; in usb4_switch_nvm_authenticate_status()
720 * usb4_switch_credits_init() - Read buffer allocation parameters
724 * allocation fields accordingly. Specifically @sw->credits_allocation
744 return -EIO; in usb4_switch_credits_init()
748 return -EMSGSIZE; in usb4_switch_credits_init()
750 max_usb3 = -1; in usb4_switch_credits_init()
751 min_dp_aux = -1; in usb4_switch_credits_init()
752 min_dp_main = -1; in usb4_switch_credits_init()
753 max_pcie = -1; in usb4_switch_credits_init()
754 max_dma = -1; in usb4_switch_credits_init()
764 switch (index) { in usb4_switch_credits_init()
794 * issues, log a warning and fall back using the hard-coded in usb4_switch_credits_init()
842 sw->credit_allocation = true; in usb4_switch_credits_init()
844 sw->max_usb3_credits = max_usb3; in usb4_switch_credits_init()
846 sw->min_dp_aux_credits = min_dp_aux; in usb4_switch_credits_init()
848 sw->min_dp_main_credits = min_dp_main; in usb4_switch_credits_init()
850 sw->max_pcie_credits = max_pcie; in usb4_switch_credits_init()
852 sw->max_dma_credits = max_dma; in usb4_switch_credits_init()
857 return -EINVAL; in usb4_switch_credits_init()
861 * usb4_switch_query_dp_resource() - Query availability of DP IN resource
871 u32 metadata = in->port; in usb4_switch_query_dp_resource()
881 if (ret == -EOPNOTSUPP) in usb4_switch_query_dp_resource()
890 * usb4_switch_alloc_dp_resource() - Allocate DP IN resource
896 * returns negative errno, in particular %-EBUSY if the resource is
901 u32 metadata = in->port; in usb4_switch_alloc_dp_resource()
907 if (ret == -EOPNOTSUPP) in usb4_switch_alloc_dp_resource()
912 return status ? -EBUSY : 0; in usb4_switch_alloc_dp_resource()
916 * usb4_switch_dealloc_dp_resource() - Releases allocated DP IN resource
924 u32 metadata = in->port; in usb4_switch_dealloc_dp_resource()
930 if (ret == -EOPNOTSUPP) in usb4_switch_dealloc_dp_resource()
935 return status ? -EIO : 0; in usb4_switch_dealloc_dp_resource()
949 if (!p->link_nr) { in usb4_port_idx()
960 * usb4_switch_map_pcie_down() - Map USB4 port to a PCIe downstream adapter
991 * usb4_switch_map_usb3_down() - Map USB4 port to a USB3 downstream adapter
1022 * usb4_switch_add_ports() - Add USB4 ports for this router
1042 if (!port->cap_usb4) in usb4_switch_add_ports()
1051 port->usb4 = usb4; in usb4_switch_add_ports()
1058 * usb4_switch_remove_ports() - Removes USB4 ports from this router
1068 if (port->usb4) { in usb4_switch_remove_ports()
1069 usb4_port_device_remove(port->usb4); in usb4_switch_remove_ports()
1070 port->usb4 = NULL; in usb4_switch_remove_ports()
1076 * usb4_port_unlock() - Unlock USB4 downstream port
1096 * usb4_port_hotplug_enable() - Enables hotplug for a port
1100 * to be used on lane, DP-IN, and DP-OUT adapters.
1116 * usb4_port_reset() - Issue downstream port reset
1126 if (!port->cap_usb4) in usb4_port_reset()
1127 return -EINVAL; in usb4_port_reset()
1130 port->cap_usb4 + PORT_CS_19, 1); in usb4_port_reset()
1137 port->cap_usb4 + PORT_CS_19, 1); in usb4_port_reset()
1144 port->cap_usb4 + PORT_CS_19, 1); in usb4_port_reset()
1151 port->cap_usb4 + PORT_CS_19, 1); in usb4_port_reset()
1159 if (!port->cap_usb4) in usb4_port_set_configured()
1160 return -EINVAL; in usb4_port_set_configured()
1163 port->cap_usb4 + PORT_CS_19, 1); in usb4_port_set_configured()
1173 port->cap_usb4 + PORT_CS_19, 1); in usb4_port_set_configured()
1177 * usb4_port_configure() - Set USB4 port configured
1188 * usb4_port_unconfigure() - Set USB4 port unconfigured
1203 if (!port->cap_usb4) in usb4_set_xdomain_configured()
1204 return -EINVAL; in usb4_set_xdomain_configured()
1207 port->cap_usb4 + PORT_CS_19, 1); in usb4_set_xdomain_configured()
1217 port->cap_usb4 + PORT_CS_19, 1); in usb4_set_xdomain_configured()
1221 * usb4_port_configure_xdomain() - Configure port for XDomain
1230 xd->link_usb4 = link_is_usb4(port); in usb4_port_configure_xdomain()
1235 * usb4_port_unconfigure_xdomain() - Unconfigure port for XDomain
1264 return -ETIMEDOUT; in usb4_port_wait_for_bit()
1270 return -EINVAL; in usb4_port_read_data()
1272 return tb_port_read(port, data, TB_CFG_PORT, port->cap_usb4 + PORT_CS_2, in usb4_port_read_data()
1280 return -EINVAL; in usb4_port_write_data()
1282 return tb_port_write(port, data, TB_CFG_PORT, port->cap_usb4 + PORT_CS_2, in usb4_port_write_data()
1293 if (!port->cap_usb4) in usb4_port_sb_read()
1294 return -EINVAL; in usb4_port_sb_read()
1304 port->cap_usb4 + PORT_CS_1, 1); in usb4_port_sb_read()
1308 ret = usb4_port_wait_for_bit(port, port->cap_usb4 + PORT_CS_1, in usb4_port_sb_read()
1314 port->cap_usb4 + PORT_CS_1, 1); in usb4_port_sb_read()
1319 return -ENODEV; in usb4_port_sb_read()
1321 return -EIO; in usb4_port_sb_read()
1333 if (!port->cap_usb4) in usb4_port_sb_write()
1334 return -EINVAL; in usb4_port_sb_write()
1351 port->cap_usb4 + PORT_CS_1, 1); in usb4_port_sb_write()
1355 ret = usb4_port_wait_for_bit(port, port->cap_usb4 + PORT_CS_1, in usb4_port_sb_write()
1361 port->cap_usb4 + PORT_CS_1, 1); in usb4_port_sb_write()
1366 return -ENODEV; in usb4_port_sb_write()
1368 return -EIO; in usb4_port_sb_write()
1375 switch (val) { in usb4_port_sb_opcode_err_to_errno()
1379 return -EAGAIN; in usb4_port_sb_opcode_err_to_errno()
1381 return -EOPNOTSUPP; in usb4_port_sb_opcode_err_to_errno()
1383 return -EIO; in usb4_port_sb_opcode_err_to_errno()
1413 return -ETIMEDOUT; in usb4_port_sb_op()
1432 * usb4_port_router_offline() - Put the USB4 port to offline mode
1437 * called before retimer access is done when the USB4 links is not up.
1448 * usb4_port_router_online() - Put the USB4 port back to online
1459 * usb4_port_enumerate_retimers() - Send RT broadcast transaction
1476 * usb4_port_clx_supported() - Check if CLx is supported by the link
1488 port->cap_usb4 + PORT_CS_18, 1); in usb4_port_clx_supported()
1496 * usb4_port_asym_supported() - If the port supports asymmetric link
1506 if (!port->cap_usb4) in usb4_port_asym_supported()
1509 if (tb_port_read(port, &val, TB_CFG_PORT, port->cap_usb4 + PORT_CS_18, 1)) in usb4_port_asym_supported()
1516 * usb4_port_asym_set_link_width() - Set link width to asymmetric or symmetric
1528 if (!port->cap_phy) in usb4_port_asym_set_link_width()
1529 return -EINVAL; in usb4_port_asym_set_link_width()
1532 port->cap_phy + LANE_ADP_CS_1, 1); in usb4_port_asym_set_link_width()
1537 switch (width) { in usb4_port_asym_set_link_width()
1551 return -EINVAL; in usb4_port_asym_set_link_width()
1555 port->cap_phy + LANE_ADP_CS_1, 1); in usb4_port_asym_set_link_width()
1559 * usb4_port_asym_start() - Start symmetry change and wait for completion
1566 * Returns %0 in case of success, %-ETIMEDOUT if case of timeout or
1575 port->cap_usb4 + PORT_CS_19, 1); in usb4_port_asym_start()
1583 port->cap_usb4 + PORT_CS_19, 1); in usb4_port_asym_start()
1591 ret = usb4_port_wait_for_bit(port, port->cap_usb4 + PORT_CS_19, in usb4_port_asym_start()
1597 return usb4_port_wait_for_bit(port, port->cap_usb4 + PORT_CS_18, in usb4_port_asym_start()
1602 * usb4_port_margining_caps() - Read USB4 port marginig capabilities
1622 * usb4_port_hw_margin() - Run hardware lane margining on port
1665 * usb4_port_sw_margin() - Run software lane margining on port
1701 * usb4_port_sw_margin_errors() - Read the software margining error counters
1730 * usb4_port_retimer_set_inbound_sbtx() - Enable sideband channel transactions
1732 * @index: Retimer index
1744 if (ret != -ENODEV) in usb4_port_retimer_set_inbound_sbtx()
1748 * Per the USB4 retimer spec, the retimer is not required to in usb4_port_retimer_set_inbound_sbtx()
1749 * send an RT (Retimer Transaction) response for the first in usb4_port_retimer_set_inbound_sbtx()
1757 * usb4_port_retimer_unset_inbound_sbtx() - Disable sideband channel transactions
1759 * @index: Retimer index
1771 * usb4_port_retimer_read() - Read from retimer sideband registers
1773 * @index: Retimer index
1778 * Function reads retimer sideband registers starting from @reg. The
1779 * retimer is connected to @port at @index. Returns %0 in case of
1780 * success, and read data is copied to @buf. If there is no retimer
1781 * present at given @index returns %-ENODEV. In any other failure
1792 * usb4_port_retimer_write() - Write to retimer sideband registers
1794 * @index: Retimer index
1799 * Writes retimer sideband registers starting from @reg. The retimer is
1801 * is no retimer present at given @index returns %-ENODEV. In any other
1812 * usb4_port_retimer_is_last() - Is the retimer last on-board retimer
1814 * @index: Retimer index
1816 * If the retimer at @index is last one (connected directly to the
1817 * Type-C port) this function returns %1. If it is not returns %0. If
1818 * the retimer is not present returns %-ENODEV. Otherwise returns
1837 * usb4_port_retimer_nvm_sector_size() - Read retimer NVM sector size
1839 * @index: Retimer index
1841 * Reads NVM sector size (in bytes) of a retimer at @index. This
1842 * operation can be used to determine whether the retimer supports NVM
1844 * in case of error. Specifically returns %-ENODEV if there is no
1845 * retimer at @index.
1863 * usb4_port_retimer_nvm_set_offset() - Set NVM write offset
1865 * @index: Retimer index
1902 struct tb_port *port = info->port; in usb4_port_retimer_nvm_write_next_block()
1903 u8 index = info->index; in usb4_port_retimer_nvm_write_next_block()
1916 * usb4_port_retimer_nvm_write() - Write to retimer NVM
1918 * @index: Retimer index
1923 * Writes @size bytes from @buf to the retimer NVM. Used for NVM
1925 * errno in case of failure. Specifically returns %-ENODEV if there is
1926 * no retimer at @index.
1943 * usb4_port_retimer_nvm_authenticate() - Start retimer NVM upgrade
1945 * @index: Retimer index
1949 * successful the retimer restarts with the new NVM and may not have the
1959 * authentication completes the retimer index is not set anymore in usb4_port_retimer_nvm_authenticate()
1968 * usb4_port_retimer_nvm_authenticate_status() - Read status of NVM upgrade
1970 * @index: Retimer index
1992 switch (ret) { in usb4_port_retimer_nvm_authenticate_status()
1997 case -EAGAIN: in usb4_port_retimer_nvm_authenticate_status()
2015 struct tb_port *port = info->port; in usb4_port_retimer_nvm_read_block()
2016 u8 index = info->index; in usb4_port_retimer_nvm_read_block()
2038 * usb4_port_retimer_nvm_read() - Read contents of retimer NVM
2040 * @index: Retimer index
2045 * Reads retimer NVM and copies the contents to @buf. Returns %0 if the
2047 * Specifically returns %-ENODEV if there is no retimer at @index.
2062 if (port->max_bw) in usb4_usb3_port_max_bandwidth()
2063 return min(bw, port->max_bw); in usb4_usb3_port_max_bandwidth()
2068 * usb4_usb3_port_max_link_rate() - Maximum support USB3 link rate
2080 return -EINVAL; in usb4_usb3_port_max_link_rate()
2083 port->cap_adap + ADP_USB3_CS_4, 1); in usb4_usb3_port_max_link_rate()
2094 * usb4_usb3_port_actual_link_rate() - Established USB3 link rate
2106 return -EINVAL; in usb4_usb3_port_actual_link_rate()
2109 port->cap_adap + ADP_USB3_CS_4, 1); in usb4_usb3_port_actual_link_rate()
2128 return -EINVAL; in usb4_usb3_port_cm_request()
2129 if (tb_route(port->sw)) in usb4_usb3_port_cm_request()
2130 return -EINVAL; in usb4_usb3_port_cm_request()
2133 port->cap_adap + ADP_USB3_CS_2, 1); in usb4_usb3_port_cm_request()
2143 port->cap_adap + ADP_USB3_CS_2, 1); in usb4_usb3_port_cm_request()
2152 return usb4_port_wait_for_bit(port, port->cap_adap + ADP_USB3_CS_1, in usb4_usb3_port_cm_request()
2178 /* 1 uframe is 1/8 ms (125 us) -> 1 / 8000 s */ in mbps_to_usb3_bw()
2191 port->cap_adap + ADP_USB3_CS_2, 1); in usb4_usb3_port_read_allocated_bandwidth()
2196 port->cap_adap + ADP_USB3_CS_3, 1); in usb4_usb3_port_read_allocated_bandwidth()
2212 * usb4_usb3_port_allocated_bandwidth() - Bandwidth allocated for USB3
2245 port->cap_adap + ADP_USB3_CS_1, 1); in usb4_usb3_port_read_consumed_bandwidth()
2250 port->cap_adap + ADP_USB3_CS_3, 1); in usb4_usb3_port_read_consumed_bandwidth()
2282 return -EINVAL; in usb4_usb3_port_write_allocated_bandwidth()
2285 port->cap_adap + ADP_USB3_CS_3, 1); in usb4_usb3_port_write_allocated_bandwidth()
2295 port->cap_adap + ADP_USB3_CS_2, 1); in usb4_usb3_port_write_allocated_bandwidth()
2304 port->cap_adap + ADP_USB3_CS_2, 1); in usb4_usb3_port_write_allocated_bandwidth()
2308 * usb4_usb3_port_allocate_bandwidth() - Allocate bandwidth for USB3
2356 * usb4_usb3_port_release_bandwidth() - Release allocated USB3 bandwidth
2406 if (!tb_switch_is_usb4(port->sw)) in is_usb4_dpin()
2412 * usb4_dp_port_set_cm_id() - Assign CM ID to the DP IN adapter
2417 * otherwise. Speficially returns %-EOPNOTSUPP if the @port does not
2426 return -EOPNOTSUPP; in usb4_dp_port_set_cm_id()
2429 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_cm_id()
2437 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_cm_id()
2441 * usb4_dp_port_bandwidth_mode_supported() - Is the bandwidth allocation mode
2457 port->cap_adap + DP_LOCAL_CAP, 1); in usb4_dp_port_bandwidth_mode_supported()
2465 * usb4_dp_port_bandwidth_mode_enabled() - Is the bandwidth allocation mode
2481 port->cap_adap + ADP_DP_CS_8, 1); in usb4_dp_port_bandwidth_mode_enabled()
2489 * usb4_dp_port_set_cm_bandwidth_mode_supported() - Set/clear CM support for
2496 * otherwise. Specifically returns %-OPNOTSUPP if the passed in adapter
2506 return -EOPNOTSUPP; in usb4_dp_port_set_cm_bandwidth_mode_supported()
2509 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_cm_bandwidth_mode_supported()
2519 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_cm_bandwidth_mode_supported()
2523 * usb4_dp_port_group_id() - Return Group ID assigned for the adapter
2528 * %-EOPNOTSUPP is returned.
2536 return -EOPNOTSUPP; in usb4_dp_port_group_id()
2539 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_group_id()
2547 * usb4_dp_port_set_group_id() - Set adapter Group ID
2553 * Specifically returns %-EOPNOTSUPP if the adapter does not support
2562 return -EOPNOTSUPP; in usb4_dp_port_set_group_id()
2565 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_group_id()
2573 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_group_id()
2577 * usb4_dp_port_nrd() - Read non-reduced rate and lanes
2579 * @rate: Non-reduced rate in Mb/s is placed here
2580 * @lanes: Non-reduced lanes are placed here
2582 * Reads the non-reduced rate and lanes from the DP IN adapter. Returns
2584 * %-EOPNOTSUPP if the adapter does not support this.
2592 return -EOPNOTSUPP; in usb4_dp_port_nrd()
2595 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_nrd()
2600 switch (tmp) { in usb4_dp_port_nrd()
2616 switch (tmp) { in usb4_dp_port_nrd()
2632 * usb4_dp_port_set_nrd() - Set non-reduced rate and lanes
2634 * @rate: Non-reduced rate in Mb/s
2635 * @lanes: Non-reduced lanes
2638 * the non-reduced values for the DP IN adapter. Returns %0 in success
2640 * %-EOPNOTSUPP is returned.
2648 return -EOPNOTSUPP; in usb4_dp_port_set_nrd()
2651 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_nrd()
2657 switch (rate) { in usb4_dp_port_set_nrd()
2673 return -EINVAL; in usb4_dp_port_set_nrd()
2678 switch (lanes) { in usb4_dp_port_set_nrd()
2688 return -EINVAL; in usb4_dp_port_set_nrd()
2692 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_nrd()
2696 * usb4_dp_port_granularity() - Return granularity for the bandwidth values
2700 * not support bandwidth allocation mode returns %-EOPNOTSUPP and negative
2709 return -EOPNOTSUPP; in usb4_dp_port_granularity()
2712 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_granularity()
2719 switch (val) { in usb4_dp_port_granularity()
2728 return -EINVAL; in usb4_dp_port_granularity()
2732 * usb4_dp_port_set_granularity() - Set granularity for the bandwidth values
2738 * adapter does not support this %-EOPNOTSUPP is returned.
2746 return -EOPNOTSUPP; in usb4_dp_port_set_granularity()
2749 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_granularity()
2755 switch (granularity) { in usb4_dp_port_set_granularity()
2766 return -EINVAL; in usb4_dp_port_set_granularity()
2770 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_granularity()
2774 * usb4_dp_port_set_estimated_bandwidth() - Set estimated bandwidth
2781 * and negative errno otherwise. Specifically returns %-EOPNOTSUPP if
2790 return -EOPNOTSUPP; in usb4_dp_port_set_estimated_bandwidth()
2798 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_estimated_bandwidth()
2806 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_set_estimated_bandwidth()
2810 * usb4_dp_port_allocated_bandwidth() - Return allocated bandwidth
2823 return -EOPNOTSUPP; in usb4_dp_port_allocated_bandwidth()
2831 port->cap_adap + DP_STATUS, 1); in usb4_dp_port_allocated_bandwidth()
2847 port->cap_adap + ADP_DP_CS_2, 1); in __usb4_dp_port_set_cm_ack()
2857 port->cap_adap + ADP_DP_CS_2, 1); in __usb4_dp_port_set_cm_ack()
2879 port->cap_adap + ADP_DP_CS_8, 1); in usb4_dp_port_wait_and_clear_cm_ack()
2890 return -ETIMEDOUT; in usb4_dp_port_wait_and_clear_cm_ack()
2893 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_wait_and_clear_cm_ack()
2899 port->cap_adap + ADP_DP_CS_2, 1); in usb4_dp_port_wait_and_clear_cm_ack()
2903 * usb4_dp_port_allocate_bandwidth() - Set allocated bandwidth
2917 return -EOPNOTSUPP; in usb4_dp_port_allocate_bandwidth()
2925 port->cap_adap + DP_STATUS, 1); in usb4_dp_port_allocate_bandwidth()
2933 port->cap_adap + DP_STATUS, 1); in usb4_dp_port_allocate_bandwidth()
2945 * usb4_dp_port_requested_bandwidth() - Read requested bandwidth
2950 * error returns negative errno. Specifically returns %-EOPNOTSUPP if
2960 return -EOPNOTSUPP; in usb4_dp_port_requested_bandwidth()
2968 port->cap_adap + ADP_DP_CS_8, 1); in usb4_dp_port_requested_bandwidth()
2973 return -ENODATA; in usb4_dp_port_requested_bandwidth()
2979 * usb4_pci_port_set_ext_encapsulation() - Enable/disable extended encapsulation
2993 return -EINVAL; in usb4_pci_port_set_ext_encapsulation()
2996 port->cap_adap + ADP_PCIE_CS_1, 1); in usb4_pci_port_set_ext_encapsulation()
3006 port->cap_adap + ADP_PCIE_CS_1, 1); in usb4_pci_port_set_ext_encapsulation()