ufs: remove write-only variables
(cherry picked from commit 2030ee0e1b17e45a162bba6a636e07886a9eb67c)