From: Ruediger Meier <sweet_f_a@gmx.de>
To: util-linux@vger.kernel.org
Cc: Michael Marineau <michael.marineau@coreos.com>
Subject: Re: [PATCH] libfdisk: (gpt) fix attributes endianess
Date: Fri, 8 May 2015 15:44:20 +0200 [thread overview]
Message-ID: <201505081544.20751.sweet_f_a@gmx.de> (raw)
In-Reply-To: <1431085193-1509-1-git-send-email-sweet_f_a@gmx.de>
On Friday 08 May 2015, Ruediger Meier wrote:
> From: Ruediger Meier <ruediger.meier@ga-group.nl>
>
> The new libfdisk/gpt test (4a4a0927) discovered that we read and
> write partition attributes wrongly on BE systems.
To be more clear ... this does not mean that 4a4a0927 is broken but the
test shows that sfdisk (and fdisk) is.
Introduced at least since 01086b80 (2014-03-13) and c77ba531
(2014-10-02).
Some notes how to reproduce.
## create gpt image
$ truncate -s 10M img
$ ./sfdisk --unit S img <<EOF
label: gpt
size=5M, attrs=""
EOF
## Both commands should do the same
$ ./sfdisk --part-attrs img 1 RequiredPartiton
$ ./test_fdisk_gpt --setattr img 1 "0x0000000000000001"
## So that for both cases and any endianess we should get
$ ./sfdisk --part-attrs img 1
RequiredPartiton
## and
$ ./test_fdisk_gpt --getattr img 1
1: 0x0000000000000001
## on disk it's always little endian
$ hexdump -C img | grep 009fbe30
009fbe30 01 00 00 00 00 00 00 00 ....
cu,
Rudi
next prev parent reply other threads:[~2015-05-08 13:44 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-08 11:39 [PATCH] libfdisk: (gpt) fix attributes endianess Ruediger Meier
2015-05-08 13:44 ` Ruediger Meier [this message]
2015-05-11 10:25 ` Karel Zak
2015-05-12 6:47 ` Ruediger Meier
2015-05-13 9:17 ` Karel Zak
2015-05-13 9:58 ` Ruediger Meier
2015-05-13 11:16 ` Karel Zak
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=201505081544.20751.sweet_f_a@gmx.de \
--to=sweet_f_a@gmx.de \
--cc=michael.marineau@coreos.com \
--cc=util-linux@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox