lkml.org 
[lkml]   [2004]   [Jan]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: suspend/resume support for PIT (time.c)
Pavel Machek <pavel@ucw.cz> wrote:
>
> +static int pit_resume(struct sys_device *dev)
> +{
> + write_seqlock_irq(&xtime_lock);
> + xtime.tv_sec = get_cmos_time() + clock_cmos_diff;
> + xtime.tv_nsec = 0;
> + write_sequnlock_irq(&xtime_lock);
> + return 0;
> +}

Have you checked the lock ranking here? get_cmos_time() takes a ton of
locks, especially if EFI is enabled. Do all those rank inside xtime_lock?

It _looks_ right, but perhaps it would be saner to move the get_coms_time()
call outside the lock?


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:59    [W:0.069 / U:0.180 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site