Whamcloud - gitweb
LU-7218 osc: fix max_dirty_mb tunable setting limit 52/16652/2
authorGregoire Pichon <gregoire.pichon@bull.net>
Mon, 28 Sep 2015 11:30:29 +0000 (13:30 +0200)
committerOleg Drokin <oleg.drokin@intel.com>
Fri, 2 Oct 2015 04:15:07 +0000 (04:15 +0000)
The OSC tunable max_dirty_mb must be set to a value strictly lower
than 2048, as it is assumed by OSS in ofd_grant_alloc() routine.

Signed-off-by: Gregoire Pichon <gregoire.pichon@bull.net>
Change-Id: I66a0927c69749cdbb9cd48459af67a57c3e25af0
Reviewed-on: http://review.whamcloud.com/16652
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bobi Jam <bobijam@hotmail.com>
lustre/osc/lproc_osc.c

index dc372fd..5fe64aa 100644 (file)
@@ -161,7 +161,7 @@ static ssize_t osc_max_dirty_mb_seq_write(struct file *file,
                return rc;
 
        if (pages_number <= 0 ||
-           pages_number > OSC_MAX_DIRTY_MB_MAX << (20 - PAGE_CACHE_SHIFT) ||
+           pages_number >= OSC_MAX_DIRTY_MB_MAX << (20 - PAGE_CACHE_SHIFT) ||
            pages_number > totalram_pages / 4) /* 1/4 of RAM */
                return -ERANGE;