All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ian Campbell <ian.campbell@citrix.com>
To: Julien Grall <julien.grall@citrix.com>, xen-devel@lists.xenproject.org
Cc: Zoltan Kiss <zoltan.kiss@huawei.com>, stefano.stabellini@citrix.com
Subject: Re: [PATCH v2 5/7] xen/arm: gic: Check the size of the CPU and vCPU interface retrieved from DT
Date: Thu, 1 Oct 2015 13:08:12 +0100	[thread overview]
Message-ID: <1443701292.11707.30.camel@citrix.com> (raw)
In-Reply-To: <1443543701-18389-6-git-send-email-julien.grall@citrix.com>

On Tue, 2015-09-29 at 17:21 +0100, Julien Grall wrote:
> @@ -641,7 +643,30 @@ static int __init gicv2_init(void)
>          panic("GICv2: Cannot find the maintenance IRQ");
>      gicv2_info.maintenance_irq = res;
>  
> -    /* TODO: Add check on distributor, cpu size */
> +    /* TODO: Add check on distributor */
> +
> +    /*
> +     * The GICv2 CPU interface should at least be 8KB. Although, most of the DT
> +     * doesn't correctly set it and use the GICv1 CPU interface size (i.e 4KB).
> +     * Warn and then fixup.
> +     */
> +    if ( csize < SZ_8K )
> +    {
> +        printk(XENLOG_WARNING "GICv2: WARNING: "
> +               "The CPU interface size is wrong: %#"PRIx64
> +               " expected %#x\n",

You missed fixing a split string constant here.

> +               csize, SZ_8K);
> +        csize = SZ_8K;
> +    }
> +
> +    /*
> +     * Check if the CPU interface and virtual CPU interface have the
> +     * same size.
> +     */
> +    if ( csize != vsize )
> +        printk(XENLOG_WARNING "GICv2: WARNING: "
> +               "The size of the CPU interface (%#"PRIpaddr") and the vCPU interface (%#"PRIpaddr") don't match\n",

Apart from the wrapping this is also just quite a long line in its own
right (100+ characters with the prefix on the preceeding line) e.g. for
reading a serial log.

How about s/the CPU interface/GICC/ and s/the vCPU interface/GICV/ ?

And maybe s/The size/Sizes/?

>  
> +    /*
> +     * Only allow support of GICv2 compatible when the CPU interface
> +     * and virtual CPU interface are 8KB
> +     * XXX: Handle other size?
> +     */
> +    if ( csize != SZ_8K && vsize != SZ_8K )
> +    {
> +        printk(XENLOG_WARNING
> +               "GICv3: WARNING: Not enabling support of GICv2 compat mode.\n"

s/of/for/

> +               "The size of the CPU interface (%#"PRIpaddr") and the vCPU interface (%#"PRIpaddr") should both be 8KB.\n",

Similarly here. Or just "GICC ("%#...") and GICV ("%#...") must both be 8KB"?

  reply	other threads:[~2015-10-01 12:08 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-29 16:21 [PATCH v2 0/7] xen/arm: gic-v2: Detect automatically aliased GIC 400 Julien Grall
2015-09-29 16:21 ` [PATCH v2 1/7] xen/arm: gic: Make it clear the GIC node is passed to make_hwdom_dt_node Julien Grall
2015-09-29 16:21 ` [PATCH v2 2/7] xen/arm: Retrieve the correct number of cells when building dom0 DT Julien Grall
2015-10-01 11:57   ` Ian Campbell
2015-09-29 16:21 ` [PATCH v2 3/7] xen/arm: Warn when a device tree path will be re-used by Xen Julien Grall
2015-10-01 12:01   ` Ian Campbell
2015-10-01 12:39     ` Julien Grall
2015-09-29 16:21 ` [PATCH v2 4/7] xen/arm: vgic-v2: Drop cbase from arch_domain Julien Grall
2015-09-29 16:21 ` [PATCH v2 5/7] xen/arm: gic: Check the size of the CPU and vCPU interface retrieved from DT Julien Grall
2015-10-01 12:08   ` Ian Campbell [this message]
2015-10-01 12:43     ` Julien Grall
2015-10-01 12:54       ` Ian Campbell
2015-09-29 16:21 ` [PATCH v2 6/7] xen/arm: gic-v2: Automatically detect aliased GIC400 Julien Grall
2015-10-01 12:10   ` Ian Campbell
2015-09-29 16:21 ` [PATCH v2 7/7] xen/arm: platform: Drop the quirks callback Julien Grall
2015-09-29 16:55   ` Julien Grall
2015-10-01 12:10     ` Ian Campbell
2015-10-01 12:56 ` [PATCH v2 0/7] xen/arm: gic-v2: Detect automatically aliased GIC 400 Ian Campbell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1443701292.11707.30.camel@citrix.com \
    --to=ian.campbell@citrix.com \
    --cc=julien.grall@citrix.com \
    --cc=stefano.stabellini@citrix.com \
    --cc=xen-devel@lists.xenproject.org \
    --cc=zoltan.kiss@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.