Home
last modified time | relevance | path

Searched refs:osr (Results 1 - 25 of 41) sorted by relevance

12

/kernel/linux/linux-5.10/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 in ms5611_i2c_read_adc_temp_and_pressure()
[all...]
H A Dms5611_spi.c57 const struct ms5611_osr *osr = st->temp_osr; in ms5611_spi_read_adc_temp_and_pressure() local
60 * Warning: &osr->cmd MUST be aligned on a word boundary since used as in ms5611_spi_read_adc_temp_and_pressure()
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 in ms5611_spi_read_adc_temp_and_pressure()
[all...]
H A Dms5611_core.c292 const struct ms5611_osr *osr, in ms5611_find_osr()
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()
291 ms5611_find_osr(int rate, const struct ms5611_osr *osr, size_t count) ms5611_find_osr() argument
/kernel/linux/linux-6.6/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 in ms5611_i2c_read_adc_temp_and_pressure()
[all...]
H A Dms5611_spi.c57 const struct ms5611_osr *osr = st->temp_osr; in ms5611_spi_read_adc_temp_and_pressure() local
60 * Warning: &osr->cmd MUST be aligned on a word boundary since used as in ms5611_spi_read_adc_temp_and_pressure()
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 in ms5611_spi_read_adc_temp_and_pressure()
[all...]
H A Dms5611_core.c292 const struct ms5611_osr *osr, in ms5611_find_osr()
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()
291 ms5611_find_osr(int rate, const struct ms5611_osr *osr, size_t count) ms5611_find_osr() argument
/kernel/linux/linux-6.6/sound/soc/codecs/
H A Dnau8540.c363 unsigned int osr; in nau8540_get_osr() local
365 regmap_read(nau8540->regmap, NAU8540_REG_ADC_SAMPLE_RATE, &osr); in nau8540_get_osr()
366 osr &= NAU8540_ADC_OSR_MASK; in nau8540_get_osr()
367 if (osr >= ARRAY_SIZE(osr_adc_sel)) in nau8540_get_osr()
369 return &osr_adc_sel[osr]; in nau8540_get_osr()
377 const struct nau8540_osr_attr *osr; in nau8540_dai_startup() local
379 osr = nau8540_get_osr(nau8540); in nau8540_dai_startup()
380 if (!osr || !osr->osr) in nau8540_dai_startup()
394 const struct nau8540_osr_attr *osr; nau8540_hw_params() local
[all...]
H A Dnau8821.c99 unsigned int osr; member
812 unsigned int osr; in nau8821_get_osr() local
815 regmap_read(nau8821->regmap, NAU8821_R2C_DAC_CTRL1, &osr); in nau8821_get_osr()
816 osr &= NAU8821_DAC_OVERSAMPLE_MASK; in nau8821_get_osr()
817 if (osr >= ARRAY_SIZE(osr_dac_sel)) in nau8821_get_osr()
819 return &osr_dac_sel[osr]; in nau8821_get_osr()
821 regmap_read(nau8821->regmap, NAU8821_R2B_ADC_RATE, &osr); in nau8821_get_osr()
822 osr &= NAU8821_ADC_SYNC_DOWN_MASK; in nau8821_get_osr()
823 if (osr >= ARRAY_SIZE(osr_adc_sel)) in nau8821_get_osr()
825 return &osr_adc_sel[osr]; in nau8821_get_osr()
834 const struct nau8821_osr_attr *osr; nau8821_dai_startup() local
851 const struct nau8821_osr_attr *osr; nau8821_hw_params() local
[all...]
H A Dnau8824.c1026 unsigned int osr; in nau8824_get_osr() local
1030 NAU8824_REG_DAC_FILTER_CTRL_1, &osr); in nau8824_get_osr()
1031 osr &= NAU8824_DAC_OVERSAMPLE_MASK; in nau8824_get_osr()
1032 if (osr >= ARRAY_SIZE(osr_dac_sel)) in nau8824_get_osr()
1034 return &osr_dac_sel[osr]; in nau8824_get_osr()
1037 NAU8824_REG_ADC_FILTER_CTRL, &osr); in nau8824_get_osr()
1038 osr &= NAU8824_ADC_SYNC_DOWN_MASK; in nau8824_get_osr()
1039 if (osr >= ARRAY_SIZE(osr_adc_sel)) in nau8824_get_osr()
1041 return &osr_adc_sel[osr]; in nau8824_get_osr()
1050 const struct nau8824_osr_attr *osr; in nau8824_dai_startup() local
1067 const struct nau8824_osr_attr *osr; nau8824_hw_params() local
[all...]
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()
1244 osr &= NAU8825_DAC_OVERSAMPLE_MASK; in nau8825_get_osr()
1245 if (osr >= ARRAY_SIZE(osr_dac_sel)) 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()
1252 if (osr >= ARRAY_SIZE(osr_adc_sel)) in nau8825_get_osr()
1254 return &osr_adc_sel[osr]; in nau8825_get_osr()
1263 const struct nau8825_osr_attr *osr; nau8825_dai_startup() local
1281 const struct nau8825_osr_attr *osr; nau8825_hw_params() local
[all...]
/kernel/linux/linux-5.10/drivers/iio/light/
H A Das73211.c91 * @osr: Cached Operational State Register.
101 u8 osr; member
243 data->osr &= ~AS73211_OSR_DOS_MASK; in as73211_req_data()
244 data->osr |= AS73211_OSR_DOS_MEASURE | AS73211_OSR_SS; in as73211_req_data()
246 smbus_data.byte = data->osr; in as73211_req_data()
259 data->osr &= ~AS73211_OSR_SS; in as73211_req_data()
536 if ((data->osr & AS73211_OSR_DOS_MASK) != AS73211_OSR_DOS_CONFIG) { in as73211_write_raw()
537 data->osr &= ~AS73211_OSR_DOS_MASK; in as73211_write_raw()
538 data->osr |= AS73211_OSR_DOS_CONFIG; in as73211_write_raw()
540 ret = i2c_smbus_write_byte_data(data->client, AS73211_REG_OSR, data->osr); in as73211_write_raw()
[all...]
/kernel/linux/linux-6.6/drivers/iio/light/
H A Das73211.c90 * @osr: Cached Operational State Register.
100 u8 osr; member
242 data->osr &= ~AS73211_OSR_DOS_MASK; in as73211_req_data()
243 data->osr |= AS73211_OSR_DOS_MEASURE | AS73211_OSR_SS; in as73211_req_data()
245 smbus_data.byte = data->osr; in as73211_req_data()
258 data->osr &= ~AS73211_OSR_SS; in as73211_req_data()
535 if ((data->osr & AS73211_OSR_DOS_MASK) != AS73211_OSR_DOS_CONFIG) { in as73211_write_raw()
536 data->osr &= ~AS73211_OSR_DOS_MASK; in as73211_write_raw()
537 data->osr |= AS73211_OSR_DOS_CONFIG; in as73211_write_raw()
539 ret = i2c_smbus_write_byte_data(data->client, AS73211_REG_OSR, data->osr); in as73211_write_raw()
[all...]
/kernel/linux/linux-5.10/crypto/
H A Djitterentropy.c74 unsigned int osr; /* Oversample rate */ member
217 if ((unsigned int)ec->rct_count >= (31 * ec->osr)) { in jent_rct_insert()
560 * We multiply the loop value with ->osr to obtain the in jent_gen_entropy()
563 if (++k >= (DATA_SIZE_BITS * ec->osr)) in jent_gen_entropy()
656 struct rand_data *jent_entropy_collector_alloc(unsigned int osr, in jent_entropy_collector_alloc() argument
680 if (0 == osr) in jent_entropy_collector_alloc()
681 osr = 1; /* minimum sampling rate is 1 */ in jent_entropy_collector_alloc()
682 entropy_collector->osr = osr; in jent_entropy_collector_alloc()
709 ec.osr in jent_entropy_init()
[all...]
/kernel/linux/linux-6.6/crypto/
H A Djitterentropy.c75 unsigned int osr; /* Oversample rate */ member
500 * We multiply the loop value with ->osr to obtain the in jent_gen_entropy()
503 if (++k >= ((DATA_SIZE_BITS + safety_factor) * ec->osr)) in jent_gen_entropy()
581 struct rand_data *jent_entropy_collector_alloc(unsigned int osr, in jent_entropy_collector_alloc() argument
606 if (osr == 0) in jent_entropy_collector_alloc()
607 osr = 1; /* minimum sampling rate is 1 */ in jent_entropy_collector_alloc()
608 entropy_collector->osr = osr; in jent_entropy_collector_alloc()
637 ec.osr = 1; in jent_entropy_init()
H A Djitterentropy.h16 extern struct rand_data *jent_entropy_collector_alloc(unsigned int osr,
/kernel/linux/linux-5.10/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_EOM in fsl_rio_tx_handler()
[all...]
/kernel/linux/linux-6.6/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_EOM in fsl_rio_tx_handler()
[all...]
/kernel/linux/linux-5.10/sound/soc/codecs/
H A Dnau8540.c360 static int nau8540_clock_check(struct nau8540 *nau8540, int rate, int osr) in nau8540_clock_check() argument
362 if (osr >= ARRAY_SIZE(osr_adc_sel)) in nau8540_clock_check()
365 if (rate * osr > CLK_ADC_MAX) { in nau8540_clock_check()
378 unsigned int val_len = 0, osr; in nau8540_hw_params() local
386 regmap_read(nau8540->regmap, NAU8540_REG_ADC_SAMPLE_RATE, &osr); in nau8540_hw_params()
387 osr &= NAU8540_ADC_OSR_MASK; in nau8540_hw_params()
388 if (nau8540_clock_check(nau8540, params_rate(params), osr)) in nau8540_hw_params()
392 osr_adc_sel[osr].clk_src << NAU8540_CLK_ADC_SRC_SFT); in nau8540_hw_params()
H A Dnau8825.c101 unsigned int osr; member
1219 int stream, int rate, int osr) in nau8825_clock_check()
1224 if (osr >= ARRAY_SIZE(osr_dac_sel)) in nau8825_clock_check()
1226 osrate = osr_dac_sel[osr].osr; in nau8825_clock_check()
1228 if (osr >= ARRAY_SIZE(osr_adc_sel)) in nau8825_clock_check()
1230 osrate = osr_adc_sel[osr].osr; in nau8825_clock_check()
1233 if (!osrate || rate * osr > CLK_DA_AD_MAX) { in nau8825_clock_check()
1247 unsigned int val_len = 0, osr, ctrl_va in nau8825_hw_params() local
1218 nau8825_clock_check(struct nau8825 *nau8825, int stream, int rate, int osr) nau8825_clock_check() argument
[all...]
H A Dnau8824.c1047 int stream, int rate, int osr) in nau8824_clock_check()
1052 if (osr >= ARRAY_SIZE(osr_dac_sel)) in nau8824_clock_check()
1054 osrate = osr_dac_sel[osr].osr; in nau8824_clock_check()
1056 if (osr >= ARRAY_SIZE(osr_adc_sel)) in nau8824_clock_check()
1058 osrate = osr_adc_sel[osr].osr; in nau8824_clock_check()
1061 if (!osrate || rate * osr > CLK_DA_AD_MAX) { in nau8824_clock_check()
1074 unsigned int val_len = 0, osr, ctrl_val, bclk_fs, bclk_div; in nau8824_hw_params() local
1088 NAU8824_REG_DAC_FILTER_CTRL_1, &osr); in nau8824_hw_params()
1046 nau8824_clock_check(struct nau8824 *nau8824, int stream, int rate, int osr) nau8824_clock_check() argument
[all...]
/kernel/linux/linux-5.10/sound/soc/fsl/
H A Dfsl_micfil.c114 int qsel, osr; in get_pdm_clk() local
118 osr = 16 - ((ctrl2_reg & MICFIL_CTRL2_CICOSR_MASK) in get_pdm_clk()
126 bclk = rate * 8 * osr / 2; /* kfactor = 0.5 */ in get_pdm_clk()
130 bclk = rate * 4 * osr * 1; /* kfactor = 1 */ in get_pdm_clk()
134 bclk = rate * 2 * osr * 2; /* kfactor = 2 */ in get_pdm_clk()
137 bclk = rate * osr * 4; /* kfactor = 4 */ in get_pdm_clk()
/kernel/linux/linux-5.10/drivers/iio/accel/
H A Dbma400_core.c327 /* preserve the range and normal mode osr */ in bma400_set_accel_output_data_rate()
342 unsigned int osr; in bma400_get_accel_oversampling_ratio() local
359 osr = (val & BMA400_LP_OSR_MASK) >> BMA400_LP_OSR_SHIFT; in bma400_get_accel_oversampling_ratio()
361 data->oversampling_ratio = osr; in bma400_get_accel_oversampling_ratio()
370 osr = (val & BMA400_NP_OSR_MASK) >> BMA400_NP_OSR_SHIFT; in bma400_get_accel_oversampling_ratio()
372 data->oversampling_ratio = osr; in bma400_get_accel_oversampling_ratio()
537 * Update our cached osr and odr based on the new in bma400_set_power_mode()
/kernel/linux/linux-6.6/sound/soc/atmel/
H A Dmchp-pdmc.c484 static u32 mchp_pdmc_mr_set_osr(int audio_filter_en, unsigned int osr) in mchp_pdmc_mr_set_osr() argument
487 switch (osr) { in mchp_pdmc_mr_set_osr()
496 switch (osr) { in mchp_pdmc_mr_set_osr()
548 unsigned int osr = 0, osr_start; in mchp_pdmc_hw_params() local
586 osr = osr_start; in mchp_pdmc_hw_params()
587 gclk_rate = fs * 16 * osr; in mchp_pdmc_hw_params()
607 mr_val |= mchp_pdmc_mr_set_osr(dd->audio_filter_en, osr); in mchp_pdmc_hw_params()
/kernel/linux/linux-5.10/drivers/input/touchscreen/
H A Delants_i2c.c451 u16 phy_x, phy_y, rows, cols, osr; in elants_i2c_query_ts_info() local
483 resp, sizeof(resp), 1, "get osr"); in elants_i2c_query_ts_info()
487 osr = resp[3]; in elants_i2c_query_ts_info()
511 if (rows == 0 || cols == 0 || osr == 0) { in elants_i2c_query_ts_info()
514 rows, cols, osr); in elants_i2c_query_ts_info()
517 ts->x_max = ELAN_TS_RESOLUTION(rows, osr); in elants_i2c_query_ts_info()
519 ts->y_max = ELAN_TS_RESOLUTION(cols, osr); in elants_i2c_query_ts_info()
/kernel/linux/linux-6.6/drivers/input/touchscreen/
H A Delants_i2c.c511 u16 phy_x, phy_y, rows, cols, osr; in elants_i2c_query_ts_info_ekth() local
543 resp, sizeof(resp), 1, "get osr"); in elants_i2c_query_ts_info_ekth()
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()

Completed in 26 milliseconds

12