diff options
| author | Hardik Garg <hargar@linux.microsoft.com> | 2026-07-27 21:11:01 +0000 |
|---|---|---|
| committer | Wei Liu <wei.liu@kernel.org> | 2026-08-24 00:01:30 +0000 |
| commit | e1fc6e70f36e93eede63df85d942011a3f96a764 (patch) | |
| tree | 8e7a650f8ebf93a1c2d9c777f66d57df977e68b5 /include/linux/timerqueue_types.h | |
| parent | 8d3ae59288f1e7d58d76558a6ee96d533bc5019f (diff) | |
Drivers: hv: Use meaningful errnos for hypercall status codes
Commit 3817854ba892 ("hyperv: Log hypercall status codes as strings")
converted hv_result_to_errno() from a switch to a table and added status
codes used for string logging. Statuses without an existing specific
mapping were assigned the generic -EIO fallback even when a more specific
errno was available.
Map HV_STATUS_ACCESS_DENIED and HV_STATUS_OPERATION_DENIED to -EACCES,
HV_STATUS_UNKNOWN_PROPERTY and HV_STATUS_PROPERTY_VALUE_OUT_OF_RANGE to
-EINVAL, and HV_STATUS_PROCESSOR_FEATURE_NOT_SUPPORTED to -EOPNOTSUPP.
This lets callers distinguish permission, argument, and capability
failures from generic I/O errors.
The table conversion also added duplicate HV_STATUS_INVALID_LP_INDEX and
HV_STATUS_INVALID_REGISTER_VALUE entries. Remove the later -EIO entries,
which are unreachable because find_hv_status_info() returns the first
match.
Signed-off-by: Hardik Garg <hargar@linux.microsoft.com>
Reviewed-by: Naman Jain <namjain@linux.microsoft.com>
Signed-off-by: Wei Liu <wei.liu@kernel.org>
Diffstat (limited to 'include/linux/timerqueue_types.h')
0 files changed, 0 insertions, 0 deletions
