Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp9003986ybi; Wed, 10 Jul 2019 03:06:24 -0700 (PDT) X-Google-Smtp-Source: APXvYqzsx2A6PEFHU2B94nqf+DYFVGEabSYGr5Gz5MPhbcxbzDzXjG9E51Ic7C1kxkvS8WFoWBN/ X-Received: by 2002:a17:902:e30d:: with SMTP id cg13mr37686313plb.173.1562753184554; Wed, 10 Jul 2019 03:06:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562753184; cv=none; d=google.com; s=arc-20160816; b=ckMJZkci/JT/6Ryn0ySDCw4aLs+zJI1Mb59q3DJkk2Bj6dbgmMC4LFsm4T8SBw+D/0 zpnW3HYuX0nmwDJRlVDacBfvN4TrYTqU2VVYsK4BF03vnsCzUgfy3vdtCZisYibWUtWt ssTO3/PMzDKuXIJDIgb+pN6n6zYhLlHgbUNfouHtbyjH5IqMx9gQfmkrOHsJ0BwPHJ3P H4VMRHiuhXBaEFvfIx92DqLvj7eLLkCAI03GvSkD0tRBIaunU7mTm0lSTnsyK06ekfXI jJJTjSlhmyJ2dkAinxWO/C32aZVGiBL1UErDDvaC2N1NorMtgSnXmLU0c+3AXsKVS4ey vgkQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=R5lhKk5eSVrlh/Vly/XIdZKWWeoGi4K84TqedOgCg40=; b=dQ0NbycJBorQMc7gVpbsCc7Es7xJQShGqUVWV/KqFU6t2TUgyKtse8+oAUinrkScLI VmFK/O4ETC3CXWfHX24XVMJ5ECVSt4+3qToei6YFsTc/oIbOiyMzX73GG3ttpIDVWTmJ 5fDMOsXQa2995ToPQ3g0F025agG2G/uCFBiHSyDeuYYibRRszWFNKU+dBzY3k+nuHq5i sXBl1sUnZf4zgofyvEvEutLWeZjwPGwGLh3l6BtN6J6Qp2Bfbf5oaK8IhQbHyUjQJask FdBu6P7jVXb/LFovSszAU3UgyQTf/7qy49omznKVNm7nrmdbvtW9lC58ND/T0f/CiNks 6rCg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e9si1779379pgc.321.2019.07.10.03.05.57; Wed, 10 Jul 2019 03:06:24 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727171AbfGJJrX (ORCPT + 99 others); Wed, 10 Jul 2019 05:47:23 -0400 Received: from foss.arm.com ([217.140.110.172]:58574 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725941AbfGJJrX (ORCPT ); Wed, 10 Jul 2019 05:47:23 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 07B07344; Wed, 10 Jul 2019 02:47:22 -0700 (PDT) Received: from [10.1.196.72] (e119884-lin.cambridge.arm.com [10.1.196.72]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 7905E3F246; Wed, 10 Jul 2019 02:47:18 -0700 (PDT) Subject: Re: [PATCH v7 10/25] arm64: compat: Add vDSO To: John Stultz Cc: linux-arch@vger.kernel.org, linux-arm-kernel , lkml , linux-mips@vger.kernel.org, linux-kselftest@vger.kernel.org, Shuah Khan , Andre Przywara , Arnd Bergmann , Huw Davies , Catalin Marinas , Daniel Lezcano , Will Deacon , Russell King , Ralf Baechle , Mark Salyzyn , Paul Burton , Dmitry Safonov <0x7f454c46@gmail.com>, Rasmus Villemoes , Thomas Gleixner , Shijith Thotton , Peter Collingbourne References: <20190621095252.32307-1-vincenzo.frascino@arm.com> <20190621095252.32307-11-vincenzo.frascino@arm.com> From: Vincenzo Frascino Message-ID: Date: Wed, 10 Jul 2019 10:47:16 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi John, On 10/07/2019 05:02, John Stultz wrote: > On Fri, Jun 21, 2019 at 3:18 AM Vincenzo Frascino > wrote: >> >> Provide the arm64 compat (AArch32) vDSO in kernel/vdso32 in a similar >> way to what happens in kernel/vdso. >> >> The compat vDSO leverages on an adaptation of the arm architecture code >> with few changes: >> - Use of lib/vdso for gettimeofday >> - Implementation of syscall based fallback >> - Introduction of clock_getres for the compat library >> - Implementation of trampolines >> - Implementation of elf note >> >> To build the compat vDSO a 32 bit compiler is required and needs to be >> specified via CONFIG_CROSS_COMPILE_COMPAT_VDSO. >> > > Hey Vincenzo! > Congrats on getting this work merged, I know its been a long effort > over a number of years! > > Though unfortunately, it seems the arm64 vdso code that just landed is > breaking AOSP for me. > > I see a lot of the following errors: > 01-01 01:22:14.097 755 755 F libc : Fatal signal 11 (SIGSEGV), > code 1 (SEGV_MAPERR), fault addr 0x3cf2c96c in tid 755 (cameraserver), > pid 755 (cameraserver) > 01-01 01:22:14.112 759 759 F libc : Fatal signal 11 (SIGSEGV), > code 1 (SEGV_MAPERR), fault addr 0x3cf2c96c in tid 759 > (android.hardwar), pid 759 (android.hardwar) > 01-01 01:22:14.120 756 756 F libc : Fatal signal 11 (SIGSEGV), > code 1 (SEGV_MAPERR), fault addr 0x3cf2c96c in tid 756 (drmserver), > pid 756 (drmserver) > > Which go away if I revert the vdso merge that went in via tip/timers. > > I tried to bisect things down a bit, but as some later fixes are > required (at one point, date was returning the start epoch and never > increasing), this hasn't worked too well. But I'm guessing since I > see: "CROSS_COMPILE_COMPAT not defined or empty, the compat vDSO will > not be built", and the system is half working, I'm guessing this is an > issue with just the 32bit code failing. While I can try to sort out > the proper CROSS_COMPILE_COMPAT in my build environment, I assume > userland shouldn't be crashing if that value isn't set. > > Any chance this issue has already been raised? > I do not have Android (bionic/libc) as part of my testing environment hence I never saw this issue. Thanks for reporting it. I am investigating the problem and will post a fix as soon as it is ready. As Will suggested, .config would help the debugging and I would like to ask to you to test my fix once it is ready. Is that OK for you? > thanks > -john > -- Regards, Vincenzo