Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp798000pxk; Sat, 12 Sep 2020 00:07:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxQoDwQAGp2eME8a8zZXqnuP+hXnpfrB0e+KPoAYcyGqGTdCINM1Lv+nKlhhFpbnnzR7aoK X-Received: by 2002:a17:906:fa8a:: with SMTP id lt10mr5025429ejb.307.1599894443443; Sat, 12 Sep 2020 00:07:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599894443; cv=none; d=google.com; s=arc-20160816; b=CNIvv1At89UBnmpFex6sNCyrMvBBzkRs+JxHVmfkI/9whx/KKsSjPQutqd62DhUi9/ o2VTCt0202pB85JxSFFN1/zeBzSBRZICrlD+o4/Qtbtvnllw5oZ6Zc9HS0GUODBE7C2H LkTPGQLwdqXpsoaHiYUI+Ki85o5AvirU7JyA2qyATtKCmoCu39cWaB7wrlV270OMhAmq 8kJRkbkW/cvxbJK5qH3lf0BAr2t7oRhGXVUhRExhApbI2tYDL54R5sjKGByrLA5IQFm/ hgVW/ZpI+gs2VF5K6xkkuEsvfuClh1J372n5H3yK12dq7UEZCH9SfbZ6+X82ni4pKuQt fGKQ== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=BRZDkyJYF1BVZmrqYIv59kbrdWDpoeLct0KjG70XXGc=; b=W7EVBradXG6XHL+swns3cIeLN7o44VgFSaJm0HaXC3PcVVj6gvtlJWbBcG7PhSMTEC G/rgbGpR7a86xzOTFSF3S2aRqpv7//VPjeb9tqlykDgySsZtjYA1dwOAnw84CVFJolAF R3vmhGoUY61vkEK7YCUMRQca5bRn7zm8PM42PugXeKQ2AFtHilFOyz1oTvGBrMJgX6K0 2FIm0JXII8EhgEkfIQIaT+l8PCNq8G99b1KJRGNloDoLTQ6vDxOWCHw3hCM4PC42Hq2f 954YkSdYEmQEeL7uKIm6bVcKCxqiqHeK+ij6AT6r0aES0C133R9ltmB8O1iWnKZRInO3 rtIQ== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v12si2821826ejb.434.2020.09.12.00.07.01; Sat, 12 Sep 2020 00:07:23 -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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725906AbgILHGQ (ORCPT + 99 others); Sat, 12 Sep 2020 03:06:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37772 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725885AbgILHGO (ORCPT ); Sat, 12 Sep 2020 03:06:14 -0400 Received: from bhuna.collabora.co.uk (bhuna.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e3e3]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 87FD0C061757 for ; Sat, 12 Sep 2020 00:06:12 -0700 (PDT) Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: krisman) with ESMTPSA id 3ECD629C42E From: Gabriel Krisman Bertazi To: luto@kernel.org, tglx@linutronix.de Cc: hpa@zytor.com, bp@alien8.de, rric@kernel.org, peterz@infradead.org, mingo@redhat.com, x86@kernel.org, linux-kernel@vger.kernel.org, Gabriel Krisman Bertazi , kernel@collabora.com Subject: [PATCH 3/6] x86: oprofile: Avoid TIF_IA32 when checking 64bit mode Date: Sat, 12 Sep 2020 03:05:50 -0400 Message-Id: <20200912070553.330622-4-krisman@collabora.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200912070553.330622-1-krisman@collabora.com> References: <20200912070553.330622-1-krisman@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org In preparation to remove TIF_IA32, stop using it in oprofile code. Signed-off-by: Gabriel Krisman Bertazi --- arch/x86/oprofile/backtrace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/oprofile/backtrace.c b/arch/x86/oprofile/backtrace.c index a2488b6e27d6..1d8391fcca68 100644 --- a/arch/x86/oprofile/backtrace.c +++ b/arch/x86/oprofile/backtrace.c @@ -49,7 +49,7 @@ x86_backtrace_32(struct pt_regs * const regs, unsigned int depth) struct stack_frame_ia32 *head; /* User process is IA32 */ - if (!current || !test_thread_flag(TIF_IA32)) + if (!current || user_64bit_mode(regs)) return 0; head = (struct stack_frame_ia32 *) regs->bp; -- 2.28.0