All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Cc: devel@driverdev.osuosl.org,
	linux-kernel <linux-kernel@vger.kernel.org>,
	Lior Dotan <liodot@gmail.com>
Subject: Re: [PATCH v4] staging: slicoss: fix different address space warnings
Date: Mon, 21 Nov 2016 11:09:50 +0100	[thread overview]
Message-ID: <20161121100950.GA32763@kroah.com> (raw)
In-Reply-To: <CAMhs-H_sbKvaJ8g50K=Jni9r8gReuCB2SmeNxL3Wm8yZC6KTFg@mail.gmail.com>

On Sun, Nov 20, 2016 at 09:21:51AM +0100, Sergio Paracuellos wrote:
> On Sat, Nov 19, 2016 at 2:20 PM, Greg KH <gregkh@linuxfoundation.org> wrote:
> > On Fri, Nov 18, 2016 at 06:57:18PM +0100, Sergio Paracuellos wrote:
> >> Remove incorrect __iomem annotation.
> >>
> >> This patch fix the following sparse warnings in slicoss driver:
> >> warning: incorrect type in assignment (different address spaces)
> >>
> >> Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
> >> ---
> >>  drivers/staging/slicoss/slic.h | 2 +-
> >>  1 file changed, 1 insertion(+), 1 deletion(-)
> >>
> >> diff --git a/drivers/staging/slicoss/slic.h b/drivers/staging/slicoss/slic.h
> >> index 420546d..14d7555 100644
> >> --- a/drivers/staging/slicoss/slic.h
> >> +++ b/drivers/staging/slicoss/slic.h
> >> @@ -380,7 +380,7 @@ struct slic_shmemory {
> >>       dma_addr_t isr_phaddr;
> >>       dma_addr_t lnkstatus_phaddr;
> >>       dma_addr_t stats_phaddr;
> >> -     struct slic_shmem_data __iomem *shmem_data;
> >> +     struct slic_shmem_data *shmem_data;
> >
> > But, is this the correct fix?  It looks like shmem_data is being treated
> > like a pointer to io memory, so we need to use the correct accessors for
> > that memory, and not just a "raw" pointer, right?  Removing this marking
> > seems to be moving backwards...
> 
> That was the intention of v3 of the patch. But after Dan suggestions I
> though that just
> removing this mark would be enough because it was wrong. I am a little
> lost now :)

Ok, I'm lost too, sorry.  I looked at the driver and shmem_data is
created by calling pci_zalloc_consistent, and that's not __iomem space,
but a real pointer.

So your patch is correct here, sorry for the noise, I'll go apply it.

thanks,

greg k-h

  reply	other threads:[~2016-11-21 10:09 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-18 17:57 [PATCH v4] staging: slicoss: fix different address space warnings Sergio Paracuellos
2016-11-18 17:57 ` Sergio Paracuellos
2016-11-19 13:20   ` Greg KH
2016-11-20  8:21     ` Sergio Paracuellos
2016-11-21 10:09       ` Greg KH [this message]
2016-11-21 11:02         ` Sergio Paracuellos

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=20161121100950.GA32763@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=devel@driverdev.osuosl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=liodot@gmail.com \
    --cc=sergio.paracuellos@gmail.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.