pmaports/device/testing/linux-htc-protou/fix-boot-gcc5.patch
Oliver Smith 64035ac463
device/*: move to device/testing/* (!1063)
Prepare for better device categorization by moving everything to testing
subdir first.

[skip-ci]: chicken-egg problem: passing pmaports CI depends on pmbootstrap MR
				depends on this MR

Related: postmarketos#16
2020-03-14 08:35:32 +01:00

25 lines
724 B
Diff

diff --git a/include/linux/unaligned/le_byteshift.h b/include/linux/unaligned/le_byteshift.h
index be376fb79..ab14cb194 100644
--- a/include/linux/unaligned/le_byteshift.h
+++ b/include/linux/unaligned/le_byteshift.h
@@ -5,17 +5,17 @@
static inline u16 __get_unaligned_le16(const u8 *p)
{
- return p[0] | p[1] << 8;
+ return p[0] + (p[1] << 8);
}
static inline u32 __get_unaligned_le32(const u8 *p)
{
- return p[0] | p[1] << 8 | p[2] << 16 | p[3] << 24;
+ return p[0] + (p[1] << 8) + (p[2] << 16) + (p[3] << 24);
}
static inline u64 __get_unaligned_le64(const u8 *p)
{
- return (u64)__get_unaligned_le32(p + 4) << 32 |
+ return ((u64)__get_unaligned_le32(p + 4) << 32) +
__get_unaligned_le32(p);
}