Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2656995pxa; Mon, 17 Aug 2020 15:42:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxFoua6yJZCaUJxKqe1FVz//t4pWwCNzml79fyzYdj2sqfi15Eu3D5J6n4IHdpa+vAUVTdG X-Received: by 2002:a17:907:10db:: with SMTP id rv27mr17134592ejb.350.1597704161042; Mon, 17 Aug 2020 15:42:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597704161; cv=none; d=google.com; s=arc-20160816; b=bUjZTg5GPErFGFL/OaNzj2TELwbLzb9EFyGH3KsqZMDJN8HEGlwGR0M9qR2nU4Jp9B oeWxswGWv2oduYM/jCinBlBdHsvOmImm7+P6WjXm1ORIw4rtjEMzokfgLwULAoSsUWcp kYu9CcXVTdKYHo9lcbtF9mrFfsKDDm2srOcYy/wj9Nh/Z2GclETh97f37mwnY9dF0E2p D3QXFL+iMQ02cKdHiC0OjZN33iKJNMGHMdITRz8B6XO9yDaUREYdRF5Odet1bVjmGSsB 1pRq0rZE0DGGXX9qwzEOyRJOKCTgjQ3YytkTIQuNnpUPHgtS+Majbce/VAFKxLn5U6jf 9cNQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=TiRromxpAtapDPT0cE8QahZ72WLQQk2bVw0/lTfrK+o=; b=qU3pMjdBb8Vquku710QR9ncaeGfel8HyxCohHkapKX694/cVl9Dul5iUlEup2iyQ1+ 7gRPin9t8chzIC2qQbWFo8v8Qgawm9J6ewe+X/NBc/t+TWRi+44OIOIT0se28CRrW6Dd 147tVjC8UggX7RQaDLmBs5rQLOYW9FSno+PRHboGIG4AU6Nceu0SvLIvwdrrBrcEdANV mGR4CPduERpPmTej4OjQEn6KowmMTdSu5fgsiR7oQLwKm9/hqa38FNq7ptxzUgfAAn8i HQsO04GDn9KCw4X+MirMM+Bs9s/F3dzImqrPUR71x3r0K1TXMksea53vjGyGr343wJCZ P42A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=wrdtmYo6; 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=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id za3si11947912ejb.312.2020.08.17.15.42.17; Mon, 17 Aug 2020 15:42:41 -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=wrdtmYo6; 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=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391164AbgHQScx (ORCPT + 99 others); Mon, 17 Aug 2020 14:32:53 -0400 Received: from mail.kernel.org ([198.145.29.99]:47142 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387595AbgHQQAq (ORCPT ); Mon, 17 Aug 2020 12:00:46 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 470CB206FA; Mon, 17 Aug 2020 16:00:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1597680045; bh=1Oa/cdJIHN1hAGIODgcRkLPdFTelsOY1qaCvCXkRJgc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=wrdtmYo6DN20iOUxoHTKjJYGw86Sx4kce4WvtuzqwP/KfG5VHWsbe6Zcjhe/WLqxl TuJ6kFO9F46KVzLC8UcFsQ4VCvbh0K2cjY3Gk9zi/TVmxXbc0sh9V9qUC4V92JLM/e ynrJWFePOD7tVG1WY4POaWPBulj7qn/Xr3cCo8Ak= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Peng Liu , "Peter Zijlstra (Intel)" , Vincent Guittot , Valentin Schneider , Sasha Levin Subject: [PATCH 5.4 008/270] sched: correct SD_flags returned by tl->sd_flags() Date: Mon, 17 Aug 2020 17:13:29 +0200 Message-Id: <20200817143756.219530666@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200817143755.807583758@linuxfoundation.org> References: <20200817143755.807583758@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Peng Liu [ Upstream commit 9b1b234bb86bcdcdb142e900d39b599185465dbb ] During sched domain init, we check whether non-topological SD_flags are returned by tl->sd_flags(), if found, fire a waning and correct the violation, but the code failed to correct the violation. Correct this. Fixes: 143e1e28cb40 ("sched: Rework sched_domain topology definition") Signed-off-by: Peng Liu Signed-off-by: Peter Zijlstra (Intel) Reviewed-by: Vincent Guittot Reviewed-by: Valentin Schneider Link: https://lkml.kernel.org/r/20200609150936.GA13060@iZj6chx1xj0e0buvshuecpZ Signed-off-by: Sasha Levin --- kernel/sched/topology.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/sched/topology.c b/kernel/sched/topology.c index 1fa1e13a59446..ffaa97a8d4051 100644 --- a/kernel/sched/topology.c +++ b/kernel/sched/topology.c @@ -1333,7 +1333,7 @@ sd_init(struct sched_domain_topology_level *tl, sd_flags = (*tl->sd_flags)(); if (WARN_ONCE(sd_flags & ~TOPOLOGY_SD_FLAGS, "wrong sd_flags in topology description\n")) - sd_flags &= ~TOPOLOGY_SD_FLAGS; + sd_flags &= TOPOLOGY_SD_FLAGS; /* Apply detected topology flags */ sd_flags |= dflags; -- 2.25.1