Bluetooth: Silence sparse warning
Silence sparse warning shown below:
...
net/bluetooth/mgmt.c:448:15: warning: cast to restricted __le32
...
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Signed-off-by: Gustavo Padovan <gustavo@padovan.org>
diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c
index f590dfb..1d3e3d0 100644
--- a/net/bluetooth/mgmt.c
+++ b/net/bluetooth/mgmt.c
@@ -443,9 +443,7 @@
return 0;
}
- memcpy(&val, &uuid128[12], 4);
-
- val = le32_to_cpu(val);
+ val = get_unaligned_le32(&uuid128[12]);
if (val > 0xffff)
return 0;