linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alexander Aring <alex.aring@gmail.com>
To: Martin Townsend <mtownsend1973@gmail.com>
Cc: linux-zigbee-devel@lists.sourceforge.net,
	linux-bluetooth@vger.kernel.org
Subject: Re: [Linux-zigbee-devel] [PATCH 1/2] Remove dev parameter from skb_delivery_cb in 6lowpan.
Date: Thu, 31 Jul 2014 07:33:13 +0200	[thread overview]
Message-ID: <20140731053232.GA26557@omega> (raw)
In-Reply-To: <1406733923-21700-2-git-send-email-martin.townsend@xsilon.com>

Hi Martin,

this patch looks good, simple rebase it on bluetooth-next.

You could do:

git remote add bluetooth-next
git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next.git

git checkout bluetooth-next/master

then git cherry-pick $COMMIT_ID

to get the necessary commits from other branches, it should fail but you
need to solve the conflicts.

On Wed, Jul 30, 2014 at 04:25:22PM +0100, Martin Townsend wrote:
> This parameter is never used by any functions that are passed to
> lowpan_process_data which uses this callback.
> 
> Signed-off-by: Martin Townsend <martin.townsend@xsilon.com>
> ---
>  include/net/6lowpan.h         | 2 +-
>  net/6lowpan/iphc.c            | 2 +-
>  net/bluetooth/6lowpan.c       | 4 ++--
>  net/ieee802154/6lowpan_rtnl.c | 5 ++---
>  4 files changed, 6 insertions(+), 7 deletions(-)
> 
> diff --git a/include/net/6lowpan.h b/include/net/6lowpan.h
> index 79b530f..995cce86 100644
> --- a/include/net/6lowpan.h
> +++ b/include/net/6lowpan.h
> @@ -422,7 +422,7 @@ lowpan_uncompress_size(const struct sk_buff *skb, u16 *dgram_offset)
>  	return skb->len + uncomp_header - ret;
>  }
>  
> -typedef int (*skb_delivery_cb)(struct sk_buff *skb, struct net_device *dev);
> +typedef int (*skb_delivery_cb)(struct sk_buff *skb);
>  
>  int lowpan_process_data(struct sk_buff *skb, struct net_device *dev,
>  		const u8 *saddr, const u8 saddr_type, const u8 saddr_len,
> diff --git a/net/6lowpan/iphc.c b/net/6lowpan/iphc.c
> index e82c9cc..b4bb27c 100644
> --- a/net/6lowpan/iphc.c
> +++ b/net/6lowpan/iphc.c
> @@ -195,7 +195,7 @@ static int skb_deliver(struct sk_buff *skb, struct ipv6hdr *hdr,
>  	raw_dump_table(__func__, "raw skb data dump before receiving",
>  		       new->data, new->len);
>  
> -	stat = deliver_skb(new, dev);
> +	stat = deliver_skb(new);
>  
>  	kfree_skb(new);
>  
I know you didn't change it and you should do this in a seperate
patch, but this should be consume_skb or dev_kfree_skb. We don't drop
the skb afterwards here with failure. The complete file have several
places like this and use kfree_skb here. We should do this in one of the
next patches.

- Alex

       reply	other threads:[~2014-07-31  5:33 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1406733923-21700-1-git-send-email-martin.townsend@xsilon.com>
     [not found] ` <1406733923-21700-2-git-send-email-martin.townsend@xsilon.com>
2014-07-31  5:33   ` Alexander Aring [this message]
     [not found] ` <1406733923-21700-3-git-send-email-martin.townsend@xsilon.com>
2014-07-31  5:54   ` [Linux-zigbee-devel] [PATCH 2/2] Change lowpan_rcv so skb is freed within function and fix return values Alexander Aring
2014-07-31  6:26     ` Alexander Aring

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=20140731053232.GA26557@omega \
    --to=alex.aring@gmail.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=linux-zigbee-devel@lists.sourceforge.net \
    --cc=mtownsend1973@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).