Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp3868355ybz; Mon, 4 May 2020 11:11:20 -0700 (PDT) X-Google-Smtp-Source: APiQypJl5zTvIWctl+vNBm+QUSReuLaQFAuvufWryqXFtIpNl7PxP05yKM+Ds9JHYCjdV2ufpe0o X-Received: by 2002:aa7:d1cc:: with SMTP id g12mr16042779edp.84.1588615880758; Mon, 04 May 2020 11:11:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588615880; cv=none; d=google.com; s=arc-20160816; b=jUc7dyvv0RnfhLZ1rr1ZGi0/kpaFYTJOT41jVihur4GMgRqUY0jk6Rb8gl4kNzWeW5 eqkQ8DZmsw1LzjEMvtPLmCobUNRxqD7rPOtZf0ftf3hRIrtjxH9xh6wSpMGbh6r+3raa QmbH2Ql1kMgkP7YsfwIQ1uwqkmponHPhUAki93p/uhTNLcaAOGCsB2oPxN+vgUh+6sgr 5WKOKANlLE2wwGoMtHNPMB4RJvnzw1lRA+WwWPgLu/fQKVoLvjNULrCfZUmFP1sSbV3k znE74NBfq7E5NGGHctSyjeK/oA+Gd0P6h17JtNtQkfhyq92V2KkqDApS/X9K4O+wMqQb iWXQ== 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:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=6Q3lk/EVY3Rz9dfNbQiLRxLbeYwE/hHF77Px6KRjZ/c=; b=HyZ+epi2gGFwjjwxMNLdrLF4G6mS8imPGEHTR4oQwMA+XahTzP41V8Ox9Eov5lVCcl tmZRSH+6dqkIoF4RQo92GkVg1xYQlO20XwWem/qMBTPEgDbxtvRhwBrLzXzseIWThMpK mv7+IK9nSQWLhU4OLMs842H1uvF/nYDb3qFvA7gTsRHC3WG/n0RJYIiZ5FFZCMYHHiyr TJtnDI7jPVvYHXc8jS/XZg0Ptoh4kpilEqrmD5gbkQQwplUiA2et4V3Wv6TPYbRtXAWd Bv7gzQcBnInNmHYeFxB6ANejel80x3ZhmJJuyTOzydYq01vFp/OUUD3PHICNG0fjI2H8 IesQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=afeLKSU3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a19si7367430ejs.131.2020.05.04.11.10.51; Mon, 04 May 2020 11:11:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=afeLKSU3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732188AbgEDSHr (ORCPT + 99 others); Mon, 4 May 2020 14:07:47 -0400 Received: from mail.kernel.org ([198.145.29.99]:38732 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732181AbgEDSHo (ORCPT ); Mon, 4 May 2020 14:07:44 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 871F62073B; Mon, 4 May 2020 18:07:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1588615664; bh=tUHjouMIe2y5rFbeb+MgvQF2ue4Iw8BcFWPGcw8xtv8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=afeLKSU3z5SQAd8kNAk5o1W/GaHSiigp17uFYldQB3TpZ6HmGD6G2m/P9dkmxxTAJ r+yQoyZjyjhAPbmIc3nCmo8g+wF2pucvYhYv+PnRTKA5O9lPvK/s0JI2/CJt3QxV8D 9bPm715nwkrlYfQKblkkXn6wJWHf6AUKhizfyGiQ= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Will Deacon , Szabolcs Nagy , Vincenzo Frascino , Catalin Marinas Subject: [PATCH 5.6 72/73] arm64: vdso: Add -fasynchronous-unwind-tables to cflags Date: Mon, 4 May 2020 19:58:15 +0200 Message-Id: <20200504165510.575729659@linuxfoundation.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200504165501.781878940@linuxfoundation.org> References: <20200504165501.781878940@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Vincenzo Frascino commit 1578e5d03112e3e9d37e1c4d95b6dfb734c73955 upstream. On arm64 linux gcc uses -fasynchronous-unwind-tables -funwind-tables by default since gcc-8, so now the de facto platform ABI is to allow unwinding from async signal handlers. However on bare metal targets (aarch64-none-elf), and on old gcc, async and sync unwind tables are not enabled by default to avoid runtime memory costs. This means if linux is built with a baremetal toolchain the vdso.so may not have unwind tables which breaks the gcc platform ABI guarantee in userspace. Add -fasynchronous-unwind-tables explicitly to the vgettimeofday.o cflags to address the ABI change. Fixes: 28b1a824a4f4 ("arm64: vdso: Substitute gettimeofday() with C implementation") Cc: Will Deacon Reported-by: Szabolcs Nagy Signed-off-by: Vincenzo Frascino Signed-off-by: Catalin Marinas Signed-off-by: Greg Kroah-Hartman --- arch/arm64/kernel/vdso/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/arch/arm64/kernel/vdso/Makefile +++ b/arch/arm64/kernel/vdso/Makefile @@ -32,7 +32,7 @@ UBSAN_SANITIZE := n OBJECT_FILES_NON_STANDARD := y KCOV_INSTRUMENT := n -CFLAGS_vgettimeofday.o = -O2 -mcmodel=tiny +CFLAGS_vgettimeofday.o = -O2 -mcmodel=tiny -fasynchronous-unwind-tables ifneq ($(c-gettimeofday-y),) CFLAGS_vgettimeofday.o += -include $(c-gettimeofday-y)