Received: by 10.213.65.68 with SMTP id h4csp648881imn; Fri, 6 Apr 2018 06:45:12 -0700 (PDT) X-Google-Smtp-Source: AIpwx49ROkb8XA+KLlztfIEkPz6eNFrSdCOwz2jS4+oKv3lcG+L4iE5OJ0p6U1yVdkCgBtP9j4do X-Received: by 2002:a17:902:3124:: with SMTP id w33-v6mr9222077plb.335.1523022312365; Fri, 06 Apr 2018 06:45:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523022312; cv=none; d=google.com; s=arc-20160816; b=DFkti9LJSO+NryNDkhzXAOlDPs3kUZcYLbRM4yRu6kMGM/5wMvFUVapznPxjemDTq4 SuDdNhhWphmDDIEGLdYmKMzI0688NhpTSs2iszfZhAw2P7eUBhnKARFuV/hvY/qoBuxI WzypPG6ZPF9vHyfwxBO49mtnLYjAh3eayh98Ua8d8LSujyQREFsj8EUchO5JOyK8GVBx ovpBygqc0/KmDm26UninKiQ8FCFxFqS9pA4zS3SNW6paZNX3q61EhZsTQhTRisDE7jwr vNmS8ytAjvRBSa4ZLCtcav1/5uG8TZzFrA1xexKylMfvwRsw75+AgKFbkY9cD4Aa/3/V GkoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=VmPE82swfQMfgEBXzzmg4KywVpJi45YSQQkYHG/A7EI=; b=Wt8fggBIn/6nlJUyS84nKtlxbG77WI3m504ZB756BCp2bIAm7cFozvmiW3+aDmG/m/ aVFzEMkglnbq8D0fE1NdJrgVCUXm1kqYh6h27FZD8s/IIlN/hN2wTILMSTctdh2Veaqz 7ldj2hpyLWT2IDFj+utuKa6o7DdAUd2fs3WKecyBQv8/mqH9ttKZg8b5K5yEvd7xXyDH eFcAOz17YVzch5kA6LM510Zg9okUT4+mvVRCTyLGy1YaRNHiq0UyFUS0kS6kPBgwl9Qs njI+1ETxAsDZ3J72JtkG6ZbUiRv7NGzMI/vTuGAHzpMWo3evVtQGrJYWAOpU+eDvtqkJ VdKg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z85si8052845pfk.194.2018.04.06.06.44.58; Fri, 06 Apr 2018 06:45:12 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756829AbeDFNnw (ORCPT + 99 others); Fri, 6 Apr 2018 09:43:52 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:37454 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756820AbeDFNns (ORCPT ); Fri, 6 Apr 2018 09:43:48 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 527E1E04; Fri, 6 Apr 2018 13:43:47 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Ben Hutchings , "Rafael J. Wysocki" , Viresh Kumar , Sasha Levin Subject: [PATCH 4.15 71/72] Revert "cpufreq: Fix governor module removal race" Date: Fri, 6 Apr 2018 15:24:46 +0200 Message-Id: <20180406084354.127651972@linuxfoundation.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180406084349.367583460@linuxfoundation.org> References: <20180406084349.367583460@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Greg Kroah-Hartman This reverts commit a853301f77b5c4feb5e17aebfd92018269525523 which was commit a8b149d32b663c1a4105273295184b78f53d33cf upstream. The backport was not correct, so just drop it entirely. Reported-by: Ben Hutchings Cc: Rafael J. Wysocki Cc: Viresh Kumar Cc: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- drivers/cpufreq/cpufreq.c | 6 ------ 1 file changed, 6 deletions(-) --- a/drivers/cpufreq/cpufreq.c +++ b/drivers/cpufreq/cpufreq.c @@ -637,8 +637,6 @@ static int cpufreq_parse_governor(char * *governor = t; err = 0; } - if (t && !try_module_get(t->owner)) - t = NULL; mutex_unlock(&cpufreq_governor_mutex); } @@ -767,10 +765,6 @@ static ssize_t store_scaling_governor(st return -EINVAL; ret = cpufreq_set_policy(policy, &new_policy); - - if (new_policy.governor) - module_put(new_policy.governor->owner); - return ret ? ret : count; }