All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: Valerio Genovese <valerio.click@gmail.com>
Cc: devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] staging: kpc2000: kpc_dma: fix symbol 'kpc_dma_add_device' was not declared.
Date: Wed, 5 Jun 2019 18:11:09 +0200	[thread overview]
Message-ID: <20190605161109.GA17272@kroah.com> (raw)
In-Reply-To: <20190605155711.19722-1-valerio.click@gmail.com>

On Wed, Jun 05, 2019 at 05:57:11PM +0200, Valerio Genovese wrote:
> This was reported by sparse:
> drivers/staging/kpc2000/kpc_dma/kpc_dma_driver.c:39:7: warning: symbol 'kpc_dma_add_device
> ' was not declared. Should it be static?
> 
> Signed-off-by: Valerio Genovese <valerio.click@gmail.com>
> ---
>  drivers/staging/kpc2000/kpc_dma/kpc_dma_driver.h | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/staging/kpc2000/kpc_dma/kpc_dma_driver.h b/drivers/staging/kpc2000/kpc_dma/kpc_dma_driver.h
> index ee47f43e71cf..19e88c3bc13f 100644
> --- a/drivers/staging/kpc2000/kpc_dma/kpc_dma_driver.h
> +++ b/drivers/staging/kpc2000/kpc_dma/kpc_dma_driver.h
> @@ -56,6 +56,7 @@ struct dev_private_data {
>  };
>  
>  struct kpc_dma_device *kpc_dma_lookup_device(int minor);
> +void kpc_dma_add_device(struct kpc_dma_device *ldev);
>  
>  extern const struct file_operations  kpc_dma_fops;
>  

This is not how you fix this issue.

Look at the warning given to you.  Think about your C programming
knowledge and remember what the 'static' keyword is and does.

Then fix the issue properly.

thanks,

greg k-h

  parent reply	other threads:[~2019-06-05 16:11 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-05 15:57 [PATCH] staging: kpc2000: kpc_dma: fix symbol 'kpc_dma_add_device' was not declared Valerio Genovese
2019-06-05 16:09 ` Matt Sickler
2019-06-05 16:11 ` Greg KH [this message]
2019-06-05 16:56   ` Valerio G

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=20190605161109.GA17272@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=devel@driverdev.osuosl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=valerio.click@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.