diff options
author | Ziyan <jaraidaniel@gmail.com> | 2015-05-10 23:19:53 +0200 |
---|---|---|
committer | Ziyan <jaraidaniel@gmail.com> | 2015-05-10 23:19:53 +0200 |
commit | 603446cc7a9d537cc12806e6cedf2d2cd1b2ffe1 (patch) | |
tree | 31e7ba487174649b0980d63c2f46496d614178bc /arch | |
parent | e47e62a291bf7271f2880968e15e2a2b653bde0c (diff) | |
download | kernel_samsung_tuna-603446cc7a9d537cc12806e6cedf2d2cd1b2ffe1.zip kernel_samsung_tuna-603446cc7a9d537cc12806e6cedf2d2cd1b2ffe1.tar.gz kernel_samsung_tuna-603446cc7a9d537cc12806e6cedf2d2cd1b2ffe1.tar.bz2 |
tuna: vibrator: remove unnecessary logging
- don't log sysfs reads
- make pwm value change log message clearer
- only log vibrator events in dynamic debug mode
Diffstat (limited to 'arch')
-rwxr-xr-x | arch/arm/mach-omap2/board-tuna-vibrator.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/arch/arm/mach-omap2/board-tuna-vibrator.c b/arch/arm/mach-omap2/board-tuna-vibrator.c index c9d3055..c9e6d30 100755 --- a/arch/arm/mach-omap2/board-tuna-vibrator.c +++ b/arch/arm/mach-omap2/board-tuna-vibrator.c @@ -48,12 +48,7 @@ static struct vibrator { static ssize_t pwmvalue_show(struct device *dev, struct device_attribute *attr, char *buf) { - int count; - - count = sprintf(buf, "%lu\n", pwmval); - pr_info("vibrator: pwmval: %lu\n", pwmval); - - return count; + return sprintf(buf, "%lu\n", pwmval); } ssize_t pwmvalue_store(struct device *dev, @@ -63,7 +58,7 @@ ssize_t pwmvalue_store(struct device *dev, if (kstrtoul(buf, 0, &pwmval)) pr_err("vibrator: error in storing pwm value\n"); - pr_info("vibrator: pwmval: %lu\n", pwmval); + pr_info("vibrator: pwmval set to %lu\n", pwmval); return size; } @@ -163,7 +158,7 @@ static void vibrator_enable(struct timed_output_dev *dev, int value) hrtimer_cancel(&vibdata.timer); if (value) { - pr_info("vibrator: value=%d, pwmval=%lu\n", value, pwmval); + pr_debug("vibrator: value=%d, pwmval=%lu\n", value, pwmval); wake_lock(&vibdata.wklock); vibrator_timer_init(); gpio_set_value(vibdata.gpio_en, 1); |