From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.127.230.115 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796208301; b=AuscvxG551geieZ0nQZts4B9GCivocWw16vdeKEOe6wMaFO/7TMfNXWNeyU8htD6pZJq k+W9Q1RxfNIvih/KtBiDAs0ntIWzKJjcr8VqEfgrjUxXIbSDu3etP5JtmXAFASSh09P8u sHoiKCGWQ0wPCQuDV1XDx56OaGEk60TNzcUsAktdM6vrmbaDzMRHYHhB1XHUzZU5Mcq0q fWC48UpsEixjafBZkX/9z2YjXKrWxJURGvKcAGGBi9yf81/9SFVTzeG3q8I3uBTaXpxE0 fOiYnkuZ2DafPmgYU/JT72FALX/ksVr37CLuhHW/8SqHf2zu8om5QI6vPNJSant3sLA== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796208301; h=DMARC-Filter:DKIM-Signature:From:Subject:Message-Id: X-Lms-Return-Path:Content-Transfer-Encoding:Content-Type:Cc:Date: Mime-Version:X-Mailer:To:X-Original-From; bh=bU0L7oUUKhWt1SAC7xcULIc26i4/ksIAVWY5mVdd/NQ=; b=RUKNMVGjiNjyqZgx48E6Z17CIYy92ShbPqjf8rTIp/hI1xvA7afbxEN1LHAYLCHP7eXu hZqxIBK/GIbWm9bcBEKQOtsaPlo9pNpnZh0pNGDoaTVrrd5vhOWXIk7TLG04MGOVculsJ CQlrV/eymeV6/g4eAMhEZozW5vP1GmiTMotUIlPLNcyzECvXLNgsP0NFlkWuqvKn9HG69 +NCQBSugR+meZUp5/Fp8+LfsPOgft6lrzfb/D3fZfCG5Z/xwtEMLug9xN5DPpGyKc66pW xGipNWChrgTyNYEiQl6WjnfmVXwqwu0MhARziKh9PZK2rIVHtP281kaW8M/fzqZNztg== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=bytedance.com; spf=pass smtp.mailfrom=bytedance.com; dkim=pass header.d=bytedance.com header.i=@bytedance.com header.a=rsa-sha256 header.s=2212171451 header.b=nSh7N8v8; arc=none smtp.remote-ip=209.127.230.115 Received: from va-1-115.ptr.blmpb.com (va-1-115.ptr.blmpb.com [209.127.230.115]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6010B606A693 for ; Wed, 2 Dec 2026 10:44:59 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 6010B606A693 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=bytedance.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bytedance.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=bytedance.com header.i=@bytedance.com header.a=rsa-sha256 header.s=2212171451 header.b=nSh7N8v8 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; s=2212171451; d=bytedance.com; t=1796208294; h=from:subject: mime-version:from:date:message-id:subject:to:cc:reply-to:content-type: mime-version:in-reply-to:message-id; bh=bU0L7oUUKhWt1SAC7xcULIc26i4/ksIAVWY5mVdd/NQ=; b=nSh7N8v8XsfdaX1hgdLokxfeNeXheAQ+SUUvSGGfPOP3nC8vplS6Oc0Ots7rUOra3441QD iWzZtSD5X/7odnvVxB0pJVwGsp3mlRaK+R9uu+0cm5mB/x86LzcrfvSgO7RxIf6YyJkAX5 k936dbdFWvhAUrBgkMeP7TVRetKRHKhKWOW4HAPmmTHPzWNMvl5kclI033XfkMvOjwUITc I2B05AoYDxNBX3x+L0cYJhX7sM2/1DxVrpQSoV8+OZBR44PgqBXqMmA84JdQ070CECyx3H RzUM5B+LAlSvyr1nF0X+mdwXmnss9FQhvckAvD516aF+gxoA6mxRig8N4G897g== From: "Chuyi Zhou" Subject: [PATCH 0/2] cgroup/cpuset: Limit v2 sibling checks to nonempty exclusive masks Message-Id: X-Lms-Return-Path: Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=UTF-8 Cc: , "Chuyi Zhou" Date: Wed, 2 Dec 2026 18:44:19 +0800 X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list Mime-Version: 1.0 X-Mailer: git-send-email 2.20.1 To: , , , , X-Original-From: Chuyi Zhou This series follows up on "cgroup/cpuset: Skip sibling checks for v2 members without exclusive CPUs" [1]. On v2, validate_change() skips the sibling walk only for members whose cpuset.cpus.exclusive stays empty. Ridong pointed out that the walk can be skipped whenever the proposed exclusive CPU mask is empty [2]. An empty mask cannot overlap a sibling's exclusive CPUs or contain a sibling's nonempty allowed CPU mask. Only the top cpuset is memory-exclusive on v2, and it has no siblings. Patch 1 skips the sibling walk for partition roots with an empty explicit exclusive CPU mask and for cpusets that clear their mask. Patch 2 separates the v1 CPU and memory checks from the v2 CPU checks so the hierarchy is selected once before the sibling walk. [1] https://lore.kernel.org/lkml/7b9ec8acd1d5fbc2e977ac08450aaf5de5952ce0.1796039668.git.zhouchuyi@bytedance.com/ [2] https://lore.kernel.org/r/825c0c94-8565-4c4c-82c7-9c0f5872e6a9@linux.dev Thanks, Chuyi Chuyi Zhou (2): cgroup/cpuset: Skip v2 sibling checks with an empty exclusive CPU mask cgroup/cpuset: Separate v1 and v2 sibling exclusivity checks kernel/cgroup/cpuset-internal.h | 6 +-- kernel/cgroup/cpuset-v1.c | 36 +++++++++---- kernel/cgroup/cpuset.c | 90 +++++++++++++-------------------- 3 files changed, 62 insertions(+), 70 deletions(-) base-commit: d2184674694f407e88b378f1f99b88d20e01d9da -- 2.20.1