Nfc HAL uses "default" service name am: 3b06b22ed4

am: 1d51e903f6

Change-Id: Ib0000338ba5b35b1784776ae147c44264f0d98e9
This commit is contained in:
Chris Phoenix 2017-01-19 01:31:59 +00:00 committed by android-build-merger
commit 636a0a646e
4 changed files with 3 additions and 6 deletions

View file

@ -65,7 +65,7 @@ INfc* HIDL_FETCH_INfc(const char * /*name*/) {
} }
} }
else else
ALOGE ("hw_get_module failed: %d", ret); ALOGE ("hw_get_module %s failed: %d", NFC_NCI_HARDWARE_MODULE_ID, ret);
if (ret == 0) { if (ret == 0) {
return new Nfc(nfc_device); return new Nfc(nfc_device);

View file

@ -9,5 +9,5 @@ using android::hardware::nfc::V1_0::INfc;
using android::hardware::defaultPassthroughServiceImplementation; using android::hardware::defaultPassthroughServiceImplementation;
int main() { int main() {
return defaultPassthroughServiceImplementation<INfc>("nfc_nci"); return defaultPassthroughServiceImplementation<INfc>();
} }

View file

@ -37,8 +37,6 @@ using ::android::hardware::Void;
using ::android::hardware::hidl_vec; using ::android::hardware::hidl_vec;
using ::android::sp; using ::android::sp;
#define NFC_NCI_SERVICE_NAME "nfc_nci"
/* NCI Commands */ /* NCI Commands */
#define CORE_RESET_CMD \ #define CORE_RESET_CMD \
{ 0x20, 0x00, 0x01, 0x00 } { 0x20, 0x00, 0x01, 0x00 }
@ -61,7 +59,7 @@ static bool passthrough = true;
class NfcHidlTest : public ::testing::Test { class NfcHidlTest : public ::testing::Test {
public: public:
virtual void SetUp() override { virtual void SetUp() override {
nfc_ = INfc::getService(NFC_NCI_SERVICE_NAME, passthrough); nfc_ = INfc::getService(passthrough);
ASSERT_NE(nfc_, nullptr); ASSERT_NE(nfc_, nullptr);
nfc_cb_ = new NfcClientCallback(*this); nfc_cb_ = new NfcClientCallback(*this);

View file

@ -54,7 +54,6 @@ class NfcHidlBasicTest(base_test_with_webdb.BaseTestWithWebDbClass):
target_version=1.0, target_version=1.0,
target_package="android.hardware.nfc", target_package="android.hardware.nfc",
target_component_name="INfc", target_component_name="INfc",
hw_binder_service_name="nfc_nci",
bits=64 if self.dut.is64Bit else 32) bits=64 if self.dut.is64Bit else 32)
def tearDownClass(self): def tearDownClass(self):