qcacmn: In case of peer reuse set valid flag

Currently if peer reference is reused valid flag is not set.
In peer delete function if valid flag is not set, function
returns with out decrementing the ref count and also not
releasing the local id. This leads to local id exhaustion if
back to back peer reuse happens which is common in case of back
to back roaming to same AP. As a result connection to AP fails
due to unavailability of local id. In this change set valid flag
if peer reference is reused.

Change-Id: Ibeccbc4d33aac9e4285b48a4b8abdd2276fd7ede
CRs-Fixed: 2624798
1 file changed