devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dinh Nguyen <dinguyen@altera.com>
To: Vince Bridgers <vbridgers2013@gmail.com>
Cc: netdev@vger.kernel.org, devicetree@vger.kernel.org,
	peppe.cavallaro@st.com, pawel.moll@arm.com, mark.rutland@arm.com,
	ijc+devicetree@hellion.org.uk, galak@codeaurora.org,
	linux@arm.linux.org.uk, linux-arm-kernel@lists.infradead.org,
	robh+dt@kernel.org, davem@davemloft.net, vbridger@altera.com
Subject: Re: [PATCH net v3 6/6] net: stmmac: squelch sparse warning with casts
Date: Wed, 30 Jul 2014 09:52:45 -0500	[thread overview]
Message-ID: <1406731965.23841.2.camel@linux-builds1> (raw)
In-Reply-To: <1406671607-27368-7-git-send-email-vbridgers2013@gmail.com>

Hi Vince,

On Tue, 2014-07-29 at 17:06 -0500, Vince Bridgers wrote:
> Add casts to squelch the following sparse warnings so we can see
> the ones that matter when they occur.
> 
> stmmac_platform.c:260:20: warning: incorrect type in argument 1
> 			  (different address spaces)
> stmmac_platform.c:260:20:    expected void const *static extern
> 			  [signed] [long] [typedef] [tls] inline [safe] ptr
> stmmac_platform.c:260:20:    got void [noderef] <asn:2>*[assigned] addr
> stmmac_platform.c:261:32: warning: incorrect type in argument 1
> 			  (different address spaces)
> stmmac_platform.c:261:32:    expected void const *static extern
> 			  [signed] [long] [typedef] [tls] inline [safe] ptr
> stmmac_platform.c:261:32:    got void [noderef] <asn:2>*[assigned] addr
> 


I think you should update your sparse. I have 0.5.0 and the only sparse
warnings for stmmac are:

drivers/net/ethernet/stmicro/stmmac/enh_desc.c:381:30: warning: symbol
'enh_desc_ops' was not declared. Should it be static?
drivers/net/ethernet/stmicro/stmmac/norm_desc.c:253:30: warning: symbol
'ndesc_ops' was not declared. Should it be static?
drivers/net/ethernet/stmicro/stmmac/dwmac-socfpga.c:128:29: warning:
symbol 'socfpga_gmac_data' was not declared. Should it be static?
drivers/net/ethernet/stmicro/stmmac/stmmac_hwtstamp.c:141:33: warning:
symbol 'stmmac_ptp' was not declared. Should it be static?


Dinh
> Signed-off-by: Vince Bridgers <vbridgers2013@gmail.com>
> ---
> V3: Add minor sparse warning correction as part of series
> V2: Not present in prior submissions
> ---
>  .../net/ethernet/stmicro/stmmac/stmmac_platform.c  |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
> index bb524a9..228003b 100644
> --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
> +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
> @@ -257,8 +257,8 @@ static int stmmac_pltfr_probe(struct platform_device *pdev)
>  
>  	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
>  	addr = devm_ioremap_resource(dev, res);
> -	if (IS_ERR(addr))
> -		return PTR_ERR(addr);
> +	if (IS_ERR((void __force *)addr))
> +		return PTR_ERR((void __force *)addr);
>  
>  	plat_dat = dev_get_platdata(&pdev->dev);
>  	if (pdev->dev.of_node) {

  reply	other threads:[~2014-07-30 14:52 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-29 22:06 [PATCH net v3 0/6] net: stmmac: Improve mcast/ucast filter for snps Vince Bridgers
     [not found] ` <1406671607-27368-1-git-send-email-vbridgers2013-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2014-07-29 22:06   ` [PATCH net v3 1/6] net: stmmac: Change MAC interface to support multiple filter configurations Vince Bridgers
2014-07-29 22:06 ` [PATCH net v3 2/6] net: stmmac: Correct set_filter for multicast and unicast cases Vince Bridgers
2014-07-29 22:06 ` [PATCH net v3 3/6] dts: Add bindings for multicast hash bins and perfect filter entries Vince Bridgers
2014-07-29 22:06 ` [PATCH net v3 4/6] ARM: socfpga: Add socfpga Ethernet filter attributes entries Vince Bridgers
2014-07-29 22:06 ` [PATCH net v3 5/6] net: stmmac: Support devicetree configs for mcast and ucast filter entries Vince Bridgers
2014-07-29 22:06 ` [PATCH net v3 6/6] net: stmmac: squelch sparse warning with casts Vince Bridgers
2014-07-30 14:52   ` Dinh Nguyen [this message]
2014-07-31 18:59 ` [PATCH net v3 0/6] net: stmmac: Improve mcast/ucast filter for snps David Miller

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=1406731965.23841.2.camel@linux-builds1 \
    --to=dinguyen@altera.com \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=galak@codeaurora.org \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux@arm.linux.org.uk \
    --cc=mark.rutland@arm.com \
    --cc=netdev@vger.kernel.org \
    --cc=pawel.moll@arm.com \
    --cc=peppe.cavallaro@st.com \
    --cc=robh+dt@kernel.org \
    --cc=vbridger@altera.com \
    --cc=vbridgers2013@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 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).