radio-tavarua: Validate whether the current station is good or bad

Provide mechanism to decide whether the currently tuned station
is valid or not.

CRs-Fixed: 371689
Change-Id: I1a28537d242fbb636732b120c9259ad5e7fffcc0
Signed-off-by: Anantha Krishnan <ananthk@codeaurora.org>
radio-tavarua: Handle I2C read/write errors during sleep mode.

Getting read/write errors when the I2C is not resumed from the sleep

Added re-try mechanism to handle during I2C read/write

Change-Id: I5a533b085ccfcda2181a2d5ea792bbb3d187c477
CRs-Fixed: 427937
Signed-off-by: Venkateshwarlu Domakonda <Venkateshwarlu@codeaurora.org>
radio: tavarua: Handle search list event properly

- Not sending the search list event to the userspace when the SOC
  returns 0 channels.
- State machine will be in search state even though the SOC
  return search list event.
- Queue the search list event to the userspace even when the SOC
  returns 0 channels.

Change-Id: Ie69d05341c67d99434cf5ed7badd7242706441bb
CRs-Fixed: 472785
Signed-off-by: Venkateshwarlu Domakonda <Venkateshwarlu@codeaurora.org>
radio: tavarua: Use proper length to read the data

- Copies the entire 16 bytes including the unused last
  byte of RX_STATIONS_0.
- Userspace will get wrong frequency.
- Use proper length to read the data when HOST receives search list event.

Change-Id: I69ecc01c327c4f803dd594a95ca539339bdec574
CRs-Fixed: 468619
Signed-off-by: Venkateshwarlu Domakonda <Venkateshwarlu@codeaurora.org>
radio: tavarua: Added NULL checks for input arguments.

Added NULL checks for input arguments.

Change-Id: Ie39c2b3254c95925723735423c81b99da59ee6ad
CRs-fixed: 548405
Signed-off-by: Satish Kodishala <skodisha@codeaurora.org>
radio: tavarua: Fix buffer overflow.

Removed improper typecasting to fix buffer overflow.

CRs-fixed: 554963

Change-Id: Ie3ae5a502f060c13eba7cb5c28a1af389b772af2
Signed-off-by: Satish Kodishala <skodisha@codeaurora.org>
radio: tavarua: Fixes for memory leaks.

Freeing memory allocated in case of failures.

Change-Id: I323b9c414d725d6b9dc0698e2ed03ef9c2450e5f
CRs-fixed: 557048
Signed-off-by: Satish Kodishala <skodisha@codeaurora.org>
defconfig: Increase log buffer size

Change-Id: I52999d45404faa4eeb7790772e43f01bdabbfb46
defonconfig: Enable android recommended configs

Change-Id: Ifd6a8f2a8342c5a76dd0d90b75efb7cbe7ed4f7d