]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
wifi: iwlwifi: mvm: ptp: free response on success path
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>
Wed, 15 Jul 2026 18:57:09 +0000 (21:57 +0300)
committerMiri Korenblit <miriam.rachel.korenblit@intel.com>
Thu, 16 Jul 2026 18:12:19 +0000 (21:12 +0300)
Release CMD_WANT_SKB response buffer after successful timestamp parsing
to avoid leaking response allocations.

Assisted-by: GitHubCopilot:GPT-5.3-Codex
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20260715215523.31b38bef398b.Ib6a5a8bdd800779c8911da6859fd450d3d19c9e9@changeid
drivers/net/wireless/intel/iwlwifi/mvm/ptp.c

index f39eb48864eb4b5ab9e950bc99dbe991dc31a4bc..49dcb1388007bcf5ef738d0cf4b93ffe85f47eb8 100644 (file)
@@ -1,6 +1,6 @@
 // SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause
 /*
- * Copyright (C) 2021 - 2023, 2025 Intel Corporation
+ * Copyright (C) 2021 - 2023, 2025-2026 Intel Corporation
  */
 
 #include "mvm.h"
@@ -121,6 +121,8 @@ iwl_mvm_get_crosstimestamp_fw(struct iwl_mvm *mvm, u32 *gp2, u64 *sys_time)
        *sys_time = (u64)le32_to_cpu(resp->platform_timestamp_hi) << 32 |
                le32_to_cpu(resp->platform_timestamp_lo);
 
+       iwl_free_resp(&cmd);
+
        return ret;
 }