summaryrefslogtreecommitdiff
path: root/net/ieee802154/socket.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/ieee802154/socket.c')
-rw-r--r--net/ieee802154/socket.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/net/ieee802154/socket.c b/net/ieee802154/socket.c
index 3b2366a88c3c..a725dd9bbda8 100644
--- a/net/ieee802154/socket.c
+++ b/net/ieee802154/socket.c
@@ -314,7 +314,8 @@ static int raw_recvmsg(struct sock *sk, struct msghdr *msg, size_t len,
int err = -EOPNOTSUPP;
struct sk_buff *skb;
- skb = skb_recv_datagram(sk, flags, noblock, &err);
+ flags |= (noblock ? MSG_DONTWAIT : 0);
+ skb = skb_recv_datagram(sk, flags, &err);
if (!skb)
goto out;
@@ -703,7 +704,8 @@ static int dgram_recvmsg(struct sock *sk, struct msghdr *msg, size_t len,
struct dgram_sock *ro = dgram_sk(sk);
DECLARE_SOCKADDR(struct sockaddr_ieee802154 *, saddr, msg->msg_name);
- skb = skb_recv_datagram(sk, flags, noblock, &err);
+ flags |= (noblock ? MSG_DONTWAIT : 0);
+ skb = skb_recv_datagram(sk, flags, &err);
if (!skb)
goto out;