So Andreas suggest a few ideas.
I'd prefer it even more if the "NONROT" state was added to the obd_statfs_state_names[] array, and was printed with the "MNTDF_VERBOSE" flag is passed, and masked up in mntdf() otherwise. That avoids special-casing the code here, and pushes the "presentation decision" up toward where options are handled.
As for what letter to use for "NONROT", one option would be to use a lower-case letter to indicate that it is not a "problem" with the target, like 'f' for "flash" or "fast", but I'm open to other options. I'd prefer to avoid overloading 'n' so early.
We might even consider changing the OS_STATE_NONROT flag to count from 0x80000000 downward to make it possible to programatically separate error states from informational states, even though this would slow down showdf() by a few cycles for flash OSTs. The original NONROT patch was landed as v2_12_53-108-g68635c3, so it isn't in a 2.13 release yet, and the backport hasn't been landed to b2_12 yet, so I don't think there isn't a release that includes this flag yet.
I'm going to do the simplest fix but if someone wants something more we can do another patch to enhance this feature.
Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/35662/
Subject:
LU-12501utils: fix 'lfs df' printing loopProject: fs/lustre-release
Branch: b2_12
Current Patch Set:
Commit: 2734b902c296f3f6cbc1522a579f23bd86d1be45