summaryrefslogtreecommitdiffstats
path: root/halimpl/bcm2079x/adaptation/patchram.cpp
diff options
context:
space:
mode:
authorEvan Chu <evanchu@broadcom.com>2013-05-01 11:29:02 -0700
committerMartijn Coenen <maco@google.com>2013-05-01 17:52:52 -0700
commit45e68232b8524aca5165dca28b994ec8c11593b1 (patch)
treecacb5bfd74b8549717a115daa36b6d49b1aa2a6e /halimpl/bcm2079x/adaptation/patchram.cpp
parentd2e38f8f4c231d56d66a7f806587fd2c942a9f12 (diff)
downloadandroid_hardware_broadcom_nfc-45e68232b8524aca5165dca28b994ec8c11593b1.tar.gz
android_hardware_broadcom_nfc-45e68232b8524aca5165dca28b994ec8c11593b1.tar.bz2
android_hardware_broadcom_nfc-45e68232b8524aca5165dca28b994ec8c11593b1.zip
Send config params on HAL_NfcPreDiscover().
Bug: 8776949 Change-Id: Idbfb9c77304ce0df8521b167f25004bfd18b59d8
Diffstat (limited to 'halimpl/bcm2079x/adaptation/patchram.cpp')
-rw-r--r--halimpl/bcm2079x/adaptation/patchram.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/halimpl/bcm2079x/adaptation/patchram.cpp b/halimpl/bcm2079x/adaptation/patchram.cpp
index 343eab2..a9083d7 100644
--- a/halimpl/bcm2079x/adaptation/patchram.cpp
+++ b/halimpl/bcm2079x/adaptation/patchram.cpp
@@ -44,10 +44,13 @@ static void * sI2cFixPrmBuf = NULL;
static UINT8 sConfig [CONFIG_MAX_LEN];
static StartupConfig sStartupConfig;
static StartupConfig sLptdConfig;
+static StartupConfig sPreDiscoveryConfig;
extern UINT8 *p_nfc_hal_dm_start_up_cfg; //defined in the HAL
static UINT8 nfa_dm_start_up_vsc_cfg[CONFIG_MAX_LEN];
extern UINT8 *p_nfc_hal_dm_start_up_vsc_cfg; //defined in the HAL
extern UINT8 *p_nfc_hal_dm_lptd_cfg; //defined in the HAL
+extern UINT8 *p_nfc_hal_pre_discover_cfg; //defined in the HAL
+
extern tSNOOZE_MODE_CONFIG gSnoozeModeCfg;
extern tNFC_HAL_CFG *p_nfc_hal_cfg;
static void mayDisableSecureElement (StartupConfig& config);
@@ -309,6 +312,7 @@ static void getNfaValues()
p_nfc_hal_cfg->nfc_hal_prm_nvm_required = TRUE; //don't download firmware if controller cannot detect EERPOM
sStartupConfig.initialize ();
sLptdConfig.initialize ();
+ sPreDiscoveryConfig.initialize();
actualLen = GetStrValue (NAME_NFA_DM_START_UP_CFG, (char*)sConfig, sizeof(sConfig));
@@ -354,6 +358,13 @@ static void getNfaValues()
mayDisableSecureElement (sStartupConfig);
p_nfc_hal_dm_start_up_cfg = const_cast<UINT8*> (sStartupConfig.getInternalBuffer ());
+
+ actualLen = GetStrValue(NAME_NFA_DM_PRE_DISCOVERY_CFG, (char*)sConfig, sizeof(sConfig));
+ if (actualLen)
+ {
+ sPreDiscoveryConfig.append (sConfig, actualLen);
+ p_nfc_hal_pre_discover_cfg = const_cast<UINT8*> (sPreDiscoveryConfig.getInternalBuffer ());
+ }
}
/*******************************************************************************