Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2635808pxa; Mon, 17 Aug 2020 15:04:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxJTkvNL5S1kkYAOO99kdGu0hlVMzG19kHdRXDQEXpkC3yTcbjOeo06EjpLDGod0O7E58wJ X-Received: by 2002:a05:6402:1c88:: with SMTP id cy8mr17486914edb.24.1597701884766; Mon, 17 Aug 2020 15:04:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597701884; cv=none; d=google.com; s=arc-20160816; b=UZLLrcue8z5ZQ1VHr8CrDiye5DVKUZIv1AEEey0QDqN8NDiyHV7eQ8TxneDvODx+mY TGaorOybcV0enYrY9yrONg6lkqLhI3brDqNOIvdSE2KQ5c0HskD0pY6GacIRe5ZG/ALw x6TuB2QJ/R9rwAtyUQXjpRIznc0Us1cnpXns4qUQ0XqtFUIPQ6iSNg3g8XILgFjAgfrL wCb+HouPz6lpQ0QebWzBmovnqv0r42kbanfQpf3s6pyi0RPlwTA4DCMm5dNkihszs1dX jlA43LV5mBupEwouIqsj0kHTkcly0j8/q+a5AjeLKSLW3+2thJzpF/8obB7b7A6w9mo4 nwxQ== 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=rRNaNhanlgKCao0PwGw7WSl5Mao9/kqwcqqdhxTE/Lw=; b=MYYY9bUfcnEjeX17x4nmNL0YsaUAPFXQea2xeMospJU89yojA/9fjOYItPacWinddA ge/D4iQ0kZ0qDPGbTIzwsfyhtZNVZsUFGD5rArMtOfTZo6lLQKllZ0RVz39BoyA1cHc9 lAhW7HbAtmj5pVZH2N8zaieDu5V1qMUUm0mmBkd6ScM+8eTr6x3w6sZ55oPek04GxOEn KOqU7OizVUf/+cZAyG9XkSx/Dk2b6835egbbtd1vSQBZ2+9fX7/1AX/ToEp/RQFBYyKJ jE4XrIsyz0EBuCKAsWCf/zLZdvzwetXczw5yBePlEx+VLul73ZG0yesCj5mhv1cIZxtV Ts2Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=2rnHbxHL; 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 gh12si12221873ejb.75.2020.08.17.15.04.20; Mon, 17 Aug 2020 15:04:44 -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=2rnHbxHL; 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 S2387896AbgHQPxI (ORCPT + 99 others); Mon, 17 Aug 2020 11:53:08 -0400 Received: from mail.kernel.org ([198.145.29.99]:49976 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730684AbgHQPks (ORCPT ); Mon, 17 Aug 2020 11:40:48 -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 90B8E207DA; Mon, 17 Aug 2020 15:40:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1597678848; bh=TKxSJQ7vNumH47O7qPfVFf/C+OEWYUJDGaHXT7FsDWo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=2rnHbxHLuApF8P/a+GnvHvJnUl7P1HMEINlMn7KLe8ZLmXqxOUIc/MLUFjywhzj2W P3C4w7RFm43eNucIegLbdACgkZCKonet46e7fY/weYqu16fSrX44Gsm8vx6UFmBoqf M38vpyfUpk0CrhqOMTvy1S3obTLk2q4uPfVNQHDM= 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.7 011/393] sched: correct SD_flags returned by tl->sd_flags() Date: Mon, 17 Aug 2020 17:11:01 +0200 Message-Id: <20200817143820.146094440@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200817143819.579311991@linuxfoundation.org> References: <20200817143819.579311991@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 8344757bba6e6..160178d6eb20e 100644 --- a/kernel/sched/topology.c +++ b/kernel/sched/topology.c @@ -1338,7 +1338,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