Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1da97f83 authored by David S. Miller's avatar David S. Miller
Browse files

[BLUETOOTH]: Fix non-COMPAT build of hci_sock.c

parent 577107e8
Loading
Loading
Loading
Loading
+4 −3
Original line number Original line Diff line number Diff line
@@ -348,16 +348,17 @@ static inline void hci_sock_cmsg(struct sock *sk, struct msghdr *msg, struct sk_


		skb_get_timestamp(skb, &tv);
		skb_get_timestamp(skb, &tv);


		data = &tv;
		len = sizeof(tv);
#ifdef CONFIG_COMPAT
		if (msg->msg_flags & MSG_CMSG_COMPAT) {
		if (msg->msg_flags & MSG_CMSG_COMPAT) {
			struct compat_timeval ctv;
			struct compat_timeval ctv;
			ctv.tv_sec = tv.tv_sec;
			ctv.tv_sec = tv.tv_sec;
			ctv.tv_usec = tv.tv_usec;
			ctv.tv_usec = tv.tv_usec;
			data = &ctv;
			data = &ctv;
			len = sizeof(ctv);
			len = sizeof(ctv);
		} else {
			data = &tv;
			len = sizeof(tv);
		}
		}
#endif


		put_cmsg(msg, SOL_HCI, HCI_CMSG_TSTAMP, len, data);
		put_cmsg(msg, SOL_HCI, HCI_CMSG_TSTAMP, len, data);
	}
	}