~ubuntu-branches/ubuntu/precise/linux-ti-omap4/precise

« back to all changes in this revision

Viewing changes to net/bluetooth/cmtp/capi.c

  • Committer: Bazaar Package Importer
  • Author(s): Paolo Pisati
  • Date: 2011-06-29 15:23:51 UTC
  • mfrom: (26.1.1 natty-proposed)
  • Revision ID: james.westby@ubuntu.com-20110629152351-xs96tm303d95rpbk
Tags: 3.0.0-1200.2
* Rebased against 3.0.0-6.7
* BSP from TI based on 3.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
35
35
#include <linux/ioctl.h>
36
36
#include <linux/file.h>
37
37
#include <linux/wait.h>
 
38
#include <linux/kthread.h>
38
39
#include <net/sock.h>
39
40
 
40
41
#include <linux/isdn/capilli.h>
143
144
 
144
145
        skb_queue_tail(&session->transmit, skb);
145
146
 
146
 
        cmtp_schedule(session);
 
147
        wake_up_interruptible(sk_sleep(session->sock->sk));
147
148
}
148
149
 
149
150
static void cmtp_send_interopmsg(struct cmtp_session *session,
155
156
 
156
157
        BT_DBG("session %p subcmd 0x%02x appl %d msgnum %d", session, subcmd, appl, msgnum);
157
158
 
158
 
        if (!(skb = alloc_skb(CAPI_MSG_BASELEN + 6 + len, GFP_ATOMIC))) {
 
159
        skb = alloc_skb(CAPI_MSG_BASELEN + 6 + len, GFP_ATOMIC);
 
160
        if (!skb) {
159
161
                BT_ERR("Can't allocate memory for interoperability packet");
160
162
                return;
161
163
        }
385
387
 
386
388
        capi_ctr_down(ctrl);
387
389
 
388
 
        atomic_inc(&session->terminate);
389
 
        cmtp_schedule(session);
 
390
        kthread_stop(session->task);
390
391
}
391
392
 
392
393
static void cmtp_register_appl(struct capi_ctr *ctrl, __u16 appl, capi_register_params *rp)