package/f2fs-tools: furthe endianness fixes
PATCH 1/1 package/f2fs-tools: furthe endianness fixes
Add appropriate checks in configure.ac.
Fixes a slew of autobuilder failures:
http://autobuild.buildroot.org/results/cf6/cf6f5b6981694f74bfca45b3d04ff35e4226b162/ http://autobuild.buildroot.org/results/b34/b346472e686af5b517b689217349eab21878bb7b/ http://autobuild.buildroot.org/results/49a/49a6a2a88cac6e0899f271a5e65c78dd9eb2eab4/ ...
Note: patches sent upstream, awaiting for reply...
Signed-off-by "Yann E. MORIN" <[email protected]>
Cc Gustavo Zacarias <[email protected]>
--- ...3-mkfs.f2fs-fix-missing-endian-conversion.patch | 42 ++++++++++++++++++ .../0004-configure-also-check-for-byteswap.h.patch | 35 +++++++++++++++ .../0005-configure-add-check-for-bswap_64.patch | 50 ++++++++++++++++++++++ 3 files changed, 127 insertions(+) create mode 100644 package/f2fs-tools/0003-mkfs.f2fs-fix-missing-endian-conversion.patch create mode 100644 package/f2fs-tools/0004-configure-also-check-for-byteswap.h.patch create mode 100644 package/f2fs-tools/0005-configure-add-check-for-bswap_64.patch
package/f2fs-tools/0003-mkfs.f2fs-fix-missing-endian-conversion.patch new file +42 -0
@@ -0,0 +1,42 @@ +commit 0b4d168d07b54f1dc6db0c4da11a939222e817f2 +Author: Changman Lee <[email protected]> +Date: Thu Nov 13 20:15:05 2014 +0900 + + mkfs.f2fs: fix missing endian conversion + + This is for conversion from cpu to little endian and vice versa. + + Signed-off-by: Changman Lee <[email protected]> + Signed-off-by: Jaegeuk Kim <[email protected]> + +diff --git a/mkfs/f2fs_format.c b/mkfs/f2fs_format.c +index 0a9d728..c0028a3 100644 +--- a/mkfs/f2fs_format.c ++++ b/mkfs/f2fs_format.c +@@ -71,7 +71,7 @@ static void configure_extension_list(void) + memcpy(super_block.extension_list[i++], *extlist, name_len); + extlist++; + } +- super_block.extension_count = i; ++ super_block.extension_count = cpu_to_le32(i); + + if (!ext_str) + return; +@@ -86,7 +86,7 @@ static void configure_extension_list(void) + break; + } + +- super_block.extension_count = i; ++ super_block.extension_count = cpu_to_le32(i); + + free(config.extension_list); + } +@@ -211,7 +211,7 @@ static int f2fs_prepare_super_block(void) + if (max_sit_bitmap_size > + (CHECKSUM_OFFSET - sizeof(struct f2fs_checkpoint) + 65)) { + max_nat_bitmap_size = CHECKSUM_OFFSET - sizeof(struct f2fs_checkpoint) + 1; +- super_block.cp_payload = F2FS_BLK_ALIGN(max_sit_bitmap_size); ++ super_block.cp_payload = cpu_to_le32(F2FS_BLK_ALIGN(max_sit_bitmap_size)); + } else { + max_nat_bitmap_size = CHECKSUM_OFFSET - sizeof(struct f2fs_checkpoint) + 1 + - max_sit_bitmap_size;
package/f2fs-tools/0004-configure-also-check-for-byteswap.h.patch new file +35 -0
@@ -0,0 +1,35 @@ +From 7b9da72b1779cbc7b6c092523877860ef9315a36 Mon Sep 17 00:00:00 2001 +From: "Yann E. MORIN" <[email protected]> +Date: Thu, 25 Dec 2014 18:39:19 +0100 +Subject: [PATCH] configure: also check for byteswap.h + +include/f2fs_fs.h checks the HAVE_BYTESWAP_H conditional, but it is +never checked for in configure. + +Add that header to the list of headers checked for. + +Signed-off-by: "Yann E. MORIN" <[email protected]> +Cc: Gustavo Zacarias <[email protected]> +--- +Note: not exactly the same as submitted upstreram, because they already +check for more headers. +--- + configure.ac | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/configure.ac b/configure.ac +index d66cb73..7cfd9b4 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -57,7 +57,7 @@ PKG_CHECK_MODULES([libuuid], [uuid]) + + # Checks for header files. + AC_CHECK_HEADERS([linux/fs.h fcntl.h mntent.h stdlib.h string.h \ +- sys/ioctl.h sys/mount.h unistd.h]) ++ sys/ioctl.h sys/mount.h unistd.h byteswap.h]) + + # Checks for typedefs, structures, and compiler characteristics. + AC_C_INLINE +-- +1.9.1 +
package/f2fs-tools/0005-configure-add-check-for-bswap_64.patch new file +50 -0
50 lines not on this page · raw message
Signature · 1 line
1.9.1
Thomas Petazzoni
AppliedPATCH 1/1 package/f2fs-tools: furthe endianness fixes
Dear Yann E. MORIN,
Quoted 8 lines · Yann E. MORIN
Add appropriate checks in configure.ac.
Fixes a slew of autobuilder failures:
http://autobuild.buildroot.org/results/cf6/cf6f5b6981694f74bfca45b3d04ff35e4226b162/ http://autobuild.buildroot.org/results/b34/b346472e686af5b517b689217349eab21878bb7b/ http://autobuild.buildroot.org/results/49a/49a6a2a88cac6e0899f271a5e65c78dd9eb2eab4/ ...
Quoted 4 lines
Note: patches sent upstream, awaiting for reply...
Signed-off-by "Yann E. MORIN" <[email protected]>Cc Gustavo Zacarias <[email protected]>
Applied, thanks.
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com