diff options
Diffstat (limited to 'services/input')
-rw-r--r-- | services/input/EventHub.cpp | 26 | ||||
-rw-r--r-- | services/input/InputDispatcher.cpp | 22 | ||||
-rw-r--r-- | services/input/InputManager.cpp | 4 | ||||
-rw-r--r-- | services/input/InputReader.cpp | 28 |
4 files changed, 40 insertions, 40 deletions
diff --git a/services/input/EventHub.cpp b/services/input/EventHub.cpp index 85ff964..4c28a16 100644 --- a/services/input/EventHub.cpp +++ b/services/input/EventHub.cpp @@ -246,7 +246,7 @@ status_t EventHub::getAbsoluteAxisInfo(int32_t deviceId, int axis, if (device && test_bit(axis, device->absBitmask)) { struct input_absinfo info; if(ioctl(device->fd, EVIOCGABS(axis), &info)) { - LOGW("Error reading absolute controller %d for device %s fd %d, errno=%d", + ALOGW("Error reading absolute controller %d for device %s fd %d, errno=%d", axis, device->identifier.name.string(), device->fd, errno); return -errno; } @@ -355,7 +355,7 @@ status_t EventHub::getAbsoluteAxisValue(int32_t deviceId, int32_t axis, int32_t* if (device && test_bit(axis, device->absBitmask)) { struct input_absinfo info; if(ioctl(device->fd, EVIOCGABS(axis), &info)) { - LOGW("Error reading absolute controller %d for device %s fd %d, errno=%d", + ALOGW("Error reading absolute controller %d for device %s fd %d, errno=%d", axis, device->identifier.name.string(), device->fd, errno); return -errno; } @@ -614,7 +614,7 @@ size_t EventHub::getEvents(int timeoutMillis, RawEvent* buffer, size_t bufferSiz if (eventItem.events & EPOLLIN) { mPendingINotify = true; } else { - LOGW("Received unexpected epoll event 0x%08x for INotify.", eventItem.events); + ALOGW("Received unexpected epoll event 0x%08x for INotify.", eventItem.events); } continue; } @@ -629,7 +629,7 @@ size_t EventHub::getEvents(int timeoutMillis, RawEvent* buffer, size_t bufferSiz nRead = read(mWakeReadPipeFd, buffer, sizeof(buffer)); } while ((nRead == -1 && errno == EINTR) || nRead == sizeof(buffer)); } else { - LOGW("Received unexpected epoll event 0x%08x for wake read pipe.", + ALOGW("Received unexpected epoll event 0x%08x for wake read pipe.", eventItem.events); } continue; @@ -637,7 +637,7 @@ size_t EventHub::getEvents(int timeoutMillis, RawEvent* buffer, size_t bufferSiz ssize_t deviceIndex = mDevices.indexOfKey(eventItem.data.u32); if (deviceIndex < 0) { - LOGW("Received unexpected epoll event 0x%08x for unknown device id %d.", + ALOGW("Received unexpected epoll event 0x%08x for unknown device id %d.", eventItem.events, eventItem.data.u32); continue; } @@ -648,13 +648,13 @@ size_t EventHub::getEvents(int timeoutMillis, RawEvent* buffer, size_t bufferSiz sizeof(struct input_event) * capacity); if (readSize == 0 || (readSize < 0 && errno == ENODEV)) { // Device was removed before INotify noticed. - LOGW("could not get event, removed? (fd: %d size: %d bufferSize: %d capacity: %d errno: %d)\n", + ALOGW("could not get event, removed? (fd: %d size: %d bufferSize: %d capacity: %d errno: %d)\n", device->fd, readSize, bufferSize, capacity, errno); deviceChanged = true; closeDeviceLocked(device); } else if (readSize < 0) { if (errno != EAGAIN && errno != EINTR) { - LOGW("could not get event (errno=%d)", errno); + ALOGW("could not get event (errno=%d)", errno); } } else if ((readSize % sizeof(struct input_event)) != 0) { LOGE("could not get event (wrong size: %d)", readSize); @@ -710,7 +710,7 @@ size_t EventHub::getEvents(int timeoutMillis, RawEvent* buffer, size_t bufferSiz } } } else { - LOGW("Received unexpected epoll event 0x%08x for device %s.", + ALOGW("Received unexpected epoll event 0x%08x for device %s.", eventItem.events, device->identifier.name.string()); } } @@ -768,7 +768,7 @@ size_t EventHub::getEvents(int timeoutMillis, RawEvent* buffer, size_t bufferSiz // Sleep after errors to avoid locking up the system. // Hopefully the error is transient. if (errno != EINTR) { - LOGW("poll failed (errno=%d)\n", errno); + ALOGW("poll failed (errno=%d)\n", errno); usleep(100000); } } else { @@ -803,7 +803,7 @@ void EventHub::wake() { } while (nWrite == -1 && errno == EINTR); if (nWrite != 1 && errno != EAGAIN) { - LOGW("Could not write wake signal, errno=%d", errno); + ALOGW("Could not write wake signal, errno=%d", errno); } } @@ -1175,13 +1175,13 @@ void EventHub::closeDeviceLocked(Device* device) { device->fd, device->classes); if (device->id == mBuiltInKeyboardId) { - LOGW("built-in keyboard device %s (id=%d) is closing! the apps will not like this", + ALOGW("built-in keyboard device %s (id=%d) is closing! the apps will not like this", device->path.string(), mBuiltInKeyboardId); mBuiltInKeyboardId = -1; } if (epoll_ctl(mEpollFd, EPOLL_CTL_DEL, device->fd, NULL)) { - LOGW("Could not remove device fd from epoll instance. errno=%d", errno); + ALOGW("Could not remove device fd from epoll instance. errno=%d", errno); } mDevices.removeItem(device->id); @@ -1231,7 +1231,7 @@ status_t EventHub::readNotifyLocked() { if(res < (int)sizeof(*event)) { if(errno == EINTR) return 0; - LOGW("could not get event, %s\n", strerror(errno)); + ALOGW("could not get event, %s\n", strerror(errno)); return -1; } //printf("got %d bytes of event information\n", res); diff --git a/services/input/InputDispatcher.cpp b/services/input/InputDispatcher.cpp index 0379d7e..19c01a1 100644 --- a/services/input/InputDispatcher.cpp +++ b/services/input/InputDispatcher.cpp @@ -1778,13 +1778,13 @@ bool InputDispatcher::checkInjectionPermission(const sp<InputWindowHandle>& wind || windowHandle->getInfo()->ownerUid != injectionState->injectorUid) && !hasInjectionPermission(injectionState->injectorPid, injectionState->injectorUid)) { if (windowHandle != NULL) { - LOGW("Permission denied: injecting event from pid %d uid %d to window %s " + ALOGW("Permission denied: injecting event from pid %d uid %d to window %s " "owned by uid %d", injectionState->injectorPid, injectionState->injectorUid, windowHandle->getName().string(), windowHandle->getInfo()->ownerUid); } else { - LOGW("Permission denied: injecting event from pid %d uid %d", + ALOGW("Permission denied: injecting event from pid %d uid %d", injectionState->injectorPid, injectionState->injectorUid); } return false; @@ -2417,7 +2417,7 @@ int InputDispatcher::handleReceiveCallback(int receiveFd, int events, void* data sp<Connection> connection = d->mConnectionsByReceiveFd.valueAt(connectionIndex); if (!(events & (ALOOPER_EVENT_ERROR | ALOOPER_EVENT_HANGUP))) { if (!(events & ALOOPER_EVENT_INPUT)) { - LOGW("channel '%s' ~ Received spurious callback for unhandled poll event. " + ALOGW("channel '%s' ~ Received spurious callback for unhandled poll event. " "events=0x%x", connection->getInputChannelName(), events); return 1; } @@ -2440,7 +2440,7 @@ int InputDispatcher::handleReceiveCallback(int receiveFd, int events, void* data // about them. notify = !connection->monitor; if (notify) { - LOGW("channel '%s' ~ Consumer closed input channel or an error occurred. " + ALOGW("channel '%s' ~ Consumer closed input channel or an error occurred. " "events=0x%x", connection->getInputChannelName(), events); } } @@ -2555,7 +2555,7 @@ InputDispatcher::splitMotionEvent(const MotionEntry* originalMotionEntry, BitSet // different pointer ids than we expected based on the previous ACTION_DOWN // or ACTION_POINTER_DOWN events that caused us to decide to split the pointers // in this way. - LOGW("Dropping split motion event because the pointer count is %d but " + ALOGW("Dropping split motion event because the pointer count is %d but " "we expected there to be %d pointers. This probably means we received " "a broken sequence of pointer ids from the input device.", splitPointerCount, pointerIds.count()); @@ -3094,7 +3094,7 @@ int32_t InputDispatcher::injectInputEvent(const InputEvent* event, } default: - LOGW("Cannot inject event of type %d", event->getType()); + ALOGW("Cannot inject event of type %d", event->getType()); return INPUT_EVENT_INJECTION_FAILED; } @@ -3195,13 +3195,13 @@ void InputDispatcher::setInjectionResultLocked(EventEntry* entry, int32_t inject ALOGV("Asynchronous input event injection succeeded."); break; case INPUT_EVENT_INJECTION_FAILED: - LOGW("Asynchronous input event injection failed."); + ALOGW("Asynchronous input event injection failed."); break; case INPUT_EVENT_INJECTION_PERMISSION_DENIED: - LOGW("Asynchronous input event injection permission denied."); + ALOGW("Asynchronous input event injection permission denied."); break; case INPUT_EVENT_INJECTION_TIMED_OUT: - LOGW("Asynchronous input event injection timed out."); + ALOGW("Asynchronous input event injection timed out."); break; } } @@ -3643,7 +3643,7 @@ status_t InputDispatcher::registerInputChannel(const sp<InputChannel>& inputChan AutoMutex _l(mLock); if (getConnectionIndexLocked(inputChannel) >= 0) { - LOGW("Attempted to register already registered input channel '%s'", + ALOGW("Attempted to register already registered input channel '%s'", inputChannel->getName().string()); return BAD_VALUE; } @@ -3694,7 +3694,7 @@ status_t InputDispatcher::unregisterInputChannelLocked(const sp<InputChannel>& i bool notify) { ssize_t connectionIndex = getConnectionIndexLocked(inputChannel); if (connectionIndex < 0) { - LOGW("Attempted to unregister already unregistered input channel '%s'", + ALOGW("Attempted to unregister already unregistered input channel '%s'", inputChannel->getName().string()); return BAD_VALUE; } diff --git a/services/input/InputManager.cpp b/services/input/InputManager.cpp index 5dfa5d5..29c5884 100644 --- a/services/input/InputManager.cpp +++ b/services/input/InputManager.cpp @@ -71,12 +71,12 @@ status_t InputManager::start() { status_t InputManager::stop() { status_t result = mReaderThread->requestExitAndWait(); if (result) { - LOGW("Could not stop InputReader thread due to error %d.", result); + ALOGW("Could not stop InputReader thread due to error %d.", result); } result = mDispatcherThread->requestExitAndWait(); if (result) { - LOGW("Could not stop InputDispatcher thread due to error %d.", result); + ALOGW("Could not stop InputDispatcher thread due to error %d.", result); } return OK; diff --git a/services/input/InputReader.cpp b/services/input/InputReader.cpp index bf398f7..e8802f5 100644 --- a/services/input/InputReader.cpp +++ b/services/input/InputReader.cpp @@ -359,7 +359,7 @@ void InputReader::addDeviceLocked(nsecs_t when, int32_t deviceId) { if (deviceIndex < 0) { mDevices.add(deviceId, device); } else { - LOGW("Ignoring spurious device added event for deviceId %d.", deviceId); + ALOGW("Ignoring spurious device added event for deviceId %d.", deviceId); delete device; return; } @@ -372,7 +372,7 @@ void InputReader::removeDeviceLocked(nsecs_t when, int32_t deviceId) { device = mDevices.valueAt(deviceIndex); mDevices.removeItemsAt(deviceIndex, 1); } else { - LOGW("Ignoring spurious device removed event for deviceId %d.", deviceId); + ALOGW("Ignoring spurious device removed event for deviceId %d.", deviceId); return; } @@ -446,7 +446,7 @@ void InputReader::processEventsForDeviceLocked(int32_t deviceId, const RawEvent* rawEvents, size_t count) { ssize_t deviceIndex = mDevices.indexOfKey(deviceId); if (deviceIndex < 0) { - LOGW("Discarding event for unknown deviceId %d.", deviceId); + ALOGW("Discarding event for unknown deviceId %d.", deviceId); return; } @@ -1546,7 +1546,7 @@ void MultiTouchMotionAccumulator::process(const RawEvent* rawEvent) { if (mCurrentSlot < 0 || size_t(mCurrentSlot) >= mSlotCount) { #if DEBUG_POINTERS if (newSlot) { - LOGW("MultiTouch device emitted invalid slot index %d but it " + ALOGW("MultiTouch device emitted invalid slot index %d but it " "should be between 0 and %d; ignoring this slot.", mCurrentSlot, mSlotCount - 1); } @@ -2113,7 +2113,7 @@ void CursorInputMapper::configureParameters() { if (cursorModeString == "navigation") { mParameters.mode = Parameters::MODE_NAVIGATION; } else if (cursorModeString != "pointer" && cursorModeString != "default") { - LOGW("Invalid value for cursor.mode: '%s'", cursorModeString.string()); + ALOGW("Invalid value for cursor.mode: '%s'", cursorModeString.string()); } } @@ -2522,7 +2522,7 @@ void TouchInputMapper::configureParameters() { } else if (gestureModeString == "spots") { mParameters.gestureMode = Parameters::GESTURE_MODE_SPOTS; } else if (gestureModeString != "default") { - LOGW("Invalid value for touch.gestureMode: '%s'", gestureModeString.string()); + ALOGW("Invalid value for touch.gestureMode: '%s'", gestureModeString.string()); } } @@ -2552,7 +2552,7 @@ void TouchInputMapper::configureParameters() { } else if (deviceTypeString == "pointer") { mParameters.deviceType = Parameters::DEVICE_TYPE_POINTER; } else if (deviceTypeString != "default") { - LOGW("Invalid value for touch.deviceType: '%s'", deviceTypeString.string()); + ALOGW("Invalid value for touch.deviceType: '%s'", deviceTypeString.string()); } } @@ -2646,7 +2646,7 @@ void TouchInputMapper::configureSurface(nsecs_t when, bool* outResetNeeded) { // Ensure we have valid X and Y axes. if (!mRawPointerAxes.x.valid || !mRawPointerAxes.y.valid) { - LOGW(INDENT "Touch device '%s' did not report support for X or Y axis! " + ALOGW(INDENT "Touch device '%s' did not report support for X or Y axis! " "The device will be inoperable.", getDeviceName().string()); mDeviceMode = DEVICE_MODE_DISABLED; return; @@ -3002,7 +3002,7 @@ void TouchInputMapper::configureVirtualKeys() { uint32_t flags; if (getEventHub()->mapKey(getDeviceId(), virtualKey.scanCode, & keyCode, & flags)) { - LOGW(INDENT "VirtualKey %d: could not obtain key code, ignoring", + ALOGW(INDENT "VirtualKey %d: could not obtain key code, ignoring", virtualKey.scanCode); mVirtualKeys.pop(); // drop the key continue; @@ -3058,7 +3058,7 @@ void TouchInputMapper::parseCalibration() { } else if (sizeCalibrationString == "area") { out.sizeCalibration = Calibration::SIZE_CALIBRATION_AREA; } else if (sizeCalibrationString != "default") { - LOGW("Invalid value for touch.size.calibration: '%s'", + ALOGW("Invalid value for touch.size.calibration: '%s'", sizeCalibrationString.string()); } } @@ -3081,7 +3081,7 @@ void TouchInputMapper::parseCalibration() { } else if (pressureCalibrationString == "amplitude") { out.pressureCalibration = Calibration::PRESSURE_CALIBRATION_AMPLITUDE; } else if (pressureCalibrationString != "default") { - LOGW("Invalid value for touch.pressure.calibration: '%s'", + ALOGW("Invalid value for touch.pressure.calibration: '%s'", pressureCalibrationString.string()); } } @@ -3100,7 +3100,7 @@ void TouchInputMapper::parseCalibration() { } else if (orientationCalibrationString == "vector") { out.orientationCalibration = Calibration::ORIENTATION_CALIBRATION_VECTOR; } else if (orientationCalibrationString != "default") { - LOGW("Invalid value for touch.orientation.calibration: '%s'", + ALOGW("Invalid value for touch.orientation.calibration: '%s'", orientationCalibrationString.string()); } } @@ -3114,7 +3114,7 @@ void TouchInputMapper::parseCalibration() { } else if (distanceCalibrationString == "scaled") { out.distanceCalibration = Calibration::DISTANCE_CALIBRATION_SCALED; } else if (distanceCalibrationString != "default") { - LOGW("Invalid value for touch.distance.calibration: '%s'", + ALOGW("Invalid value for touch.distance.calibration: '%s'", distanceCalibrationString.string()); } } @@ -5678,7 +5678,7 @@ void MultiTouchInputMapper::configureRawPointerAxes() { && mRawPointerAxes.slot.minValue == 0 && mRawPointerAxes.slot.maxValue > 0) { size_t slotCount = mRawPointerAxes.slot.maxValue + 1; if (slotCount > MAX_SLOTS) { - LOGW("MultiTouch Device %s reported %d slots but the framework " + ALOGW("MultiTouch Device %s reported %d slots but the framework " "only supports a maximum of %d slots at this time.", getDeviceName().string(), slotCount, MAX_SLOTS); slotCount = MAX_SLOTS; |