kvmc: fix invalid reads