From owner-svn-src-head@freebsd.org Sun Sep 23 20:41:18 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 87CC210973AE; Sun, 23 Sep 2018 20:41:18 +0000 (UTC) (envelope-from andreast@FreeBSD.org) Received: from smtp.imp.ch (smtp.imp.ch [IPv6:2001:4060:1:1001::13:196]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2AB1E81F3E; Sun, 23 Sep 2018 20:41:18 +0000 (UTC) (envelope-from andreast@FreeBSD.org) Received: from [192.168.225.14] (dhclient-91-190-10-49.flashcable.ch [91.190.10.49]) (using TLSv1 with cipher ECDHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by fgznet.ch (Postfix) with ESMTPSA id 76CEBC191E; Sun, 23 Sep 2018 22:41:08 +0200 (CEST) Subject: Re: svn commit: r338486 - in head/libexec/rtld-elf: . aarch64 arm mips powerpc powerpc64 riscv To: Brooks Davis , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org References: <201809052323.w85NNGMZ044128@repo.freebsd.org> From: Andreas Tobler Message-ID: <2ecbc67d-cf5c-8b8f-fcb3-08c6148ee297@FreeBSD.org> Date: Sun, 23 Sep 2018 22:41:08 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <201809052323.w85NNGMZ044128@repo.freebsd.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: de-CH Content-Transfer-Encoding: 7bit X-Scanned-By: Asterix Submit on 127.0.1.1 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 23 Sep 2018 20:41:18 -0000 Hi Brooks, On 06.09.18 01:23, Brooks Davis wrote: > Author: brooks > Date: Wed Sep 5 23:23:16 2018 > New Revision: 338486 > URL: https://svnweb.freebsd.org/changeset/base/338486 > > Log: > Rework rtld's TLS Variant I implementation to match r326794 > > The above commit fixed handling overaligned TLS segments in libc's > TLS Variant I implementation, but rtld provides its own implementation > for dynamically-linked executables which lacks these fixes. Thus, > port these changes to rtld. > > This was previously commited as r337978 and reverted in r338149 due to > exposing a bug the ARM rtld. This bug was fixed in r338317 by mmel. > > Submitted by: James Clarke > Approved by: re (kib) > Reviewed by: kbowling > Testing by: kbowling (powerpc64), br (riscv), kevans (armv7) And no testing on powerpc? This patch breaks ppc-32. It makes the system unusable, one can not even login. Neither on the console nor via ssh. After entering the user I get flooded with backslashes and the login shell dumps core. (Only visible if I netboot) I'm testing now a fix and see if it survives world and kernel build. > Modified: head/libexec/rtld-elf/powerpc/rtld_machdep.h > ============================================================================== > --- head/libexec/rtld-elf/powerpc/rtld_machdep.h Wed Sep 5 21:47:22 2018 (r338485) > +++ head/libexec/rtld-elf/powerpc/rtld_machdep.h Wed Sep 5 23:23:16 2018 (r338486) > @@ -74,10 +74,11 @@ void _rtld_powerpc_pltcall(void); > #define round(size, align) \ > (((size) + (align) - 1) & ~((align) - 1)) > #define calculate_first_tls_offset(size, align) \ > - round(8, align) > + TLS_TCB_SIZE Here, if I revert to 'round(8, align)', I can login again. But the fix I'm testing now, is to increase the TLS_TCB_SIZE to 16 as suggested by Justin. I'll let you know how it goes. Andreas