2014-02-06 22:55:22 +01:00
|
|
|
mmc-utils: fix mmc.h includes
|
2014-01-30 10:59:06 +01:00
|
|
|
|
|
|
|
Some toolchains include asm-generic/int-l64.h from their asm/types.h
|
|
|
|
file for certain 64-bit architectures. This causes a conflict between
|
|
|
|
types like this one:
|
|
|
|
|
|
|
|
asm-generic/int-l64.h:28:25: error: conflicting types for '__s64'
|
|
|
|
typedef __signed__ long __s64;
|
|
|
|
^
|
|
|
|
In file included from mmc.h:17:0,
|
|
|
|
from mmc_cmds.c:30:
|
|
|
|
asm-generic/int-ll64.h:29:44: note: previous declaration of '__s64' was
|
|
|
|
here
|
|
|
|
__extension__ typedef __signed__ long long __s64;
|
|
|
|
|
2014-02-06 22:55:22 +01:00
|
|
|
[Ryan: added include of linux/types.h because mmc/ioctl.h does not
|
|
|
|
include it in kernel version before 3.4]
|
|
|
|
|
2014-01-30 10:59:06 +01:00
|
|
|
Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
|
2014-02-06 22:55:22 +01:00
|
|
|
Signed-off-by: Ryan Barnett <rjbarnet@rockwellcollins.com>
|
2014-01-30 10:59:06 +01:00
|
|
|
---
|
|
|
|
mmc.h | 4 +++-
|
|
|
|
1 files changed, 3 insertions(+), 1 deletions(-)
|
|
|
|
diff --git a/mmc.h b/mmc.h
|
|
|
|
index 9871d62..2d54ec5 100644
|
|
|
|
--- a/mmc.h
|
|
|
|
+++ b/mmc.h
|
2014-02-06 22:55:22 +01:00
|
|
|
@@ -14,9 +14,12 @@
|
2014-01-30 10:59:06 +01:00
|
|
|
* Boston, MA 021110-1307, USA.
|
|
|
|
*/
|
2014-02-06 22:55:22 +01:00
|
|
|
|
2014-01-30 10:59:06 +01:00
|
|
|
-#include <asm-generic/int-ll64.h>
|
2014-02-06 22:55:22 +01:00
|
|
|
+#include <linux/types.h>
|
2014-01-30 10:59:06 +01:00
|
|
|
#include <linux/mmc/ioctl.h>
|
|
|
|
#include <stdio.h>
|
|
|
|
+#ifndef _ASM_GENERIC_INT_L64_H
|
|
|
|
+#include <asm-generic/int-ll64.h>
|
|
|
|
+#endif
|
2014-02-06 22:55:22 +01:00
|
|
|
|
2014-01-30 10:59:06 +01:00
|
|
|
#define CHECK(expr, msg, err_stmt) { if (expr) { fprintf(stderr, msg); err_stmt; } }
|
|
|
|
|