From nobody Sat Feb 7 21:15:20 2026 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (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 32CB2F513 for ; Sun, 25 Jan 2026 16:07:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769357263; cv=none; b=tpOYcUGucwCTqfye5qMI9V1jm5jTdbf/bSdxzzZy94fvFildD40e5gWZwqT1PyXggcriNEVczwysP5Rvf8P5WayWfOKnhyLp/aPH1JC6HXwNtuk65H7Fg0SGrTOgAjIfEbih3xaFMPZVnalAUyeLUNk/D6pIjzYoJwBFzj2sQDQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769357263; c=relaxed/simple; bh=1lGyYdRNHkzunJkfjyz57W92tLBgj8dcgac0gWPppr4=; h=Date:From:To:Cc:Subject:Message-ID:MIME-Version:Content-Type: Content-Disposition:In-Reply-To; b=IGZKmeCpOoHfc+IqHw/Ehky4/MZXkLDA3aOUgmoP+PyyMA4v9L5E3Vqt3iPVBCRuHrF0nssfdCbAMKnEE0ZI1S+riwAlu8DAtF5ad3CampDcIuJD7w6Pkach+az7es5lHJyv1BkW2lcSJSixhrzO5k3dp8s0vSSPZM/RLc5/1G4= 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=A+wOi+sl; arc=none smtp.client-ip=170.10.133.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="A+wOi+sl" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1769357261; 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: in-reply-to:in-reply-to; bh=aojbJJ5FzMzE2HJE4QEerULCpiKv5AGEyOIjsVq7b3Q=; b=A+wOi+slVatp38lrcnDoUrXmLlVqKCZ0mnfw7awmcdnzlCIil8oZiNseMdtlwypjYmZfwI fMKbMF/0lfmHe3ASaKt8IIozyeLGeS/WI8hbhrEjplUZ14OvWnJ0wmFKiC4aCMV0Imewbo HboLSoIsvPAp18GWxixQxRL/YJul8LQ= Received: from mx-prod-mc-06.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-632-m897L2klPTqHE3h_lcyBAg-1; Sun, 25 Jan 2026 11:07:38 -0500 X-MC-Unique: m897L2klPTqHE3h_lcyBAg-1 X-Mimecast-MFC-AGG-ID: m897L2klPTqHE3h_lcyBAg_1769357256 Received: from mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.12]) (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-06.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id E58761800451; Sun, 25 Jan 2026 16:07:35 +0000 (UTC) Received: from fedora (unknown [10.45.224.8]) by mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with SMTP id D7B8A1958DC4; Sun, 25 Jan 2026 16:07:29 +0000 (UTC) Received: by fedora (nbSMTP-1.00) for uid 1000 oleg@redhat.com; Sun, 25 Jan 2026 17:07:35 +0100 (CET) Date: Sun, 25 Jan 2026 17:07:28 +0100 From: Oleg Nesterov To: Andrew Morton Cc: Alice Ryhl , Boris Brezillon , Christian =?iso-8859-1?Q?K=F6nig?= , Felix Kuehling , Leon Romanovsky , Steven Price , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Simon Horman , linux-kernel@vger.kernel.org, amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-rdma@vger.kernel.org, netdev@vger.kernel.org Subject: [PATCH v2 3/7] drm/amdgpu: don't abuse current->group_leader Message-ID: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Scanned-By: MIMEDefang 3.0 on 10.30.177.12 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Cleanup and preparation to simplify the next changes. - Use current->tgid instead of current->group_leader->pid - Use get_task_pid(current, PIDTYPE_TGID) instead of get_task_pid(current->group_leader, PIDTYPE_PID) Signed-off-by: Oleg Nesterov Acked-by: Felix Kuehling --- drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c b/drivers/gpu= /drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c index b1c24c8fa686..df22b54ba346 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c @@ -1421,7 +1421,7 @@ static int init_kfd_vm(struct amdgpu_vm *vm, void **p= rocess_info, goto create_evict_fence_fail; } =20 - info->pid =3D get_task_pid(current->group_leader, PIDTYPE_PID); + info->pid =3D get_task_pid(current, PIDTYPE_TGID); INIT_DELAYED_WORK(&info->restore_userptr_work, amdgpu_amdkfd_restore_userptr_worker); =20 diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/a= mdgpu/amdgpu_vm.c index a67285118c37..a0f8ba382b9e 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c @@ -2554,7 +2554,7 @@ void amdgpu_vm_set_task_info(struct amdgpu_vm *vm) if (current->group_leader->mm !=3D current->mm) return; =20 - vm->task_info->tgid =3D current->group_leader->pid; + vm->task_info->tgid =3D current->tgid; get_task_comm(vm->task_info->process_name, current->group_leader); } =20 --=20 2.52.0