]> git.karo-electronics.de Git - karo-tx-linux.git/commit
rtc: rtc-hid-sensor-time: allow full years (16bit) in HID reports
authorAlexander Holler <holler@ahsoftware.de>
Wed, 19 Jun 2013 00:07:50 +0000 (10:07 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 19 Jun 2013 07:27:24 +0000 (17:27 +1000)
commit6338d3d97ec18545590ba75b8323ab58a13bbde3
tree8f51f78ae3807b524dbd01d6caa78433f3e92b3b
parent0de72b396364b6dbc67ec58ee71b918f00c1764a
rtc: rtc-hid-sensor-time: allow full years (16bit) in HID reports

The draft for HID-sensors (HUTRR39) currently doesn't define the range for
the attribute year.  Asking one of the authors revealed that full years
(e.g.  2013 instead of just 13) were meant.

So we now allow both, 8 bit and 16 bit values for the attribute year and
assuming full years when the value is 16 bits wide.

We will still support 8 bit values until the specification gets final
(and maybe defines a way to set the time too).

Signed-off-by: Alexander Holler <holler@ahsoftware.de>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Cc: Lars-Peter Clausen <lars@metafoo.de>
Cc: Jonathan Cameron <jic23@cam.ac.uk>
Cc: Jiri Kosina <jkosina@suse.cz>
Cc: John Stultz <john.stultz@linaro.org>
Cc: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
drivers/rtc/rtc-hid-sensor-time.c