[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen master] xen/arm: vgic-v2: Drop cbase from arch_domain
commit 810a50db69703f715d199d6b3a5f08193155d48b Author: Julien Grall <julien.grall@xxxxxxxxxx> AuthorDate: Tue Sep 29 17:21:38 2015 +0100 Commit: Ian Campbell <ian.campbell@xxxxxxxxxx> CommitDate: Thu Oct 1 13:51:58 2015 +0100 xen/arm: vgic-v2: Drop cbase from arch_domain The field value is only used within a single function in the vgic-v2 emulation. So it's not necessary to store the value in the domain structure. This is also saving 8 bytes on a structure which begin to be constrained (the maximum size of struct domain is 4KB). Signed-off-by: Julien Grall <julien.grall@xxxxxxxxxx> Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx> --- xen/arch/arm/vgic-v2.c | 11 ++++++----- xen/include/asm-arm/domain.h | 1 - 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/xen/arch/arm/vgic-v2.c b/xen/arch/arm/vgic-v2.c index f886724..309d579 100644 --- a/xen/arch/arm/vgic-v2.c +++ b/xen/arch/arm/vgic-v2.c @@ -548,6 +548,7 @@ static int vgic_v2_vcpu_init(struct vcpu *v) static int vgic_v2_domain_init(struct domain *d) { int i, ret; + paddr_t cbase; /* * The hardware domain gets the hardware address. @@ -556,12 +557,12 @@ static int vgic_v2_domain_init(struct domain *d) if ( is_hardware_domain(d) ) { d->arch.vgic.dbase = vgic_v2_hw.dbase; - d->arch.vgic.cbase = vgic_v2_hw.cbase; + cbase = vgic_v2_hw.cbase; } else { d->arch.vgic.dbase = GUEST_GICD_BASE; - d->arch.vgic.cbase = GUEST_GICC_BASE; + cbase = GUEST_GICC_BASE; } /* @@ -571,16 +572,16 @@ static int vgic_v2_domain_init(struct domain *d) * The second page is always mapped at +4K irrespective of the * GIC_64K_STRIDE quirk. The DTB passed to the guest reflects this. */ - ret = map_mmio_regions(d, paddr_to_pfn(d->arch.vgic.cbase), 1, + ret = map_mmio_regions(d, paddr_to_pfn(cbase), 1, paddr_to_pfn(vgic_v2_hw.vbase)); if ( ret ) return ret; if ( !platform_has_quirk(PLATFORM_QUIRK_GIC_64K_STRIDE) ) - ret = map_mmio_regions(d, paddr_to_pfn(d->arch.vgic.cbase + PAGE_SIZE), + ret = map_mmio_regions(d, paddr_to_pfn(cbase + PAGE_SIZE), 1, paddr_to_pfn(vgic_v2_hw.vbase + PAGE_SIZE)); else - ret = map_mmio_regions(d, paddr_to_pfn(d->arch.vgic.cbase + PAGE_SIZE), + ret = map_mmio_regions(d, paddr_to_pfn(cbase + PAGE_SIZE), 1, paddr_to_pfn(vgic_v2_hw.vbase + SZ_64K)); if ( ret ) diff --git a/xen/include/asm-arm/domain.h b/xen/include/asm-arm/domain.h index 01859cc..b89727e 100644 --- a/xen/include/asm-arm/domain.h +++ b/xen/include/asm-arm/domain.h @@ -102,7 +102,6 @@ struct arch_domain struct pending_irq *pending_irqs; /* Base address for guest GIC */ paddr_t dbase; /* Distributor base address */ - paddr_t cbase; /* CPU base address */ #ifdef HAS_GICV3 /* GIC V3 addressing */ /* List of contiguous occupied by the redistributors */ -- generated by git-patchbot for /home/xen/git/xen.git#master _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |