qcacmn: Replace panic by QDF_DEBUG_PANIC

Replace panic by QDF_DEBUG_PANIC because if PANIC_ON_BUG is compiled out,
we do not want to panic the system.

Change-Id: Idae89d6881ed5543273b047a0b77bc3ae55132b5
CRs-Fixed: 2545292
diff --git a/qdf/linux/src/i_qdf_util.h b/qdf/linux/src/i_qdf_util.h
index 764152b..469320e 100644
--- a/qdf/linux/src/i_qdf_util.h
+++ b/qdf/linux/src/i_qdf_util.h
@@ -205,7 +205,7 @@
 		qdf_err("Assertion failed! %s:%s %s:%d",   \
 		#expr, __FUNCTION__, __FILE__, __LINE__);      \
 		dump_stack();                                      \
-		panic("Take care of the TARGET ASSERT first\n");          \
+		QDF_DEBUG_PANIC("Take care of the TARGET ASSERT first\n");  \
 	}     \
 } while (0)
 
diff --git a/qdf/linux/src/qdf_mem.c b/qdf/linux/src/qdf_mem.c
index 73cdb54..aba3fc6 100644
--- a/qdf/linux/src/qdf_mem.c
+++ b/qdf/linux/src/qdf_mem.c
@@ -938,7 +938,8 @@
 		leak_count += qdf_mem_domain_check_for_leaks(i, domains + i);
 
 	if (leak_count)
-		panic("%u fatal memory leaks detected!", leak_count);
+		QDF_DEBUG_PANIC("%u fatal memory leaks detected!",
+				leak_count);
 }
 
 /**
@@ -1029,7 +1030,8 @@
 		return;
 
 	if (qdf_unlikely((qdf_size_t)ptr <= sizeof(*header)))
-		panic("Failed to free invalid memory location %pK", ptr);
+		QDF_DEBUG_PANIC("Failed to free invalid memory location %pK",
+				ptr);
 
 	qdf_talloc_assert_no_children_fl(ptr, func, line);
 
@@ -1064,7 +1066,8 @@
 	leaks_count += qdf_mem_domain_check_for_leaks(current_domain, dma_list);
 
 	if (leaks_count)
-		panic("%u fatal memory leaks detected!", leaks_count);
+		QDF_DEBUG_PANIC("%u fatal memory leaks detected!",
+				leaks_count);
 }
 
 /**