Home
last modified time | relevance | path

Searched +full:reg +full:- +full:data (Results 1 – 25 of 1121) sorted by relevance

12345678910>>...45

/linux/drivers/usb/chipidea/
H A Dusbmisc_imx.c1 // SPDX-License-Identifier: GPL-2.0+
87 /* For imx6dql, it is host-only controller, for later imx6, it is otg's */
105 /* The default DM/DP value is pull-down */
144 int (*init)(struct imx_usbmisc_data *data);
146 int (*post)(struct imx_usbmisc_data *data);
148 int (*set_wakeup)(struct imx_usbmisc_data *data, bool enabled);
150 int (*hsic_set_connect)(struct imx_usbmisc_data *data);
152 int (*hsic_set_clk)(struct imx_usbmisc_data *data, bool enabled);
154 int (*charger_detection)(struct imx_usbmisc_data *data);
156 int (*power_lost_check)(struct imx_usbmisc_data *data);
[all …]
/linux/drivers/net/ethernet/ti/
H A Ddavinci_mdio.c1 // SPDX-License-Identifier: GPL-2.0+
28 #include <linux/mdio-bitbang.h>
32 * This timeout definition is a worst-case ultra defensive measure against
110 static void davinci_mdio_init_clk(struct davinci_mdio_data *data) in davinci_mdio_init_clk() argument
114 mdio_in = clk_get_rate(data->clk); in davinci_mdio_init_clk()
115 div = (mdio_in / data->pdata.bus_freq) - 1; in davinci_mdio_init_clk()
119 data->clk_div = div; in davinci_mdio_init_clk()
123 * 32 bits of transferred data in davinci_mdio_init_clk()
130 * In the worst case, we could be kicking off a user-access immediately in davinci_mdio_init_clk()
131 * after the mdio bus scan state-machine triggered its own read. If in davinci_mdio_init_clk()
[all …]
/linux/tools/testing/selftests/user_events/
H A Dftrace_test.c1 // SPDX-License-Identifier: GPL-2.0
33 if (fd == -1) in trace_bytes()
34 return -1; in trace_bytes()
39 if (got == -1) in trace_bytes()
40 return -1; in trace_bytes()
69 return -1; in skip_until_empty_line()
78 return -1; in get_print_fmt()
103 return -1; in get_print_fmt()
113 if (fd == -1) in wait_for_delete()
134 if (fd == -1) in clear()
[all …]
/linux/drivers/hwmon/
H A Dw83627ehf.c1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * w83627ehf - Driver for the hardware monitoring functionality of
4 * the Winbond W83627EHF Super-I/O chip
5 * Copyright (C) 2005-2012 Jean Delvare <jdelvare@suse.de>
10 * Copyright (C) 2010 Sheng-Yuan Huang (Nuvoton) (PS00)
18 * This driver also supports the W83627EHG, which is the lead-free
27 * w83627dhg-p 9 5 4 3 0xb070 0xc1 0x5ca3
30 * w83667hg-b 9 5 3 4 0xb350 0xc1 0x5ca3
41 #include <linux/hwmon-sysfs.h>
42 #include <linux/hwmon-vid.h>
[all …]
H A Dmax6650.c1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * max6650.c - Part of lm_sensors, Linux kernel modules for hardware
18 * http://pdfserv.maxim-ic.com/en/ds/MAX6650-MAX6651.pdf
27 #include <linux/hwmon-sysfs.h>
91 /* Minimum and maximum values of the FAN-RPM */
95 #define DIV_FROM_REG(reg) (1 << ((reg) & 7)) argument
99 * Client data (each client gets its own)
130 .data = (void *)1
134 .data = (void *)4
143 * Useful range for dac is 0-180 for 12V fans and 0-76 for 5V fans. in dac_to_pwm()
[all …]
H A Dnct6775-core.c1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * nct6775 - Driver for the hardware monitoring functionality of
4 * Nuvoton NCT677x Super-I/O chips
6 * Copyright (C) 2012 Guenter Roeck <linux@roeck-us.net>
9 * Copyright (C) 2005-2012 Jean Delvare <jdelvare@suse.de>
14 * Copyright (C) 2010 Sheng-Yuan Huang (Nuvoton) (PS00)
36 * nct6796d-s 18 7 7 6+2 0xd801 0xc1 0x5ca3
37 * nct6799d-r 18 7 7 6+2 0xd802 0xc1 0x5ca3
50 #include <linux/hwmon-sysfs.h>
64 /* used to set data->name = nct6775_device_names[data->sio_kind] */
[all …]
/linux/drivers/thermal/
H A Darmada_thermal.c1 // SPDX-License-Identifier: GPL-2.0-only
72 struct armada_thermal_data *data; member
85 /* Formula coeficients: temp = (b - m * reg) / div */
122 } data; member
126 * struct armada_thermal_sensor - hold the information of one thermal sensor
139 struct armada_thermal_data *data = priv->data; in armadaxp_init() local
140 u32 reg; in armadaxp_init() local
142 regmap_read(priv->syscon, data->syscon_control1_off, &reg); in armadaxp_init()
143 reg |= PMU_TDC0_OTF_CAL_MASK; in armadaxp_init()
146 reg &= ~PMU_TDC0_REF_CAL_CNT_MASK; in armadaxp_init()
[all …]
/linux/sound/firewire/tascam/
H A Dtascam-stream.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * tascam-stream.c - a part of driver for TASCAM FireWire series
16 static int get_clock(struct snd_tscm *tscm, u32 *data) in get_clock() argument
19 __be32 reg; in get_clock() local
23 err = snd_fw_transaction(tscm->unit, TCODE_READ_QUADLET_REQUEST, in get_clock()
25 &reg, sizeof(reg), 0); in get_clock()
29 *data = be32_to_cpu(reg); in get_clock()
30 if (*data & CLOCK_STATUS_MASK) in get_clock()
39 return -EAGAIN; in get_clock()
47 u32 data; in set_clock() local
[all …]
/linux/drivers/hwmon/pmbus/
H A Dpmbus_core.c1 // SPDX-License-Identifier: GPL-2.0-or-later
19 #include <linux/hwmon-sysfs.h>
40 u16 reg; /* register */ member
44 int data; /* Sensor data. member
75 #define pb_reg_to_index(page, reg, mask) (((page) << PB_PAGE_SHIFT) | \ argument
76 ((reg) << PB_REG_SHIFT) | (mask))
87 u32 flags; /* from platform data */
109 s16 currpage; /* current page, -1 for unknown/unset */
110 s16 currphase; /* current phase, 0xff for all, -1 for unknown/unset */
121 u8 reg; member
[all …]
/linux/drivers/regulator/
H A Dtps6507x-regulator.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * tps6507x-regulator.c
7 * Copyright (C) 2009 Texas Instrument Incorporated - https://www.ti.com/
33 /* Number of step-down converters available */
113 static inline int tps6507x_pmic_read(struct tps6507x_pmic *tps, u8 reg) in tps6507x_pmic_read() argument
118 err = tps->mfd->read_dev(tps->mfd, reg, 1, &val); in tps6507x_pmic_read()
126 static inline int tps6507x_pmic_write(struct tps6507x_pmic *tps, u8 reg, u8 val) in tps6507x_pmic_write() argument
128 return tps->mfd->write_dev(tps->mfd, reg, 1, &val); in tps6507x_pmic_write()
131 static int tps6507x_pmic_set_bits(struct tps6507x_pmic *tps, u8 reg, u8 mask) in tps6507x_pmic_set_bits() argument
133 int err, data; in tps6507x_pmic_set_bits() local
[all …]
/linux/drivers/acpi/riscv/
H A Dcppc.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * Implement CPPC FFH helper routines for RISC-V.
20 /* RISC-V FFH definitions from RISC-V FFH spec */
30 u32 reg; member
53 struct sbi_cppc_data *data = (struct sbi_cppc_data *)read_data; in sbi_cppc_read() local
55 data->ret = sbi_ecall(SBI_EXT_CPPC, SBI_CPPC_READ, in sbi_cppc_read()
56 data->reg, 0, 0, 0, 0, 0); in sbi_cppc_read()
61 struct sbi_cppc_data *data = (struct sbi_cppc_data *)write_data; in sbi_cppc_write() local
63 data->ret = sbi_ecall(SBI_EXT_CPPC, SBI_CPPC_WRITE, in sbi_cppc_write()
64 data->reg, data->val, 0, 0, 0, 0); in sbi_cppc_write()
[all …]
/linux/sound/firewire/motu/
H A Dmotu-protocol-v3.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * motu-protocol-v3.c - a part of driver for MOTU FireWire series
5 * Copyright (c) 2015-2017 Takashi Sakamoto <o-takashi@sakamocchi.jp>
40 __be32 reg; in snd_motu_protocol_v3_get_clock_rate() local
41 u32 data; in snd_motu_protocol_v3_get_clock_rate() local
44 err = snd_motu_transaction_read(motu, V3_CLOCK_STATUS_OFFSET, &reg, in snd_motu_protocol_v3_get_clock_rate()
45 sizeof(reg)); in snd_motu_protocol_v3_get_clock_rate()
48 data = be32_to_cpu(reg); in snd_motu_protocol_v3_get_clock_rate()
50 data = (data & V3_CLOCK_RATE_MASK) >> V3_CLOCK_RATE_SHIFT; in snd_motu_protocol_v3_get_clock_rate()
51 if (data >= ARRAY_SIZE(snd_motu_clock_rates)) in snd_motu_protocol_v3_get_clock_rate()
[all …]
H A Dmotu-protocol-v1.c1 // SPDX-License-Identifier: GPL-2.0-only
2 // motu-protocol-v1.c - a part of driver for MOTU FireWire series
4 // Copyright (c) 2021 Takashi Sakamoto <o-takashi@sakamocchi.jp>
12 // 0xffff0000: ISOC_COMM_CONTROL_MASK in motu-stream.c.
20 // 0x00000800: analog-1/2
21 // 0x00001a00: analog-3/4
22 // 0x00002c00: analog-5/6
23 // 0x00003e00: analog-7/8
24 // 0x00000000: analog-1
25 // 0x00000900: analog-2
[all …]
H A Dmotu-protocol-v2.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * motu-protocol-v2.c - a part of driver for MOTU FireWire series
5 * Copyright (c) 2015-2017 Takashi Sakamoto <o-takashi@sakamocchi.jp>
34 static int get_clock_rate(u32 data, unsigned int *rate) in get_clock_rate() argument
36 unsigned int index = (data & V2_CLOCK_RATE_MASK) >> V2_CLOCK_RATE_SHIFT; in get_clock_rate()
38 return -EIO; in get_clock_rate()
48 __be32 reg; in snd_motu_protocol_v2_get_clock_rate() local
51 err = snd_motu_transaction_read(motu, V2_CLOCK_STATUS_OFFSET, &reg, in snd_motu_protocol_v2_get_clock_rate()
52 sizeof(reg)); in snd_motu_protocol_v2_get_clock_rate()
56 return get_clock_rate(be32_to_cpu(reg), rate); in snd_motu_protocol_v2_get_clock_rate()
[all …]
/linux/sound/pci/oxygen/
H A Dxonar_cs43xx.c1 // SPDX-License-Identifier: GPL-2.0-only
10 * -----------
14 * I²C <-> CS4398 (addr 1001111) (front)
15 * <-> CS4362A (addr 0011000) (surround, center/LFE, back)
17 * GPI 0 <- external power present (DX only)
19 * GPIO 0 -> enable output to speakers
20 * GPIO 1 -> route output to front panel
21 * GPIO 2 -> M0 of CS5361
22 * GPIO 3 -> M1 of CS5361
23 * GPIO 6 -> ?
[all …]
/linux/drivers/clk/sunxi/
H A Dclk-sun4i-display.c1 // SPDX-License-Identifier: GPL-2.0-or-later
5 * Maxime Ripard <maxime.ripard@free-electrons.com>
8 #include <linux/clk-provider.h>
12 #include <linux/reset-controller.h>
33 void __iomem *reg; member
49 struct reset_data *data = rcdev_to_reset_data(rcdev); in sun4i_a10_display_assert() local
51 u32 reg; in sun4i_a10_display_assert() local
53 spin_lock_irqsave(data->lock, flags); in sun4i_a10_display_assert()
55 reg = readl(data->reg); in sun4i_a10_display_assert()
56 writel(reg & ~BIT(data->offset + id), data->reg); in sun4i_a10_display_assert()
[all …]
/linux/drivers/gpu/drm/nouveau/nvkm/subdev/bus/
H A Dhwsq.h1 /* SPDX-License-Identifier: MIT */
18 u32 data; member
30 .data = 0xdeadbeef, in hwsq_stride()
41 .stride = addr2 - addr1, in hwsq_reg2()
43 .data = 0xdeadbeef, in hwsq_reg2()
56 .data = 0xdeadbeef, in hwsq_reg()
65 ret = nvkm_hwsq_init(subdev, &ram->hwsq); in hwsq_init()
69 ram->sequence++; in hwsq_init()
70 ram->subdev = subdev; in hwsq_init()
78 if (ram->subdev) { in hwsq_exec()
[all …]
/linux/drivers/net/ipa/
H A Dipa_resource.c1 // SPDX-License-Identifier: GPL-2.0
3 /* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
4 * Copyright (C) 2018-2024 Linaro Ltd.
29 const struct ipa_resource_data *data) in ipa_resource_limits_valid() argument
38 group_count = data->rsrc_group_src_count; in ipa_resource_limits_valid()
42 /* Return an error if a non-zero resource limit is specified in ipa_resource_limits_valid()
45 for (i = 0; i < data->resource_src_count; i++) { in ipa_resource_limits_valid()
48 resource = &data->resource_src[i]; in ipa_resource_limits_valid()
50 if (resource->limits[j].min || resource->limits[j].max) in ipa_resource_limits_valid()
54 group_count = data->rsrc_group_dst_count; in ipa_resource_limits_valid()
[all …]
/linux/drivers/usb/typec/tcpm/
H A Dtcpci.c1 // SPDX-License-Identifier: GPL-2.0+
3 * Copyright 2015-2017 Google, Inc
5 * USB Type-C Port Controller Interface.
42 struct tcpci_data *data; member
47 struct tcpci_data data; member
52 return tcpci->port; in tcpci_get_tcpm_port()
61 static int tcpci_read16(struct tcpci *tcpci, unsigned int reg, u16 *val) in tcpci_read16() argument
63 return regmap_raw_read(tcpci->regmap, reg, val, sizeof(u16)); in tcpci_read16()
66 static int tcpci_write16(struct tcpci *tcpci, unsigned int reg, u16 val) in tcpci_write16() argument
68 return regmap_raw_write(tcpci->regmap, reg, &val, sizeof(u16)); in tcpci_write16()
[all …]
/linux/drivers/misc/
H A Dad525x_dpot.c1 // SPDX-License-Identifier: GPL-2.0-or-later
4 * Copyright (c) 2009-2010 Analog Devices, Inc.
33 * AD5291 1 256 20, 50, 100 (20-TP)
34 * AD5292 1 1024 20, 50, 100 (20-TP)
56 * AD5270 1 1024 20, 50, 100 (50-TP)
57 * AD5271 1 256 20, 50, 100 (50-TP)
58 * AD5272 1 1024 20, 50, 100 (50-TP)
59 * AD5274 1 256 20, 50, 100 (50-TP)
61 * See Documentation/misc-devices/ad525x_dpot.rst for more info.
68 * Copyright (c) 2006-2011 Michael Hennerich <michael.hennerich@analog.com>
[all …]
/linux/drivers/mfd/
H A Dwm8350-irq.c1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * wm8350-irq.c -- IRQ support for Wolfson WM8350
36 int reg; member
44 .reg = WM8350_OVER_CURRENT_INT_OFFSET,
50 .reg = WM8350_UNDER_VOLTAGE_INT_OFFSET,
55 .reg = WM8350_UNDER_VOLTAGE_INT_OFFSET,
60 .reg = WM8350_UNDER_VOLTAGE_INT_OFFSET,
65 .reg = WM8350_UNDER_VOLTAGE_INT_OFFSET,
70 .reg = WM8350_UNDER_VOLTAGE_INT_OFFSET,
75 .reg = WM8350_UNDER_VOLTAGE_INT_OFFSET,
[all …]
/linux/drivers/clk/
H A Dclk-si544.c1 // SPDX-License-Identifier: GPL-2.0
8 #include <linux/clk-provider.h>
68 * struct clk_si544_muldiv - Multiplier/divider settings
73 * If ls_div_bits is non-zero, hs_div must be even
74 * @delta_m: Frequency shift for small -950..+950 ppm changes, 24 bit
85 static int si544_enable_output(struct clk_si544 *data, bool enable) in si544_enable_output() argument
87 return regmap_update_bits(data->regmap, SI544_REG_OE_STATE, in si544_enable_output()
93 struct clk_si544 *data = to_clk_si544(hw); in si544_prepare() local
95 return si544_enable_output(data, true); in si544_prepare()
100 struct clk_si544 *data = to_clk_si544(hw); in si544_unprepare() local
[all …]
/linux/drivers/usb/cdns3/
H A Dcdns3-ti.c1 // SPDX-License-Identifier: GPL-2.0
3 * cdns3-ti.c - TI specific Glue layer for Cadence USB Controller
5 * Copyright (C) 2019 Texas Instruments Incorporated - https://www.ti.com
14 #include <linux/dma-mapping.h>
79 static inline u32 cdns_ti_readl(struct cdns_ti *data, u32 offset) in cdns_ti_readl() argument
81 return readl(data->usbss + offset); in cdns_ti_readl()
84 static inline void cdns_ti_writel(struct cdns_ti *data, u32 offset, u32 value) in cdns_ti_writel() argument
86 writel(value, data->usbss + offset); in cdns_ti_writel()
103 struct device *dev = &pdev->dev; in cdns_ti_probe()
104 struct device_node *node = pdev->dev.of_node; in cdns_ti_probe()
[all …]
/linux/drivers/usb/gadget/udc/
H A Dfusb300_udc.c1 // SPDX-License-Identifier: GPL-2.0
7 * Author : Yuan-hsin Chen <yhchen@faraday-tech.com>
9 #include <linux/dma-mapping.h>
22 MODULE_AUTHOR("Yuan-Hsin Chen, Feng-Hsin Chiang <john453@faraday-tech.com>");
39 u32 reg = ioread32(fusb300->reg + offset); in fusb300_enable_bit() local
41 reg |= value; in fusb300_enable_bit()
42 iowrite32(reg, fusb300->reg + offset); in fusb300_enable_bit()
48 u32 reg = ioread32(fusb300->reg + offset); in fusb300_disable_bit() local
50 reg &= ~value; in fusb300_disable_bit()
51 iowrite32(reg, fusb300->reg + offset); in fusb300_disable_bit()
[all …]
/linux/drivers/net/ethernet/intel/igc/
H A Digc_diag.c1 // SPDX-License-Identifier: GPL-2.0
35 static bool reg_pattern_test(struct igc_adapter *adapter, u64 *data, int reg, in reg_pattern_test() argument
38 struct igc_hw *hw = &adapter->hw; in reg_pattern_test()
45 before = rd32(reg); in reg_pattern_test()
46 wr32(reg, test_pattern[pat] & write); in reg_pattern_test()
47 val = rd32(reg); in reg_pattern_test()
49 netdev_err(adapter->netdev, in reg_pattern_test()
50 "pattern test reg %04X failed: got 0x%08X expected 0x%08X", in reg_pattern_test()
51 reg, val, test_pattern[pat] & write & mask); in reg_pattern_test()
52 *data = reg; in reg_pattern_test()
[all …]

12345678910>>...45