Skip to content

Commit 97a9e14

Browse files
authored
drivers: hv: mshv_vtl: return 0 for MSHV_CAP_LOWER_VTL_TIMER_VIRT if feature unsupported
Returning -EOPNOTSUPP is a fatal error. It means that the driver doesn't know the feature. Not that the feature is not supported due to the runtime platform reason. Return 0 for MSHV_CAP_LOWER_VTL_TIMER_VIRT on non-TDX platform, which is safer. Fixes: 3528fd7: 3528fd7 ("drivers: hv: mshv_vtl: Advertise TDX timer service extension")
2 parents 28e74f6 + 1047cf1 commit 97a9e14

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/hv/mshv_vtl_main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -332,7 +332,7 @@ static long __mshv_vtl_ioctl_check_extension(u32 arg)
332332
case MSHV_CAP_LOWER_VTL_TIMER_VIRT:
333333
if (hv_isolation_type_tdx())
334334
return mshv_tdx_vtl_ioctl_check_extension(arg);
335-
break;
335+
return 0;
336336
}
337337

338338
return -EOPNOTSUPP;

0 commit comments

Comments
 (0)