From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 25E0EC83F0A for ; Wed, 9 Jul 2025 18:45:27 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id E53D810E359; Wed, 9 Jul 2025 18:45:26 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="D9USgzp+"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.14]) by gabe.freedesktop.org (Postfix) with ESMTPS id 6B24B10E82D for ; Wed, 9 Jul 2025 18:45:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1752086725; x=1783622725; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=lFJAoaBsqvLfWqq9QLWuaiPqon8ZGhk3HZHjCdijZ1Y=; b=D9USgzp+ot7ELxCq3iIOGLZtZ5AF5wTe1ghqHiUWkUoeiVDTGoPaEQik HZsw7ysj0o6XaLyrrzZimW/HBlRuSyJrPwFbcIc6H7oeDTcMi0D695pAH pn5OCkmovGvF3ycIHM8MYMEfez24Kr0WjNAsfYw9ePxTI9L7sj08rKAjX 9MTOLmibeQwfL758eAiXZ7/mmt+u6U8Wk6Cuzi5wvKqJMD2BGVpWI8JFz aMjweAuj6LJGiP9LShtgTRFgVU5UkGfezfq2T9cFYr64y6vrK0wWRUuZa pZtAx47Iw3YUdsnuHffQQDahYZfn9n3+ZpUA5jWAAR8YonDw9SZB611nq Q==; X-CSE-ConnectionGUID: ZOXgYBBRQYKgfzyYr6jOUQ== X-CSE-MsgGUID: zrv/yYK+RFq0tjAYqPVH4w== X-IronPort-AV: E=McAfee;i="6800,10657,11489"; a="54451044" X-IronPort-AV: E=Sophos;i="6.16,298,1744095600"; d="scan'208";a="54451044" Received: from fmviesa004.fm.intel.com ([10.60.135.144]) by fmvoesa108.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Jul 2025 11:45:25 -0700 X-CSE-ConnectionGUID: fTgrnX0oS7aqQLmFqNsdnA== X-CSE-MsgGUID: W2shbcf+TWG0wpJ+bUXFoA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.16,298,1744095600"; d="scan'208";a="161404861" Received: from mjruhl-desk.amr.corp.intel.com (HELO mjruhl-desk.intel.com) ([10.124.221.121]) by fmviesa004-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Jul 2025 11:45:24 -0700 From: "Michael J. Ruhl" To: platform-driver-x86@vger.kernel.org, intel-xe@lists.freedesktop.org, hdegoede@redhat.com, ilpo.jarvinen@linux.intel.com, lucas.demarchi@intel.com, rodrigo.vivi@intel.com, thomas.hellstrom@linux.intel.com, airlied@gmail.com, simona@ffwll.ch, david.e.box@linux.intel.com Cc: "Michael J. Ruhl" Subject: [PATCH v7 04/12] platform/x86/intel/pmt: mutex clean up Date: Wed, 9 Jul 2025 14:44:50 -0400 Message-ID: <20250709184458.298283-5-michael.j.ruhl@intel.com> X-Mailer: git-send-email 2.50.0 In-Reply-To: <20250709184458.298283-1-michael.j.ruhl@intel.com> References: <20250709184458.298283-1-michael.j.ruhl@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: intel-xe@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel Xe graphics driver List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-xe-bounces@lists.freedesktop.org Sender: "Intel-xe" The header file for mutex usage and mutex_destroy() cleanup code is absent from the crashlog.c module. Add the header file and mutex_destroy(). Reviewed-by: Ilpo Järvinen Signed-off-by: Michael J. Ruhl --- drivers/platform/x86/intel/pmt/crashlog.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/platform/x86/intel/pmt/crashlog.c b/drivers/platform/x86/intel/pmt/crashlog.c index d40c8e212733..6e32fc1f8f1d 100644 --- a/drivers/platform/x86/intel/pmt/crashlog.c +++ b/drivers/platform/x86/intel/pmt/crashlog.c @@ -12,6 +12,7 @@ #include #include #include +#include #include #include #include @@ -262,8 +263,12 @@ static void pmt_crashlog_remove(struct auxiliary_device *auxdev) struct pmt_crashlog_priv *priv = auxiliary_get_drvdata(auxdev); int i; - for (i = 0; i < priv->num_entries; i++) - intel_pmt_dev_destroy(&priv->entry[i].entry, &pmt_crashlog_ns); + for (i = 0; i < priv->num_entries; i++) { + struct crashlog_entry *crashlog = &priv->entry[i]; + + intel_pmt_dev_destroy(&crashlog->entry, &pmt_crashlog_ns); + mutex_destroy(&crashlog->control_mutex); + } } static int pmt_crashlog_probe(struct auxiliary_device *auxdev, -- 2.50.0