Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp882295pxk; Thu, 17 Sep 2020 20:14:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx0k+MBsgIeBV8XwlXT+jj9QV3LDPf3jKlaf+sXwn96OSP4MJ4bpI4kBNodKVrbrQdQu8NU X-Received: by 2002:a17:906:33ca:: with SMTP id w10mr35577898eja.438.1600398860402; Thu, 17 Sep 2020 20:14:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600398860; cv=none; d=google.com; s=arc-20160816; b=wMkgd6ChxZadep2onhPxFcuxHI9npBeTFyZf2TpfYn5QIaRjBIJxEq2dTI5ghYdIAo Vr5dE6ALgSUc1BUg7gzJND+GUtRMDCkviA0bQQC2JbVIiRA0vLe0jT4hH/2nJuV4E/uS zT9PPXh6g407I0QrS/Xk5znaX4UTmcdXmhQgTlwuypU1ieD4bZPp8OaXM5Tb+q3KJiYk btPbdY6PxFNQoJw/UjoUl26gn9ID9/9TSlSfohv5/sz+cs+RPAsDJV7XdQUGj6EVUie1 VV/37hHVn68z8tHEqIXSI4zTispfzrphG3cIt1Xy2HF2FZdfcAhmKGnJJdhoubEYUSqN atWg== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=t5r5kH2L3kyJK0uW7G9V3zOPrH4y463nnCEQwebS8zE=; b=fqfcJqk4woW0jaZSfIXTdXoDs/IDwlYZdEYjFbwwM6Ol0KAlO4ex0FiBEP3GxmroZ5 BaUpvzpsfY88CTbg+00AOojKwZd9ga+SIpAExudIQUhT7/l63HJ3AR7qjc6BpvG0nDpX etXTF6/3qKStmbF+7yJAYlJyjjxfVr6N7OnjruZA5xhTtNVUUqO6UcqJ7ZRVat77GpL1 v7kRIBk4C7K0gzCpDMT/c2W3ARZ41zZlzTey+uREGAdZcGF/s3YKBGDXMKYYhtwUgbS4 M3sJs3jk5f55dmjYIJunrRjQnuCHbZgJewumA5Yrq9P9eYXzd3nHnoas2DFo/HNXf7Y1 Hs/w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=tG6Sf7Y0; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id 32si1223183edr.270.2020.09.17.20.13.57; Thu, 17 Sep 2020 20:14:20 -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; dkim=pass header.i=@kernel.org header.s=default header.b=tG6Sf7Y0; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726890AbgIRCCz (ORCPT + 99 others); Thu, 17 Sep 2020 22:02:55 -0400 Received: from mail.kernel.org ([198.145.29.99]:48170 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726826AbgIRCCn (ORCPT ); Thu, 17 Sep 2020 22:02:43 -0400 Received: from sasha-vm.mshome.net (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id C7F2B2376F; Fri, 18 Sep 2020 02:02:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1600394562; bh=7LXURWva2hr25lWX5PhgyRYZqNDi63uIDEJvA5/Ru90=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=tG6Sf7Y0KBnNreRQwrQZRhAb5pMNAv1tPzEa7YGbMMqqNdqIayZ0eeTykLz8FlcRT wcsseMWqkrH2/skflNi/bHuqX6k/d2+0IhlvfwvUszVNa1f+6lS6eu0vP2Emz27Uzf QeTEBqpDU9bICF61aQLClbx2Hn1WpmpsplMYA6OU= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: "Steven Rostedt (VMware)" , Jessica Yu , Divya Indi , Peter Zijlstra , Sasha Levin Subject: [PATCH AUTOSEL 5.4 075/330] module: Remove accidental change of module_enable_x() Date: Thu, 17 Sep 2020 21:56:55 -0400 Message-Id: <20200918020110.2063155-75-sashal@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200918020110.2063155-1-sashal@kernel.org> References: <20200918020110.2063155-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: "Steven Rostedt (VMware)" [ Upstream commit af74262337faa65d5ac2944553437d3f5fb29123 ] When pulling in Divya Indi's patch, I made a minor fix to remove unneeded braces. I commited my fix up via "git commit -a --amend". Unfortunately, I didn't realize I had some changes I was testing in the module code, and those changes were applied to Divya's patch as well. This reverts the accidental updates to the module code. Cc: Jessica Yu Cc: Divya Indi Reported-by: Peter Zijlstra Fixes: e585e6469d6f ("tracing: Verify if trace array exists before destroying it.") Signed-off-by: Steven Rostedt (VMware) Signed-off-by: Sasha Levin --- kernel/module.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/kernel/module.c b/kernel/module.c index 0e3743dd3a568..819c5d3b4c295 100644 --- a/kernel/module.c +++ b/kernel/module.c @@ -3753,6 +3753,7 @@ static int complete_formation(struct module *mod, struct load_info *info) module_enable_ro(mod, false); module_enable_nx(mod); + module_enable_x(mod); /* Mark state as coming so strong_try_module_get() ignores us, * but kallsyms etc. can see us. */ @@ -3775,11 +3776,6 @@ static int prepare_coming_module(struct module *mod) if (err) return err; - /* Make module executable after ftrace is enabled */ - mutex_lock(&module_mutex); - module_enable_x(mod); - mutex_unlock(&module_mutex); - blocking_notifier_call_chain(&module_notify_list, MODULE_STATE_COMING, mod); return 0; -- 2.25.1