Received: by 2002:a05:6358:489b:b0:bb:da1:e618 with SMTP id x27csp2002578rwn; Fri, 16 Sep 2022 04:22:57 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7d9md05xkMs+hgZBkCBBGvdC14tLV9Z5albs1icDWhVpH91/BJLZ/KSMxtoZ/DmsTregl3 X-Received: by 2002:a17:907:1b03:b0:6ff:78d4:c140 with SMTP id mp3-20020a1709071b0300b006ff78d4c140mr3230978ejc.554.1663327376821; Fri, 16 Sep 2022 04:22:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663327376; cv=none; d=google.com; s=arc-20160816; b=Q5iy1iv6T8nKDA4tKjnMTH2VPFA2HeS3nHYYvZNVZ1e3VCBLZuDIzjsCfLnErFl4UE x2jtJOc4toHO5CUNKZf6bu9wc7dc3Is+pKCgzis0DAkUqf6mqlqAfNXINYPuPoCTiYMo opa83iGFPJTX/mD9B6sp5DkxWcaLjbgdN3RKHBhhNUm83oiPH55UPO5te1du2e9la7x0 PAqf0xMvXT4BKBmI+fywIiHmYyeCsYgoEVLsBquU50XHCQCiId59mBhLj5CBQDvXkUoL 6k+5q/mLNa1OelfxIyJtrLs5ktlEWjAgAV5892JYXm/yi8CtFTdmoENflLyeubnEDooj pbCg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=UdZXYkzSQy33m205gdBdxIGOu0oMc7xwvkpAtCcP4Vg=; b=ASCoefqOf+V7Vk8tV008AVZMYyRQFTQyZ3oQ7Il/vZ8cIPorJ8qfT/NHq0DLbBaaBh LhgadYdKSBOSSizwPa2qj3xXqh07ELhzPtB/umR4VVeLdYSvId9zLAJn2+ZFrzVPNzIV 5prDe5lKRu8bE2UaPr0qj115fwySBzwdf0fHPqoGPjHyn6rmulQxUonP+VZn09cSuX5e yEMVsxRXjVwnPhEbqG5eJtitahsreZUcoE89dIdUg1QS8TosgDfj3CaF5FFfTX2wcic9 VkBzqfFMxTGFna2ulWdK6B+261wIKzNcQ5i5zXu9gixdJQgkg3ipUNkYaukG66aHv7Jj dd9A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="PeSucU/q"; 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=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id dd5-20020a1709069b8500b00734b2821879si8782825ejc.898.2022.09.16.04.22.29; Fri, 16 Sep 2022 04:22:56 -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=@linuxfoundation.org header.s=korg header.b="PeSucU/q"; 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=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231836AbiIPKV0 (ORCPT + 99 others); Fri, 16 Sep 2022 06:21:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37692 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231972AbiIPKTR (ORCPT ); Fri, 16 Sep 2022 06:19:17 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0F6A3B07D1; Fri, 16 Sep 2022 03:13:06 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 102EFB82547; Fri, 16 Sep 2022 10:12:17 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7FB3FC433D6; Fri, 16 Sep 2022 10:12:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1663323135; bh=l7ifI2D61ypQD6Xd9t895tJj406Be87y8pTmmgihQz8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=PeSucU/qqRSaNJjsLT8vJrhZfv7Aiunww6TyGIZfpMFcxM2it2pPx37dd19R1K0d1 9a+zSgiLUygVMluPyF0Plr0bfpKKp8z68v5/87g6alKxe+j0qFSL0k3P7JK+Ls1Taf bGJ12kivpPr/9diwU5pQSXsAYhvz+qXNe6/m3CsM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Borislav Petkov , "Peter Zijlstra (Intel)" , Sasha Levin Subject: [PATCH 5.15 09/35] task_stack, x86/cea: Force-inline stack helpers Date: Fri, 16 Sep 2022 12:08:32 +0200 Message-Id: <20220916100447.330584007@linuxfoundation.org> X-Mailer: git-send-email 2.37.3 In-Reply-To: <20220916100446.916515275@linuxfoundation.org> References: <20220916100446.916515275@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS 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 From: Borislav Petkov [ Upstream commit e87f4152e542610d0b4c6c8548964a68a59d2040 ] Force-inline two stack helpers to fix the following objtool warnings: vmlinux.o: warning: objtool: in_task_stack()+0xc: call to task_stack_page() leaves .noinstr.text section vmlinux.o: warning: objtool: in_entry_stack()+0x10: call to cpu_entry_stack() leaves .noinstr.text section Signed-off-by: Borislav Petkov Acked-by: Peter Zijlstra (Intel) Link: https://lore.kernel.org/r/20220324183607.31717-2-bp@alien8.de Stable-dep-of: 54c3931957f6 ("tracing: hold caller_addr to hardirq_{enable,disable}_ip") Signed-off-by: Sasha Levin --- arch/x86/include/asm/cpu_entry_area.h | 2 +- include/linux/sched/task_stack.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/x86/include/asm/cpu_entry_area.h b/arch/x86/include/asm/cpu_entry_area.h index dd5ea1bdf04c5..75efc4c6f0766 100644 --- a/arch/x86/include/asm/cpu_entry_area.h +++ b/arch/x86/include/asm/cpu_entry_area.h @@ -143,7 +143,7 @@ extern void cea_set_pte(void *cea_vaddr, phys_addr_t pa, pgprot_t flags); extern struct cpu_entry_area *get_cpu_entry_area(int cpu); -static inline struct entry_stack *cpu_entry_stack(int cpu) +static __always_inline struct entry_stack *cpu_entry_stack(int cpu) { return &get_cpu_entry_area(cpu)->entry_stack_page.stack; } diff --git a/include/linux/sched/task_stack.h b/include/linux/sched/task_stack.h index d10150587d819..1009b6b5ce403 100644 --- a/include/linux/sched/task_stack.h +++ b/include/linux/sched/task_stack.h @@ -16,7 +16,7 @@ * try_get_task_stack() instead. task_stack_page will return a pointer * that could get freed out from under you. */ -static inline void *task_stack_page(const struct task_struct *task) +static __always_inline void *task_stack_page(const struct task_struct *task) { return task->stack; } -- 2.35.1