diag: Handle diag memory pool correctly in diagchar_write
diag: Handle diag memory pool correctly in diagchar_write

Memory allocated from the diag memory pool was not freed
correctly and mutexes were not unlocked properly. This
change adds fixes the memory leak and the mutex unlocking
issues.

Change-Id: If7bf45586e8bc66ce85ad42ace2397bcb0294801
Signed-off-by: Ravi Aravamudhan <aa3210a89d655a9fa3f729366f4d5a1b8908c2e8@codeaurora.org>

TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas