Netdev List
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: ben@decadent.org.uk
Cc: divy@chelsio.com, netdev@vger.kernel.org
Subject: Re: [PATCH net] cxgb3: Fix length calculation in write_ofld_wr() on 32-bit architectures
Date: Tue, 29 Oct 2013 00:14:35 -0400 (EDT)	[thread overview]
Message-ID: <20131029.001435.1010950710191845263.davem@davemloft.net> (raw)
In-Reply-To: <1382907759.2994.36.camel@deadeye.wl.decadent.org.uk>

From: Ben Hutchings <ben@decadent.org.uk>
Date: Sun, 27 Oct 2013 21:02:39 +0000

> The length calculation here is now invalid on 32-bit architectures,
> since sk_buff::tail is a pointer and sk_buff::transport_header is
> an integer offset:
> 
> drivers/net/ethernet/chelsio/cxgb3/sge.c: In function 'write_ofld_wr':
> drivers/net/ethernet/chelsio/cxgb3/sge.c:1603:9: warning: passing argument 4 of 'make_sgl' makes integer from pointer without a cast [enabled by default]
>          adap->pdev);
>          ^
> drivers/net/ethernet/chelsio/cxgb3/sge.c:964:28: note: expected 'unsigned int' but argument is of type 'sk_buff_data_t'
>  static inline unsigned int make_sgl(const struct sk_buff *skb,
>                             ^
> 
> Use the appropriate skb accessor functions.
> 
> Compile-tested only.
> 
> Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
> Fixes: 1a37e412a022 ('net: Use 16bits for *_headers fields of struct skbuff')
> ---
> This is needed for 3.11-stable.

Applied and queued up for -stable, thanks Ben.

      reply	other threads:[~2013-10-29  4:14 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-27 21:02 [PATCH net] cxgb3: Fix length calculation in write_ofld_wr() on 32-bit architectures Ben Hutchings
2013-10-29  4:14 ` David Miller [this message]

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=20131029.001435.1010950710191845263.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=ben@decadent.org.uk \
    --cc=divy@chelsio.com \
    --cc=netdev@vger.kernel.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