Received: by 2002:a05:7412:9c07:b0:fa:6e18:a558 with SMTP id lr7csp48645rdb; Fri, 26 Jan 2024 18:21:50 -0800 (PST) X-Google-Smtp-Source: AGHT+IF5cMPUYF4YhzB/M4CKIEIWQHogKQlWBnfCwU9Y53UE6baTxurwscC/9vLnosWltESfytTy X-Received: by 2002:ac2:5331:0:b0:50e:75f8:ac9f with SMTP id f17-20020ac25331000000b0050e75f8ac9fmr877176lfh.28.1706322110327; Fri, 26 Jan 2024 18:21:50 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706322110; cv=pass; d=google.com; s=arc-20160816; b=JenlAdtONbULY/cY3rj0WI4JMgU/z2MNVem/AffI7ydvlcJVyJT/aiQwDdw8iOgn7f h24eLmFNimlQJlxN35DrXk4iLdXUjJZxwVE1nUTpk3y9VXevW5pVwfqhsEhbnPPC78Lq d82o2dS81zNeUPZwFJCn71lPbsj79ZmKnt1mITgquh3D/YRXIU7I+PjWCuXgFq4FsKgK 9aWa7ghpHuACXWavh+AnKjti00O1LMfWzMKViTjs3DNl1U10ou2jodWP/Uq0R3XinJPM 6cp1IGMBQgC04XJ5ZADw5uevz3W1OYR2OjuUMbiytdCbBo02za2HpTmMfn1TQNbF+nmj KZmA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=3mxHfQelYlqL6oP1Hnoe6QZezCLAhWkLAbAnrEYZUDY=; fh=G5DaSdor7MropyFk0CA4E4srFTXsRWsLAIC8xcZLlO4=; b=K2dLVc3uVU/DdR4XIa0sbhlOFEt2YhqGwdd9pLpsJn51DGQMK+izUhWs31dnYgikoU uWsa0O8tgJrnn1UpF469hkjr6J8ZHOOg8EQj4uIou9sExClda7ZMmnbB3MKKPmB5UIer bnsNW4XbsesLwtjPJlO5/X0iWlxC5q7ViW31xdfxsx8MRuffMkQ0Z6efDkOTpBxfbEj7 lIxKfid4N3bNqjyJQa+AZVDceujjywtG9wnSefhNfXoGMAjc/GKP6D9HuCj77fJnUqlJ MF+1KPOK43es2DM+xsp/HUEoVUes3EtFkOSeMx8w4xDmpKKxtlyX3Di5K1KqG5Mm4K3Y hVow== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=OSEMzeJT; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-41009-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-41009-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id gg4-20020a170906e28400b00a3193803d20si1138389ejb.126.2024.01.26.18.21.50 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 26 Jan 2024 18:21:50 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-41009-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=OSEMzeJT; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-41009-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-41009-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 9AFC21F2AB62 for ; Sat, 27 Jan 2024 02:14:42 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D670A13FE7; Sat, 27 Jan 2024 02:08:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="OSEMzeJT" Received: from out-171.mta1.migadu.com (out-171.mta1.migadu.com [95.215.58.171]) (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 26494125A7 for ; Sat, 27 Jan 2024 02:08:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.171 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706321324; cv=none; b=YUKlaExRXWSD6dXlZ/pwyNeIFcq7EnZiW7iGr7hihcFQCoWPEuiokpvhrN2nxyvhb7o6K0XcqKWlGHmC19IoaukmLN/BNqp36jFeX7EUxOR2RtBrwEkR3rbSeqxme0jAu6ubWu50kisI28proLxp0axBCm+iYRFDpzLJaXpwIFA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706321324; c=relaxed/simple; bh=iy4bbPlcTHR5BujKxgwpeH6pLrpzI4Fhpz5iOUvrDBk=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=Vd5HwkspCwUvu4symr9b0Y/ZVMFaS2VE7UnQa6sMgCpmE6Fq/aA9BQ9dHdZNhDY5Qc7jClssdz+ehODNHbNmZzW6OFtBW//FtKO88Jm3iUhwvCQVjPTVNZ8XZUOSi+YhkvLlehX33oJLFFhnrYKePyN8VlYIsbCJb6KElIUHcCI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=OSEMzeJT; arc=none smtp.client-ip=95.215.58.171 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1706321320; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=3mxHfQelYlqL6oP1Hnoe6QZezCLAhWkLAbAnrEYZUDY=; b=OSEMzeJTWSmablzulvFvVfNX5hGQRamLGo2HX4EUeO9P2OMLBXPodf+HaSi4Ws2B10k6FB LFdSHAH/6v9tW82PDrv8NhWtuj3XCcRtl9PWY27sYpY2Lbr7fmLbShK9BjrQyPNEZ5BKeG R6aEmWU7ZAd9wBrxp91RNt6GZyYPJP0= From: Kent Overstreet To: linux-kernel@vger.kernel.org, netdev@vger.kernel.org, linux-fsdevel@vger.kernel.org Cc: Kent Overstreet , peterz@infradead.org, boqun.feng@gmail.com Subject: [PATCH 0/4] lockdep cmp fn conversions Date: Fri, 26 Jan 2024 21:08:27 -0500 Message-ID: <20240127020833.487907-1-kent.overstreet@linux.dev> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT rationale: *_lock_nested() is fundamentally broken - in order for lockdep to work we need to be able to check that we're following some defined ordering, and it's not possible to define a total ordering of an arbitrary number of objects with only a small fixed size enum. so it needs to go. awhile back I added the ability to set a comparison function for a lock class, and this is the start of hopefully a slow steady trickle of patches as time allows to convert code to use it. Kent Overstreet (4): fs/pipe: Convert to lockdep_cmp_fn pktcdvd: kill mutex_lock_nested() usage net: Convert sk->sk_peer_lock to lock_set_cmp_fn_ptr_order() af_unix: convert to lock_cmp_fn drivers/block/pktcdvd.c | 8 ++--- fs/pipe.c | 77 ++++++++++++++++------------------------ include/linux/lockdep.h | 3 ++ include/net/af_unix.h | 3 -- kernel/locking/lockdep.c | 6 ++++ net/core/sock.c | 1 + net/unix/af_unix.c | 24 ++++++------- net/unix/diag.c | 2 +- 8 files changed, 55 insertions(+), 69 deletions(-) -- 2.43.0