[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230406131755.GA1608262@pevik>
Date: Thu, 6 Apr 2023 15:17:55 +0200
From: Petr Vorel <pvorel@...e.cz>
To: Arnd Bergmann <arnd@...db.de>
Cc: Naresh Kamboju <naresh.kamboju@...aro.org>,
open list <linux-kernel@...r.kernel.org>,
LTP List <ltp@...ts.linux.it>, llvm@...ts.linux.dev,
chrubis <chrubis@...e.cz>, Nathan Chancellor <nathan@...nel.org>,
Anders Roxell <anders.roxell@...aro.org>,
Daniel Díaz <daniel.diaz@...aro.org>,
Benjamin Copeland <ben.copeland@...aro.org>,
Tudor Cretu <tudor.cretu@....com>
Subject: Re: LTP: list of failures on 32bit and compat mode
> On Thu, Apr 6, 2023, at 14:48, Petr Vorel wrote:
> >> On Thu, Apr 6, 2023, at 12:56, Petr Vorel wrote:
> >> Ah, I see. This must be the padding code then, not the time64
> >> conversion:
> >> +int recvmmsg(int fd, struct mmsghdr *msgvec, unsigned int vlen, unsigned int flags, struct timespec *timeout)
> >> +{
> >> +#if LONG_MAX > INT_MAX
> >> + struct mmsghdr *mh = msgvec;
> >> + unsigned int i;
> >> + for (i = vlen; i; i--, mh++)
> >> + mh->msg_hdr.__pad1 = mh->msg_hdr.__pad2 = 0;
> >> +#endif
> > I suppose this is a suggestion for fix in LTP. I'd expect is should go into
> > testcases/kernel/syscalls/sendmmsg/sendmmsg_var.h into static inline int
> > sys_recvmmsg(...)
> > But that at least on glibc 64bit compilation does not see __pad1 member:
> > ../sendmmsg/sendmmsg_var.h: In function ‘sys_recvmmsg’:
> > ../sendmmsg/sendmmsg_var.h:47:28: error: ‘struct msghdr’ has no member
> > named ‘__pad1’
> > 47 | mh->msg_hdr.__pad1 = mh->msg_hdr.__pad2 = 0;
> > | ^
> Sorry, I should have been clearer, the snippet I cited is
> from the musl sources, and the __pad access is what causes the
> segfault. The fix is to catch the fault on ltp, same as for the
> time64 conversions.
Thanks! I've just searched in musl as well, because it didn't make sense to me
it'd be a code for LTP.
"to catch the fault on ltp" I wonder if it's not actually musl bug.
Kind regards,
Petr
> Arnd
Powered by blists - more mailing lists