* From https://github.com/LineageOS/android_device_xiaomi_twolip * Rebrand to tulip * Move props to a specific folder * Unify shims in a specific folder * Move idc files to keylayout folder * Minor refactor to light HAL Signed-off-by: Arturo <rtsanonynousperson@gmail.com>
33 lines
834 B
C++
33 lines
834 B
C++
/*
|
|
* Copyright 2016 The Android Open Source Project
|
|
*
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
|
|
#define LOG_TAG "android.hardware.ir@1.0-service.tulip"
|
|
|
|
#include <android-base/logging.h>
|
|
#include <hidl/HidlTransportSupport.h>
|
|
#include "ConsumerIr.h"
|
|
|
|
using android::hardware::ir::V1_0::IConsumerIr;
|
|
using android::hardware::ir::V1_0::implementation::ConsumerIr;
|
|
using android::hardware::configureRpcThreadpool;
|
|
using android::hardware::joinRpcThreadpool;
|
|
|
|
int main() {
|
|
android::sp<IConsumerIr> service = new ConsumerIr();
|
|
|
|
configureRpcThreadpool(1, true /*callerWillJoin*/);
|
|
|
|
android::status_t status = service->registerAsService();
|
|
if (status != android::OK) {
|
|
LOG(ERROR) << "Cannot register ConsumerIr service";
|
|
return 1;
|
|
}
|
|
|
|
joinRpcThreadpool();
|
|
|
|
return 1; // should never get here
|
|
}
|