Hi Andre, On 17/03/2017 15:38, Andre Przywara wrote: > Hi Eric, > > On 06/03/17 11:34, Eric Auger wrote: >> We plan to use vgic_find_mmio_region in vgic-its.c so let's >> turn it into a public function. > > Just a nit below, but for the patch: > >> Signed-off-by: Eric Auger <eric.auger@xxxxxxxxxx> > > Reviewed-by: Andre Przywara <andre.przywara@xxxxxxx> First thank you for the whole series review. > >> --- >> virt/kvm/arm/vgic/vgic-mmio.c | 3 +-- >> virt/kvm/arm/vgic/vgic-mmio.h | 5 +++++ >> 2 files changed, 6 insertions(+), 2 deletions(-) >> >> diff --git a/virt/kvm/arm/vgic/vgic-mmio.c b/virt/kvm/arm/vgic/vgic-mmio.c >> index 3654b4c..0427ddb 100644 >> --- a/virt/kvm/arm/vgic/vgic-mmio.c >> +++ b/virt/kvm/arm/vgic/vgic-mmio.c >> @@ -430,8 +430,7 @@ static int match_region(const void *key, const void *elt) >> return 0; >> } >> >> -/* Find the proper register handler entry given a certain address offset. */ >> -static const struct vgic_register_region * >> +const struct vgic_register_region * >> vgic_find_mmio_region(const struct vgic_register_region *region, int nr_regions, >> unsigned int offset) >> { >> diff --git a/virt/kvm/arm/vgic/vgic-mmio.h b/virt/kvm/arm/vgic/vgic-mmio.h >> index 98bb566..055ad42 100644 >> --- a/virt/kvm/arm/vgic/vgic-mmio.h >> +++ b/virt/kvm/arm/vgic/vgic-mmio.h >> @@ -192,4 +192,9 @@ u64 vgic_sanitise_shareability(u64 reg); >> u64 vgic_sanitise_field(u64 reg, u64 field_mask, int field_shift, >> u64 (*sanitise_fn)(u64)); >> >> +/* Find the proper register handler entry given a certain address offset */ >> +const struct vgic_register_region * >> +vgic_find_mmio_region(const struct vgic_register_region *region, > > I wonder if we should use the opportunity to use the plural in the > variable name here ("regions") to make it clear that this is an array > (just needed some time myself here to remember what it does). done, I renamed the region parameter into regions Thanks Eric > > Cheers, > Andre. > >> + int nr_regions, unsigned int offset); >> + >> #endif >>