public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH trivial 1/3] Bluetooth: Make l2cap_data_channel return void
@ 2012-05-31  8:18 Andrei Emeltchenko
  2012-05-31  8:18 ` [PATCH trivial 2/3] Bluetooth: Make l2cap_conless_channel " Andrei Emeltchenko
  2012-05-31  8:18 ` [PATCH trivial 3/3] Bluetooth: Make l2cap_att_channel " Andrei Emeltchenko
  0 siblings, 2 replies; 4+ messages in thread
From: Andrei Emeltchenko @ 2012-05-31  8:18 UTC (permalink / raw)
  To: linux-bluetooth

From: Andrei Emeltchenko <andrei.emeltchenko@intel.com>

l2cap_data_channel always return 0 which is not used anywhere,
make it void function.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
---
 net/bluetooth/l2cap_core.c |    9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c
index bef5266..56f5c0e 100644
--- a/net/bluetooth/l2cap_core.c
+++ b/net/bluetooth/l2cap_core.c
@@ -5128,7 +5128,8 @@ drop:
 	return 0;
 }
 
-static inline int l2cap_data_channel(struct l2cap_conn *conn, u16 cid, struct sk_buff *skb)
+static void l2cap_data_channel(struct l2cap_conn *conn, u16 cid,
+			       struct sk_buff *skb)
 {
 	struct l2cap_chan *chan;
 
@@ -5138,7 +5139,7 @@ static inline int l2cap_data_channel(struct l2cap_conn *conn, u16 cid, struct sk
 			chan = a2mp_channel_create(conn, skb);
 			if (!chan) {
 				kfree_skb(skb);
-				return 0;
+				return;
 			}
 
 			l2cap_chan_lock(chan);
@@ -5146,7 +5147,7 @@ static inline int l2cap_data_channel(struct l2cap_conn *conn, u16 cid, struct sk
 			BT_DBG("unknown cid 0x%4.4x", cid);
 			/* Drop packet and return */
 			kfree_skb(skb);
-			return 0;
+			return;
 		}
 	}
 
@@ -5184,8 +5185,6 @@ drop:
 
 done:
 	l2cap_chan_unlock(chan);
-
-	return 0;
 }
 
 static inline int l2cap_conless_channel(struct l2cap_conn *conn, __le16 psm, struct sk_buff *skb)
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH trivial 2/3] Bluetooth: Make l2cap_conless_channel return void
  2012-05-31  8:18 [PATCH trivial 1/3] Bluetooth: Make l2cap_data_channel return void Andrei Emeltchenko
@ 2012-05-31  8:18 ` Andrei Emeltchenko
  2012-05-31  8:18 ` [PATCH trivial 3/3] Bluetooth: Make l2cap_att_channel " Andrei Emeltchenko
  1 sibling, 0 replies; 4+ messages in thread
From: Andrei Emeltchenko @ 2012-05-31  8:18 UTC (permalink / raw)
  To: linux-bluetooth

From: Andrei Emeltchenko <andrei.emeltchenko@intel.com>

l2cap_conless_channel always return 0 which is not used.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
---
 net/bluetooth/l2cap_core.c |    7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c
index 56f5c0e..a8d69ab 100644
--- a/net/bluetooth/l2cap_core.c
+++ b/net/bluetooth/l2cap_core.c
@@ -5187,7 +5187,8 @@ done:
 	l2cap_chan_unlock(chan);
 }
 
-static inline int l2cap_conless_channel(struct l2cap_conn *conn, __le16 psm, struct sk_buff *skb)
+static void l2cap_conless_channel(struct l2cap_conn *conn, __le16 psm,
+				  struct sk_buff *skb)
 {
 	struct l2cap_chan *chan;
 
@@ -5204,12 +5205,10 @@ static inline int l2cap_conless_channel(struct l2cap_conn *conn, __le16 psm, str
 		goto drop;
 
 	if (!chan->ops->recv(chan, skb))
-		return 0;
+		return;
 
 drop:
 	kfree_skb(skb);
-
-	return 0;
 }
 
 static inline int l2cap_att_channel(struct l2cap_conn *conn, u16 cid,
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH trivial 3/3] Bluetooth: Make l2cap_att_channel return void
  2012-05-31  8:18 [PATCH trivial 1/3] Bluetooth: Make l2cap_data_channel return void Andrei Emeltchenko
  2012-05-31  8:18 ` [PATCH trivial 2/3] Bluetooth: Make l2cap_conless_channel " Andrei Emeltchenko
@ 2012-05-31  8:18 ` Andrei Emeltchenko
  2012-05-31 13:27   ` Gustavo Padovan
  1 sibling, 1 reply; 4+ messages in thread
From: Andrei Emeltchenko @ 2012-05-31  8:18 UTC (permalink / raw)
  To: linux-bluetooth

From: Andrei Emeltchenko <andrei.emeltchenko@intel.com>

l2cap_att_channel always returns 0 which is not used.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
---
 net/bluetooth/l2cap_core.c |    8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c
index a8d69ab..8229ae4 100644
--- a/net/bluetooth/l2cap_core.c
+++ b/net/bluetooth/l2cap_core.c
@@ -5211,8 +5211,8 @@ drop:
 	kfree_skb(skb);
 }
 
-static inline int l2cap_att_channel(struct l2cap_conn *conn, u16 cid,
-				    struct sk_buff *skb)
+static void l2cap_att_channel(struct l2cap_conn *conn, u16 cid,
+			      struct sk_buff *skb)
 {
 	struct l2cap_chan *chan;
 
@@ -5229,12 +5229,10 @@ static inline int l2cap_att_channel(struct l2cap_conn *conn, u16 cid,
 		goto drop;
 
 	if (!chan->ops->recv(chan, skb))
-		return 0;
+		return;
 
 drop:
 	kfree_skb(skb);
-
-	return 0;
 }
 
 static void l2cap_recv_frame(struct l2cap_conn *conn, struct sk_buff *skb)
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH trivial 3/3] Bluetooth: Make l2cap_att_channel return void
  2012-05-31  8:18 ` [PATCH trivial 3/3] Bluetooth: Make l2cap_att_channel " Andrei Emeltchenko
@ 2012-05-31 13:27   ` Gustavo Padovan
  0 siblings, 0 replies; 4+ messages in thread
From: Gustavo Padovan @ 2012-05-31 13:27 UTC (permalink / raw)
  To: Andrei Emeltchenko; +Cc: linux-bluetooth

Hi Andrei,

* Andrei Emeltchenko <Andrei.Emeltchenko.news@gmail.com> [2012-05-31 11:18:57 +0300]:

> From: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
> 
> l2cap_att_channel always returns 0 which is not used.
> 
> Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
> ---
>  net/bluetooth/l2cap_core.c |    8 +++-----
>  1 file changed, 3 insertions(+), 5 deletions(-)

All 3 patches have been applied to bluetooth-next. Thanks.

	Gustavo

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-05-31 13:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-31  8:18 [PATCH trivial 1/3] Bluetooth: Make l2cap_data_channel return void Andrei Emeltchenko
2012-05-31  8:18 ` [PATCH trivial 2/3] Bluetooth: Make l2cap_conless_channel " Andrei Emeltchenko
2012-05-31  8:18 ` [PATCH trivial 3/3] Bluetooth: Make l2cap_att_channel " Andrei Emeltchenko
2012-05-31 13:27   ` Gustavo Padovan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox