Re: [PATCH v4 09/13] iio: adc: mt6370: Add Mediatek MT6370 support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jul 4, 2022 at 7:42 AM ChiaEn Wu <peterwu.pub@xxxxxxxxx> wrote:
>
> From: ChiaEn Wu <chiaen_wu@xxxxxxxxxxx>
>
> Add Mediatek MT6370 ADC support.

...

> +         This driver can also be built as a module. If so the module

If so,

> +         will be called "mt6370-adc.ko".

No ".ko" part.

...

> +#define ADC_CONV_TIME_US               35000

Since it's actually MS, drop this and use MS * 1000 whenever it's needed.


> +#define ADC_CONV_TIME_MS               (ADC_CONV_TIME_US / 1000)

...

> +static int mt6370_adc_read_label(struct iio_dev *iio_dev,
> +                                struct iio_chan_spec const *chan, char *label)
> +{
> +       return snprintf(label, PAGE_SIZE, "%s\n",
> +                       mt6370_channel_labels[chan->channel]);

sysfs_emit()

> +}

...

> +static int mt6370_adc_probe(struct platform_device *pdev)
> +{
> +       int ret;
> +       struct mt6370_adc_data *priv;
> +       struct regmap *regmap;
> +       struct iio_dev *indio_dev;

Per all your patches, use reversed xmas tree ordering ("longest line
first" rule).
Also it may be good to have a temporary variable for struct device pointer.

> +}

...

> +MODULE_DESCRIPTION("MT6370 ADC Drvier");

Driver. Spell check your patches.

-- 
With Best Regards,
Andy Shevchenko



[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux