* [PATCH] via-mpu: compile without Power Management support
@ 2005-12-15 3:45 Kristian Mueller
2005-12-15 4:14 ` Olof Johansson
0 siblings, 1 reply; 4+ messages in thread
From: Kristian Mueller @ 2005-12-15 3:45 UTC (permalink / raw)
To: linuxppc-dev
[-- Attachment #1: Type: text/plain, Size: 77 bytes --]
Don't check for sleep_in_progress if there is no
Power Management support.
[-- Attachment #2: pmu-without-pm.patch --]
[-- Type: text/x-patch, Size: 817 bytes --]
--- linux/drivers/macintosh/via-pmu.c.orig 2005-12-15 11:28:28.000000000 +0800
+++ linux/drivers/macintosh/via-pmu.c 2005-12-15 10:04:53.000000000 +0800
@@ -2911,8 +2911,10 @@ pmu_ioctl(struct inode * inode, struct f
* the fbdev
*/
case PMU_IOC_GET_BACKLIGHT:
+#if defined(CONFIG_PM) && defined(CONFIG_PPC32)
if (sleep_in_progress)
return -EBUSY;
+#endif /* CONFIG_PM && CONFIG_PPC32 */
error = get_backlight_level();
if (error < 0)
return error;
@@ -2920,8 +2922,10 @@ pmu_ioctl(struct inode * inode, struct f
case PMU_IOC_SET_BACKLIGHT:
{
__u32 value;
+#if defined(CONFIG_PM) && defined(CONFIG_PPC32)
if (sleep_in_progress)
return -EBUSY;
+#endif /* CONFIG_PM && CONFIG_PPC32 */
error = get_user(value, argp);
if (!error)
error = set_backlight_level(value);
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH] via-mpu: compile without Power Management support 2005-12-15 3:45 [PATCH] via-mpu: compile without Power Management support Kristian Mueller @ 2005-12-15 4:14 ` Olof Johansson 2005-12-15 4:31 ` Kristian Mueller 0 siblings, 1 reply; 4+ messages in thread From: Olof Johansson @ 2005-12-15 4:14 UTC (permalink / raw) To: Kristian Mueller; +Cc: linuxppc-dev On Thu, Dec 15, 2005 at 11:45:22AM +0800, Kristian Mueller wrote: > Don't check for sleep_in_progress if there is no > Power Management support. Creeping #ifdeffing, not good. Please move the sleep_in_progress variable outside of #ifdef where it's defined instead, it will default to 0 and never trigger, but things will still build. -Olof ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] via-mpu: compile without Power Management support 2005-12-15 4:14 ` Olof Johansson @ 2005-12-15 4:31 ` Kristian Mueller 2005-12-15 5:30 ` Paul Mackerras 0 siblings, 1 reply; 4+ messages in thread From: Kristian Mueller @ 2005-12-15 4:31 UTC (permalink / raw) To: Olof Johansson; +Cc: linuxppc-dev [-- Attachment #1: Type: text/plain, Size: 271 bytes --] > Please move the sleep_in_progress variable outside of #ifdef where it's > defined instead, it will default to 0 and never trigger, but things will > still build. Okay good point, done. Fix compilation of via-mpu.c without Power Management support. Regards, Kristian [-- Attachment #2: pmu-without-pm-revised.patch --] [-- Type: text/x-patch, Size: 493 bytes --] --- linux/drivers/macintosh/via-pmu.c.orig 2005-12-15 11:28:28.000000000 +0800 +++ linux/drivers/macintosh/via-pmu.c 2005-12-15 12:20:43.000000000 +0800 @@ -157,8 +157,8 @@ static int pmu_version; static int drop_interrupts; #if defined(CONFIG_PM) && defined(CONFIG_PPC32) static int option_lid_wakeup = 1; -static int sleep_in_progress; #endif /* CONFIG_PM && CONFIG_PPC32 */ +static int sleep_in_progress; static unsigned long async_req_locks; static unsigned int pmu_irq_stats[11]; ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] via-mpu: compile without Power Management support 2005-12-15 4:31 ` Kristian Mueller @ 2005-12-15 5:30 ` Paul Mackerras 0 siblings, 0 replies; 4+ messages in thread From: Paul Mackerras @ 2005-12-15 5:30 UTC (permalink / raw) To: Kristian Mueller; +Cc: linuxppc-dev Kristian Mueller writes: > Fix compilation of via-mpu.c without Power Management support. I'll take this without a Signed-off-by line this time, since it's pretty trivial, but in general please include a Signed-off-by line (see Documentation/SubmittingPatches for what that is). Paul. ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2005-12-15 5:30 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2005-12-15 3:45 [PATCH] via-mpu: compile without Power Management support Kristian Mueller 2005-12-15 4:14 ` Olof Johansson 2005-12-15 4:31 ` Kristian Mueller 2005-12-15 5:30 ` Paul Mackerras
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).