wl12xx: Check buffer bound when processing nvs data
wl12xx: Check buffer bound when processing nvs data

An nvs with malformed contents could cause the processing of the
calibration data to read beyond the end of the buffer. Prevent this
from happening by adding bound checking.

Signed-off-by: Pontus Fuchs <a5605b7eadbbe8624843094042f247faf6b65fe5@gmail.com>
Cc: 4fbacc2fa0ffdbb11bf1ad6925b886ebd08dd15f@kernel.org
Reviewed-by: Luciano Coelho <d1ef580865f8eb2e1d1c65bc406aba322cc98f3e@ti.com>
Signed-off-by: Luciano Coelho <d1ef580865f8eb2e1d1c65bc406aba322cc98f3e@ti.com>

TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs