From e0a52fbe19e4454ba7d3b7594a41c8630c3338c8 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Pali=20Roh=C3=A1r?= Date: Sat, 9 Feb 2013 11:06:05 +0100 Subject: [PATCH 1/1] =?utf8?q?Fix=20reporting=20temperature=20in=20rx51=5Fba?= =?utf8?q?ttery=20driver=20(driver=20should=20export=20temperature=20in=201/?= =?utf8?q?10=20=C2=B0C)?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- kernel-power-2.6.28/debian/changelog | 1 + .../debian/patches/rx51_battery.patch | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/kernel-power-2.6.28/debian/changelog b/kernel-power-2.6.28/debian/changelog index cadf824..0d4f6d0 100644 --- a/kernel-power-2.6.28/debian/changelog +++ b/kernel-power-2.6.28/debian/changelog @@ -13,6 +13,7 @@ kernel-power (1:2.6.28-10power52) fremantle; urgency=low * Add sysfs entry hostdevice2 which show host device speed detected by musb_virthub.c * Optify bootimg package * Enable vlan (8021q) module + * Fix reporting temperature in rx51_battery driver (driver should export temperature in 1/10 °C) -- Pali Rohár Fri, 18 Jan 2013 17:31:40 +0100 diff --git a/kernel-power-2.6.28/debian/patches/rx51_battery.patch b/kernel-power-2.6.28/debian/patches/rx51_battery.patch index dd80bc2..877e81e 100644 --- a/kernel-power-2.6.28/debian/patches/rx51_battery.patch +++ b/kernel-power-2.6.28/debian/patches/rx51_battery.patch @@ -119,7 +119,7 @@ + + /* First check for temperature in first direct table */ + if (raw < ARRAY_SIZE(rx51_temp_table1)) -+ return rx51_temp_table1[raw] * 100; ++ return rx51_temp_table1[raw] * 10; + + /* Binary search RAW value in second inverse table */ + while (max-min > 1) { @@ -132,7 +132,7 @@ + break; + } + -+ return (rx51_temp_table2_first - min) * 100; ++ return (rx51_temp_table2_first - min) * 10; +} + +/* -- 1.7.9.5