qcacmn: Handle error case with HAL SRNG setup

If hal_srng_setup() fails, memory allocated for srng
is not freed resulting in a leak. Free the memory in
that case. In future, return error to caller and
assert when invalid ring ID is used during setup.

Change-Id: I6f3a7494a5c5e861652f3a38d18c220cd9a6eef2
2 files changed