[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [xen master] xen/x86: Remove the use of K&R functions
commit 22b2fa4766728c3057757c00e79da5f7803fff33 Author: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> AuthorDate: Thu Feb 16 22:14:12 2023 +0000 Commit: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> CommitDate: Fri Feb 17 11:01:54 2023 +0000 xen/x86: Remove the use of K&R functions Clang-15 (as seen in the FreeBSD 14 tests) complains: arch/x86/time.c:1364:20: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] s_time_t get_s_time() ^ void The error message is a bit confusing but appears to new as part of -Wdeprecated-non-prototype which is part of supporting C2x which formally removes K&R syntax. Either way, fix the identified functions. Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx> --- xen/arch/x86/hvm/vmx/vmcs.c | 2 +- xen/arch/x86/time.c | 2 +- xen/drivers/passthrough/iommu.c | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/xen/arch/x86/hvm/vmx/vmcs.c b/xen/arch/x86/hvm/vmx/vmcs.c index 09edbd23b3..e1c268789e 100644 --- a/xen/arch/x86/hvm/vmx/vmcs.c +++ b/xen/arch/x86/hvm/vmx/vmcs.c @@ -781,7 +781,7 @@ static int _vmx_cpu_up(bool bsp) return 0; } -int cf_check vmx_cpu_up() +int cf_check vmx_cpu_up(void) { return _vmx_cpu_up(false); } diff --git a/xen/arch/x86/time.c b/xen/arch/x86/time.c index 782b11c8a9..4e44a43cc5 100644 --- a/xen/arch/x86/time.c +++ b/xen/arch/x86/time.c @@ -1361,7 +1361,7 @@ s_time_t get_s_time_fixed(u64 at_tsc) return t->stamp.local_stime + scale_delta(delta, &t->tsc_scale); } -s_time_t get_s_time() +s_time_t get_s_time(void) { return get_s_time_fixed(0); } diff --git a/xen/drivers/passthrough/iommu.c b/xen/drivers/passthrough/iommu.c index 921b71e819..0e187f6ae3 100644 --- a/xen/drivers/passthrough/iommu.c +++ b/xen/drivers/passthrough/iommu.c @@ -606,7 +606,7 @@ int __init iommu_setup(void) return rc; } -int iommu_suspend() +int iommu_suspend(void) { if ( iommu_enabled ) return iommu_call(iommu_get_ops(), suspend); @@ -614,7 +614,7 @@ int iommu_suspend() return 0; } -void iommu_resume() +void iommu_resume(void) { if ( iommu_enabled ) iommu_vcall(iommu_get_ops(), resume); -- generated by git-patchbot for /home/xen/git/xen.git#master
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |