summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorOleg Drokin <green@linuxhacker.ru>2016-08-25 13:50:59 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-09-01 17:29:22 +0200
commit44fae22b36e218ed30d3f4debba9b0c1d3d6fdf1 (patch)
treeeeff5ec0401228440542d80e00c5ae7769c7702c /drivers
parentd6e7a2fe932643bc44f7463881969b14e8f4db38 (diff)
staging/lustre: Fix max_dirty_mb output in sysfs
%ul definitely was supposed to be %lu in the format string, so we print long unsigned int value, not just unsigned int with a letter l added at the end. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/staging/lustre/lustre/obdclass/linux/linux-sysctl.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/staging/lustre/lustre/obdclass/linux/linux-sysctl.c b/drivers/staging/lustre/lustre/obdclass/linux/linux-sysctl.c
index 8f70dd2686f9..bcf005dee36e 100644
--- a/drivers/staging/lustre/lustre/obdclass/linux/linux-sysctl.c
+++ b/drivers/staging/lustre/lustre/obdclass/linux/linux-sysctl.c
@@ -95,8 +95,9 @@ LUSTRE_STATIC_UINT_ATTR(timeout, &obd_timeout);
static ssize_t max_dirty_mb_show(struct kobject *kobj, struct attribute *attr,
char *buf)
{
- return sprintf(buf, "%ul\n",
- obd_max_dirty_pages / (1 << (20 - PAGE_SHIFT)));
+ return sprintf(buf, "%lu\n",
+ (unsigned long)obd_max_dirty_pages /
+ (1 << (20 - PAGE_SHIFT)));
}
static ssize_t max_dirty_mb_store(struct kobject *kobj, struct attribute *attr,