Home
last modified time | relevance | path

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

12345678910>>...43

/linux-6.14.4/sound/core/oss/
Drate.c2 * Rate conversion Plug-In
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
29 #define R_MASK (BITS-1)
55 unsigned int channel; in rate_init() local
56 struct rate_priv *data = (struct rate_priv *)plugin->extra_data; in rate_init() local
57 data->pos = 0; in rate_init()
58 for (channel = 0; channel < plugin->src_format.channels; channel++) { in rate_init()
59 data->channels[channel].last_S1 = 0; in rate_init()
60 data->channels[channel].last_S2 = 0; in rate_init()
73 unsigned int channel; in resample_expand() local
[all …]
Dmulaw.c2 * Mu-Law conversion Plug-In Interface
4 * Uros Bizjak <uros@kss-loka.si>
20 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
29 #define SIGN_BIT (0x80) /* Sign bit for a u-law byte. */
31 #define NSEGS (8) /* Number of u-law segments. */
55 * linear2ulaw() - Convert a linear PCM value to u-law
58 * is biased by adding 33 which shifts the encoding range from (0 - 8158) to
59 * (33 - 8191). The result can be seen in the following encoding table:
62 * ------------------------ ---------------
75 * four bits wxyz. * The trailing bits (a - h) are ignored.
[all …]
Dlinear.c2 * Linear conversion Plug-In
4 * Abramo Bagnara <abramo@alsa-project.org>
19 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
36 unsigned int copy_ofs; /* byte offset in temporary u32 data */
42 static inline void do_convert(struct linear_priv *data, in do_convert() argument
48 memcpy(p + data->copy_ofs, src + data->src_ofs, data->copy_bytes); in do_convert()
49 if (data->cvt_endian) in do_convert()
51 tmp ^= data->flip; in do_convert()
52 memcpy(dst, p + data->dst_ofs, data->dst_bytes); in do_convert()
60 struct linear_priv *data = (struct linear_priv *)plugin->extra_data; in convert() local
[all …]
/linux-6.14.4/drivers/hwmon/
Dmax31790.c1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * max31790.c - Part of lm_sensors, Linux kernel modules for hardware
56 * Client data (each client gets its own)
75 struct max31790_data *data = dev_get_drvdata(dev); in max31790_update_device() local
76 struct i2c_client *client = data->client; in max31790_update_device()
77 struct max31790_data *ret = data; in max31790_update_device()
81 mutex_lock(&data->update_lock); in max31790_update_device()
83 if (time_after(jiffies, data->last_updated + HZ) || !data->valid) { in max31790_update_device()
88 data->fault_status |= rv & 0x3F; in max31790_update_device()
94 data->fault_status |= (rv & 0x3F) << 6; in max31790_update_device()
[all …]
Dmax6639.c1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * max6639.c - Support for Maxim MAX6639
5 * 2-Channel Temperature Monitor with Dual PWM Fan-Speed Controller
19 #include <linux/hwmon-sysfs.h>
28 /* The MAX6639 registers, valid channel numbers: 0, 1 */
74 * Client data (each client gets its own)
88 static int max6639_temp_read_input(struct device *dev, int channel, long *temp) in max6639_temp_read_input() argument
90 u32 regs[2] = { MAX6639_REG_TEMP_EXT(channel), MAX6639_REG_TEMP(channel) }; in max6639_temp_read_input()
91 struct max6639_data *data = dev_get_drvdata(dev); in max6639_temp_read_input() local
95 res = regmap_multi_reg_read(data->regmap, regs, regvals, 2); in max6639_temp_read_input()
[all …]
Dtmp464.c1 // SPDX-License-Identifier: GPL-2.0-or-later
24 #define TMP464_NUM_CHANNELS 5 /* chan 0 is internal, 1-4 are remote */
25 #define TMP468_NUM_CHANNELS 9 /* chan 0 is internal, 1-8 are remote */
29 #define TMP464_TEMP_REG(channel) (channel) argument
30 #define TMP464_TEMP_OFFSET_REG(channel) (0x40 + ((channel) - 1) * 8) argument
31 #define TMP464_N_FACTOR_REG(channel) (0x41 + ((channel) - 1) * 8) argument
78 .data = (void *)TMP464_NUM_CHANNELS
82 .data = (void *)TMP468_NUM_CHANNELS
102 struct tmp464_channel channel[MAX_CHANNELS]; member
120 static int tmp464_enable_channels(struct tmp464_data *data) in tmp464_enable_channels() argument
[all …]
Dnct7904.c1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * nct7904.c - driver for Nuvoton NCT7904D.
92 #define FANCTL1_FMR_REG 0x00 /* Bank 3; 1 reg per channel */
93 #define FANCTL1_OUT_REG 0x10 /* Bank 3; 1 reg per channel */
110 /*The timeout range is 1-255 minutes*/
145 static int nct7904_bank_lock(struct nct7904_data *data, unsigned int bank) in nct7904_bank_lock() argument
149 mutex_lock(&data->bank_lock); in nct7904_bank_lock()
150 if (data->bank_sel == bank) in nct7904_bank_lock()
152 ret = i2c_smbus_write_byte_data(data->client, BANK_SEL_REG, bank); in nct7904_bank_lock()
154 data->bank_sel = bank; in nct7904_bank_lock()
[all …]
Dmax197.c1 // SPDX-License-Identifier: GPL-2.0-only
5 * Copyright (c) 2012 Savoir-faire Linux Inc.
21 #include <linux/hwmon-sysfs.h>
34 #define MAX197_SCALE 12207 /* Scale coefficient for raw data */
40 * struct max197_data - device instance specific data
41 * @pdata: Platform data.
57 static inline void max197_set_unipolarity(struct max197_data *data, int channel) in max197_set_unipolarity() argument
59 data->ctrl_bytes[channel] &= ~MAX197_BIP; in max197_set_unipolarity()
62 static inline void max197_set_bipolarity(struct max197_data *data, int channel) in max197_set_bipolarity() argument
64 data->ctrl_bytes[channel] |= MAX197_BIP; in max197_set_bipolarity()
[all …]
Dadt7411.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * Driver for the ADT7411 (I2C/SPI 8 channel 10 bit ADC & temperature-sensor)
7 * TODO: SPI, use power-down mode for suspend?, interrupt handling?
18 #include <linux/hwmon-sysfs.h>
63 ? 0x2b + 2 * ((nr)-2) \
66 ? 0x2c + 2 * ((nr)-2) \
112 * msb-registers get locked by the hardware. After _one_ of those msb is read,
119 struct adt7411_data *data = i2c_get_clientdata(client); in adt7411_read_10_bit() local
122 mutex_lock(&data->device_lock); in adt7411_read_10_bit()
135 mutex_unlock(&data->device_lock); in adt7411_read_10_bit()
[all …]
Dadm9240.c1 // SPDX-License-Identifier: GPL-2.0-or-later
21 * Alarms 16-bit map of active alarms
26 * Test hardware: Intel SE440BX-2 desktop motherboard --Grant
36 #include <linux/hwmon-sysfs.h>
38 #include <linux/hwmon-vid.h>
74 return (val * mul - div / 2) / div; in SCALE()
93 /* temperature range: -40..125, 127 disables temperature alarm */
96 val = clamp_val(val, -40000, 127000); in TEMP_TO_REG()
104 return -1; in FAN_FROM_REG()
124 /* per client data */
[all …]
Dtmp421.c1 // SPDX-License-Identifier: GPL-2.0-or-later
20 #include <linux/hwmon-sysfs.h>
72 .data = (void *)2
76 .data = (void *)3
80 .data = (void *)4
84 .data = (void *)2
88 .data = (void *)3
111 struct tmp421_channel channel[MAX_CHANNELS]; member
120 temp = temp - 64 * 256; in temp_from_raw()
127 static int tmp421_update_device(struct tmp421_data *data) in tmp421_update_device() argument
[all …]
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 <[email protected]>
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 …]
Dmax31730.c1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * Driver for MAX31730 3-Channel Remote Temperature Sensor
5 * Copyright (c) 2019 Guenter Roeck <linux@roeck-us.net>
41 #define MAX31730_TEMP_MIN (-128000)
44 /* Each client has this additional data */
53 /*-----------------------------------------------------------------------*/
60 static int max31730_write_config(struct max31730_data *data, u8 set_mask, in max31730_write_config() argument
66 value = data->current_conf & ~clr_mask; in max31730_write_config()
69 if (data->current_conf != value) { in max31730_write_config()
72 err = i2c_smbus_write_byte_data(data->client, MAX31730_REG_CONF, in max31730_write_config()
[all …]
Dlm95241.c1 // SPDX-License-Identifier: GPL-2.0-or-later
75 /* Client data (each client gets its own) */
80 unsigned long interval; /* in milli-seconds */
102 struct lm95241_data *data = dev_get_drvdata(dev); in lm95241_update_device() local
103 struct i2c_client *client = data->client; in lm95241_update_device()
105 mutex_lock(&data->update_lock); in lm95241_update_device()
107 if (time_after(jiffies, data->last_updated in lm95241_update_device()
108 + msecs_to_jiffies(data->interval)) || in lm95241_update_device()
109 !data->valid) { in lm95241_update_device()
112 dev_dbg(dev, "Updating lm95241 data.\n"); in lm95241_update_device()
[all …]
Dmax127.c1 // SPDX-License-Identifier: GPL-2.0+
15 * MAX127 Control Byte. Refer to MAX127 datasheet, Table 1 "Control-Byte
29 * MAX127 channel input ranges. Refer to MAX127 datasheet, Table 3 "Range
37 * - the first byte contains data[11:4].
38 * - the second byte contains data[3:0] (MSB) and 4 dummy 0s (LSB).
57 .addr = client->addr, in max127_select_channel()
63 status = i2c_transfer(client->adapter, &msg, 1); in max127_select_channel()
67 return -EIO; in max127_select_channel()
77 .addr = client->addr, in max127_read_channel()
83 status = i2c_transfer(client->adapter, &msg, 1); in max127_read_channel()
[all …]
/linux-6.14.4/drivers/rpmsg/
Dqcom_smd.c1 // SPDX-License-Identifier: GPL-2.0
4 * Copyright (c) 2012-2013, The Linux Foundation. All rights reserved.
27 * The Qualcomm Shared Memory communication solution provides point-to-point
28 * channels for clients to send and receive streaming or packet based data.
30 * Each channel consists of a control item (channel info) and a ring buffer
31 * pair. The channel info carry information related to channel state, flow
37 * Upon creating a new channel the remote processor allocates channel info and
39 * interrupt is sent to the other end of the channel and a scan for new
40 * channels should be done. A channel never goes away, it will only change
44 * channel by setting the state of its end of the channel to "opening" and
[all …]
Dqcom_glink_native.c1 // SPDX-License-Identifier: GPL-2.0
3 * Copyright (c) 2016-2017, Linaro Ltd
42 u8 data[]; member
44 static_assert(offsetof(struct glink_msg, data) == sizeof(struct glink_msg_hdr),
48 * struct glink_defer_cmd - deferred incoming control message
51 * @data: payload of the message
60 u8 data[]; member
64 * struct glink_core_rx_intent - RX intent
67 * @data: pointer to the data (may be NULL for zero-copy)
71 * @in_use: To mark if intent is already in use for the channel
[all …]
/linux-6.14.4/drivers/thermal/qcom/
Dqcom-spmi-adc-tm5.c1 // SPDX-License-Identifier: GPL-2.0-only
6 * Copyright (c) 2012-2020, The Linux Foundation. All rights reserved.
12 #include <linux/iio/adc/qcom-vadc-common.h>
27 * channel is programmed to use one of ADC channels for voltage comparison.
169 int (*disable_channel)(struct adc_tm5_channel *channel);
170 int (*configure)(struct adc_tm5_channel *channel, int low, int high);
171 irqreturn_t (*isr)(int irq, void *data);
178 * struct adc_tm5_channel - ADC Thermal Monitoring channel data.
179 * @channel: channel number.
180 * @adc_channel: corresponding ADC channel number.
[all …]
/linux-6.14.4/drivers/firmware/tegra/
Dbpmp.c1 // SPDX-License-Identifier: GPL-2.0-only
18 #include <soc/tegra/bpmp-abi.h>
21 #include "bpmp-private.h"
28 channel_to_ops(struct tegra_bpmp_channel *channel) in channel_to_ops() argument
30 struct tegra_bpmp *bpmp = channel->bpmp; in channel_to_ops()
32 return bpmp->soc->ops; in channel_to_ops()
41 np = of_parse_phandle(dev->of_node, "nvidia,bpmp", 0); in tegra_bpmp_get()
43 return ERR_PTR(-ENOENT); in tegra_bpmp_get()
47 bpmp = ERR_PTR(-ENODEV); in tegra_bpmp_get()
53 bpmp = ERR_PTR(-EPROBE_DEFER); in tegra_bpmp_get()
[all …]
/linux-6.14.4/sound/core/seq/
Dseq_ump_convert.c1 // SPDX-License-Identifier: GPL-2.0-or-later
68 return port->ump_group ? (port->ump_group - 1) : 0; in get_ump_group()
76 * UMP -> MIDI1 sequencer event
85 ev->data.note.channel = val->note.channel; in ump_midi1_to_note_ev()
86 ev->data.note.note = val->note.note; in ump_midi1_to_note_ev()
87 ev->data.note.velocity = val->note.velocity; in ump_midi1_to_note_ev()
94 ev->data.control.channel = val->caf.channel; in ump_midi1_to_ctrl_ev()
95 ev->data.control.value = val->caf.data; in ump_midi1_to_ctrl_ev()
102 ev->data.control.channel = val->pb.channel; in ump_midi1_to_pitchbend_ev()
103 ev->data.control.value = (val->pb.data_msb << 7) | val->pb.data_lsb; in ump_midi1_to_pitchbend_ev()
[all …]
/linux-6.14.4/drivers/iio/dac/
Dti-dac5571.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * ti-dac5571.c - Texas Instruments 8/10/12-bit 1/4-channel DAC driver
55 int (*dac5571_cmd)(struct dac5571_data *data, int channel, u16 val);
56 int (*dac5571_pwrdwn)(struct dac5571_data *data, int channel, u8 pwrdwn);
67 static int dac5571_cmd_single(struct dac5571_data *data, int channel, u16 val) in dac5571_cmd_single() argument
71 shift = 12 - data->spec->resolution; in dac5571_cmd_single()
72 data->buf[1] = val << shift; in dac5571_cmd_single()
73 data->buf[0] = val >> (8 - shift); in dac5571_cmd_single()
75 if (i2c_master_send(data->client, data->buf, 2) != 2) in dac5571_cmd_single()
76 return -EIO; in dac5571_cmd_single()
[all …]
/linux-6.14.4/Documentation/ABI/testing/
Dconfigfs-most9 # mount -t configfs none /sys/kernel/config/
19 configure the buffer size for this channel
22 configure the sub-buffer size for this channel
23 (needed for synchronous and isochronous data)
28 channel
31 configure type of data that will travel over
32 this channel
39 configure DBR data buffer size (this is used
51 channel
52 name of the channel the link is to be attached to
[all …]
/linux-6.14.4/drivers/nvme/host/
Dhwmon.c1 // SPDX-License-Identifier: GPL-2.0
32 return -EIO; in nvme_get_temp_thresh()
55 return -EIO; in nvme_set_temp_thresh()
60 static int nvme_hwmon_get_smart_log(struct nvme_hwmon_data *data) in nvme_hwmon_get_smart_log() argument
62 return nvme_get_log(data->ctrl, NVME_NSID_ALL, NVME_LOG_SMART, 0, in nvme_hwmon_get_smart_log()
63 NVME_CSI_NVM, data->log, sizeof(*data->log), 0); in nvme_hwmon_get_smart_log()
67 u32 attr, int channel, long *val) in nvme_hwmon_read() argument
69 struct nvme_hwmon_data *data = dev_get_drvdata(dev); in nvme_hwmon_read() local
70 struct nvme_smart_log *log = data->log; in nvme_hwmon_read()
80 return nvme_get_temp_thresh(data->ctrl, channel, false, val); in nvme_hwmon_read()
[all …]
/linux-6.14.4/Documentation/filesystems/
Drelay.rst1 .. SPDX-License-Identifier: GPL-2.0
8 efficiently log and transfer large quantities of data from the kernel
9 to userspace via user-defined 'relay channels'.
11 A 'relay channel' is a kernel->user data relay mechanism implemented
12 as a set of per-cpu kernel buffers ('channel buffers'), each
14 clients write into the channel buffers using efficient write
15 functions; these automatically log into the current cpu's channel
17 and retrieve the data as it becomes available. The relay files
19 are associated with the channel buffers using the API described below.
21 The format of the data logged into the channel buffers is completely
[all …]
/linux-6.14.4/sound/soc/sprd/
Dsprd-mcdt.c1 // SPDX-License-Identifier: GPL-2.0
14 #include "sprd-mcdt.h"
57 /* Channel water mark definition */
62 /* DMA channel select definition */
75 /* DMA channel ACK select definition */
78 /* Channel FIFO definition */
121 u32 orig = readl_relaxed(mcdt->base + reg); in sprd_mcdt_update()
125 writel_relaxed(tmp, mcdt->base + reg); in sprd_mcdt_update()
128 static void sprd_mcdt_dac_set_watermark(struct sprd_mcdt_dev *mcdt, u8 channel, in sprd_mcdt_dac_set_watermark() argument
131 u32 reg = MCDT_DAC0_WTMK + channel * 4; in sprd_mcdt_dac_set_watermark()
[all …]

12345678910>>...43