Home
last modified time | relevance | path

Searched refs:dac (Results 1 – 25 of 59) sorted by relevance

123

/drivers/net/wireless/broadcom/b43/
Dtables_lpphy.c1070 { .gm = 7, .pga = 15, .pad = 14, .dac = 0, .bb_mult = 152, },
1071 { .gm = 7, .pga = 15, .pad = 14, .dac = 0, .bb_mult = 147, },
1072 { .gm = 7, .pga = 15, .pad = 14, .dac = 0, .bb_mult = 143, },
1073 { .gm = 7, .pga = 15, .pad = 14, .dac = 0, .bb_mult = 139, },
1074 { .gm = 7, .pga = 15, .pad = 14, .dac = 0, .bb_mult = 135, },
1075 { .gm = 7, .pga = 15, .pad = 14, .dac = 0, .bb_mult = 131, },
1076 { .gm = 7, .pga = 15, .pad = 14, .dac = 0, .bb_mult = 128, },
1077 { .gm = 7, .pga = 15, .pad = 14, .dac = 0, .bb_mult = 124, },
1078 { .gm = 7, .pga = 15, .pad = 14, .dac = 0, .bb_mult = 121, },
1079 { .gm = 7, .pga = 15, .pad = 14, .dac = 0, .bb_mult = 117, },
[all …]
/drivers/iio/dac/
Dlpc18xx_dac.c53 struct lpc18xx_dac *dac = iio_priv(indio_dev); in lpc18xx_dac_read_raw() local
58 reg = readl(dac->base + LPC18XX_DAC_CR); in lpc18xx_dac_read_raw()
65 *val = regulator_get_voltage(dac->vref) / 1000; in lpc18xx_dac_read_raw()
78 struct lpc18xx_dac *dac = iio_priv(indio_dev); in lpc18xx_dac_write_raw() local
89 mutex_lock(&dac->lock); in lpc18xx_dac_write_raw()
90 writel(reg, dac->base + LPC18XX_DAC_CR); in lpc18xx_dac_write_raw()
91 writel(LPC18XX_DAC_CTRL_DMA_ENA, dac->base + LPC18XX_DAC_CTRL); in lpc18xx_dac_write_raw()
92 mutex_unlock(&dac->lock); in lpc18xx_dac_write_raw()
108 struct lpc18xx_dac *dac; in lpc18xx_dac_probe() local
111 indio_dev = devm_iio_device_alloc(&pdev->dev, sizeof(*dac)); in lpc18xx_dac_probe()
[all …]
Ddpot-dac.c56 struct dpot_dac *dac = iio_priv(indio_dev); in dpot_dac_read_raw() local
62 return iio_read_channel_raw(dac->dpot, val); in dpot_dac_read_raw()
65 ret = iio_read_channel_scale(dac->dpot, val, val2); in dpot_dac_read_raw()
69 do_div(tmp, dac->max_ohms); in dpot_dac_read_raw()
70 tmp *= regulator_get_voltage(dac->vref) / 1000; in dpot_dac_read_raw()
84 *val *= regulator_get_voltage(dac->vref) / 1000; in dpot_dac_read_raw()
85 *val2 *= dac->max_ohms; in dpot_dac_read_raw()
100 struct dpot_dac *dac = iio_priv(indio_dev); in dpot_dac_read_avail() local
105 return iio_read_avail_channel_raw(dac->dpot, vals, length); in dpot_dac_read_avail()
115 struct dpot_dac *dac = iio_priv(indio_dev); in dpot_dac_write_raw() local
[all …]
Dstm32-dac.c39 struct stm32_dac *dac = iio_priv(indio_dev); in stm32_dac_is_enabled() local
43 ret = regmap_read(dac->common->regmap, STM32_DAC_CR, &val); in stm32_dac_is_enabled()
57 struct stm32_dac *dac = iio_priv(indio_dev); in stm32_dac_set_enable_state() local
64 mutex_lock(&dac->lock); in stm32_dac_set_enable_state()
67 mutex_unlock(&dac->lock); in stm32_dac_set_enable_state()
74 mutex_unlock(&dac->lock); in stm32_dac_set_enable_state()
79 ret = regmap_update_bits(dac->common->regmap, STM32_DAC_CR, msk, en); in stm32_dac_set_enable_state()
80 mutex_unlock(&dac->lock); in stm32_dac_set_enable_state()
92 if (en && dac->common->hfsel) in stm32_dac_set_enable_state()
111 static int stm32_dac_get_value(struct stm32_dac *dac, int channel, int *val) in stm32_dac_get_value() argument
[all …]
Dad5755.c515 for (i = 0; i < ARRAY_SIZE(pdata->dac); ++i) { in ad5755_setup_pdata()
516 val = pdata->dac[i].slew.step_size << in ad5755_setup_pdata()
518 val |= pdata->dac[i].slew.rate << in ad5755_setup_pdata()
520 if (pdata->dac[i].slew.enable) in ad5755_setup_pdata()
529 for (i = 0; i < ARRAY_SIZE(pdata->dac); ++i) { in ad5755_setup_pdata()
530 if (!ad5755_is_valid_mode(st, pdata->dac[i].mode)) in ad5755_setup_pdata()
534 if (!pdata->dac[i].ext_current_sense_resistor) in ad5755_setup_pdata()
536 if (pdata->dac[i].enable_voltage_overrange) in ad5755_setup_pdata()
538 val |= pdata->dac[i].mode; in ad5755_setup_pdata()
572 if (pdata && ad5755_is_voltage_mode(pdata->dac[i].mode)) in ad5755_init_channels()
[all …]
DMakefile30 obj-$(CONFIG_CIO_DAC) += cio-dac.o
31 obj-$(CONFIG_DPOT_DAC) += dpot-dac.o
41 obj-$(CONFIG_STM32_DAC_CORE) += stm32-dac-core.o
42 obj-$(CONFIG_STM32_DAC) += stm32-dac.o
Dad5766.c142 static int __ad5766_spi_read(struct ad5766_state *st, u8 dac, int *val) in __ad5766_spi_read() argument
159 st->data[0].d32 = AD5766_CMD_READBACK_REG(dac); in __ad5766_spi_read()
179 static int ad5766_read(struct iio_dev *indio_dev, u8 dac, int *val) in ad5766_read() argument
185 ret = __ad5766_spi_read(st, dac, val); in ad5766_read()
191 static int ad5766_write(struct iio_dev *indio_dev, u8 dac, u16 data) in ad5766_write() argument
197 ret = __ad5766_spi_write(st, AD5766_CMD_WR_DAC_REG(dac), data); in ad5766_write()
/drivers/gpu/drm/nouveau/nvkm/engine/disp/
Ddacnv50.c29 nv50_dac_clock(struct nvkm_ior *dac) in nv50_dac_clock() argument
31 struct nvkm_device *device = dac->disp->engine.subdev.device; in nv50_dac_clock()
32 const u32 doff = nv50_ior_base(dac); in nv50_dac_clock()
37 nv50_dac_sense(struct nvkm_ior *dac, u32 loadval) in nv50_dac_sense() argument
39 struct nvkm_device *device = dac->disp->engine.subdev.device; in nv50_dac_sense()
40 const u32 doff = nv50_ior_base(dac); in nv50_dac_sense()
42 dac->func->power(dac, false, true, false, false, false); in nv50_dac_sense()
49 dac->func->power(dac, false, false, false, false, false); in nv50_dac_sense()
66 nv50_dac_power(struct nvkm_ior *dac, bool normal, bool pu, in nv50_dac_power() argument
69 struct nvkm_device *device = dac->disp->engine.subdev.device; in nv50_dac_power()
[all …]
Ddacgf119.c25 gf119_dac_clock(struct nvkm_ior *dac) in gf119_dac_clock() argument
27 struct nvkm_device *device = dac->disp->engine.subdev.device; in gf119_dac_clock()
28 const u32 doff = nv50_ior_base(dac); in gf119_dac_clock()
33 gf119_dac_state(struct nvkm_ior *dac, struct nvkm_ior_state *state) in gf119_dac_state() argument
35 struct nvkm_device *device = dac->disp->engine.subdev.device; in gf119_dac_state()
36 const u32 coff = (state == &dac->asy) * 0x20000 + dac->id * 0x20; in gf119_dac_state()
Dnv50.c105 if (func->dac.cnt) { in nv50_disp_oneinit_()
106 disp->dac.nr = func->dac.cnt(&disp->base, &disp->dac.mask); in nv50_disp_oneinit_()
108 disp->dac.nr, disp->dac.mask); in nv50_disp_oneinit_()
109 for_each_set_bit(i, &disp->dac.mask, disp->dac.nr) { in nv50_disp_oneinit_()
110 ret = func->dac.new(&disp->base, i); in nv50_disp_oneinit_()
720 for (i = 0; i < disp->dac.nr; i++) { in nv50_disp_init()
766 .dac = { .cnt = nv50_dac_cnt, .new = nv50_dac_new },
Dnv50.h23 } wndw, head, dac; member
67 } wndw, head, dac, sor, pior; member
/drivers/leds/
Dleds-dac124s085.c52 struct dac124s085 *dac; in dac124s085_probe() local
56 dac = devm_kzalloc(&spi->dev, sizeof(*dac), GFP_KERNEL); in dac124s085_probe()
57 if (!dac) in dac124s085_probe()
62 for (i = 0; i < ARRAY_SIZE(dac->leds); i++) { in dac124s085_probe()
63 led = dac->leds + i; in dac124s085_probe()
77 spi_set_drvdata(spi, dac); in dac124s085_probe()
83 led_classdev_unregister(&dac->leds[i].ldev); in dac124s085_probe()
90 struct dac124s085 *dac = spi_get_drvdata(spi); in dac124s085_remove() local
93 for (i = 0; i < ARRAY_SIZE(dac->leds); i++) in dac124s085_remove()
94 led_classdev_unregister(&dac->leds[i].ldev); in dac124s085_remove()
/drivers/video/fbdev/
Dffb.c355 struct ffb_dac __iomem *dac; member
427 struct ffb_dac __iomem *dac = par->dac; in ffb_switch_from_graph() local
446 upa_writel(FFB_DAC_CUR_CTRL, &dac->type2); in ffb_switch_from_graph()
448 upa_writel(0, &dac->value2); in ffb_switch_from_graph()
451 FFB_DAC_CUR_CTRL_P1), &dac->value2); in ffb_switch_from_graph()
676 struct ffb_dac __iomem *dac = par->dac; in ffb_blank() local
685 upa_writel(FFB_DAC_TGEN, &dac->type); in ffb_blank()
686 val = upa_readl(&dac->value); in ffb_blank()
701 upa_writel(FFB_DAC_TGEN, &dac->type); in ffb_blank()
702 upa_writel(val, &dac->value); in ffb_blank()
[all …]
Darkfb.c33 struct dac_info *dac; member
367 struct dac_info dac; member
504 int rv = dac_set_freq(par->dac, 0, 1000000000 / pixclock); in ark_set_pixclock()
554 dac_set_mode(par->dac, DAC_PSEUDO8_8); in arkfb_release()
711 dac_set_mode(par->dac, DAC_PSEUDO8_8); in arkfb_set_par()
720 dac_set_mode(par->dac, DAC_PSEUDO8_8); in arkfb_set_par()
727 dac_set_mode(par->dac, DAC_PSEUDO8_8); in arkfb_set_par()
737 dac_set_mode(par->dac, DAC_PSEUDO8_8); in arkfb_set_par()
741 dac_set_mode(par->dac, DAC_PSEUDO8_16); in arkfb_set_par()
750 dac_set_mode(par->dac, DAC_RGB1555_16); in arkfb_set_par()
[all …]
Dpmag-ba-fb.c42 volatile u32 __iomem *dac; member
82 writeb(v, par->dac + reg / 4); in dac_write()
87 return readb(par->dac + reg / 4); in dac_read()
189 par->dac = par->mmio + PMAG_BA_BT459; in pmagbafb_probe()
Dpmagb-b-fb.c40 volatile u32 __iomem *dac; member
81 writeb(v, par->dac + reg / 4); in dac_write()
86 return readb(par->dac + reg / 4); in dac_read()
297 par->dac = par->mmio + PMAGB_B_BT459; in pmagbbfb_probe()
/drivers/iio/adc/
Denvelope-detector.c56 struct iio_channel *dac; member
150 ret = iio_write_channel_raw(env->dac, env->invert ? 0 : env->dac_max); in envelope_detector_setup_compare()
158 ret = iio_write_channel_raw(env->dac, env->level); in envelope_detector_setup_compare()
221 return iio_read_channel_scale(env->dac, val, val2); in envelope_detector_read_raw()
350 env->dac = devm_iio_channel_get(dev, "dac"); in envelope_detector_probe()
351 if (IS_ERR(env->dac)) in envelope_detector_probe()
352 return dev_err_probe(dev, PTR_ERR(env->dac), in envelope_detector_probe()
374 ret = iio_get_channel_type(env->dac, &type); in envelope_detector_probe()
383 ret = iio_read_max_channel_raw(env->dac, &env->dac_max); in envelope_detector_probe()
/drivers/gpu/drm/sun4i/
Dsun4i_tv.c30 #define SUN4I_TVE_EN_DAC_MAP(dac, out) (((out) & 0xf) << (dac + 1) * 4) argument
51 #define SUN4I_TVE_DAC0_DAC_EN(dac) BIT(dac) argument
54 #define SUN4I_TVE_NOTCH_DAC0_TO_DAC_DLY(dac, x) ((4 - (x)) << (dac * 3)) argument
71 #define SUN4I_TVE_DAC1_AMPLITUDE(dac, x) ((x) << (dac * 8)) argument
74 #define SUN4I_TVE_DETECT_STA_DAC(dac) BIT((dac * 8)) argument
/drivers/hwmon/
Dmax6650.c114 u8 dac; member
140 static int dac_to_pwm(int dac, bool v12) in dac_to_pwm() argument
146 return clamp_val(255 - (255 * dac) / DAC_LIMIT(v12), 0, 255); in dac_to_pwm()
445 data->dac = reg; in max6650_init_client()
499 data->dac = pwm_to_dac(state, data->config & MAX6650_CFG_V12); in max6650_set_cur_state()
500 err = i2c_smbus_write_byte_data(client, MAX6650_REG_DAC, data->dac); in max6650_set_cur_state()
532 *val = dac_to_pwm(data->dac, in max6650_read()
629 data->dac = reg; in max6650_write()
/drivers/media/i2c/
Dadv7343.c232 state->pdata->mode_config.dac[2] << 2 | in adv7343_setoutput()
233 state->pdata->mode_config.dac[1] << 3 | in adv7343_setoutput()
234 state->pdata->mode_config.dac[0] << 4 | in adv7343_setoutput()
235 state->pdata->mode_config.dac[5] << 5 | in adv7343_setoutput()
236 state->pdata->mode_config.dac[4] << 6 | in adv7343_setoutput()
237 state->pdata->mode_config.dac[3] << 7; in adv7343_setoutput()
421 pdata->mode_config.dac, 6); in adv7343_get_pdata()
Dak881x.c183 u8 dac; in ak881x_s_stream() local
187 dac = 3; in ak881x_s_stream()
189 dac = 4; in ak881x_s_stream()
191 reg_write(client, AK881X_DAC_MODE, dac); in ak881x_s_stream()
/drivers/iio/addac/
Dstx104.c64 u16 dac[2]; member
191 iowrite16(val, &priv->reg->dac[chan->channel]); in stx104_write_raw()
373 iowrite16(0, &priv->reg->dac[0]); in stx104_probe()
374 iowrite16(0, &priv->reg->dac[1]); in stx104_probe()
/drivers/gpu/drm/radeon/
Dradeon_combios.c865 uint8_t rev, bg, dac; in radeon_combios_get_primary_dac_info() local
881 dac = (RBIOS8(dac_info + 0x2) >> 4) & 0xf; in radeon_combios_get_primary_dac_info()
882 p_dac->ps2_pdac_adj = (bg << 8) | (dac); in radeon_combios_get_primary_dac_info()
885 dac = RBIOS8(dac_info + 0x3) & 0xf; in radeon_combios_get_primary_dac_info()
886 p_dac->ps2_pdac_adj = (bg << 8) | (dac); in radeon_combios_get_primary_dac_info()
889 if ((dac == 0) || (bg == 0)) in radeon_combios_get_primary_dac_info()
1016 uint8_t rev, bg, dac; in radeon_combios_get_tv_dac_info() local
1030 dac = RBIOS8(dac_info + 0xd) & 0xf; in radeon_combios_get_tv_dac_info()
1031 tv_dac->ps2_tvdac_adj = (bg << 16) | (dac << 20); in radeon_combios_get_tv_dac_info()
1034 dac = RBIOS8(dac_info + 0xf) & 0xf; in radeon_combios_get_tv_dac_info()
[all …]
/drivers/input/touchscreen/
Dad7877.c169 u16 dac; member
497 return sprintf(buf, "%u\n", ts->dac); in ad7877_dac_show()
513 ts->dac = val & 0xFF; in ad7877_dac_store()
514 ad7877_write(ts->spi, AD7877_REG_DAC, (ts->dac << 4) | AD7877_DAC_CONF); in ad7877_dac_store()
520 static DEVICE_ATTR(dac, 0664, ad7877_dac_show, ad7877_dac_store);
/drivers/gpu/drm/nouveau/dispnv50/
Dcore827d.c33 .dac = &dac507d,

123