From patchwork Fri Apr 14 14:47:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: tip-bot2 for Thomas Gleixner X-Patchwork-Id: 83473 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:6358:3046:b0:115:7a1d:dabb with SMTP id p6csp389201rwl; Fri, 14 Apr 2023 08:08:42 -0700 (PDT) X-Google-Smtp-Source: AKy350bcpebghPr7HYP85tWkmcs2kz14AGAFLY7DD/l3wBgY8/lwLtM8Y4bcpnhXP1oO+G8CCFOc X-Received: by 2002:a92:ce07:0:b0:328:95cc:e296 with SMTP id b7-20020a92ce07000000b0032895cce296mr4088457ilo.2.1681484922657; Fri, 14 Apr 2023 08:08:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681484922; cv=none; d=google.com; s=arc-20160816; b=ucXTCx0pmYvQqvL2Uh0qcTLe2SKjBY4nw9krWdCwXeU+KOe4eOty/V26d3NGkVQLv9 Jj38NMuIYhsSZOeDVgB0WnUBoeUyHZ6W+Oimkb0bXJJrwRqPt+AvCrWPBeDzrZhcdv5T cGTx21R2k/jdVsVm/9hxVy6gsMFxScn0ZSIW20f7OTiTl4yEULEm2P+S49KssQTRCezw mw46EnUQb6FPa0588Ce1zNkWgENz6pUpOnnmQ4329hU9PqEwz2gZkbzrDsVDkivlp1XY 4vW5+G9o3z6bdy6iAIaXqbBvdobL3n076p2fS/3PUpizoznGDY8UC3tEUC6IByBUMAwj QGeQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=8/9e9YsQ2EUkL2LLf8mvhm3+zBTdxBKufAnVicgwPsc=; b=u2iSrrBKeJRUFIR3DYaWaEulCVQmdZkzbS2DgTakrhBWGWl1g8hYVbzBYf3MPml+ep MyDqjzgo4Ouex3rylDM552p/IWwCvm3mR0rXQHTQBb3ZcGFnk75BlA5FeYgTPR1YiCxM 6lwdsdnR+kjKMYgN6oiYAY5XwMar163D1xItU4pBDd4EdIH9rR5D96i3mHW+W4oaii5m 6bBSdMGSAp3JPtRP+Lqn3686FbMBoO+/kBnWcRrHCw6AKT+3RStuksnYP5ZH3N30ivHp lwxgH0BGWoP827VhLt6HDmFjjfnpw2wx0YRlvH3AXmNv6nqULeJSFFd54CrlWUSPr6LK VafQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=xLkFIGKh; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id d3-20020a056e021c4300b00325d3c0f602si3977420ilg.48.2023.04.14.08.08.25; Fri, 14 Apr 2023 08:08:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=xLkFIGKh; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231477AbjDNOs2 (ORCPT + 99 others); Fri, 14 Apr 2023 10:48:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42358 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230390AbjDNOsC (ORCPT ); Fri, 14 Apr 2023 10:48:02 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 237C3BB9A; Fri, 14 Apr 2023 07:48:01 -0700 (PDT) Date: Fri, 14 Apr 2023 14:47:57 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1681483677; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=8/9e9YsQ2EUkL2LLf8mvhm3+zBTdxBKufAnVicgwPsc=; b=xLkFIGKhh/AWA/QYbZWgstdjw/rmTRRfinBUl0RbvXAny1CzyehJyIrpyxZtrw1OARMSY7 uBLZ8w3j4lnxIPRqHceYo8aSc1feKrtULcHXtmgAVeGS7ZBcsmw38oz/d59ExPr3P9ru4W BwYEHrjk7tQWj7hZpYoSNhBSxTOvQAOoVqRhbWoxqti13TdxW8Nho9em1ZL1hE62RJDmCI c8fjHoCHuok0wcEPGWHe18Q5AuPj3mXpHVHOJ1/sF5UcPB0PIDIYKHFj8f6dQjSCLpa7yb NEJpQMtqFZzObWVld6+sjJIjtDH0ilXQTH/+CiRiu7Ot8tt9LrzsHH7Swff88Q== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1681483677; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=8/9e9YsQ2EUkL2LLf8mvhm3+zBTdxBKufAnVicgwPsc=; b=Qo7H2OMUhT59Yb5HofyXRZuJcPHFYPuIA2EYbIPlCmZiPn/mpVKcLhaM/XUsXMZJ5yG3+H wtkw04tiDzGj55Aw== From: "tip-bot2 for Josh Poimboeuf" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: objtool/core] sched: Fix KCSAN noinstr violation Cc: Josh Poimboeuf , "Peter Zijlstra (Intel)" , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: References: MIME-Version: 1.0 Message-ID: <168148367716.404.4222570877291738976.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762992899540074210?= X-GMAIL-MSGID: =?utf-8?q?1763164734229054582?= The following commit has been merged into the objtool/core branch of tip: Commit-ID: e0b081d17a9f4e5c0cbb0e5fbeb1abe3de0f7e4e Gitweb: https://git.kernel.org/tip/e0b081d17a9f4e5c0cbb0e5fbeb1abe3de0f7e4e Author: Josh Poimboeuf AuthorDate: Wed, 12 Apr 2023 10:24:07 -07:00 Committer: Peter Zijlstra CommitterDate: Fri, 14 Apr 2023 16:08:26 +02:00 sched: Fix KCSAN noinstr violation With KCSAN enabled, end_of_stack() can get out-of-lined. Force it inline. Fixes the following warnings: vmlinux.o: warning: objtool: check_stackleak_irqoff+0x2b: call to end_of_stack() leaves .noinstr.text section Signed-off-by: Josh Poimboeuf Signed-off-by: Peter Zijlstra (Intel) Link: https://lore.kernel.org/r/cc1b4d73d3a428a00d206242a68fdf99a934ca7b.1681320026.git.jpoimboe@kernel.org --- include/linux/sched/task_stack.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/sched/task_stack.h b/include/linux/sched/task_stack.h index 5e799a4..f158b02 100644 --- a/include/linux/sched/task_stack.h +++ b/include/linux/sched/task_stack.h @@ -23,7 +23,7 @@ static __always_inline void *task_stack_page(const struct task_struct *task) #define setup_thread_stack(new,old) do { } while(0) -static inline unsigned long *end_of_stack(const struct task_struct *task) +static __always_inline unsigned long *end_of_stack(const struct task_struct *task) { #ifdef CONFIG_STACK_GROWSUP return (unsigned long *)((unsigned long)task->stack + THREAD_SIZE) - 1;