vmm: fix "set but not used" warnings
(cherry picked from commit 39d87a023567f633c6990ac7fcc3a20691a1efd6)