* [PATCH] compal-laptop.c: added JHL90, battery & hwmon interface
@ 2010-04-05 19:14 Roald Frederickx
2010-04-08 16:16 ` Roald Frederickx
0 siblings, 1 reply; 2+ messages in thread
From: Roald Frederickx @ 2010-04-05 19:14 UTC (permalink / raw)
To: mingo, superm1, mario_limonciello, linux-kernel
[-- Attachment #1: Type: text/plain, Size: 2598 bytes --]
Dear kernel developers,
On February the fourth I have contacted Cezary Jackiewicz regarding a
(large) addition to the compal-laptop driver (he is listed in the
maintainers file as the person to contact). However I still haven't
received any reply to date. I have recently checked the github commits
on this driver and I saw some activity during February and March. I
have patched my original addition to the driver to reflect the changes
that were made to the driver in the meantime. This mail is sent to all
the people that were involved in those github commits (excluding
Linus) and to the kernel mailing list.
About the additions:
The driver now supports the Compal JHL90 (which I use) and it has some
added features. The biggest novelties are a battery interface
(power_supply) and a temperature and fan control interface (hmwon).
Much of the original code of the old features is still there, but I've
changed some names to keep the naming more coherent with the added
functionalities.
This is my first kernel patch, so I'm new to this. I've added my name
and email address as an author (I'm willing to respond to questions,
and/or to test future versions on a JHL90 platform). I also bumped up
the version number to 0.2.7 as this is quite a big change.
Some technical stuff about the new driver:
NOTE: First of all, I'm not sure if the extra features also work on
the other Compal boards. If it turns out they only work on the JHL90,
then the driver can easily be altered to only enable them if the DMI
detection find such a board. (I can make those changes, should this be
needed.)
I've noticed a quirk in my fan controller. I have to re-send the
wanted pwm-level to the controller every so often. If I don't do this,
the fanspeed will slowly rise until after a couple of minutes it's at
full speed. (Note that every normal userland application will probably
update the pwm-level every so often anyway, based on temperature
readings, so this might not be an issue in practice) If this turns out
to be a problem with all the controllers, maybe we should implement a
kernel timer and have the driver re-send the pwm level every XX
seconds to make this transparent to userspace? (However, I couldn't
immediately find a way to do this *cleanly*.)
Additional information can be found in the source comments.
Lastly: the code. I've just inserted the entire source code. A diff
wouldn't be of much use given the amount of code that was altered and
added. It's attached as a bzipped tarball containing two files:
compal-laptop.c and the advised README.
Kind regards,
Roald Frederickx
[-- Attachment #2: compal-laptop.tar.bz2 --]
[-- Type: application/x-bzip2, Size: 8283 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] compal-laptop.c: added JHL90, battery & hwmon interface
2010-04-05 19:14 [PATCH] compal-laptop.c: added JHL90, battery & hwmon interface Roald Frederickx
@ 2010-04-08 16:16 ` Roald Frederickx
0 siblings, 0 replies; 2+ messages in thread
From: Roald Frederickx @ 2010-04-08 16:16 UTC (permalink / raw)
To: mingo, superm1, mario_limonciello, linux-kernel
I overlooked a patch (I reverted back to an older kernel for an
unrelated issue), this should be applied for the current kernel:
--- compal-laptop.c 2010-04-05 20:44:22.727791103 +0200
+++ compal-laptop-new.c 2010-04-06 16:29:00.799286626 +0200
@@ -928,12 +928,15 @@
/* Register backlight stuff */
if (!acpi_video_backlight_support()) {
- compalbl_device = backlight_device_register(DRIVER_NAME,
- NULL, NULL, &compalbl_ops);
+ struct backlight_properties props;
+ memset(&props, 0, sizeof(struct backlight_properties));
+ props.max_brightness = BACKLIGHT_LEVEL_MAX;
+ compalbl_device = backlight_device_register(DRIVER_NAME,
+ NULL, NULL,
+ &compalbl_ops,
+ &props);
if (IS_ERR(compalbl_device))
return PTR_ERR(compalbl_device);
-
- compalbl_device->props.max_brightness = BACKLIGHT_LEVEL_MAX;
}
ret = platform_driver_register(&compal_driver);
2010/4/5 Roald Frederickx <roald.frederickx@gmail.com>:
> Dear kernel developers,
>
> On February the fourth I have contacted Cezary Jackiewicz regarding a
> (large) addition to the compal-laptop driver (he is listed in the
> maintainers file as the person to contact). However I still haven't
> received any reply to date. I have recently checked the github commits
> on this driver and I saw some activity during February and March. I
> have patched my original addition to the driver to reflect the changes
> that were made to the driver in the meantime. This mail is sent to all
> the people that were involved in those github commits (excluding
> Linus) and to the kernel mailing list.
>
>
> About the additions:
>
> The driver now supports the Compal JHL90 (which I use) and it has some
> added features. The biggest novelties are a battery interface
> (power_supply) and a temperature and fan control interface (hmwon).
>
> Much of the original code of the old features is still there, but I've
> changed some names to keep the naming more coherent with the added
> functionalities.
>
> This is my first kernel patch, so I'm new to this. I've added my name
> and email address as an author (I'm willing to respond to questions,
> and/or to test future versions on a JHL90 platform). I also bumped up
> the version number to 0.2.7 as this is quite a big change.
>
>
> Some technical stuff about the new driver:
>
> NOTE: First of all, I'm not sure if the extra features also work on
> the other Compal boards. If it turns out they only work on the JHL90,
> then the driver can easily be altered to only enable them if the DMI
> detection find such a board. (I can make those changes, should this be
> needed.)
>
> I've noticed a quirk in my fan controller. I have to re-send the
> wanted pwm-level to the controller every so often. If I don't do this,
> the fanspeed will slowly rise until after a couple of minutes it's at
> full speed. (Note that every normal userland application will probably
> update the pwm-level every so often anyway, based on temperature
> readings, so this might not be an issue in practice) If this turns out
> to be a problem with all the controllers, maybe we should implement a
> kernel timer and have the driver re-send the pwm level every XX
> seconds to make this transparent to userspace? (However, I couldn't
> immediately find a way to do this *cleanly*.)
>
> Additional information can be found in the source comments.
>
>
> Lastly: the code. I've just inserted the entire source code. A diff
> wouldn't be of much use given the amount of code that was altered and
> added. It's attached as a bzipped tarball containing two files:
> compal-laptop.c and the advised README.
>
>
> Kind regards,
>
> Roald Frederickx
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-04-08 16:17 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-05 19:14 [PATCH] compal-laptop.c: added JHL90, battery & hwmon interface Roald Frederickx
2010-04-08 16:16 ` Roald Frederickx
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).