Separate function to add fd to epoll
Since we will be adding video devices in addition to input devices to
epoll, we will be using the same function for adding an fd to epoll.
Small refactor here to make the later patch simpler.
Test: use booted device (EventHub native tests are pending)
Bug: 111480215
Change-Id: If257b3734ca12d0061648aa6ac5347ee1b0629a3
diff --git a/services/inputflinger/include/EventHub.h b/services/inputflinger/include/EventHub.h
index e2c7e82..5db7c0a 100644
--- a/services/inputflinger/include/EventHub.h
+++ b/services/inputflinger/include/EventHub.h
@@ -391,6 +391,8 @@
bool isDeviceEnabled(int32_t deviceId);
status_t enableDevice(int32_t deviceId);
status_t disableDevice(int32_t deviceId);
+ status_t registerFdForEpoll(int fd);
+ status_t unregisterFdFromEpoll(int fd);
status_t registerDeviceForEpollLocked(Device* device);
status_t unregisterDeviceFromEpollLocked(Device* device);