/drivers/gpu/drm/nouveau/nvkm/subdev/pci/ |
D | pcie.c | 33 nvkm_pcie_speed(enum pci_bus_speed speed) in nvkm_pcie_speed() argument 35 switch (speed) { in nvkm_pcie_speed() 44 if (speed == 0x17) in nvkm_pcie_speed() 108 if (pci->pcie.speed != -1) in nvkm_pcie_init() 109 nvkm_pcie_set_link(pci, pci->pcie.speed, pci->pcie.width); in nvkm_pcie_init() 115 nvkm_pcie_set_link(struct nvkm_pci *pci, enum nvkm_pcie_speed speed, u8 width) in nvkm_pcie_set_link() argument 128 nvkm_trace(subdev, "requested %s\n", nvkm_pcie_speeds[speed]); in nvkm_pcie_set_link() 141 if (speed > max_speed) { in nvkm_pcie_set_link() 143 "requested speed to %s", nvkm_pcie_speeds[speed], in nvkm_pcie_set_link() 145 speed = max_speed; in nvkm_pcie_set_link() [all …]
|
D | gk104.c | 33 gk104_pcie_set_cap_speed(struct nvkm_pci *pci, enum nvkm_pcie_speed speed) in gk104_pcie_set_cap_speed() argument 37 switch (speed) { in gk104_pcie_set_cap_speed() 56 int speed = gf100_pcie_cap_speed(pci); in gk104_pcie_cap_speed() local 58 if (speed == 0) in gk104_pcie_cap_speed() 61 if (speed >= 1) { in gk104_pcie_cap_speed() 78 gk104_pcie_set_lnkctl_speed(struct nvkm_pci *pci, enum nvkm_pcie_speed speed) in gk104_pcie_set_lnkctl_speed() argument 81 switch (speed) { in gk104_pcie_set_lnkctl_speed() 127 gk104_pcie_set_link_speed(struct nvkm_pci *pci, enum nvkm_pcie_speed speed) in gk104_pcie_set_link_speed() argument 132 switch (speed) { in gk104_pcie_set_link_speed() 182 gk104_pcie_set_link(struct nvkm_pci *pci, enum nvkm_pcie_speed speed, u8 width) in gk104_pcie_set_link() argument [all …]
|
/drivers/net/ethernet/stmicro/stmmac/ |
D | dwmac-rk.c | 33 void (*set_rgmii_speed)(struct rk_priv_data *bsp_priv, int speed); 34 void (*set_rmii_speed)(struct rk_priv_data *bsp_priv, int speed); 117 static void px30_set_rmii_speed(struct rk_priv_data *bsp_priv, int speed) in px30_set_rmii_speed() argument 128 if (speed == 10) { in px30_set_rmii_speed() 136 } else if (speed == 100) { in px30_set_rmii_speed() 146 dev_err(dev, "unknown speed value for RMII! speed=%d", speed); in px30_set_rmii_speed() 215 static void rk3128_set_rgmii_speed(struct rk_priv_data *bsp_priv, int speed) in rk3128_set_rgmii_speed() argument 224 if (speed == 10) in rk3128_set_rgmii_speed() 227 else if (speed == 100) in rk3128_set_rgmii_speed() 230 else if (speed == 1000) in rk3128_set_rgmii_speed() [all …]
|
/drivers/platform/x86/ |
D | gpd-pocket-fan.c | 55 static void gpd_pocket_fan_set_speed(struct gpd_pocket_fan_data *fan, int speed) in gpd_pocket_fan_set_speed() argument 57 if (speed == fan->last_speed) in gpd_pocket_fan_set_speed() 60 gpiod_direction_output(fan->gpio0, !!(speed & 1)); in gpd_pocket_fan_set_speed() 61 gpiod_direction_output(fan->gpio1, !!(speed & 2)); in gpd_pocket_fan_set_speed() 63 fan->last_speed = speed; in gpd_pocket_fan_set_speed() 78 int t0, t1, temp, speed, min_speed, i; in gpd_pocket_fan_worker() local 83 speed = MAX_SPEED; in gpd_pocket_fan_worker() 89 speed = fan->last_speed; in gpd_pocket_fan_worker() 97 if (speed < i) in gpd_pocket_fan_worker() 98 speed = i; in gpd_pocket_fan_worker() [all …]
|
/drivers/net/ethernet/marvell/prestera/ |
D | prestera_ethtool.c | 23 u32 speed; member 30 .speed = 10, 37 .speed = 10, 44 .speed = 100, 51 .speed = 100, 58 .speed = 1000, 65 .speed = 1000, 72 .speed = 1000, 79 .speed = 1000, 86 .speed = 2500, [all …]
|
/drivers/cpufreq/ |
D | qcom-cpufreq-nvmem.c | 56 int *speed, int *pvs, int *pvs_ver, in get_krait_bin_format_a() argument 63 *speed = pte_efuse & 0xf; in get_krait_bin_format_a() 64 if (*speed == 0xf) in get_krait_bin_format_a() 65 *speed = (pte_efuse >> 4) & 0xf; in get_krait_bin_format_a() 67 if (*speed == 0xf) { in get_krait_bin_format_a() 68 *speed = 0; in get_krait_bin_format_a() 69 dev_warn(cpu_dev, "Speed bin: Defaulting to %d\n", *speed); in get_krait_bin_format_a() 71 dev_dbg(cpu_dev, "Speed bin: %d\n", *speed); in get_krait_bin_format_a() 87 int *speed, int *pvs, int *pvs_ver, in get_krait_bin_format_b() argument 100 *speed = (pte_efuse >> 27) & 0xf; in get_krait_bin_format_b() [all …]
|
D | longhaul.c | 90 static char *print_speed(int speed) in print_speed() argument 92 if (speed < 1000) { in print_speed() 93 snprintf(speedbuffer, sizeof(speedbuffer), "%dMHz", speed); in print_speed() 97 if (speed%1000 == 0) in print_speed() 99 "%dGHz", speed/1000); in print_speed() 102 "%d.%dGHz", speed/1000, (speed%1000)/100); in print_speed() 249 int speed, mult; in longhaul_setstate() local 263 speed = calc_speed(mult); in longhaul_setstate() 264 if ((speed > highest_speed) || (speed < lowest_speed)) in longhaul_setstate() 272 freqs.new = speed; in longhaul_setstate() [all …]
|
/drivers/usb/core/ |
D | devices.c | 142 static char *usb_dump_endpoint_descriptor(int speed, char *start, char *end, in usb_dump_endpoint_descriptor() argument 153 if (speed == USB_SPEED_HIGH) in usb_dump_endpoint_descriptor() 175 interval = usb_decode_interval(desc, speed); in usb_dump_endpoint_descriptor() 222 static char *usb_dump_interface(int speed, char *start, char *end, in usb_dump_interface() argument 231 start = usb_dump_endpoint_descriptor(speed, in usb_dump_interface() 259 int active, int speed) in usb_dump_config_descriptor() argument 265 if (speed >= USB_SPEED_SUPER) in usb_dump_config_descriptor() 279 static char *usb_dump_config(int speed, char *start, char *end, in usb_dump_config() argument 292 speed); in usb_dump_config() 303 start = usb_dump_interface(speed, in usb_dump_config() [all …]
|
/drivers/ata/ |
D | pata_sis.c | 231 int speed = adev->pio_mode - XFER_PIO_0; in sis_old_set_piomode() local 244 t1 |= active[speed]; in sis_old_set_piomode() 245 t2 |= recovery[speed]; in sis_old_set_piomode() 267 int speed = adev->pio_mode - XFER_PIO_0; in sis_100_set_piomode() local 273 pci_write_config_byte(pdev, port, actrec[speed]); in sis_100_set_piomode() 293 int speed = adev->pio_mode - XFER_PIO_0; in sis_133_set_piomode() local 317 t1 |= timing133[speed]; in sis_133_set_piomode() 319 t1 |= timing100[speed]; in sis_133_set_piomode() 339 int speed = adev->dma_mode - XFER_MW_DMA_0; in sis_old_set_dmamode() local 352 timing |= mwdma_bits[speed]; in sis_old_set_dmamode() [all …]
|
D | libata-pata-timings.c | 115 int ata_timing_compute(struct ata_device *adev, unsigned short speed, in ata_timing_compute() argument 125 s = ata_timing_find_mode(speed); in ata_timing_compute() 139 if (speed >= XFER_PIO_0 && speed < XFER_SW_DMA_0) { in ata_timing_compute() 140 if (speed <= XFER_PIO_2) in ata_timing_compute() 142 else if ((speed <= XFER_PIO_4) || in ata_timing_compute() 143 (speed == XFER_PIO_5 && !ata_id_is_cfa(id))) in ata_timing_compute() 145 } else if (speed >= XFER_MW_DMA_0 && speed <= XFER_MW_DMA_2) in ata_timing_compute() 163 if (speed > XFER_PIO_6) { in ata_timing_compute()
|
/drivers/net/ethernet/aquantia/atlantic/hw_atl/ |
D | hw_atl_utils_fw2x.c | 85 static int aq_fw2x_set_link_speed(struct aq_hw_s *self, u32 speed); 125 static enum hw_atl_fw2x_rate link_speed_mask_2fw2x_ratemask(u32 speed) in link_speed_mask_2fw2x_ratemask() argument 129 if (speed & AQ_NIC_RATE_10G) in link_speed_mask_2fw2x_ratemask() 132 if (speed & AQ_NIC_RATE_5G) in link_speed_mask_2fw2x_ratemask() 135 if (speed & AQ_NIC_RATE_2G5) in link_speed_mask_2fw2x_ratemask() 138 if (speed & AQ_NIC_RATE_1G) in link_speed_mask_2fw2x_ratemask() 141 if (speed & AQ_NIC_RATE_100M) in link_speed_mask_2fw2x_ratemask() 147 static u32 fw2x_to_eee_mask(u32 speed) in fw2x_to_eee_mask() argument 151 if (speed & HW_ATL_FW2X_CAP_EEE_10G_MASK) in fw2x_to_eee_mask() 153 if (speed & HW_ATL_FW2X_CAP_EEE_5G_MASK) in fw2x_to_eee_mask() [all …]
|
/drivers/mtd/tests/ |
D | speedtest.c | 176 long speed; in mtd_speedtest_init() local 258 speed = calc_speed(); in mtd_speedtest_init() 259 pr_info("eraseblock write speed is %ld KiB/s\n", speed); in mtd_speedtest_init() 276 speed = calc_speed(); in mtd_speedtest_init() 277 pr_info("eraseblock read speed is %ld KiB/s\n", speed); in mtd_speedtest_init() 298 speed = calc_speed(); in mtd_speedtest_init() 299 pr_info("page write speed is %ld KiB/s\n", speed); in mtd_speedtest_init() 316 speed = calc_speed(); in mtd_speedtest_init() 317 pr_info("page read speed is %ld KiB/s\n", speed); in mtd_speedtest_init() 338 speed = calc_speed(); in mtd_speedtest_init() [all …]
|
/drivers/net/phy/ |
D | swphy.c | 41 static const struct swmii_regs speed[] = { variable 71 static int swphy_decode_speed(int speed) in swphy_decode_speed() argument 73 switch (speed) { in swphy_decode_speed() 98 err = swphy_decode_speed(state->speed); in swphy_validate_state() 126 speed_index = swphy_decode_speed(state->speed); in swphy_read_reg() 132 bmsr |= speed[speed_index].bmsr & duplex[duplex_index].bmsr; in swphy_read_reg() 133 estat |= speed[speed_index].estat & duplex[duplex_index].estat; in swphy_read_reg() 138 lpa |= speed[speed_index].lpa & duplex[duplex_index].lpa; in swphy_read_reg() 139 lpagb |= speed[speed_index].lpagb & duplex[duplex_index].lpagb; in swphy_read_reg()
|
D | phy-core.c | 14 const char *phy_speed_to_str(int speed) in phy_speed_to_str() argument 21 switch (speed) { in phy_speed_to_str() 160 #define PHY_SETTING(s, d, b) { .speed = SPEED_ ## s, .duplex = DUPLEX_ ## d, \ 289 phy_lookup_setting(int speed, int duplex, const unsigned long *mask, bool exact) in phy_lookup_setting() argument 298 if (p->speed == speed && p->duplex == duplex) { in phy_lookup_setting() 303 if (!match && p->speed <= speed) in phy_lookup_setting() 307 if (p->speed < speed) in phy_lookup_setting() 329 (count == 0 || speeds[count - 1] != settings[i].speed)) in phy_speeds() 330 speeds[count++] = settings[i].speed; in phy_speeds() 341 if (p->speed > max_speed) in __set_linkmode_max_speed() [all …]
|
D | phy_led_triggers.c | 9 unsigned int speed) in phy_speed_to_led_trigger() argument 14 if (phy->phy_led_triggers[i].speed == speed) in phy_speed_to_led_trigger() 36 if (phy->speed == 0) in phy_led_trigger_change_speed() 39 plt = phy_speed_to_led_trigger(phy, phy->speed); in phy_led_trigger_change_speed() 43 phy->speed); in phy_led_trigger_change_speed() 69 unsigned int speed, in phy_led_trigger_register() argument 72 plt->speed = speed; in phy_led_trigger_register()
|
/drivers/usb/misc/ |
D | trancevibrator.c | 30 unsigned int speed; member 39 return sprintf(buf, "%d\n", tv->speed); in speed_show() 56 old = tv->speed; in speed_store() 57 tv->speed = temp; in speed_store() 59 dev_dbg(&tv->udev->dev, "speed = %d\n", tv->speed); in speed_store() 65 tv->speed, /* speed value */ in speed_store() 68 tv->speed = old; in speed_store() 74 static DEVICE_ATTR_RW(speed);
|
/drivers/net/ethernet/microchip/sparx5/ |
D | sparx5_port.c | 39 status->speed = SPEED_10; in decode_sgmii_word() 42 status->speed = SPEED_100; in decode_sgmii_word() 45 status->speed = SPEED_1000; in decode_sgmii_word() 98 status->speed = SPEED_1000; in sparx5_get_dev2g5_status() 100 status->speed = SPEED_2500; in sparx5_get_dev2g5_status() 149 status->speed = SPEED_5000; in sparx5_get_sfi_status() 151 status->speed = SPEED_10000; in sparx5_get_sfi_status() 153 status->speed = SPEED_25000; in sparx5_get_sfi_status() 165 status->speed = port->conf.speed; in sparx5_get_port_status() 197 conf->speed, phy_modes(conf->portmode)); in sparx5_port_error() [all …]
|
/drivers/gpu/drm/amd/pm/powerplay/hwmgr/ |
D | vega20_thermal.c | 118 uint32_t *speed) in vega20_fan_ctrl_get_fan_speed_pwm() argument 134 *speed = MIN((uint32_t)tmp64, 255); in vega20_fan_ctrl_get_fan_speed_pwm() 140 uint32_t speed) in vega20_fan_ctrl_set_fan_speed_pwm() argument 147 speed = MIN(speed, 255); in vega20_fan_ctrl_set_fan_speed_pwm() 158 tmp64 = (uint64_t)speed * duty100; in vega20_fan_ctrl_set_fan_speed_pwm() 181 int vega20_fan_ctrl_get_fan_speed_rpm(struct pp_hwmgr *hwmgr, uint32_t *speed) in vega20_fan_ctrl_get_fan_speed_rpm() argument 183 *speed = 0; in vega20_fan_ctrl_get_fan_speed_rpm() 185 return vega20_get_current_rpm(hwmgr, speed); in vega20_fan_ctrl_get_fan_speed_rpm() 188 int vega20_fan_ctrl_set_fan_speed_rpm(struct pp_hwmgr *hwmgr, uint32_t speed) in vega20_fan_ctrl_set_fan_speed_rpm() argument 194 if (!speed) in vega20_fan_ctrl_set_fan_speed_rpm() [all …]
|
D | smu7_thermal.c | 55 uint32_t *speed) in smu7_fan_ctrl_get_fan_speed_pwm() argument 75 *speed = MIN((uint32_t)tmp64, 255); in smu7_fan_ctrl_get_fan_speed_pwm() 80 int smu7_fan_ctrl_get_fan_speed_rpm(struct pp_hwmgr *hwmgr, uint32_t *speed) in smu7_fan_ctrl_get_fan_speed_rpm() argument 97 *speed = 60 * crystal_clock_freq * 10000 / tach_period; in smu7_fan_ctrl_get_fan_speed_rpm() 204 uint32_t speed) in smu7_fan_ctrl_set_fan_speed_pwm() argument 213 speed = MIN(speed, 255); in smu7_fan_ctrl_set_fan_speed_pwm() 224 tmp64 = (uint64_t)speed * duty100; in smu7_fan_ctrl_set_fan_speed_pwm() 262 int smu7_fan_ctrl_set_fan_speed_rpm(struct pp_hwmgr *hwmgr, uint32_t speed) in smu7_fan_ctrl_set_fan_speed_rpm() argument 270 speed == 0 || in smu7_fan_ctrl_set_fan_speed_rpm() 271 (speed < hwmgr->thermal_controller.fanInfo.ulMinRPM) || in smu7_fan_ctrl_set_fan_speed_rpm() [all …]
|
/drivers/net/dsa/mv88e6xxx/ |
D | port.c | 220 int port, int speed, bool alt_bit, in mv88e6xxx_port_set_speed_duplex() argument 226 switch (speed) { in mv88e6xxx_port_set_speed_duplex() 286 if (speed != SPEED_UNFORCED) in mv88e6xxx_port_set_speed_duplex() 295 if (speed != SPEED_UNFORCED) in mv88e6xxx_port_set_speed_duplex() 296 dev_dbg(chip->dev, "p%d: Speed set to %d Mbps\n", port, speed); in mv88e6xxx_port_set_speed_duplex() 308 int speed, int duplex) in mv88e6185_port_set_speed_duplex() argument 310 if (speed == 200 || speed > 1000) in mv88e6185_port_set_speed_duplex() 313 return mv88e6xxx_port_set_speed_duplex(chip, port, speed, false, false, in mv88e6185_port_set_speed_duplex() 319 int speed, int duplex) in mv88e6250_port_set_speed_duplex() argument 321 if (speed > 100) in mv88e6250_port_set_speed_duplex() [all …]
|
/drivers/net/ethernet/mellanox/mlxsw/ |
D | spectrum_ethtool.c | 1272 u32 speed; member 1279 .speed = SPEED_100, 1285 .speed = SPEED_1000, 1290 .speed = SPEED_1000, 1296 .speed = SPEED_10000, 1304 .speed = SPEED_10000, 1309 .speed = SPEED_40000, 1314 .speed = SPEED_40000, 1319 .speed = SPEED_40000, 1324 .speed = SPEED_40000, [all …]
|
/drivers/net/ethernet/huawei/hinic/ |
D | hinic_ethtool.c | 61 u32 speed; member 69 u32 speed; member 86 .speed = SPEED_10000, 91 .speed = SPEED_40000, 96 .speed = SPEED_40000, 101 .speed = SPEED_100000, 106 .speed = SPEED_100000, 111 .speed = SPEED_25000, 116 .speed = SPEED_25000, 121 .speed = SPEED_25000, [all …]
|
/drivers/net/pcs/ |
D | pcs-xpcs.c | 360 static void xpcs_config_usxgmii(struct dw_xpcs *xpcs, int speed) in xpcs_config_usxgmii() argument 364 switch (speed) { in xpcs_config_usxgmii() 538 int speed = SPEED_UNKNOWN; in xpcs_get_max_xlgmii_speed() local 581 if (new_speed > speed) in xpcs_get_max_xlgmii_speed() 582 speed = new_speed; in xpcs_get_max_xlgmii_speed() 585 return speed; in xpcs_get_max_xlgmii_speed() 596 state->speed = SPEED_10000; in xpcs_resolve_pma() 599 state->speed = xpcs_get_max_xlgmii_speed(xpcs, state); in xpcs_resolve_pma() 602 state->speed = SPEED_UNKNOWN; in xpcs_resolve_pma() 997 state->speed = SPEED_UNKNOWN; in xpcs_get_state_c37_sgmii() [all …]
|
/drivers/hwmon/ |
D | gpio-fan.c | 39 struct gpio_fan_speed *speed; member 133 __set_fan_ctrl(fan_data, fan_data->speed[speed_index].ctrl_val); in set_fan_speed() 143 if (fan_data->speed[i].ctrl_val == ctrl_val) in get_fan_speed_index() 154 struct gpio_fan_speed *speed = fan_data->speed; in rpm_to_speed_index() local 158 if (speed[i].rpm >= rpm) in rpm_to_speed_index() 245 return sprintf(buf, "%d\n", fan_data->speed[0].rpm); in fan1_min_show() 254 fan_data->speed[fan_data->num_speed - 1].rpm); in fan1_max_show() 262 return sprintf(buf, "%d\n", fan_data->speed[fan_data->speed_index].rpm); in fan1_input_show() 411 struct gpio_fan_speed *speed; in gpio_fan_get_of_data() local 463 speed = devm_kcalloc(dev, in gpio_fan_get_of_data() [all …]
|
/drivers/net/ethernet/ibm/ehea/ |
D | ehea_ethtool.c | 25 u32 speed; in ehea_get_link_ksettings() local 36 speed = SPEED_10; in ehea_get_link_ksettings() 39 speed = SPEED_100; in ehea_get_link_ksettings() 42 speed = SPEED_1000; in ehea_get_link_ksettings() 45 speed = SPEED_10000; in ehea_get_link_ksettings() 48 speed = -1; in ehea_get_link_ksettings() 54 speed = SPEED_UNKNOWN; in ehea_get_link_ksettings() 57 cmd->base.speed = speed; in ehea_get_link_ksettings() 59 if (cmd->base.speed == SPEED_10000) { in ehea_get_link_ksettings() 96 switch (cmd->base.speed) { in ehea_set_link_ksettings()
|