diff options
author | Andrei Emeltchenko <andrei.emeltchenko@intel.com> | 2012-05-29 06:59:15 -0400 |
---|---|---|
committer | Johan Hedberg <johan.hedberg@intel.com> | 2012-06-04 23:34:13 -0400 |
commit | f6410a849b76f56c78d989786eb427b85a559b9f (patch) | |
tree | b8414c4fb0f7bf2e7763edb0965473cad2e6b9fb /net/bluetooth/a2mp.c | |
parent | 6113f84fc1a8962aed25f54a115b196e9aea151f (diff) |
Bluetooth: A2MP: Process A2MP Command Responses
Process A2MP responses, print cmd code and ident for now.
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Diffstat (limited to 'net/bluetooth/a2mp.c')
-rw-r--r-- | net/bluetooth/a2mp.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/net/bluetooth/a2mp.c b/net/bluetooth/a2mp.c index 400696b3b817..6a933dab1b7f 100644 --- a/net/bluetooth/a2mp.c +++ b/net/bluetooth/a2mp.c | |||
@@ -313,6 +313,15 @@ send_rsp: | |||
313 | return 0; | 313 | return 0; |
314 | } | 314 | } |
315 | 315 | ||
316 | static inline int a2mp_cmd_rsp(struct amp_mgr *mgr, struct sk_buff *skb, | ||
317 | struct a2mp_cmd *hdr) | ||
318 | { | ||
319 | BT_DBG("ident %d code %d", hdr->ident, hdr->code); | ||
320 | |||
321 | skb_pull(skb, le16_to_cpu(hdr->len)); | ||
322 | return 0; | ||
323 | } | ||
324 | |||
316 | /* Handle A2MP signalling */ | 325 | /* Handle A2MP signalling */ |
317 | static int a2mp_chan_recv_cb(struct l2cap_chan *chan, struct sk_buff *skb) | 326 | static int a2mp_chan_recv_cb(struct l2cap_chan *chan, struct sk_buff *skb) |
318 | { | 327 | { |
@@ -372,6 +381,9 @@ static int a2mp_chan_recv_cb(struct l2cap_chan *chan, struct sk_buff *skb) | |||
372 | case A2MP_GETAMPASSOC_RSP: | 381 | case A2MP_GETAMPASSOC_RSP: |
373 | case A2MP_CREATEPHYSLINK_RSP: | 382 | case A2MP_CREATEPHYSLINK_RSP: |
374 | case A2MP_DISCONNPHYSLINK_RSP: | 383 | case A2MP_DISCONNPHYSLINK_RSP: |
384 | err = a2mp_cmd_rsp(mgr, skb, hdr); | ||
385 | break; | ||
386 | |||
375 | default: | 387 | default: |
376 | BT_ERR("Unknown A2MP sig cmd 0x%2.2x", hdr->code); | 388 | BT_ERR("Unknown A2MP sig cmd 0x%2.2x", hdr->code); |
377 | err = -EINVAL; | 389 | err = -EINVAL; |