diff options
author | Samuel Ortiz <sameo@linux.intel.com> | 2011-12-14 10:43:08 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-12-14 14:50:12 -0500 |
commit | db81a62451b24eaef59f41e6fb312a88e1a83454 (patch) | |
tree | 7d2f730daacb982db12a866d89bc119cc103d33c /net/nfc | |
parent | 94a098da42f258ae7019acbbea3bc5f93dc6f8f1 (diff) |
NFC: Atomic socket allocation
rawsock_create() is called with preemption disabled, so we should not
sleep.
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/nfc')
-rw-r--r-- | net/nfc/rawsock.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/nfc/rawsock.c b/net/nfc/rawsock.c index 11ac0a17156e..2e2f8c6a61fe 100644 --- a/net/nfc/rawsock.c +++ b/net/nfc/rawsock.c | |||
@@ -310,7 +310,7 @@ static int rawsock_create(struct net *net, struct socket *sock, | |||
310 | 310 | ||
311 | sock->ops = &rawsock_ops; | 311 | sock->ops = &rawsock_ops; |
312 | 312 | ||
313 | sk = sk_alloc(net, PF_NFC, GFP_KERNEL, nfc_proto->proto); | 313 | sk = sk_alloc(net, PF_NFC, GFP_ATOMIC, nfc_proto->proto); |
314 | if (!sk) | 314 | if (!sk) |
315 | return -ENOMEM; | 315 | return -ENOMEM; |
316 | 316 | ||