Skip to content

Commit

Permalink
iio: adc: twl4030-madc: Re-use generic struct s16_fract
Browse files Browse the repository at this point in the history
Instead of custom data type re-use generic struct s16_fract.
No changes intended.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20220126135353.24007-3-andriy.shevchenko@linux.intel.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
  • Loading branch information
Andy Shevchenko authored and Jonathan Cameron committed Jan 30, 2022
1 parent 84cd574 commit 8f2abd4
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions drivers/iio/adc/twl4030-madc.c
Original file line number Diff line number Diff line change
Expand Up @@ -231,13 +231,7 @@ static const struct iio_chan_spec twl4030_madc_iio_channels[] = {

static struct twl4030_madc_data *twl4030_madc;

struct twl4030_prescale_divider_ratios {
s16 numerator;
s16 denominator;
};

static const struct twl4030_prescale_divider_ratios
twl4030_divider_ratios[16] = {
static const struct s16_fract twl4030_divider_ratios[16] = {
{1, 1}, /* CHANNEL 0 No Prescaler */
{1, 1}, /* CHANNEL 1 No Prescaler */
{6, 10}, /* CHANNEL 2 */
Expand All @@ -256,7 +250,6 @@ twl4030_divider_ratios[16] = {
{5, 11}, /* CHANNEL 15 */
};


/* Conversion table from -3 to 55 degrees Celcius */
static int twl4030_therm_tbl[] = {
30800, 29500, 28300, 27100,
Expand Down

0 comments on commit 8f2abd4

Please sign in to comment.