Re: [PATCH v4 15/27] KVM: S390: Prepare gmap for a second KVM implementation
From: Steffen Eiden
Date: Fri Jul 10 2026 - 08:33:48 EST
On Fri, Jul 10, 2026 at 11:29:39AM +0200, Christian Borntraeger wrote:
>
>
> Am 06.07.26 um 10:52 schrieb Steffen Eiden:
> [...]
>
> > --- a/arch/s390/include/asm/kvm_host.h
> > +++ b/arch/s390/include/asm/kvm_host.h
> > @@ -5,4 +5,13 @@
> > #include <asm/kvm_host_s390.h>
> > +#define PGM_PROTECTION 0x04
> > +#define PGM_ADDRESSING 0x05
> > +#define PGM_SEGMENT_TRANSLATION 0x10
> > +#define PGM_PAGE_TRANSLATION 0x11
> > +#define PGM_ASCE_TYPE 0x38
> > +#define PGM_REGION_FIRST_TRANS 0x39
> > +#define PGM_REGION_SECOND_TRANS 0x3a
> > +#define PGM_REGION_THIRD_TRANS 0x3b
> > +
> > #endif /* ASM_KVM_HOST_H */
> > diff --git a/arch/s390/include/asm/kvm_host_s390.h b/arch/s390/include/asm/kvm_host_s390.h
> > index 5293b0067422..7b7aa166cff7 100644
> > --- a/arch/s390/include/asm/kvm_host_s390.h
> > +++ b/arch/s390/include/asm/kvm_host_s390.h
> > @@ -153,8 +153,7 @@ struct kvm_vcpu_stat {
> > #define PGM_OPERATION 0x01
> > #define PGM_PRIVILEGED_OP 0x02
> > #define PGM_EXECUTE 0x03
> > -#define PGM_PROTECTION 0x04
> > -#define PGM_ADDRESSING 0x05
> > +/* 0x04 & 0x05 defined in kvm_host.h */
>
> I think I would move ALL PGM defines into kvm_host.h. Those are certainly valid from a host
> point of view, even for the arm64 kvm module. Yes, its unused but it will be much cleaner
> than having everything in one place and doing these cross-reference comments.
>
> [...]
Malkes sense. I'll move all.
Steffen