Message ID | 20220509120330.3043773-3-tabba@google.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | KVM: arm64: Do not communicate host pmu event changes by accessing hyp data | expand |
On Mon, May 09, 2022 at 12:03:28PM +0000, Fuad Tabba wrote: > struct kvm_pmu has 2 holes using 10 bytes. This is instantiated > in all vcpus, so it adds up. This repacking removes all holes. nit: commit messages should be written in the imperative. So maybe 'Repack the structure to remove all holes'. > No functional change intended. > > Signed-off-by: Fuad Tabba <tabba@google.com> Otherwise: Reviewed-by: Oliver Upton <oupton@google.com> > --- > include/kvm/arm_pmu.h | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/include/kvm/arm_pmu.h b/include/kvm/arm_pmu.h > index 20193416d214..eaa8290b116f 100644 > --- a/include/kvm/arm_pmu.h > +++ b/include/kvm/arm_pmu.h > @@ -21,12 +21,12 @@ struct kvm_pmc { > }; > > struct kvm_pmu { > - int irq_num; > + struct irq_work overflow_work; > struct kvm_pmc pmc[ARMV8_PMU_MAX_COUNTERS]; > DECLARE_BITMAP(chained, ARMV8_PMU_MAX_COUNTER_PAIRS); > + int irq_num; > bool created; > bool irq_level; > - struct irq_work overflow_work; > }; > > struct arm_pmu_entry { > -- > 2.36.0.512.ge40c2bad7a-goog > > _______________________________________________ > kvmarm mailing list > kvmarm@lists.cs.columbia.edu > https://lists.cs.columbia.edu/mailman/listinfo/kvmarm
Hi Oliver, Thanks for your reviews. On Mon, May 9, 2022 at 8:57 PM Oliver Upton <oupton@google.com> wrote: > > On Mon, May 09, 2022 at 12:03:28PM +0000, Fuad Tabba wrote: > > struct kvm_pmu has 2 holes using 10 bytes. This is instantiated > > in all vcpus, so it adds up. This repacking removes all holes. > > nit: commit messages should be written in the imperative. So maybe > 'Repack the structure to remove all holes'. Will fix that when I respin this. Cheers, /fuad > > > No functional change intended. > > > > Signed-off-by: Fuad Tabba <tabba@google.com> > > Otherwise: > > Reviewed-by: Oliver Upton <oupton@google.com> > > > --- > > include/kvm/arm_pmu.h | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/include/kvm/arm_pmu.h b/include/kvm/arm_pmu.h > > index 20193416d214..eaa8290b116f 100644 > > --- a/include/kvm/arm_pmu.h > > +++ b/include/kvm/arm_pmu.h > > @@ -21,12 +21,12 @@ struct kvm_pmc { > > }; > > > > struct kvm_pmu { > > - int irq_num; > > + struct irq_work overflow_work; > > struct kvm_pmc pmc[ARMV8_PMU_MAX_COUNTERS]; > > DECLARE_BITMAP(chained, ARMV8_PMU_MAX_COUNTER_PAIRS); > > + int irq_num; > > bool created; > > bool irq_level; > > - struct irq_work overflow_work; > > }; > > > > struct arm_pmu_entry { > > -- > > 2.36.0.512.ge40c2bad7a-goog > > > > _______________________________________________ > > kvmarm mailing list > > kvmarm@lists.cs.columbia.edu > > https://lists.cs.columbia.edu/mailman/listinfo/kvmarm
diff --git a/include/kvm/arm_pmu.h b/include/kvm/arm_pmu.h index 20193416d214..eaa8290b116f 100644 --- a/include/kvm/arm_pmu.h +++ b/include/kvm/arm_pmu.h @@ -21,12 +21,12 @@ struct kvm_pmc { }; struct kvm_pmu { - int irq_num; + struct irq_work overflow_work; struct kvm_pmc pmc[ARMV8_PMU_MAX_COUNTERS]; DECLARE_BITMAP(chained, ARMV8_PMU_MAX_COUNTER_PAIRS); + int irq_num; bool created; bool irq_level; - struct irq_work overflow_work; }; struct arm_pmu_entry {
struct kvm_pmu has 2 holes using 10 bytes. This is instantiated in all vcpus, so it adds up. This repacking removes all holes. No functional change intended. Signed-off-by: Fuad Tabba <tabba@google.com> --- include/kvm/arm_pmu.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)