From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5EA9A1A682F for ; Sun, 29 Mar 2026 17:27:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.129.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774805280; cv=none; b=JQjPonq7BpmFrCJXSoZoFeN/Ys4xbUO2t8sLDUkNvheegpkud33c4wsLleqks9lvIfsZPsSwjvuiq7wpCtRf1/Q+CrS55Wdfa71WW8unDr240xdHeGDtw+s5xszZVvj8rOf8a9EfcpYdUhGYjOj0EGRKO3oke3TCzSaNLPe3wqA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774805280; c=relaxed/simple; bh=FBK16IFbceRoUPVqR007h8YWl7ntSE2Sz/VaT1hYlAw=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=PBsivhJvlAOIYebPDPnj5O3uQ6nNI74N8DGOnHRWRTk7D+9O6bVnY05NSRVKxY0TesC8jxEjEAuMVY++4rSMN46WhnlCcPE4W5bJf0dwiU4/2pGCwgaKsiDS4aJgeg6crLvH4YJuqR0XKt3m5MizqmCWWIO8HRpQGBbYW5AzbAc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=Q/7apRJk; arc=none smtp.client-ip=170.10.129.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="Q/7apRJk" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1774805278; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ai8AsVLXijVWDN/d10Bl+3Vl9B1BnDDB1K/ob97G5vc=; b=Q/7apRJkwUPnBpQj7GujJuHkh2BSqC/dAIuZAghkOxuHgwJFAdqesMM5UPNlW7uf7bgcz9 eqVkEjwDe46EwocN57A2i100IbvWGPCDTS632uAJ1Kmx/PgRNqw73uwQUBQdNFbytOvy6s 2Egq2BAyJO3hImloRNOxw1DajZwCqSI= Received: from mx-prod-mc-08.mail-002.prod.us-west-2.aws.redhat.com (ec2-35-165-154-97.us-west-2.compute.amazonaws.com [35.165.154.97]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-611-rFMsIPzqMO6rV2UZsusW9w-1; Sun, 29 Mar 2026 13:27:56 -0400 X-MC-Unique: rFMsIPzqMO6rV2UZsusW9w-1 X-Mimecast-MFC-AGG-ID: rFMsIPzqMO6rV2UZsusW9w_1774805275 Received: from mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-08.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id B90FC1800344; Sun, 29 Mar 2026 17:27:54 +0000 (UTC) Received: from [10.22.80.75] (unknown [10.22.80.75]) by mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 3376630001A1; Sun, 29 Mar 2026 17:27:52 +0000 (UTC) Message-ID: Date: Sun, 29 Mar 2026 13:27:52 -0400 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] cgroup/cpuset: Skip security check for hotplug induced v1 task migration To: Chen Ridong , Chen Ridong , Tejun Heo , Johannes Weiner , =?UTF-8?Q?Michal_Koutn=C3=BD?= Cc: cgroups@vger.kernel.org, linux-kernel@vger.kernel.org References: <20260327201546.2463644-1-longman@redhat.com> Content-Language: en-US From: Waiman Long In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.4 On 3/27/26 9:39 PM, Chen Ridong wrote: > > On 2026/3/28 4:15, Waiman Long wrote: >> When a CPU hot removal causes a v1 cpuset to lose all its CPUs, the >> cpuset hotplug handler will schedule a work function to migrate tasks >> in that cpuset with no CPU to its parent to enable those tasks to >> continue running. >> >> If a strict security policy is in place, however, the task migration >> may fail when security_task_setscheduler() call in cpuset_can_attach() >> returns a -EACCESS error. That will mean that those tasks will have >> no CPU to run on. The system administrators will have to explicitly >> intervene to either add CPUs to that cpuset or move the tasks elsewhere >> if they are aware of it. >> >> This problem was found by a reported test failure in the LTP's >> cpuset_hotplug_test.sh. Fix this problem by treating this special case >> as an exception to skip the setsched security check as it is initated >> internally within the kernel itself instead of from user input. With that >> patch applied, the cpuset_hotplug_test.sh test can be run successfully >> without failure. >> >> Signed-off-by: Waiman Long > Should we add a Fixes tag? The call to security_task_setscheduler() was added a long time ago and the cpuset v1 task migration is more like a corner case that shouldn't normally happen. So I don't want to put a fixes tag that will force a backport to earlier stable releases. Cheers, Longman