[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [RFC 05/22] xen/arm: gic-v3: Rework the print message at initialization



On Fri, 2015-05-08 at 14:29 +0100, Julien Grall wrote:

Subject: "messages printed"

>     - Print all the redistributor regions rather than only the first
>     one...
>     - Add # in the format to print 0x for hexadecimal. It's easier to
>     differentiation from decimal

FWIW # doesn't work if the value is 0 (it still comes out as 0, not
0x0). Some people prefer 0x%FOO for that reason (mainly if you are
trying to line things up).

You may not care here.

>     - Re-order informations printed
>     - Drop print of the virtual address. It's not useful

The virtual address may appear in BUG info and stack traces etc, e.g. in
the fault addresses as well as in registers, where it may be useful to
know that an address corresponds (or is supposed to) the GIC.

> 
> Signed-off-by: Julien Grall <julien.grall@xxxxxxxxxx>
> ---
>  xen/arch/arm/gic-v3.c | 26 ++++++++++++++------------
>  1 file changed, 14 insertions(+), 12 deletions(-)
> 
> diff --git a/xen/arch/arm/gic-v3.c b/xen/arch/arm/gic-v3.c
> index 16b1df4..c109433 100644
> --- a/xen/arch/arm/gic-v3.c
> +++ b/xen/arch/arm/gic-v3.c
> @@ -1252,18 +1252,20 @@ static int __init gicv3_init(void)
>      }
>  
>      printk("GICv3 initialization:\n"
> -           "      gic_dist_addr=%"PRIpaddr"\n"
> -           "      gic_dist_mapaddr=%p\n"
> -           "      gic_rdist_regions=%d\n"
> -           "      gic_rdist_stride=%x\n"
> -           "      gic_rdist_base=%"PRIpaddr"\n"
> -           "      gic_rdist_base_size=%"PRIpaddr"\n"
> -           "      gic_rdist_base_mapaddr=%p\n"
> -           "      gic_maintenance_irq=%u\n",
> -           gicv3.dbase, gicv3.map_dbase, gicv3.rdist_count,
> -           gicv3.rdist_stride, gicv3.rdist_regions[0].base,
> -           gicv3.rdist_regions[0].size, gicv3.rdist_regions[0].map_base,
> -           gicv3_info.maintenance_irq);
> +           "      gic_dist_addr=%#"PRIpaddr"\n"
> +           "      gic_maintenance_irq=%u\n"
> +           "      gic_rdist_stride=%#x\n"
> +           "      gic_rdist_regions=%d\n",
> +           gicv3.dbase, gicv3_info.maintenance_irq,
> +           gicv3.rdist_stride, gicv3.rdist_count);
> +    printk("      redistributor regions:\n");
> +    for ( i = 0; i < gicv3.rdist_count; i++ )
> +    {
> +        const struct rdist_region *r = &gicv3.rdist_regions[i];
> +
> +        printk("        - region %u: %#"PRIpaddr" - %#"PRIpaddr"\n",
> +               i, r->base, r->base + r->size);
> +    }
>  
>      spin_lock_init(&gicv3.lock);
>  



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.