diff mbox series

target/arm/kvm64.c: Remove unused include

Message ID 20230925110429.3917202-1-peter.maydell@linaro.org
State Superseded
Headers show
Series target/arm/kvm64.c: Remove unused include | expand

Commit Message

Peter Maydell Sept. 25, 2023, 11:04 a.m. UTC
The include of hw/arm/virt.h in kvm64.c is unnecessary and also a
layering violation since the generic KVM code shouldn't need to know
anything about board-specifics.  The include line is an accidental
leftover from commit 15613357ba53a4763, where we cleaned up the code
to not depend on virt board internals but forgot to also remove the
now-redundant include line.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
 target/arm/kvm64.c | 1 -
 1 file changed, 1 deletion(-)

Comments

Gavin Shan Sept. 27, 2023, 7:19 a.m. UTC | #1
On 9/25/23 21:04, Peter Maydell wrote:
> The include of hw/arm/virt.h in kvm64.c is unnecessary and also a
> layering violation since the generic KVM code shouldn't need to know
> anything about board-specifics.  The include line is an accidental
> leftover from commit 15613357ba53a4763, where we cleaned up the code
> to not depend on virt board internals but forgot to also remove the
> now-redundant include line.
> 
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
> ---
>   target/arm/kvm64.c | 1 -
>   1 file changed, 1 deletion(-)
> 

Reviewed-by: Gavin Shan <gshan@redhat.com>

> diff --git a/target/arm/kvm64.c b/target/arm/kvm64.c
> index 5e95c496bb9..3ea9f1d6743 100644
> --- a/target/arm/kvm64.c
> +++ b/target/arm/kvm64.c
> @@ -30,7 +30,6 @@
>   #include "internals.h"
>   #include "hw/acpi/acpi.h"
>   #include "hw/acpi/ghes.h"
> -#include "hw/arm/virt.h"
>   
>   static bool have_guest_debug;
>
Philippe Mathieu-Daudé Oct. 2, 2023, 6:53 a.m. UTC | #2
On 25/9/23 13:04, Peter Maydell wrote:
> The include of hw/arm/virt.h in kvm64.c is unnecessary and also a
> layering violation since the generic KVM code shouldn't need to know
> anything about board-specifics.  The include line is an accidental
> leftover from commit 15613357ba53a4763, where we cleaned up the code
> to not depend on virt board internals but forgot to also remove the
> now-redundant include line.
> 
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
> ---
>   target/arm/kvm64.c | 1 -
>   1 file changed, 1 deletion(-)

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
diff mbox series

Patch

diff --git a/target/arm/kvm64.c b/target/arm/kvm64.c
index 5e95c496bb9..3ea9f1d6743 100644
--- a/target/arm/kvm64.c
+++ b/target/arm/kvm64.c
@@ -30,7 +30,6 @@ 
 #include "internals.h"
 #include "hw/acpi/acpi.h"
 #include "hw/acpi/ghes.h"
-#include "hw/arm/virt.h"
 
 static bool have_guest_debug;