From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.13]) (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 C8D2B1F5617 for ; Thu, 20 Nov 2025 11:04:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.13 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763636676; cv=none; b=gprbmsGLRviveSfwpMmKPLfCZPTSXKKNCWdzdP8AjD8nyQWxZbpKe1sLIZRGr5+9b2KAQ8s35LTUHtSTD+hHORa33T9AjYg1E2GQMb7Zik8sCiW5v6edXFKMj+lvfLQxLKtaBNQBYeLhXiaHLffC72N6JFXbrGXJEYl3lsmJKzA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763636676; c=relaxed/simple; bh=qY4iz8vRxeI2vbkflJyrv/cHwEXqr2dgwNE/Eha7pEw=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type; b=A7DFC8tPExqjK49Wu151C2yWq3NL65HZozE0BmMeL920se5ZzcfXj+TjnoA6d0CGW2LOois/oTcPqlPg3gubOzEZRoqMLcevXFfHZAWjGiD1/wroFMhcjUIjrbCRY2bi8lhSgeqlZAhNTN5LlBchq79WYSC4XiO37v8sRta9vxM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=pass smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=h43GKWX3; arc=none smtp.client-ip=192.198.163.13 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="h43GKWX3" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1763636675; x=1795172675; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=qY4iz8vRxeI2vbkflJyrv/cHwEXqr2dgwNE/Eha7pEw=; b=h43GKWX3NCO8LDRXJnqiar/atVWn3Wke46uv1Mryp6JsOxM05rhxffGS SaWfv9FiJjGqNGAghSbAirZ4Y0xC5kuOFeD+e6m9KH8vM6ewa/H5qxXc+ KMpRlJlVnjPqMxwsk+PGIasWwRG9greMewenAYLIy8urI3yavnNcazC3r E1XBKU+M2ZOfIPB7YtZrsp6pi2rnHcNryzFsbqojiE9+3crLMIiaT5NEv EqrxR7KuyHVPxPRFCdRerojfQGIQkbqq8wJa1CZLPOUc6HS8Mscq36iZk ADpehAMPI3rF089h8QctDUmzPEDc2TE/7cvWbUeiYvmABo0KbC4VbU/vq Q==; X-CSE-ConnectionGUID: xtB79bJZSr2munJ+vW+XAQ== X-CSE-MsgGUID: vS4FKlCiSdGCPDwrdvOAsA== X-IronPort-AV: E=McAfee;i="6800,10657,11618"; a="68307986" X-IronPort-AV: E=Sophos;i="6.19,317,1754982000"; d="scan'208";a="68307986" Received: from orviesa001.jf.intel.com ([10.64.159.141]) by fmvoesa107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Nov 2025 03:04:34 -0800 X-CSE-ConnectionGUID: slshScBUT3qTys+qrixn+Q== X-CSE-MsgGUID: i4D01uSBTaei2uUY9iTRTQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.19,317,1754982000"; d="scan'208";a="228643691" Received: from agladkov-desk.ger.corp.intel.com (HELO fedora) ([10.245.244.142]) by smtpauth.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Nov 2025 03:04:30 -0800 From: =?UTF-8?q?Thomas=20Hellstr=C3=B6m?= To: intel-xe@lists.freedesktop.org Cc: =?UTF-8?q?Thomas=20Hellstr=C3=B6m?= , Matthew Auld , Matthew Brost , Maarten Lankhorst , Peter Zijlstra , Ingo Molnar , Will Deacon , Boqun Feng , Waiman Long , Sumit Semwal , =?UTF-8?q?Christian=20K=C3=B6nig?= , LKML , dri-devel@lists.freedesktop.org, linaro-mm-sig@lists.linaro.org Subject: [RFC PATCH 0/2] locking/ww_mutex, dma-buf/dma-resv: Improve detection of unheld locks Date: Thu, 20 Nov 2025 12:03:39 +0100 Message-ID: <20251120110341.2425-1-thomas.hellstrom@linux.intel.com> X-Mailer: git-send-email 2.51.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit WW mutexes and dma-resv objects, which embed them, typically have a number of locks belocking to the same lock class. However code using them typically want to verify the locking on object granularity, not lock-class granularity. This series add ww_mutex functions to facilitate that, (patch 1) and utilizes these functions in the dma-resv lock checks. Thomas Hellström (2): kernel/locking/ww_mutex: Add per-lock lock-check helpers dma-buf/dma-resv: Improve the dma-resv lockdep checks include/linux/dma-resv.h | 7 +++++-- include/linux/ww_mutex.h | 18 ++++++++++++++++++ kernel/locking/mutex.c | 10 ++++++++++ 3 files changed, 33 insertions(+), 2 deletions(-) -- 2.51.1