qcacld-3.0: Fix asymmetry of ipa pdev create and destroy handler

Fix asymmetry of ipa create and destroy handler

Change-Id: I89f5ca112ef3cc6b46fef8273800c668936f9c2f
CRs-Fixed: 2353796
diff --git a/components/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c b/components/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c
index aab026c..8ca5779 100644
--- a/components/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c
+++ b/components/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c
@@ -38,6 +38,11 @@
 	QDF_STATUS status;
 	struct wlan_ipa_priv *ipa_obj;
 
+	if (!ipa_config_is_enabled()) {
+		ipa_debug("IPA is disabled");
+		return QDF_STATUS_SUCCESS;
+	}
+
 	ipa_obj = wlan_objmgr_pdev_get_comp_private_obj(pdev,
 							WLAN_UMAC_COMP_IPA);
 	if (!ipa_obj) {
@@ -75,9 +80,7 @@
 
 	if (!ipa_config_is_enabled()) {
 		ipa_info("IPA is disabled");
-		wlan_objmgr_unregister_pdev_destroy_handler(WLAN_UMAC_COMP_IPA,
-				ipa_pdev_obj_destroy_notification, NULL);
-		return QDF_STATUS_COMP_DISABLED;
+		return QDF_STATUS_SUCCESS;
 	}
 
 	ipa_obj = qdf_mem_malloc(sizeof(*ipa_obj));