From: Hongbo Li <lihongbo22@huawei.com>
To: <linux-erofs@lists.ozlabs.org>
Subject: Re: [PATCH v1 1/1] erofs-utils: fix endiannes issue
Date: Tue, 29 Apr 2025 16:30:17 +0800 [thread overview]
Message-ID: <6492b5cc-092a-46ff-98b4-9cd874af3c07@huawei.com> (raw)
In-Reply-To: <20250429073052.53681-1-egorenar@linux.ibm.com>
On 2025/4/29 15:30, Alexander Egorenkov wrote:
> From: Super User <root@a8345034.lnxne.boe>
>
> Macros __BYTE_ORDER, __LITTLE_ENDIAN and __BIG_ENDIAN are defined in
> user space header 'endian.h'. Not including this header results in
> the condition #if __BYTE_ORDER == __LITTLE_ENDIAN being always true, even on
> BE architectures (e.g. s390x). Due to this bug the compressor library was
> built for LE byte-order on BE arch s390x.
>
> Fixes: bc99c763e3fe ("erofs-utils: switch to effective unaligned access")
> Signed-off-by: Alexander Egorenkov <egorenar@linux.ibm.com>
> ---
> include/erofs/defs.h | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/include/erofs/defs.h b/include/erofs/defs.h
> index 051a270531ca..196dfa8191a8 100644
> --- a/include/erofs/defs.h
> +++ b/include/erofs/defs.h
> @@ -19,6 +19,7 @@ extern "C"
> #include <inttypes.h>
> #include <limits.h>
> #include <stdbool.h>
> +#include <endian.h>
>
Reviewed-by: Hongbo Li <lihongbo22@huawei.com>
> #ifdef HAVE_CONFIG_H
> #include <config.h>
next prev parent reply other threads:[~2025-04-29 8:30 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-29 7:30 [PATCH v1 1/1] erofs-utils: fix endiannes issue Alexander Egorenkov
2025-04-29 8:30 ` Hongbo Li [this message]
2025-04-29 11:07 ` Ian Kent
2025-04-29 13:54 ` Gao Xiang
2025-04-29 14:00 ` Alexander Egorenkov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=6492b5cc-092a-46ff-98b4-9cd874af3c07@huawei.com \
--to=lihongbo22@huawei.com \
--cc=linux-erofs@lists.ozlabs.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.