RE: [PATCH v6 1/2] scsi: ufs: Probe for temperature notification support

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

 



> > +static int ufs_hwmon_read(struct device *dev, enum
> hwmon_sensor_types type, u32 attr, int channel,
> > +                       long *val)
> > +{
> > +     struct ufs_hwmon_data *data = dev_get_drvdata(dev);
> > +     struct ufs_hba *hba = data->hba;
> > +     int err;
> > +
> > +     if (type != hwmon_temp)
> > +             return 0;
> > +
> 
> Was that there before ? Dorry, I didn't notice.
> First of all, strictly speaking it is unnecessary, but if it is there
> it should return an error. Plus, checking the type here but not in
> the write function is a bit inconsistent.
Will remove.  Done.

> > +static int ufs_hwmon_write(struct device *dev, enum
> hwmon_sensor_types type, u32 attr, int channel,
> > +                        long val)
> > +{
> > +     struct ufs_hwmon_data *data = dev_get_drvdata(dev);
> > +     struct ufs_hba *hba = data->hba;
> > +     int err = 0;
> 
> Still unnecessary.
Done.





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux