From: Thiemo Seufer <ths@networkno.de>
To: Claudio Scordino <claudio@evidence.eu.com>
Cc: michael trimarchi <michael@evidence.eu.com>, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] fstat bug on armeb stll exists!
Date: Sun, 2 Dec 2007 07:12:00 +0000 [thread overview]
Message-ID: <20071202071200.GC617@networkno.de> (raw)
In-Reply-To: <474EC207.1030700@evidence.eu.com>
Claudio Scordino wrote:
> Hi all,
>
> more than one year ago we sent a patch on this mailing list to fix a
> problem of the fstat syscall for armeb. See
>
> http://lists.gnu.org/archive/html/qemu-devel/2006-09/msg00137.html
>
> We found the bug compiling a Linux kernel for armeb on scratchbox.
>
> Qemu seemed to ignore the fact that in big endian systems the fields
> st_blocks and its padding are swapped (to allow future expansion of the
> field,) so the fix consisted only in swapping the two fields (only in big
> endian systems, of course).
>
> The patch just changed qemu/linux-user/syscall_defs.h to
>
> #ifndef TARGET_WORDS_BIGENDIAN
> target_ulong st_blocks;
> target_ulong __pad4;
> #else
> target_ulong __pad4;
> target_ulong st_blocks;
> #endif
AFAICS this assumption matches neither the glibc 2.6 nor the Linux
2.6.23 definitions. There is, however, an endianness difference in
handling the st_dev and st_rdev fields which is not handled properly
in QEMU.
I think this needs a separate struct stat definition for (non-EABI)
big endian ARM.
Thiemo
prev parent reply other threads:[~2007-12-02 7:12 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-29 13:43 [Qemu-devel] fstat bug on armeb stll exists! Claudio Scordino
2007-12-02 7:12 ` Thiemo Seufer [this message]
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=20071202071200.GC617@networkno.de \
--to=ths@networkno.de \
--cc=claudio@evidence.eu.com \
--cc=michael@evidence.eu.com \
--cc=qemu-devel@nongnu.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;
as well as URLs for NNTP newsgroup(s).