diff options
author | Andre Guedes <aguedespe@gmail.com> | 2012-06-08 00:05:45 +0200 |
---|---|---|
committer | Gustavo Padovan <gustavo.padovan@collabora.co.uk> | 2012-06-19 05:53:37 +0200 |
commit | 12b9456502d421a8272615fb641349eb2013b6d8 (patch) | |
tree | 520cbb58cb915faac60f26eaee85243079c5b5b1 /net | |
parent | Bluetooth: Use GFP_KERNEL in mgmt_handlers (diff) | |
download | linux-12b9456502d421a8272615fb641349eb2013b6d8.tar.xz linux-12b9456502d421a8272615fb641349eb2013b6d8.zip |
Bluetooth: Use GFP_KERNEL in mgmt_pending_add
We are allowed to sleep in mgmt_pending_add, so we should use
GFP_KERNEL for memory allocations instead of GFP_ATOMIC.
Signed-off-by: Andre Guedes <aguedespe@gmail.com>
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Diffstat (limited to 'net')
-rw-r--r-- | net/bluetooth/mgmt.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c index 86590c653232..41b5192bc041 100644 --- a/net/bluetooth/mgmt.c +++ b/net/bluetooth/mgmt.c @@ -687,14 +687,14 @@ static struct pending_cmd *mgmt_pending_add(struct sock *sk, u16 opcode, { struct pending_cmd *cmd; - cmd = kmalloc(sizeof(*cmd), GFP_ATOMIC); + cmd = kmalloc(sizeof(*cmd), GFP_KERNEL); if (!cmd) return NULL; cmd->opcode = opcode; cmd->index = hdev->id; - cmd->param = kmalloc(len, GFP_ATOMIC); + cmd->param = kmalloc(len, GFP_KERNEL); if (!cmd->param) { kfree(cmd); return NULL; |