From nobody Tue Dec 16 05:40:20 2025 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DF6B7223701 for ; Tue, 14 Jan 2025 23:15:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736896520; cv=none; b=sE4jqCElqnoCqWiJDz99wdrtJ7O0T0dQVApDMR4vqoE09j3ZCopUZA4OHsUMr7GIo0PuuRoXHXw/PhwHo+mxeYJ6EPTFZ2WU+GefNfd0o0e51B0uyPmEHzbX1jirooHOc8EiJrp8fNou92Z1TtNG95L5hVNY+mjzd1ZB0963scI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736896520; c=relaxed/simple; bh=sWUWAF396kiMsEfoNAL5bSK9ZkpcgbDFPSBBHHw4b90=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=bdbUBIL5n4M0CVjNYmCs/NBWWAPiUxOhWzzc16DsicqvSZxhGiCvblytIqx0Q8EzyRO6nVHzhYlVPaTwff/r6BagDOrXxPso9cg+1DTIiTzUbupUIJ/vvBm/xxrDRomDXGrZSrYqW/zqgtcPYr3J8tHnmDhJXvueoY6VHlq88KQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=VDuUDRl6; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="VDuUDRl6" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 67BBCC4CEDD; Tue, 14 Jan 2025 23:15:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1736896518; bh=sWUWAF396kiMsEfoNAL5bSK9ZkpcgbDFPSBBHHw4b90=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=VDuUDRl614Bl0+2dKvwwYXd8wbkWGC8G/nfDNCDWvxcMFIwHsdZemKC1Ug23LHNCF zDU+vx+WAQbY4hsBUNFIJjwEi3zv2iA+9h03IJebp1uUL/ghxj1VvFx0lyZcCzdOMW m21T8igTXtQSM0P6QrQp503BKIVi4Kv5jxmc1JoP2H7xT04qTcTnMTKgmt8qqj88hr tuzM++61o1NP5IvQ98z4P1HIDMyL3fO/9UH9tIaA2g4U+tYKhJhu+E09xg4IjfvATG /pybvPR+Tg63Zz/ypR/1ovIM/yVhcgMolJuOKnJGI5yN2Zpqz/9Js+GJOmMhQhUPYD QMf1/onpTjY5g== From: Frederic Weisbecker To: Thomas Gleixner Cc: LKML , Frederic Weisbecker , anna-maria@linutronix.de Subject: [PATCH 4/4] timers/migration: Simplify top level detection on group setup Date: Wed, 15 Jan 2025 00:15:07 +0100 Message-ID: <20250114231507.21672-5-frederic@kernel.org> X-Mailer: git-send-email 2.46.0 In-Reply-To: <20250114231507.21672-1-frederic@kernel.org> References: <20250114231507.21672-1-frederic@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Having a single group on a given level is enough to know this is the top level, because a root has to have at least two children, unless that root is the only group and the children are actual CPUs. Simplify the test in tmigr_setup_groups() accordingly. Signed-off-by: Frederic Weisbecker --- kernel/time/timer_migration.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/kernel/time/timer_migration.c b/kernel/time/timer_migration.c index 066c9ddca4ec..9cb9b6584ea1 100644 --- a/kernel/time/timer_migration.c +++ b/kernel/time/timer_migration.c @@ -1670,9 +1670,7 @@ static int tmigr_setup_groups(unsigned int cpu, unsig= ned int node) * be different from tmigr_hierarchy_levels, contains only a * single group. */ - if (group->parent || i =3D=3D tmigr_hierarchy_levels || - (list_empty(&tmigr_level_list[i]) && - list_is_singular(&tmigr_level_list[i - 1]))) + if (group->parent || list_is_singular(&tmigr_level_list[i - 1])) break; =20 } while (i < tmigr_hierarchy_levels); --=20 2.46.0