On Fri, Apr 5, 2024 at 2:04 PM <devel-request(a)lists.crash-utility.osci.io>
wrote:
Date: Fri, 5 Apr 2024 06:01:33 +0000
From: HAGIO KAZUHITO(萩尾 一仁) <k-hagio-ab(a)nec.com>
Subject: [Crash-utility] Re: [PATCH v4 ] Adding the zram decompression
algorithm "lzo-rle" to support kernel versions >= 5.1
To: Yulong TANG 汤玉龙 <yulong.tang(a)nio.com>,
"devel(a)lists.crash-utility.osci.io"
<devel(a)lists.crash-utility.osci.io>
Message-ID: <ce7328ee-aab4-4b72-85d5-77e5ef3aff9a(a)nec.com>
Content-Type: multipart/mixed;
boundary="_002_ce7328eeaab44b7285d577e5ef3aff9aneccom_"
Hi, Yulong
I have one question about the following function:
+static uint16_t get_unaligned_le16(const void *p) {
+ uint16_t value;
+ memcpy(&value, p, sizeof(uint16_t));
+ return value;
+}
Is this for handling the data under a little-endian machine? It might have
a different result when calling the above function on a
big-endian/little-endian machine, is that expected behavior? Just confirm
with you.
Thanks
Lianbo