dm: cmos: fix a logic error for read to clear range
Signed-off-by: Binbin Wu <binbin.wu@intel.com> Acked-by: Anthony Xu <anthony.xu@intel.com>
This commit is contained in:
parent
3e598ebb28
commit
0c630d9003
|
@ -92,7 +92,7 @@ cmos_io_handler(struct vmctx *ctx, int vcpu, int in, int port, int bytes,
|
|||
if (in) {
|
||||
*eax = ctx->cmos_buffer[buf_offset];
|
||||
/* read to clear for Key range */
|
||||
if ((buf_offset >= CMOS_VRPMB_START) ||
|
||||
if ((buf_offset >= CMOS_VRPMB_START) &&
|
||||
(buf_offset <= CMOS_VRPMB_END))
|
||||
ctx->cmos_buffer[buf_offset] = 0;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue