[PATCH 5.4 21/36] nvmem: check for NULL reg_read and reg_write before dereferencing