Skip to content

Commit

Permalink
Bluetooth: Silence sparse warning
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Andrei Emeltchenko authored and Gustavo Padovan committed May 9, 2012
1 parent c72d4b8 commit 3e9fb6d
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions net/bluetooth/mgmt.c
Original file line number Diff line number Diff line change
Expand Up @@ -443,9 +443,7 @@ static u16 get_uuid16(u8 *uuid128)
return 0;
}

memcpy(&val, &uuid128[12], 4);

val = le32_to_cpu(val);
val = get_unaligned_le32(&uuid128[12]);
if (val > 0xffff)
return 0;

Expand Down

0 comments on commit 3e9fb6d

Please sign in to comment.