| /OK3568_Linux_fs/kernel/drivers/usb/dwc3/ |
| H A D | drd.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * drd.c - DesignWare USB3 DRD Controller Dual-role support 5 * Copyright (C) 2017 Texas Instruments Incorporated - https://www.ti.com 21 u32 reg = dwc3_readl(dwc->regs, DWC3_OEVTEN); in dwc3_otg_disable_events() 24 dwc3_writel(dwc->regs, DWC3_OEVTEN, reg); in dwc3_otg_disable_events() 29 u32 reg = dwc3_readl(dwc->regs, DWC3_OEVTEN); in dwc3_otg_enable_events() 32 dwc3_writel(dwc->regs, DWC3_OEVTEN, reg); in dwc3_otg_enable_events() 37 u32 reg = dwc3_readl(dwc->regs, DWC3_OEVT); in dwc3_otg_clear_events() 39 dwc3_writel(dwc->regs, DWC3_OEVTEN, reg); in dwc3_otg_clear_events() 56 spin_lock(&dwc->lock); in dwc3_otg_thread_irq() [all …]
|
| /OK3568_Linux_fs/kernel/Documentation/devicetree/bindings/usb/ |
| H A D | usb-drd.yaml | 1 # SPDX-License-Identifier: GPL-2.0 3 --- 4 $id: http://devicetree.org/schemas/usb/usb-drd.yaml# 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - Greg Kroah-Hartman <gregkh@linuxfoundation.org> 13 otg-rev: 16 which the device and its descriptors are compliant, in binary-coded 18 features (HNP/SRP/ADP) is enabled. If ADP is required, otg-rev should be 24 Tells Dual-Role USB controllers that we want to work on a particular 25 mode. In case this attribute isn't passed via DT, USB DRD controllers [all …]
|
| H A D | mediatek,mtu3.txt | 4 - compatible : should be "mediatek,<soc-model>-mtu3", "mediatek,mtu3", 5 soc-model is the name of SoC, such as mt8173, mt2712 etc, 8 - "mediatek,mt8173-mtu3" 9 - reg : specifies physical base address and size of the registers 10 - reg-names: should be "mac" for device IP and "ippc" for IP port control 11 - interrupts : interrupt used by the device IP 12 - power-domains : a phandle to USB power domain node to control USB's 14 - vusb33-supply : regulator of USB avdd3.3v 15 - clocks : a list of phandle + clock-specifier pairs, one for each 16 entry in clock-names [all …]
|
| /OK3568_Linux_fs/kernel/drivers/usb/mtu3/ |
| H A D | mtu3_dr.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * mtu3_dr.c - dual role switch and host glue layer 10 #include <linux/usb/role.h> 28 switch (state) { in mailbox_state_string() 37 default: in mailbox_state_string() 44 mtu3_setbits(ssusb->mac_base, U3D_DEVICE_CONTROL, DC_SESSION); in toggle_opstate() 45 mtu3_setbits(ssusb->mac_base, U3D_POWER_MANAGEMENT, SOFT_CONN); in toggle_opstate() 48 /* only port0 supports dual-role mode */ 52 void __iomem *ibase = ssusb->ippc_base; in ssusb_port0_switch() 55 dev_dbg(ssusb->dev, "%s (switch u%d port0 to %s)\n", __func__, in ssusb_port0_switch() [all …]
|
| H A D | mtu3_plat.c | 1 // SPDX-License-Identifier: GPL-2.0 9 #include <linux/dma-mapping.h> 21 /* u2-port0 should be powered on and enabled; */ 24 void __iomem *ibase = ssusb->ippc_base; in ssusb_check_clocks() 34 dev_err(ssusb->dev, "clks of sts1 are not stable!\n"); in ssusb_check_clocks() 41 dev_err(ssusb->dev, "mac2 clock is not stable\n"); in ssusb_check_clocks() 53 for (i = 0; i < ssusb->num_phys; i++) { in ssusb_phy_init() 54 ret = phy_init(ssusb->phys[i]); in ssusb_phy_init() 61 for (; i > 0; i--) in ssusb_phy_init() 62 phy_exit(ssusb->phys[i - 1]); in ssusb_phy_init() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/usb/cdns3/ |
| H A D | core.c | 1 // SPDX-License-Identifier: GPL-2.0 5 * Copyright (C) 2018-2019 Cadence. 6 * Copyright (C) 2017-2018 NXP 14 #include <linux/dma-mapping.h> 24 #include "host-export.h" 25 #include "gadget-export.h" 30 static int cdns3_role_start(struct cdns3 *cdns, enum usb_role role) in cdns3_role_start() argument 34 if (WARN_ON(role > USB_ROLE_DEVICE)) in cdns3_role_start() 37 mutex_lock(&cdns->mutex); in cdns3_role_start() 38 cdns->role = role; in cdns3_role_start() [all …]
|
| H A D | Kconfig | 2 tristate "Cadence USB3 Dual-Role Controller" 7 Say Y here if your system has a Cadence USB3 dual-role controller. 8 It supports: dual-role switch, Host-only, and Peripheral-only. 20 Cadence USBSS-DEV driver. 22 This controller supports FF, HS and SS mode. It doesn't support 23 LS and SSP mode. 36 tristate "Cadence USB3 support on PCIe-based platforms" 38 default USB_CDNS3 44 be dynamically linked and module will be called cdns3-pci.ko 49 default USB_CDNS3 [all …]
|
| /OK3568_Linux_fs/kernel/Documentation/driver-api/usb/ |
| H A D | typec.rst | 3 USB Type-C connector class 7 ------------ 9 The typec class is meant for describing the USB Type-C ports in a system to the 14 The platforms are expected to register every USB Type-C port they have with the 15 class. In a normal case the registration will be done by a USB Type-C or PD PHY 18 considers the component registering the USB Type-C ports with the class as "port 26 attributes are described in Documentation/ABI/testing/sysfs-class-typec. 29 -------------------- 36 "port0-partner". Full path to the device would be 37 /sys/class/typec/port0/port0-partner/. [all …]
|
| /OK3568_Linux_fs/kernel/Documentation/devicetree/bindings/net/dsa/ |
| H A D | sja1105.txt | 1 NXP SJA1105 switch driver 6 - compatible: 8 - "nxp,sja1105e" 9 - "nxp,sja1105t" 10 - "nxp,sja1105p" 11 - "nxp,sja1105q" 12 - "nxp,sja1105r" 13 - "nxp,sja1105s" 18 and the non-SGMII devices, while pin-compatible, are not equal in terms 24 - sja1105,role-mac: [all …]
|
| /OK3568_Linux_fs/external/rkwifibt/drivers/rtl8852bs/phl/ |
| H A D | phl_ecsa.c | 25 param->ch); in _phl_ecsa_dump_param() 27 param->op_class); in _phl_ecsa_dump_param() 29 param->count); in _phl_ecsa_dump_param() 30 PHL_TRACE(COMP_PHL_ECSA, _PHL_INFO_, "%s: Mode %d\n", __FUNCTION__, in _phl_ecsa_dump_param() 31 param->mode); in _phl_ecsa_dump_param() 33 param->delay_start_ms); in _phl_ecsa_dump_param() 34 PHL_DUMP_CHAN_DEF(&(param->new_chan_def)); in _phl_ecsa_dump_param() 43 struct rtw_phl_com_t *phl_com = ecsa_ctrl->phl_com; in _phl_ecsa_tx_pause() 44 struct phl_info_t *phl_info = (struct phl_info_t *)phl_com->phl_priv; in _phl_ecsa_tx_pause() 45 struct rtw_wifi_role_t *wifi_role = ecsa_ctrl->role; in _phl_ecsa_tx_pause() [all …]
|
| H A D | phl_cmd_ps.c | 46 switch (ps_state) { in _ps_state_to_str() 53 default: in _ps_state_to_str() 108 struct phl_info_t *phl_info = ps->phl_info; in _chk_rssi_diff_reach_thld() 109 struct rtw_ps_cap_t *ps_cap = _get_ps_cap(ps->phl_info); in _chk_rssi_diff_reach_thld() 111 u8 *rssi_bcn_min = &ps->rssi_bcn_min; in _chk_rssi_diff_reach_thld() 124 if (DIFF(*rssi_bcn_min, cur_rssi_bcn_min) < ps_cap->lps_rssi_diff_threshold) { in _chk_rssi_diff_reach_thld() 126 __func__, *rssi_bcn_min, cur_rssi_bcn_min, ps_cap->lps_rssi_diff_threshold); in _chk_rssi_diff_reach_thld() 146 struct phl_info_t *phl_info = ps->phl_info; in _chk_bcn_offset_changed() 153 wrole = rtw_phl_get_wrole_by_ridx(phl_info->phl_com, ridx); in _chk_bcn_offset_changed() 157 if (rtw_phl_role_is_client_category(wrole) && wrole->mstate == MLME_LINKED) { in _chk_bcn_offset_changed() [all …]
|
| /OK3568_Linux_fs/external/rkwifibt/drivers/rtl8852be/phl/ |
| H A D | phl_ecsa.c | 25 param->ch); in _phl_ecsa_dump_param() 27 param->op_class); in _phl_ecsa_dump_param() 29 param->count); in _phl_ecsa_dump_param() 30 PHL_TRACE(COMP_PHL_ECSA, _PHL_INFO_, "%s: Mode %d\n", __FUNCTION__, in _phl_ecsa_dump_param() 31 param->mode); in _phl_ecsa_dump_param() 33 param->delay_start_ms); in _phl_ecsa_dump_param() 34 PHL_DUMP_CHAN_DEF(&(param->new_chan_def)); in _phl_ecsa_dump_param() 43 struct rtw_phl_com_t *phl_com = ecsa_ctrl->phl_com; in _phl_ecsa_tx_pause() 44 struct phl_info_t *phl_info = (struct phl_info_t *)phl_com->phl_priv; in _phl_ecsa_tx_pause() 45 struct rtw_wifi_role_t *wifi_role = ecsa_ctrl->role; in _phl_ecsa_tx_pause() [all …]
|
| H A D | phl_cmd_ps.c | 30 * +----------------------+-------------------+-----------------------+ 32 * +----------------------+-------------------+-----------------------+ 34 * | +-------------------+-----------------------+ 36 * | +-------------------+-----------------------+ 40 * +----------------------+-------------------+-----------------------+ 42 * | +-------------------+-----------------------+ 47 * +----------------------+-------------------+-----------------------+ 67 switch (ps_state) { in _ps_state_to_str() 74 default: in _ps_state_to_str() 129 struct phl_info_t *phl_info = ps->phl_info; in _chk_rssi_diff_reach_thld() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/usb/musb/ |
| H A D | mediatek.c | 1 // SPDX-License-Identifier: GPL-2.0 11 #include <linux/dma-mapping.h> 15 #include <linux/usb/role.h> 50 enum usb_role role; member 56 struct device *dev = glue->dev; in mtk_musb_clks_get() 58 glue->main = devm_clk_get(dev, "main"); in mtk_musb_clks_get() 59 if (IS_ERR(glue->main)) { in mtk_musb_clks_get() 61 return PTR_ERR(glue->main); in mtk_musb_clks_get() 64 glue->mcu = devm_clk_get(dev, "mcu"); in mtk_musb_clks_get() 65 if (IS_ERR(glue->mcu)) { in mtk_musb_clks_get() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/usb/typec/ |
| H A D | tps6598x.c | 1 // SPDX-License-Identifier: GPL-2.0 15 #include <linux/usb/role.h> 113 return -EINVAL; in tps6598x_block_read() 115 if (!tps->i2c_protocol) in tps6598x_block_read() 116 return regmap_raw_read(tps->regmap, reg, val, len); in tps6598x_block_read() 118 ret = regmap_raw_read(tps->regmap, reg, data, sizeof(data)); in tps6598x_block_read() 123 return -EIO; in tps6598x_block_read() 134 if (!tps->i2c_protocol) in tps6598x_block_write() 135 return regmap_raw_write(tps->regmap, reg, val, len); in tps6598x_block_write() 140 return regmap_raw_write(tps->regmap, reg, data, sizeof(data)); in tps6598x_block_write() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/usb/typec/ucsi/ |
| H A D | ucsi.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * USB Type-C Connector System Software Interface driver 21 * UCSI_TIMEOUT_MS - PPM communication timeout 31 * UCSI_SWAP_TIMEOUT_MS - Timeout for role swap requests 46 return ucsi->ops->sync_write(ucsi, UCSI_CONTROL, &ctrl, sizeof(ctrl)); in ucsi_acknowledge_command() 56 return ucsi->ops->sync_write(ucsi, UCSI_CONTROL, &ctrl, sizeof(ctrl)); in ucsi_acknowledge_connector_change() 75 ret = ucsi->ops->read(ucsi, UCSI_MESSAGE_IN, &error, sizeof(error)); in ucsi_read_error() 83 switch (error) { in ucsi_read_error() 85 return -EOPNOTSUPP; in ucsi_read_error() 87 return -ECOMM; in ucsi_read_error() [all …]
|
| /OK3568_Linux_fs/u-boot/drivers/usb/cdns3/ |
| H A D | core.c | 1 // SPDX-License-Identifier: GPL-2.0 5 * Copyright (C) 2018-2019 Cadence. 6 * Copyright (C) 2017-2018 NXP 16 #include <dm/device-internal.h> 24 #include "host-export.h" 25 #include "gadget-export.h" 42 WARN_ON(!cdns->roles[cdns->role]); in cdns3_get_current_role_driver() 43 return cdns->roles[cdns->role]; in cdns3_get_current_role_driver() 46 static int cdns3_role_start(struct cdns3 *cdns, enum usb_role role) in cdns3_role_start() argument 50 if (WARN_ON(role > USB_ROLE_DEVICE)) in cdns3_role_start() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/usb/chipidea/ |
| H A D | core.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * core.c - ChipIdea USB IP core family device controller 5 * Copyright (C) 2008 Chipidea - MIPS Technologies, Inc. All rights reserved. 12 * - Four transfers are supported, usbtest is passed 13 * - USB Certification for gadget: CH9 and Mass Storage are passed 14 * - Low power mode 15 * - USB wakeup 19 #include <linux/dma-mapping.h> 103 ci->hw_bank.regmap[i] = in hw_alloc_regmap() 104 (i <= CAP_LAST ? ci->hw_bank.cap : ci->hw_bank.op) + in hw_alloc_regmap() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/net/wireless/rockchip_wlan/rtl8822be/hal/ |
| H A D | hal_mcc.c | 39 struct mcc_obj_priv *pmccobjpriv = &(adapter_to_dvobj(padapter)->mcc_objpriv); in rtw_hal_check_mcc_status() 41 if (pmccobjpriv->mcc_status & (mcc_status)) in rtw_hal_check_mcc_status() 49 struct mcc_obj_priv *pmccobjpriv = &(adapter_to_dvobj(padapter)->mcc_objpriv); in rtw_hal_set_mcc_status() 51 pmccobjpriv->mcc_status |= (mcc_status); in rtw_hal_set_mcc_status() 56 struct mcc_obj_priv *pmccobjpriv = &(adapter_to_dvobj(padapter)->mcc_objpriv); in rtw_hal_clear_mcc_status() 58 pmccobjpriv->mcc_status &= (~mcc_status); in rtw_hal_clear_mcc_status() 64 struct mcc_obj_priv *pmccobjpriv = &(pdvobjpriv->mcc_objpriv); in rtw_hal_config_mcc_role_setting() 65 struct mcc_adapter_priv *pmccadapriv = &padapter->mcc_adapterpriv; in rtw_hal_config_mcc_role_setting() 66 struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv; in rtw_hal_config_mcc_role_setting() 67 struct mlme_priv *pmlmepriv = &(padapter->mlmepriv); in rtw_hal_config_mcc_role_setting() [all …]
|
| /OK3568_Linux_fs/kernel/arch/arm64/boot/dts/hisilicon/ |
| H A D | hi3660-hikey960.dts | 1 // SPDX-License-Identifier: GPL-2.0 9 /dts-v1/; 12 #include "hikey960-pinctrl.dtsi" 13 #include "hi3660-drm.dtsi" 14 #include "hi3660-gpu.dtsi" 16 #include <dt-bindings/gpio/gpio.h> 17 #include <dt-bindings/input/input.h> 18 #include <dt-bindings/interrupt-controller/irq.h> 19 #include <dt-bindings/usb/pd.h> 23 compatible = "hisilicon,hi3660-hikey960", "hisilicon,hi3660"; [all …]
|
| /OK3568_Linux_fs/kernel/drivers/extcon/ |
| H A D | extcon-axp288.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * extcon-axp288.c - X-Power AXP288 PMIC extcon cable detection driver 5 * Copyright (c) 2017-2018 Hans de Goede <hdegoede@redhat.com> 19 #include <linux/extcon-provider.h> 22 #include <linux/usb/role.h> 26 #include <asm/intel-family.h> 136 ret = regmap_read(info->regmap, AXP288_PS_BOOT_REASON_REG, &val); in axp288_extcon_log_rsi() 138 dev_err(info->dev, "failed to read reset source indicator\n"); in axp288_extcon_log_rsi() 142 bits = val & GENMASK(ARRAY_SIZE(axp288_pwr_up_down_info) - 1, 0); in axp288_extcon_log_rsi() 144 dev_dbg(info->dev, "%s\n", axp288_pwr_up_down_info[i]); in axp288_extcon_log_rsi() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/media/tuners/ |
| H A D | tda18271-fe.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 tda18271-fe.c - driver for the Philips / NXP TDA18271 silicon tuner 9 #include "tda18271-priv.h" 17 MODULE_PARM_DESC(debug, "set debug level (info=1, map=2, reg=4, adv=8, cal=16 (or-able))"); 19 static int tda18271_cal_on_startup = -1; 26 /*---------------------------------------------------------------------*/ 30 struct tda18271_priv *priv = fe->tuner_priv; in tda18271_toggle_output() 33 priv->output_opt & TDA18271_OUTPUT_LT_OFF ? 1 : 0, in tda18271_toggle_output() 34 priv->output_opt & TDA18271_OUTPUT_XT_OFF ? 1 : 0); in tda18271_toggle_output() 39 tda_dbg("%s mode: xtal oscillator %s, slave tuner loop through %s\n", in tda18271_toggle_output() [all …]
|
| /OK3568_Linux_fs/external/rkwifibt/drivers/rtl8852be/phl/hal_g6/btc/ |
| H A D | hal_btc.c | 24 /* [31:24] -> main-version 25 * [23:16] -> sub-version 26 * [15:8] -> Hot-Fix-version 27 * [7:0] -> branch ID, ex: 0x00-> Main-Branch 29 * btcx_desired: BT FW coex version -> main-version + 1 if update. 30 * wlcx_desired: WL FW coex version -> sub-version + 1 if update 53 btc->cx.wl.dbcc_info.real_band[phy_idx] =\ 54 (btc->cx.wl.scan_info.phy_map & BIT(phy_idx) ?\ 55 btc->cx.wl.dbcc_info.scan_band[phy_idx] :\ 56 btc->cx.wl.dbcc_info.op_band[phy_idx]) [all …]
|
| /OK3568_Linux_fs/kernel/arch/arm64/boot/dts/rockchip/ |
| H A D | rk3588-evb4-lp4.dtsi | 1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 7 #include "dt-bindings/usb/pd.h" 9 #include "rk3588-evb.dtsi" 10 #include "rk3588-rk806-single.dtsi" 13 fan: pwm-fan { 14 compatible = "pwm-fan"; 15 #cooling-cells = <2>; 17 cooling-levels = <0 50 100 150 200 255>; 18 rockchip,temp-trips = < 27 pcie30_avdd1v8: pcie30-avdd1v8 { [all …]
|
| /OK3568_Linux_fs/kernel/drivers/usb/typec/mux/ |
| H A D | intel_pmc_mux.c | 1 // SPDX-License-Identifier: GPL-2.0 14 #include <linux/usb/role.h> 42 /* Alt Mode Request */ 59 /* Common Mode Data bits */ 65 /* DP specific Mode Data bits */ 68 /* TBT specific Mode Data bits */ 89 /* activity type: Safe Mode */ 129 enum usb_role role; member 152 /* SoC expects the USB Type-C port numbers to start with 0 */ in update_port_status() 153 port_num = port->usb3_port - 1; in update_port_status() [all …]
|