| /linux/scripts/coccinelle/misc/ |
| H A D | minmax.cocci | 1 // SPDX-License-Identifier: GPL-2.0-only 3 /// Check for opencoded min(), max() implementations. 9 // Options: --no-includes --includ [all...] |
| /linux/Documentation/scheduler/ |
| H A D | sched-pelt.c | 6 * C program (compile with -lm) 21 unsigned int x; in calc_runnable_avg_yN_inv() local 23 /* To silence -Wunused-but-set-variable warnings. */ in calc_runnable_avg_yN_inv() 26 x = ((1UL<<32)-1)*pow(y, i); in calc_runnable_avg_yN_inv() 29 printf("0x%8x, ", x); in calc_runnable_avg_yN_inv() 55 int n = -1; 57 long max = 1024; variable 61 long last = 0, y_inv = ((1UL<<32)-1)*y; in calc_converged_max() 64 if (n > -1) in calc_converged_max() 65 max = ((max*y_inv)>>SHIFT) + 1024; in calc_converged_max() [all …]
|
| /linux/Documentation/devicetree/bindings/iio/accel/ |
| H A D | lis302.txt | 8 - compatible: should be set to "st,lis3lv02d-spi" 9 - reg: the chipselect index 10 - spi-max-frequency: maximal bus speed, should be set to 1000000 unless 12 - interrupts: the interrupt generated by the device 15 - compatible: should be set to "st,lis3lv02d" 16 - reg: i2c slave address 17 - Vdd-supply: The input supply for Vdd 18 - Vdd_IO-supply: The input supply for Vdd_IO 23 - st,click-single-{x,y,z}: if present, tells the device to issue an 25 x/y/z axis. [all …]
|
| /linux/include/linux/ |
| H A D | minmax.h | 1 /* SPDX-License-Identifier: GPL-2.0 */ 11 * min()/max()/clamp() macros must accomplish several things: 13 * - Avoid multiple evaluations of the arguments (so side-effects like 14 * "x++" happen only once) when non-constant. 15 * - Perform signed v unsigned type-checking (to generate compile 17 * - Unsigned char/short are always promoted to signed int and can be 19 * - Unsigned arguments can be compared against non-negative signed constants. 20 * - Comparison of a signed argument against an unsigned constant fails 23 #define __typecheck(x, y) \ argument 24 (!!(sizeof((typeof(x) *)1 == (typeof(y) *)1))) [all …]
|
| /linux/sound/firewire/fireworks/ |
| H A D | fireworks_proc.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * fireworks_proc.c - a part of driver for Fireworks based devices 5 * Copyright (c) 2009-2010 Clemens Ladisch 6 * Copyright (c) 2013-2014 Takashi Sakamoto 19 if (grp->type < ARRAY_SIZE(ch_type)) in get_phys_name() 20 return ch_type[grp->type]; in get_phys_name() 30 struct snd_efw *efw = entry->private_data; in proc_read_hwinfo() 41 snd_iprintf(buffer, "guid_hi: 0x%X\n", hwinfo->guid_hi); in proc_read_hwinfo() 42 snd_iprintf(buffer, "guid_lo: 0x%X\n", hwinfo->guid_lo); in proc_read_hwinfo() 43 snd_iprintf(buffer, "type: 0x%X\n", hwinfo->type); in proc_read_hwinfo() [all …]
|
| /linux/arch/riscv/boot/dts/allwinner/ |
| H A D | sun20i-d1-clockworkpi-v3.14.dts | 1 // SPDX-License-Identifier: (GPL-2.0+ or MIT) 4 #include <dt-bindings/gpio/gpio.h> 6 /dts-v1/; 8 #include "sun20i-d1.dtsi" 9 #include "sun20i-common-regulators.dtsi" 12 model = "ClockworkPi v3.14 (R-01)"; 13 compatible = "clockwork,r-01-clockworkpi-v3.14", "allwinner,sun20i-d1"; 21 stdout-path = "serial0:115200n8"; 25 * This regulator is PWM-controlled, but the PWM controller is not 28 reg_vdd_cpu: vdd-cpu { [all …]
|
| /linux/drivers/gpu/drm/i915/gt/ |
| H A D | selftest_slpc.c | 1 // SPDX-License-Identifier: MIT 56 struct intel_guc_slpc *slpc = >_to_guc(gt)->slpc; in slpc_set_freq() 60 pr_err("Unable to update max freq"); in slpc_set_freq() 73 static int slpc_restore_freq(struct intel_guc_slpc *slpc, u32 min, u32 max) in slpc_restore_freq() argument 77 err = slpc_set_max_freq(slpc, max); in slpc_restore_freq() 79 pr_err("Unable to restore max freq"); in slpc_restore_freq() 100 u64 x[5]; in slpc_measure_power() local 104 x[i] = __measure_power(5); in slpc_measure_power() 109 sort(x, 5, sizeof(*x), cmp_u64, NULL); in slpc_measure_power() 110 return div_u64(x[1] + 2 * x[2] + x[3], 4); in slpc_measure_power() [all …]
|
| /linux/Documentation/devicetree/bindings/input/touchscreen/ |
| H A D | ti,tsc2005.yaml | 1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 3 --- 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - Marek Vasut <marex@denx.de> 11 - Michael Welling <mwelling@ieee.org> 19 - ti,tsc2004 20 - ti,tsc2005 31 reset-gpios: 35 spi-max-frequency: 39 ti,x-plate-ohms: [all …]
|
| /linux/arch/s390/boot/ |
| H A D | physmem_info.c | 1 // SPDX-License-Identifier: GPL-2.0 35 return &physmem_info.online_extended[n - MEM_INLINED_ENTRIES]; in __get_physmem_range_ptr() 47 range = __get_physmem_range_ptr(physmem_info.range_count - 1); in add_physmem_online_range() 48 if (range->end == start) { in add_physmem_online_range() 49 range->end = end; in add_physmem_online_range() 55 range->start = start; in add_physmem_online_range() 56 range->end = end; in add_physmem_online_range() 79 cc = exception ? -1 : CC_TRANSFORM(cc); in __diag260() 80 return cc == 0 ? ry : -1; in __diag260() 94 if (rc == -1) in diag260() [all …]
|
| /linux/drivers/infiniband/hw/cxgb4/ |
| H A D | resource.c | 2 * Copyright (c) 2009-2010 Chelsio, Inc. All rights reserved. 14 * - Redistributions of source code must retain the above 18 * - Redistributions in binary form must reproduce the above 42 if (c4iw_id_table_alloc(&rdev->resource.qid_table, in c4iw_init_qid_table() 43 rdev->lldi.vr->qp.start, in c4iw_init_qid_table() 44 rdev->lldi.vr->qp.size, in c4iw_init_qid_table() 45 rdev->lldi.vr->qp.size, 0)) in c4iw_init_qid_table() 46 return -ENOMEM; in c4iw_init_qid_table() 48 for (i = rdev->lldi.vr->qp.start; in c4iw_init_qid_table() 49 i < rdev->lldi.vr->qp.start + rdev->lldi.vr->qp.size; i++) in c4iw_init_qid_table() [all …]
|
| /linux/drivers/iio/dac/ |
| H A D | ad5770r.c | 1 // SPDX-License-Identifier: GPL-2.0+ 39 #define ADI_SPI_IF_SW_RESET_SEL(x) ((x) & ADI_SPI_IF_SW_RESET_MSK) argument 41 #define ADI_SPI_IF_ADDR_ASC_SEL(x) (((x) << 2) & ADI_SPI_IF_ADDR_ASC_MSK) argument 45 #define ADI_SPI_IF_SINGLE_INS_SEL(x) FIELD_PREP(ADI_SPI_IF_SINGLE_INS_MSK, x) argument 47 #define ADI_SPI_IF_SHORT_INS_SEL(x) FIELD_PREP(ADI_SPI_IF_SINGLE_INS_MSK, x) argument 51 #define ADI_SPI_IF_STRICT_REG_GET(x) FIELD_GET(ADI_SPI_IF_STRICT_REG_MSK, x) argument 64 #define AD5770R_CFG_CH0_SINK_EN(x) (((x) & 0x1) << 7) argument 65 #define AD5770R_CFG_SHUTDOWN_B(x, ch) (((x) & 0x1) << (ch)) argument 68 #define AD5770R_RANGE_OUTPUT_SCALING(x) (((x) & GENMASK(5, 0)) << 2) argument 69 #define AD5770R_RANGE_MODE(x) ((x) & GENMASK(1, 0)) argument [all …]
|
| H A D | ad5758.c | 1 // SPDX-License-Identifier: GPL-2.0 52 #define AD5758_DAC_CONFIG_RANGE_MODE(x) (((x) & 0xF) << 0) argument 54 #define AD5758_DAC_CONFIG_INT_EN_MODE(x) (((x) & 0x1) << 5) argument 56 #define AD5758_DAC_CONFIG_OUT_EN_MODE(x) (((x) & 0x1) << 6) argument 58 #define AD5758_DAC_CONFIG_SR_EN_MODE(x) (((x) & 0x1) << 8) argument 60 #define AD5758_DAC_CONFIG_SR_CLOCK_MODE(x) (((x) & 0xF) << 9) argument 62 #define AD5758_DAC_CONFIG_SR_STEP_MODE(x) (((x) & 0x7) << 13) argument 73 #define AD5758_DCDC_CONFIG1_DCDC_VPROG_MODE(x) (((x) & 0x1F) << 0) argument 75 #define AD5758_DCDC_CONFIG1_DCDC_MODE_MODE(x) (((x) & 0x3) << 5) argument 79 #define AD5758_DCDC_CONFIG2_ILIMIT_MODE(x) (((x) & 0x7) << 1) argument [all …]
|
| /linux/sound/isa/gus/ |
| H A D | gusmax.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * Driver for Gravis UltraSound MAX soundcard 22 MODULE_DESCRIPTION("Gravis UltraSound MAX"); 25 static int index[SNDRV_CARDS] = SNDRV_DEFAULT_IDX; /* Index 0-MAX */ 32 static int joystick_dac[SNDRV_CARDS] = {[0 ... (SNDRV_CARDS - 92 int loop, max = 5; snd_gusmax_interrupt() local [all...] |
| /linux/Documentation/input/devices/ |
| H A D | cma3000_d0x.rst | 1 CMA3000-D0x Accelerometer 5 * VTI CMA3000-D0x 8 CMA3000-D0X Product Family Specification 8281000A.02.pdf 15 ----------- 17 CMA3000 Tri-axis accelerometer supports Motion detect, Measurement and 25 This mode is used to read the acceleration data on X,Y,Z 47 ------------- 50 Noise on X Axis 74 --------------- 78 Input device name: "cma3000-accelerometer" [all …]
|
| /linux/drivers/net/wireless/realtek/rtlwifi/ |
| H A D | debug.c | 1 // SPDX-License-Identifier: GPL-2.0 2 /* Copyright(c) 2009-2012 Realtek Corporation.*/ 14 if (unlikely((comp & rtlpriv->cfg->mod_params->debug_mask) && in _rtl_dbg_print() 15 level <= rtlpriv->cfg->mod_params->debug_level)) { in _rtl_dbg_print() 35 if (unlikely(((comp) & rtlpriv->cfg->mod_params->debug_mask) && in _rtl_dbg_print_data() 36 ((level) <= rtlpriv->cfg->mod_params->debug_level))) { in _rtl_dbg_print_data() 38 current->comm, current->pid, titlestring); in _rtl_dbg_print_data() 57 struct rtl_debugfs_priv *debugfs_priv = m->private; in rtl_debug_get_common() 59 return debugfs_priv->cb_read(m, v); in rtl_debug_get_common() 64 return single_open(file, rtl_debug_get_common, inode->i_private); in dl_debug_open_common() [all …]
|
| /linux/drivers/hid/ |
| H A D | hid-samsung.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 6 * Copyright (c) 2000-2005 Vojtech Pavlik <vojtech@suse.cz> 7 * Copyright (c) 2005 Michael Haboustak <mike-@cinci.rr.com> for Concept2, Inc 8 * Copyright (c) 2006-2007 Jiri Kosina 30 #include "hid-ids.h" 85 hid_map_usage_clear(hi, usage, bit, max, EV_KEY, (c)) 89 unsigned long **bit, int *max) in samsung_kbd_mouse_input_mapping() argument 91 struct usb_interface *intf = to_usb_interface(hdev->dev.parent); in samsung_kbd_mouse_input_mapping() 92 unsigned short ifnum = intf->cur_altsetting->desc.bInterfaceNumber; in samsung_kbd_mouse_input_mapping() 94 if (ifnum != 1 || HID_UP_CONSUMER != (usage->hid & HID_USAGE_PAGE)) in samsung_kbd_mouse_input_mapping() [all …]
|
| /linux/drivers/gpu/drm/gma500/ |
| H A D | cdv_intel_display.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * Copyright © 2006-2011 Intel Corporation 38 .dot = {.min = 20000, .max = 115500}, 39 .vco = {.min = 1800000, .max = 3600000}, 40 .n = {.min = 2, .max = 6}, 41 .m = {.min = 60, .max = 160}, 42 .m1 = {.min = 0, .max = 0}, 43 .m2 = {.min = 58, .max = 158}, 44 .p = {.min = 28, .max = 140}, 45 .p1 = {.min = 2, .max = 10}, [all …]
|
| /linux/arch/arm/boot/dts/ti/omap/ |
| H A D | omap3-overo-common-peripherals.dtsi | 1 // SPDX-License-Identifier: GPL-2.0-only 11 lis33_3v3: lis33-3v3-reg { 12 compatible = "regulator-fixed"; 13 regulator-name = "lis33-3v3-reg"; 14 regulator-min-microvolt = <3300000>; 15 regulator-max-microvolt = <3300000>; 18 lis33_1v8: lis33-1v8-reg { 19 compatible = "regulator-fixed"; 20 regulator-name = "lis33-1v8-reg"; 21 regulator-min-microvolt = <1800000>; [all …]
|
| /linux/Documentation/ABI/testing/ |
| H A D | sysfs-class-powercap | 4 Contact: linux-pm@vger.kernel.org 13 Contact: linux-pm@vger.kernel.org 22 Contact: linux-pm@vger.kernel.org 30 Contact: linux-pm@vger.kernel.org 35 E.g. intel-rapl:0:1:1. 40 Contact: linux-pm@vger.kernel.org 51 Contact: linux-pm@vger.kernel.org 58 Contact: linux-pm@vger.kernel.org 60 Current energy counter in micro-joules. Write "0" to reset. 62 read-only. [all …]
|
| /linux/arch/arm/boot/dts/allwinner/ |
| H A D | sun8i-a83t-allwinner-h8homlet-v2.dts | 5 * This file is dual-licensed: you can use it either under the terms 44 /dts-v1/; 45 #include "sun8i-a83t.dtsi" 47 #include <dt-bindings/gpio/gpio.h> 51 compatible = "allwinner,h8homlet-v2", "allwinner,sun8i-a83t"; 58 stdout-path = "serial0:115200n8"; 61 reg_usb0_vbus: reg-usb0-vbus { 62 compatible = "regulator-fixed"; 63 regulator-name = "usb0-vbus"; 64 regulator-min-microvolt = <5000000>; [all …]
|
| /linux/drivers/usb/phy/ |
| H A D | phy.c | 1 // SPDX-License-Identifier: GPL-2.0+ 3 * phy.c -- USB phy handling 5 * Copyright (C) 2004-2013 Texas Instruments 57 if (phy->type != type) in __usb_find_phy() 63 return ERR_PTR(-ENODEV); in __usb_find_phy() 71 return ERR_PTR(-ENODEV); in __of_usb_find_phy() 74 if (node != phy->dev->of_node) in __of_usb_find_phy() 80 return ERR_PTR(-EPROBE_DEFER); in __of_usb_find_phy() 88 if (usb_phy->dev == dev) in __device_to_usb_phy() 97 usb_phy->chg_cur.sdp_min = DEFAULT_SDP_CUR_MIN; in usb_phy_set_default_current() [all …]
|
| /linux/arch/arm64/boot/dts/allwinner/ |
| H A D | sun50i-h616-orangepi-zero2.dts | 1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 6 /dts-v1/; 8 #include "sun50i-h616-orangepi-zero.dtsi" 9 #include "sun50i-h616-cpu-opp.dtsi" 13 compatible = "xunlong,orangepi-zero2", "allwinner,sun50i-h616"; 17 cpu-supply = <®_dcdca>; 21 allwinner,rx-delay-ps = <3100>; 22 allwinner,tx-delay-ps = <700>; 23 phy-mode = "rgmii"; 24 phy-supply = <®_dcdce>; [all …]
|
| H A D | sun50i-h700-anbernic-rg35xx-2024.dts | 1 // SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 6 /dts-v1/; 8 #include "sun50i-h616.dtsi" 9 #include "sun50i-h616-cpu-opp.dtsi" 10 #include <dt-bindings/gpio/gpio.h> 11 #include <dt-bindings/input/linux-event-codes.h> 12 #include <dt-bindings/interrupt-controller/arm-gic.h> 13 #include <dt-bindings/leds/common.h> 17 chassis-type = "handset"; 18 compatible = "anbernic,rg35xx-2024", "allwinner,sun50i-h700"; [all …]
|
| H A D | sun50i-h616-x96-mate.dts | 1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 6 /dts-v1/; 8 #include "sun50i-h616.dtsi" 9 #include "sun50i-h616-cpu-opp.dtsi" 11 #include <dt-bindings/gpio/gpio.h> 12 #include <dt-bindings/interrupt-controller/arm-gic.h> 16 compatible = "hechuang,x96-mate", "allwinner,sun50i-h616"; 23 stdout-path = "serial0:115200n8"; 28 compatible = "regulator-fixed"; 29 regulator-name = "vcc-5v"; [all …]
|
| /linux/drivers/media/pci/cx88/ |
| H A D | cx88-dsp.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 9 #include "cx88-reg.h" 70 static s32 int_cos(u32 x) in int_cos() argument 74 u16 period = x / INT_PI; in int_cos() 77 return -int_cos(x - INT_PI); in int_cos() 78 x = x % INT_PI; in int_cos() 79 if (x > INT_PI / 2) in int_cos() 80 return -int_cos(INT_PI / 2 - (x % (INT_PI / 2))); in int_cos() 82 * Now x is between 0 and INT_PI/2. in int_cos() 83 * To calculate cos(x) we use it's Taylor polinom. in int_cos() [all …]
|