mirror of
https://github.com/torvalds/linux.git
synced 2026-06-03 12:03:54 +02:00
platform/x86/intel/pmt: mutex clean up
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 <ilpo.jarvinen@linux.intel.com> Signed-off-by: Michael J. Ruhl <michael.j.ruhl@intel.com> Link: https://lore.kernel.org/r/20250713172943.7335-6-michael.j.ruhl@intel.com Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
This commit is contained in:
parent
ba22fe0cff
commit
75a496aa05
|
|
@ -12,6 +12,7 @@
|
|||
#include <linux/intel_vsec.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/mutex.h>
|
||||
#include <linux/pci.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/uaccess.h>
|
||||
|
|
@ -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,
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user