Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp659615pxb; Tue, 5 Apr 2022 17:40:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwSK1w+KWS4zxDTQ47+eGOCGq+knJwBXBMZ3CMngKjT/adWgDDUOJ37+EeslKLEDGzQ8ieb X-Received: by 2002:a17:907:3f02:b0:6e7:7172:4437 with SMTP id hq2-20020a1709073f0200b006e771724437mr5735775ejc.361.1649205645185; Tue, 05 Apr 2022 17:40:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649205645; cv=none; d=google.com; s=arc-20160816; b=NXgNr6mGORYktqiYCOT22cdqV25zm5vRfDe7oKZRQeRvtD8OirwDFlSieBGWoEysea uhvAZNIXXJOryIVjTjFIIenaKBkbi5W4Pii2RmeMjSMTsZHDRt2asH0XFgrA0fsNadQn agvarwsYqmmASUY+eBS8phX7lxck9Ap4+y164jOsMU4Apv11BM/Elp345yLN58g2nmPU WZ4KSWKCjsaE3Jx1i6at/m/ed6EOf7HqTVFID3W6+mJojAxNUDPu/Zp9Pu0cHDxZ31xE IfRJlWibLvgj6OOwY74U4q9cx1+fUTo42AvUEcGo5lf3D1SgSEaw4vAIl1qU/1P5a02H YAhA== 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=HYku11ScP/BzrhmcDROtjagbguO24f17nAJmqWJA//g=; b=pfR5zBoxo9XyUzqEI2h+BGuYk6Xfug4SbMj7PBJBRrl46Na2CKoOdWXBVwreNTbONi A7+BeHYWN6HCj96SC43/m0s4ViJuADfHuzdUFiCxVWhGdLHr5AotGzzp4b6YvM9aCm15 LASJcbqbyusNq2pcBxBJDMu7yajKBZiAR7bEP8Nnn2jzEYsu/Qru9LVavQ/AIG9b8nMv q0skwU+6xHKaI4OyStwB6VqEC+s82ixh5C0cmBmj4yGuk8cqShKgrx5weoQlRWE7suax CyCqivtnUBWxFG5LkW0v74NeFD6R0GJGs7aXUaM5LkjjAhvrtOkyHFrqKRgU8XEllohH xY9w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=LBbzIceB; 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 y5-20020a17090629c500b006e7ef40a0easi5870985eje.626.2022.04.05.17.40.19; Tue, 05 Apr 2022 17:40:45 -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=LBbzIceB; 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 S238714AbiDEOr1 (ORCPT + 99 others); Tue, 5 Apr 2022 10:47:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38324 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244521AbiDEJl1 (ORCPT ); Tue, 5 Apr 2022 05:41:27 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BD799BBE01; Tue, 5 Apr 2022 02:26:54 -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 dfw.source.kernel.org (Postfix) with ESMTPS id 5ADB06144D; Tue, 5 Apr 2022 09:26:54 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6DF1AC385A3; Tue, 5 Apr 2022 09:26:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1649150813; bh=vCNxLByh22qWpvDtzrk7nKcRMnmgzftlBFDb7fx5dWY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=LBbzIceB1Fhg4w25eaCo0HlI7z8/RAiSunTpQSFrWHIzTs3vb1NyOCy+gODLfVXpA 4usa4BrU0oDhsN2FBhOVhxHP9JvTUPBiHoLAua0+aMxnA07lyYlP7DD5MbCIV91P64 7TePqFiNVb7PLmKug5wjWrTDybgJkVoXs2K/1uG8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Max Filippov Subject: [PATCH 5.15 173/913] xtensa: fix stop_machine_cpuslocked call in patch_text Date: Tue, 5 Apr 2022 09:20:35 +0200 Message-Id: <20220405070345.038365579@linuxfoundation.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220405070339.801210740@linuxfoundation.org> References: <20220405070339.801210740@linuxfoundation.org> User-Agent: quilt/0.66 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,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 From: Max Filippov commit f406f2d03e07afc199dd8cf501f361dde6be8a69 upstream. patch_text must invoke patch_text_stop_machine on all online CPUs, but it calls stop_machine_cpuslocked with NULL cpumask. As a result only one CPU runs patch_text_stop_machine potentially leaving stale icache entries on other CPUs. Fix that by calling stop_machine_cpuslocked with cpu_online_mask as the last argument. Cc: stable@vger.kernel.org Fixes: 64711f9a47d4 ("xtensa: implement jump_label support") Signed-off-by: Max Filippov Signed-off-by: Greg Kroah-Hartman --- arch/xtensa/kernel/jump_label.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/arch/xtensa/kernel/jump_label.c +++ b/arch/xtensa/kernel/jump_label.c @@ -61,7 +61,7 @@ static void patch_text(unsigned long add .data = data, }; stop_machine_cpuslocked(patch_text_stop_machine, - &patch, NULL); + &patch, cpu_online_mask); } else { unsigned long flags;