linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: linuxppc-dev@lists.ozlabs.org
Cc: Daniel Axtens <dja@axtens.net>, linuxppc-dev@ozlabs.org
Subject: Re: [PATCH 3/6] powerpc/xics: Fully qualify cast to silence sparse
Date: Mon, 04 Jul 2016 09:46:21 +0200	[thread overview]
Message-ID: <6138424.54EmzRVKbE@wuerfel> (raw)
In-Reply-To: <1467616182-30886-3-git-send-email-dja@axtens.net>

On Monday, July 4, 2016 5:09:39 PM CEST Daniel Axtens wrote:
> Make the cast fully line up with what out_rm8 expects.
> 
> Signed-off-by: Daniel Axtens <dja@axtens.net>
> ---
>  arch/powerpc/sysdev/xics/icp-native.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/powerpc/sysdev/xics/icp-native.c b/arch/powerpc/sysdev/xics/icp-native.c
> index afdf62f2a695..e9cffb06cc01 100644
> --- a/arch/powerpc/sysdev/xics/icp-native.c
> +++ b/arch/powerpc/sysdev/xics/icp-native.c
> @@ -176,7 +176,7 @@ void icp_native_cause_ipi_rm(int cpu)
>          * causing the IPI.
>          */
>         xics_phys = paca[cpu].kvm_hstate.xics_phys;
> -       out_rm8((u8 *)(xics_phys + XICS_MFRR), IPI_PRIORITY);
> +       out_rm8((volatile u8 __iomem *)(xics_phys + XICS_MFRR), IPI_PRIORITY);
>  }

We don't normally mark pointers as 'volatile' when passing them
to the MMIO accessors. The reason that they take a volatile argument
is mainly to avoid a warning for drivers that for historic reasons
use volatile pointers intead of __iomem pointers.

	Arnd

  parent reply	other threads:[~2016-07-04  7:43 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-04  7:09 [PATCH 1/6] powerpc/kvm: Clarify __user annotations Daniel Axtens
2016-07-04  7:09 ` [PATCH 2/6] powerpc/kernel: Drop annotation for generic, unannotated function Daniel Axtens
2016-07-04  7:09 ` [PATCH 3/6] powerpc/xics: Fully qualify cast to silence sparse Daniel Axtens
2016-07-04  7:27   ` Andrew Donnellan
2016-07-04  7:46   ` Arnd Bergmann [this message]
2016-07-04  7:09 ` [PATCH 4/6] powerpc/kernel: Clean up some sparse warnings Daniel Axtens
2016-07-04  7:50   ` Arnd Bergmann
2016-07-04  7:09 ` [PATCH 5/6] powerpc/sparse: Pass endianness to sparse Daniel Axtens
2016-07-04  7:32   ` Andrew Donnellan
2016-07-04  7:52   ` Arnd Bergmann
2016-07-04  7:09 ` [PATCH 6/6] powerpc/sparse: Make ppc_md.{halt, restart} __noreturn Daniel Axtens
2016-07-04 10:20   ` kbuild test robot
2016-07-04  7:26 ` [PATCH 1/6] powerpc/kvm: Clarify __user annotations Andrew Donnellan

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=6138424.54EmzRVKbE@wuerfel \
    --to=arnd@arndb.de \
    --cc=dja@axtens.net \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=linuxppc-dev@ozlabs.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).