diff options
author | Javi Ferrer <javi.f.o@gmail.com> | 2015-05-12 19:40:59 +0200 |
---|---|---|
committer | forkbomb <keepcalm444@gmail.com> | 2015-11-25 08:33:40 +1100 |
commit | 948970715990bde9caf07377f928530848d19a36 (patch) | |
tree | 8ed27e6116225749dab0ac6de29b640e9617bfab /libsensors/input.c | |
parent | ef3bca4b0959df074d5b0867b95699c330b5779e (diff) | |
download | device_samsung_i9300-948970715990bde9caf07377f928530848d19a36.zip device_samsung_i9300-948970715990bde9caf07377f928530848d19a36.tar.gz device_samsung_i9300-948970715990bde9caf07377f928530848d19a36.tar.bz2 |
i9300: update libsensors from replicant
- Orientation sensor still broken
Change-Id: I7d20afbbc1f8b1ca5d046a38c0c3b7ce824c12cd
Diffstat (limited to 'libsensors/input.c')
-rw-r--r-- | libsensors/input.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/libsensors/input.c b/libsensors/input.c index f1e5283..5a58b45 100644 --- a/libsensors/input.c +++ b/libsensors/input.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2013 Paul Kocialkowski + * Copyright (C) 2013 Paul Kocialkowski <contact@paulk.fr> * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -25,10 +25,10 @@ #include <linux/input.h> #include <linux/uinput.h> -#define LOG_TAG "exynos_sensors" +#define LOG_TAG "smdk4x12_sensors" #include <utils/Log.h> -#include "exynos_sensors.h" +#include "smdk4x12_sensors.h" void input_event_set(struct input_event *event, int type, int code, int value) { @@ -276,12 +276,12 @@ complete: return rc; } -int sysfs_string_read(char *path, char *buffer, int length) +int sysfs_string_read(char *path, char *buffer, size_t length) { int fd = -1; int rc; - if (path == NULL || buffer == NULL || length <= 0) + if (path == NULL || buffer == NULL || length == 0) return -1; fd = open(path, O_RDONLY); @@ -305,12 +305,12 @@ complete: return rc; } -int sysfs_string_write(char *path, char *buffer, int length) +int sysfs_string_write(char *path, char *buffer, size_t length) { int fd = -1; int rc; - if (path == NULL || buffer == NULL || length <= 0) + if (path == NULL || buffer == NULL || length == 0) return -1; fd = open(path, O_WRONLY); |