diff options
author | Nicholas Piggin <npiggin@gmail.com> | 2021-11-26 15:21:33 +1000 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2021-12-16 21:31:45 +1100 |
commit | 0a006ace634dcaf1bbf9125fb8089a4a50bf33d6 (patch) | |
tree | 22d613673533b45c8ae7fe4896fc10a3b8cd5c76 /arch/powerpc/platforms | |
parent | 6ed05a8efda56e5be11081954929421de19cce88 (diff) | |
download | linux-0a006ace634dcaf1bbf9125fb8089a4a50bf33d6.tar.bz2 |
powerpc/pseries/vas: Don't print an error when VAS is unavailable
KVM does not support VAS so guests always print a useless error on boot
vas: HCALL(398) error -2, query_type 0, result buffer 0x57f2000
Change this to only print the message if the error is not H_FUNCTION.
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20211126052133.1664375-1-npiggin@gmail.com
Diffstat (limited to 'arch/powerpc/platforms')
-rw-r--r-- | arch/powerpc/platforms/pseries/vas.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/arch/powerpc/platforms/pseries/vas.c b/arch/powerpc/platforms/pseries/vas.c index b043e3936d21..734523e2272f 100644 --- a/arch/powerpc/platforms/pseries/vas.c +++ b/arch/powerpc/platforms/pseries/vas.c @@ -151,8 +151,15 @@ int h_query_vas_capabilities(const u64 hcall, u8 query_type, u64 result) if (rc == H_SUCCESS) return 0; - pr_err("HCALL(%llx) error %ld, query_type %u, result buffer 0x%llx\n", - hcall, rc, query_type, result); + /* H_FUNCTION means HV does not support VAS so don't print an error */ + if (rc != H_FUNCTION) { + pr_err("%s error %ld, query_type %u, result buffer 0x%llx\n", + (hcall == H_QUERY_VAS_CAPABILITIES) ? + "H_QUERY_VAS_CAPABILITIES" : + "H_QUERY_NX_CAPABILITIES", + rc, query_type, result); + } + return -EIO; } EXPORT_SYMBOL_GPL(h_query_vas_capabilities); |