Home
last modified time | relevance | path

Searched refs:osr (Results 1 – 25 of 34) sorted by relevance

12

/linux-6.15/drivers/iio/pressure/
H A Dms5611_i2c.c62 const struct ms5611_osr *osr = st->temp_osr; in ms5611_i2c_read_adc_temp_and_pressure() local
64 ret = i2c_smbus_write_byte(st->client, osr->cmd); in ms5611_i2c_read_adc_temp_and_pressure()
68 usleep_range(osr->conv_usec, osr->conv_usec + (osr->conv_usec / 10UL)); in ms5611_i2c_read_adc_temp_and_pressure()
73 osr = st->pressure_osr; in ms5611_i2c_read_adc_temp_and_pressure()
74 ret = i2c_smbus_write_byte(st->client, osr->cmd); in ms5611_i2c_read_adc_temp_and_pressure()
78 usleep_range(osr->conv_usec, osr->conv_usec + (osr->conv_usec / 10UL)); in ms5611_i2c_read_adc_temp_and_pressure()
H A Dms5611_spi.c57 const struct ms5611_osr *osr = st->temp_osr; in ms5611_spi_read_adc_temp_and_pressure() local
63 ret = spi_write_then_read(st->client, &osr->cmd, 1, NULL, 0); in ms5611_spi_read_adc_temp_and_pressure()
67 usleep_range(osr->conv_usec, osr->conv_usec + (osr->conv_usec / 10UL)); in ms5611_spi_read_adc_temp_and_pressure()
72 osr = st->pressure_osr; in ms5611_spi_read_adc_temp_and_pressure()
73 ret = spi_write_then_read(st->client, &osr->cmd, 1, NULL, 0); in ms5611_spi_read_adc_temp_and_pressure()
77 usleep_range(osr->conv_usec, osr->conv_usec + (osr->conv_usec / 10UL)); in ms5611_spi_read_adc_temp_and_pressure()
H A Dms5611_core.c292 const struct ms5611_osr *osr, in ms5611_find_osr() argument
298 if ((unsigned short)rate == osr[r].rate) in ms5611_find_osr()
302 return &osr[r]; in ms5611_find_osr()
310 const struct ms5611_osr *osr = NULL; in ms5611_write_raw() local
317 osr = ms5611_find_osr(val, ms5611_avail_temp_osr, in ms5611_write_raw()
320 osr = ms5611_find_osr(val, ms5611_avail_pressure_osr, in ms5611_write_raw()
322 if (!osr) in ms5611_write_raw()
332 st->temp_osr = osr; in ms5611_write_raw()
334 st->pressure_osr = osr; in ms5611_write_raw()
/linux-6.15/crypto/
H A Djitterentropy.c77 unsigned int osr; /* Oversample rate */ member
189 if (osr >= ARRAY_SIZE(jent_apt_cutoff_lookup)) { in jent_apt_init()
195 ec->apt_cutoff = jent_apt_cutoff_lookup[osr - 1]; in jent_apt_init()
197 jent_apt_cutoff_permanent_lookup[osr - 1]; in jent_apt_init()
287 if ((unsigned int)ec->rct_count >= (60 * ec->osr)) { in jent_rct_insert()
290 } else if ((unsigned int)ec->rct_count >= (30 * ec->osr)) { in jent_rct_insert()
576 if (++k >= ((DATA_SIZE_BITS + safety_factor) * ec->osr)) in jent_gen_entropy()
684 if (osr == 0) in jent_entropy_collector_alloc()
685 osr = 1; /* H_submitter = 1 / osr */ in jent_entropy_collector_alloc()
686 entropy_collector->osr = osr; in jent_entropy_collector_alloc()
[all …]
H A Djitterentropy.h14 extern int jent_entropy_init(unsigned int osr, unsigned int flags,
19 extern struct rand_data *jent_entropy_collector_alloc(unsigned int osr,
/linux-6.15/sound/soc/codecs/
H A Dnau8325.c476 unsigned int osr; in nau8325_get_osr() local
479 osr &= NAU8325_DAC_OVERSAMPLE_MASK; in nau8325_get_osr()
480 if (osr >= ARRAY_SIZE(osr_dac_sel)) in nau8325_get_osr()
483 return &osr_dac_sel[osr]; in nau8325_get_osr()
491 const struct nau8325_osr_attr *osr; in nau8325_dai_startup() local
493 osr = nau8325_get_osr(nau8325); in nau8325_dai_startup()
494 if (!osr || !osr->osr) in nau8325_dai_startup()
499 0, CLK_DA_AD_MAX / osr->osr); in nau8325_dai_startup()
509 const struct nau8325_osr_attr *osr; in nau8325_hw_params() local
513 osr = nau8325_get_osr(nau8325); in nau8325_hw_params()
[all …]
H A Dnau8540.c407 unsigned int osr; in nau8540_get_osr() local
410 osr &= NAU8540_ADC_OSR_MASK; in nau8540_get_osr()
411 if (osr >= ARRAY_SIZE(osr_adc_sel)) in nau8540_get_osr()
413 return &osr_adc_sel[osr]; in nau8540_get_osr()
421 const struct nau8540_osr_attr *osr; in nau8540_dai_startup() local
423 osr = nau8540_get_osr(nau8540); in nau8540_dai_startup()
424 if (!osr || !osr->osr) in nau8540_dai_startup()
429 0, CLK_ADC_MAX / osr->osr); in nau8540_dai_startup()
446 osr = nau8540_get_osr(nau8540); in nau8540_hw_params()
447 if (!osr || !osr->osr) in nau8540_hw_params()
[all …]
H A Dnau8821.c99 unsigned int osr; member
803 unsigned int osr; in nau8821_get_osr() local
810 return &osr_dac_sel[osr]; in nau8821_get_osr()
813 osr &= NAU8821_ADC_SYNC_DOWN_MASK; in nau8821_get_osr()
816 return &osr_adc_sel[osr]; in nau8821_get_osr()
825 const struct nau8821_osr_attr *osr; in nau8821_dai_startup() local
828 if (!osr || !osr->osr) in nau8821_dai_startup()
833 0, CLK_DA_AD_MAX / osr->osr); in nau8821_dai_startup()
842 const struct nau8821_osr_attr *osr; in nau8821_hw_params() local
852 if (!osr || !osr->osr) in nau8821_hw_params()
[all …]
H A Dnau8824.c1039 unsigned int osr; in nau8824_get_osr() local
1044 osr &= NAU8824_DAC_OVERSAMPLE_MASK; in nau8824_get_osr()
1047 return &osr_dac_sel[osr]; in nau8824_get_osr()
1051 osr &= NAU8824_ADC_SYNC_DOWN_MASK; in nau8824_get_osr()
1054 return &osr_adc_sel[osr]; in nau8824_get_osr()
1063 const struct nau8824_osr_attr *osr; in nau8824_dai_startup() local
1066 if (!osr || !osr->osr) in nau8824_dai_startup()
1071 0, CLK_DA_AD_MAX / osr->osr); in nau8824_dai_startup()
1080 const struct nau8824_osr_attr *osr; in nau8824_hw_params() local
1093 if (!osr || !osr->osr) in nau8824_hw_params()
[all …]
H A Dwm1250-ev1.c21 struct gpio_desc *osr; member
155 wm1250->osr = devm_gpiod_get(&i2c->dev, "osr", GPIOD_OUT_LOW); in wm1250_ev1_pdata()
156 if (IS_ERR(wm1250->osr)) in wm1250_ev1_pdata()
157 return dev_err_probe(&i2c->dev, PTR_ERR(wm1250->osr), in wm1250_ev1_pdata()
H A Dnau8825.c103 unsigned int osr; member
1239 unsigned int osr; in nau8825_get_osr() local
1243 NAU8825_REG_DAC_CTRL1, &osr); in nau8825_get_osr()
1247 return &osr_dac_sel[osr]; in nau8825_get_osr()
1250 NAU8825_REG_ADC_RATE, &osr); in nau8825_get_osr()
1251 osr &= NAU8825_ADC_SYNC_DOWN_MASK; in nau8825_get_osr()
1254 return &osr_adc_sel[osr]; in nau8825_get_osr()
1266 if (!osr || !osr->osr) in nau8825_dai_startup()
1271 0, CLK_DA_AD_MAX / osr->osr); in nau8825_dai_startup()
1293 if (!osr || !osr->osr) in nau8825_hw_params()
[all …]
H A Dwm8580.c542 int i, ratio, osr; in wm8580_paif_hw_params() local
583 osr = WM8580_DACOSR; in wm8580_paif_hw_params()
587 osr = 0; in wm8580_paif_hw_params()
592 snd_soc_component_update_bits(component, WM8580_PAIF3, WM8580_DACOSR, osr); in wm8580_paif_hw_params()
H A Dnau8540.h260 unsigned int osr; member
H A Dnau8325.h387 unsigned int osr; member
/linux-6.15/drivers/iio/light/
H A Das73211.c118 u8 osr; member
293 data->osr &= ~AS73211_OSR_DOS_MASK; in as73211_req_data()
296 smbus_data.byte = data->osr; in as73211_req_data()
309 data->osr &= ~AS73211_OSR_SS; in as73211_req_data()
612 data->osr &= ~AS73211_OSR_DOS_MASK; in as73211_write_raw()
613 data->osr |= AS73211_OSR_DOS_CONFIG; in as73211_write_raw()
728 data->osr &= ~AS73211_OSR_PD; in as73211_power()
730 data->osr |= AS73211_OSR_PD; in as73211_power()
781 data->osr = ret; in as73211_probe()
784 data->osr |= AS73211_OSR_SW_RES; in as73211_probe()
[all …]
/linux-6.15/drivers/iio/adc/
H A Dad4851.c189 unsigned int osr; member
298 unsigned int osr) in ad4851_set_oversampling_ratio() argument
305 if (osr == 1) { in ad4851_set_oversampling_ratio()
311 val = ad4851_osr_to_regval(osr); in ad4851_set_oversampling_ratio()
330 switch (osr) { in ad4851_set_oversampling_ratio()
369 if (st->osr != osr) { in ad4851_set_oversampling_ratio()
374 st->osr = osr; in ad4851_set_oversampling_ratio()
382 unsigned int osr; in ad4851_get_oversampling_ratio() local
396 st->osr = *val; in ad4851_get_oversampling_ratio()
801 *val2 = st->osr; in ad4851_read_raw()
[all …]
H A Dad4695.c1185 unsigned int osr = 1; in ad4695_read_raw() local
1188 osr = cfg->oversampling_ratio; in ad4695_read_raw()
1223 int osr = ad4695_osr_to_regval(val); in ad4695_set_osr_val() local
1225 if (osr < 0) in ad4695_set_osr_val()
1226 return osr; in ad4695_set_osr_val()
1244 switch (osr) { in ad4695_get_calibbias()
1281 unsigned int osr = 1; in __ad4695_write_raw() local
1322 osr); in __ad4695_write_raw()
1395 unsigned int osr = 1; in ad4695_read_avail() local
1413 ret = ad4695_osr_to_regval(osr); in ad4695_read_avail()
[all …]
H A Dmcp3911.c224 unsigned int osr; in mcp3910_get_osr() local
230 osr = FIELD_GET(MCP3910_CONFIG0_OSR, *val); in mcp3910_get_osr()
231 *val = 32 << osr; in mcp3910_get_osr()
237 unsigned int osr = FIELD_PREP(MCP3910_CONFIG0_OSR, val); in mcp3910_set_osr() local
240 return mcp3911_update(adc, MCP3910_REG_CONFIG0, mask, osr, 3); in mcp3910_set_osr()
245 unsigned int osr = FIELD_PREP(MCP3911_CONFIG_OSR, val); in mcp3911_set_osr() local
248 return mcp3911_update(adc, MCP3911_REG_CONFIG, mask, osr, 2); in mcp3911_set_osr()
254 unsigned int osr; in mcp3911_get_osr() local
260 osr = FIELD_GET(MCP3911_CONFIG_OSR, *val); in mcp3911_get_osr()
261 *val = 32 << osr; in mcp3911_get_osr()
H A Dad7380.c1503 int ret, osr, boost; in ad7380_set_oversampling_ratio() local
1505 osr = ad7380_osr_to_regval(val); in ad7380_set_oversampling_ratio()
1506 if (osr < 0) in ad7380_set_oversampling_ratio()
1507 return osr; in ad7380_set_oversampling_ratio()
1510 boost = osr > 0 ? 1 : 0; in ad7380_set_oversampling_ratio()
1515 FIELD_PREP(AD7380_CONFIG1_OSR, osr) | in ad7380_set_oversampling_ratio()
H A Dat91-sama5d2_adc.c859 unsigned int emr, osr; in at91_adc_config_emr() local
874 osr = AT91_SAMA5D2_EMR_OSR(AT91_SAMA5D2_EMR_OSR_1SAMPLES, in at91_adc_config_emr()
878 osr = AT91_SAMA5D2_EMR_OSR(AT91_SAMA5D2_EMR_OSR_4SAMPLES, in at91_adc_config_emr()
882 osr = AT91_SAMA5D2_EMR_OSR(AT91_SAMA5D2_EMR_OSR_16SAMPLES, in at91_adc_config_emr()
886 osr = AT91_SAMA5D2_EMR_OSR(AT91_SAMA5D2_EMR_OSR_64SAMPLES, in at91_adc_config_emr()
890 osr = AT91_SAMA5D2_EMR_OSR(AT91_SAMA5D2_EMR_OSR_256SAMPLES, in at91_adc_config_emr()
905 emr |= osr | AT91_SAMA5D2_TRACKX(trackx); in at91_adc_config_emr()
/linux-6.15/arch/powerpc/sysdev/
H A Dfsl_rmu.c107 u32 osr; member
207 int osr; in fsl_rio_tx_handler() local
211 osr = in_be32(&rmu->msg_regs->osr); in fsl_rio_tx_handler()
213 if (osr & RIO_MSG_OSR_TE) { in fsl_rio_tx_handler()
215 out_be32(&rmu->msg_regs->osr, RIO_MSG_OSR_TE); in fsl_rio_tx_handler()
219 if (osr & RIO_MSG_OSR_QOI) { in fsl_rio_tx_handler()
221 out_be32(&rmu->msg_regs->osr, RIO_MSG_OSR_QOI); in fsl_rio_tx_handler()
225 if (osr & RIO_MSG_OSR_EOMI) { in fsl_rio_tx_handler()
234 out_be32(&rmu->msg_regs->osr, RIO_MSG_OSR_EOMI); in fsl_rio_tx_handler()
773 out_be32(&rmu->msg_regs->osr, 0x000000b3); in fsl_open_outb_mbox()
/linux-6.15/sound/soc/atmel/
H A Dmchp-pdmc.c462 static u32 mchp_pdmc_mr_set_osr(int audio_filter_en, unsigned int osr) in mchp_pdmc_mr_set_osr() argument
465 switch (osr) { in mchp_pdmc_mr_set_osr()
474 switch (osr) { in mchp_pdmc_mr_set_osr()
529 unsigned int osr = 0, osr_start; in mchp_pdmc_hw_params() local
576 osr = osr_start; in mchp_pdmc_hw_params()
577 gclk_rate = fs * 16 * osr; in mchp_pdmc_hw_params()
597 mr_val |= mchp_pdmc_mr_set_osr(dd->audio_filter_en, osr); in mchp_pdmc_hw_params()
/linux-6.15/drivers/input/touchscreen/
H A Delants_i2c.c511 u16 phy_x, phy_y, rows, cols, osr; in elants_i2c_query_ts_info_ekth() local
547 osr = resp[3]; in elants_i2c_query_ts_info_ekth()
571 if (rows == 0 || cols == 0 || osr == 0) { in elants_i2c_query_ts_info_ekth()
574 rows, cols, osr); in elants_i2c_query_ts_info_ekth()
577 ts->x_max = ELAN_TS_RESOLUTION(rows, osr); in elants_i2c_query_ts_info_ekth()
579 ts->y_max = ELAN_TS_RESOLUTION(cols, osr); in elants_i2c_query_ts_info_ekth()
/linux-6.15/drivers/iio/accel/
H A Dbma400_core.c578 unsigned int osr; in bma400_get_accel_oversampling_ratio() local
595 osr = (val & BMA400_LP_OSR_MASK) >> BMA400_LP_OSR_SHIFT; in bma400_get_accel_oversampling_ratio()
597 data->oversampling_ratio = osr; in bma400_get_accel_oversampling_ratio()
606 osr = (val & BMA400_NP_OSR_MASK) >> BMA400_NP_OSR_SHIFT; in bma400_get_accel_oversampling_ratio()
608 data->oversampling_ratio = osr; in bma400_get_accel_oversampling_ratio()
/linux-6.15/sound/soc/fsl/
H A Dfsl_micfil.c786 int osr = MICFIL_OSR_DEFAULT; in fsl_micfil_hw_params() local
836 mclk_rate = rate * clk_div * osr * 8; in fsl_micfil_hw_params()
854 FIELD_PREP(MICFIL_CTRL2_CICOSR, 32 - osr)); in fsl_micfil_hw_params()
859 FIELD_PREP(MICFIL_VAD0_CTRL1_CICOSR, 16 - osr)); in fsl_micfil_hw_params()

12