Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp2908634iog; Mon, 27 Jun 2022 05:33:25 -0700 (PDT) X-Google-Smtp-Source: AGRyM1u9cf56NcpqBZK0lU87fgSKB7LCAR2xoD3nCjNrdD+HPIMfiv0cKT/AgIlrF/KKtyRQM3+D X-Received: by 2002:a63:b55c:0:b0:40c:c512:daf7 with SMTP id u28-20020a63b55c000000b0040cc512daf7mr12454509pgo.405.1656333205748; Mon, 27 Jun 2022 05:33:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656333205; cv=none; d=google.com; s=arc-20160816; b=ZLWEAYSjrHTKmNlSGYo9Z15kFPjVfYDrUHynE2oo9mKh+upGiAIjGblTSJXJLZJ498 j9EYfESHjmgFqOCm1Xvncp88iLRD1QF+t9zvxKvD8DxUYwc9M9w8r+cDCAqAFeClJ0dZ ua6lbMuaSUmLfzoa2iueaRnP2kYF7a8ak+cbsBv5rn2ZH93h7G5NDqXXPnIzBgFmaecX MFXjtEuwRCU2vvxJ0D4JYYiPAmLPrf7b+J+5zt5nS0SVbHYu5TEj6EXdwGMEwsGoBWfL 9ko4DmUHW2/J9SnhgNaC8ZwquDIZ2Hn57Xlytt92R8Uxa/v25B/DGndkX7uwg5AGHSaM c1DA== 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=HZH7uwSvh/c8lDiYUxNOwmXKdYL145Tfha6DUWY6+Y8=; b=p273fA7k224WrGxxSRRBBtiuohLOs+H/P9EvrRaR/9gAIvikSr42ep7WTbUPb5FmQd kRYjK8neCzwPb9kIaPitFUll10zIA736q4mF6Si4wfBHC1+BrKFTPfl/CIjyxVOnFnwG 238xpy81MhPI5Rb4gWMv2+iwTRi4GTj+OTGdA4iKGilebKhyRd+tiz+ywseG/Tu6DBFM p9Zn4AiSd8q+iKrKAkV3TQqU6MFQIiFp4tq/2MY4p3TO981Vjc/Iuvs9E6CfjUezAJBg SxeE6vdnKp8L1I4o21Kgh6DAnAEdefeXvCdhczdkcCP8iWf6cwj+NOTzal2grk8ajr1S tcaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=1jKsxoaW; 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 c14-20020a170903234e00b0016a480d205csi12288275plh.156.2022.06.27.05.33.12; Mon, 27 Jun 2022 05:33:25 -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=1jKsxoaW; 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 S236021AbiF0LfM (ORCPT + 99 others); Mon, 27 Jun 2022 07:35:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55606 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236275AbiF0Ldd (ORCPT ); Mon, 27 Jun 2022 07:33:33 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 960D3D12F; Mon, 27 Jun 2022 04:30:47 -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 487CEB8111B; Mon, 27 Jun 2022 11:30:46 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A19F7C3411D; Mon, 27 Jun 2022 11:30:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1656329445; bh=Y8/7DRUh+lZjPlYwIbH/DiRIh4q8KDZY8gKG2Qs2WwE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=1jKsxoaWqNfQNtXQXq0/T//P49T0wsReCRKKqCev5L9N+xA/tg0/T2MADVpOH0CM2 gb3Hb1F1fI1dlWCyRPLEIHWtCZfk89IreynzKHLvmPz6yfuDoe8/AkELQn3L2+Tx4A x9M8q2KDJC/b1vY0aBhiG+zXErOPp6aOWvXJAuOs= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Helge Deller , John David Anglin Subject: [PATCH 5.4 48/60] parisc: Enable ARCH_HAS_STRICT_MODULE_RWX Date: Mon, 27 Jun 2022 13:21:59 +0200 Message-Id: <20220627111929.102264306@linuxfoundation.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220627111927.641837068@linuxfoundation.org> References: <20220627111927.641837068@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.5 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: Helge Deller commit 0a1355db36718178becd2bfe728a023933d73123 upstream. Fix a boot crash on a c8000 machine as reported by Dave. Basically it changes patch_map() to return an alias mapping to the to-be-patched code in order to prevent writing to write-protected memory. Signed-off-by: Helge Deller Suggested-by: John David Anglin Cc: stable@vger.kernel.org # v5.2+ Link: https://lore.kernel.org/all/e8ec39e8-25f8-e6b4-b7ed-4cb23efc756e@bell.net/ Signed-off-by: Greg Kroah-Hartman --- arch/parisc/Kconfig | 1 + 1 file changed, 1 insertion(+) --- a/arch/parisc/Kconfig +++ b/arch/parisc/Kconfig @@ -11,6 +11,7 @@ config PARISC select ARCH_WANT_FRAME_POINTERS select ARCH_HAS_ELF_RANDOMIZE select ARCH_HAS_STRICT_KERNEL_RWX + select ARCH_HAS_STRICT_MODULE_RWX select ARCH_HAS_UBSAN_SANITIZE_ALL select ARCH_NO_SG_CHAIN select ARCH_SUPPORTS_MEMORY_FAILURE