OSDN Git Service

Merge "msm: ipa3: Release the IPA lock acquired"
authorLinux Build Service Account <lnxbuild@localhost>
Fri, 1 Mar 2019 06:47:10 +0000 (22:47 -0800)
committerGerrit - the friendly Code Review server <code-review@localhost>
Fri, 1 Mar 2019 06:47:10 +0000 (22:47 -0800)
drivers/platform/msm/ipa/ipa_v2/ipa_rt.c
drivers/platform/msm/ipa/ipa_v3/ipa_rt.c

index 4fea125..af8d9dc 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2012-2019, The Linux Foundation. All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License version 2 and
@@ -1404,6 +1404,7 @@ int ipa2_reset_rt(enum ipa_ip_type ip, bool user_only)
                                        hdr_entry->cookie != IPA_HDR_COOKIE) {
                                                IPAERR_RL(
                                                "Header already deleted\n");
+                                               mutex_unlock(&ipa_ctx->lock);
                                                return -EINVAL;
                                        }
                                } else if (rule->proc_ctx) {
@@ -1415,6 +1416,7 @@ int ipa2_reset_rt(enum ipa_ip_type ip, bool user_only)
                                                        IPA_PROC_HDR_COOKIE) {
                                        IPAERR_RL(
                                                "Proc entry already deleted\n");
+                                               mutex_unlock(&ipa_ctx->lock);
                                                return -EINVAL;
                                        }
                                }
index 2568430..659d38e 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2012-2019, The Linux Foundation. All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License version 2 and
@@ -1548,6 +1548,7 @@ int ipa3_reset_rt(enum ipa_ip_type ip, bool user_only)
                                        hdr_entry->cookie != IPA_HDR_COOKIE) {
                                                IPAERR_RL(
                                                "Header already deleted\n");
+                                               mutex_unlock(&ipa3_ctx->lock);
                                                return -EINVAL;
                                        }
                                } else if (rule->proc_ctx) {
@@ -1559,6 +1560,7 @@ int ipa3_reset_rt(enum ipa_ip_type ip, bool user_only)
                                                        IPA_PROC_HDR_COOKIE) {
                                                IPAERR_RL(
                                                "Proc entry already deleted\n");
+                                               mutex_unlock(&ipa3_ctx->lock);
                                                return -EINVAL;
                                        }
                                }