diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c index 699aa8372ac0..d96a2013deac 100644 --- a/drivers/devfreq/devfreq.c +++ b/drivers/devfreq/devfreq.c @@ -1255,7 +1255,7 @@ static ssize_t min_freq_show(struct device *dev, struct device_attribute *attr, return sprintf(buf, "%lu\n", MAX(df->scaling_min_freq, df->min_freq)); } -static ssize_t max_freq_store(struct device *dev, struct device_attribute *attr, +static ssize_t __maybe_unused max_freq_store(struct device *dev, struct device_attribute *attr, const char *buf, size_t count) { struct devfreq *df = to_devfreq(dev); @@ -1301,7 +1301,7 @@ static ssize_t max_freq_show(struct device *dev, struct device_attribute *attr, return sprintf(buf, "%lu\n", MIN(df->scaling_max_freq, df->max_freq)); } -static DEVICE_ATTR_RW(max_freq); +static DEVICE_ATTR_RO(max_freq); static ssize_t available_frequencies_show(struct device *d, struct device_attribute *attr,