mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2005@gmx.net>
Cc: ncunningham@linuxmail.org,
	ACPI List <acpi-devel@lists.sourceforge.net>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [RFC] Reliable video POSTing on resume (was: Re: [ACPI] Samsung P35, S3, black screen (radeon))
Date: Fri, 4 Feb 2005 08:48:02 +0100	[thread overview]
Message-ID: <20050204074802.GD1086@elf.ucw.cz> (raw)
In-Reply-To: <4202DF7B.2000506@gmx.net>

Hi!

> > I'd love to see it too. Pavel, even if you don't want to merge it for a
> > while, we can always incorporate it in the Suspend2 patches so it gets
> > some testing. I know I'd try it on my i830 based Omnibook.
> 
> Can we use call_usermodehelper at this early resume stage (before any
> video access)? Calling vm86 directly is probably not going to fly
> because we want to be shielded from any misbehaviour in the bios code
> and it may be necessary to kill the process running the bios code.
> 
> Cases in point: My bios will cause the POSTing application to segfault.
> Others have reported the POSTing application just hangs, but the
> important things are done before the hang, so killing it after maybe
> 5 seconds would be ok.
> 
> Rough outline how to do that without adding tons of code:
> We need a call_usermodehelper_from_ram_with_timeout for that.
> 
> Kernel:                          Userspace:
> User wants to enter S3
> init_mutex_locked(s3_sem)
> call_usermodehelper("vesaposter")
>                                  vesaposter calls LRMI_init
>                                  vesaposter mlocks all its memory
>                                  vesaposter calls into kernel
>                                           and down(s3_sem)
> suspend vesafb
> 
> User has triggered resume
> run wakeup.S
> thaw essential threads
> set a timer of 5 seconds
> up(s3_sem)
> thaw and schedule vesaposter
> wait for timer or vesaposter termination
>                                  vesaposter returns from kernel
>                                  vesaposter posts video card
>                                  vesaposter terminates
> resume vesafb
> continue resume
> 
> Problems with that approach:
> - vesaposter has to be locked in memory to avoid disk accesses
> - vesafb has to refrain from touching video until after POST
> - the vesaposter thread has to be the first unfrozen and
>   scheduled and completed thread. Only after that we can resume
>   vesafb and other threads
> - the locking will be tricky

- it is ugly

What about simply blocking all video accesses before disk (etc) is
resumed, so that "normal" (not locked in memory) application can be
used?
								Pavel
-- 
People were complaining that M$ turns users into beta-testers...
...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!

  parent reply	other threads:[~2005-02-04  7:54 UTC|newest]

Thread overview: 82+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20050122134205.GA9354@wsc-gmbh.de>
     [not found] ` <4201825B.2090703@gmx.net>
     [not found]   ` <e796392205020221387d4d8562@mail.gmail.com>
     [not found]     ` <420217DB.709@gmx.net>
     [not found]       ` <4202A972.1070003@gmx.net>
     [not found]         ` <20050203225410.GB1110@elf.ucw.cz>
     [not found]           ` <1107474198.5727.9.camel@desktop.cunninghams>
2005-02-04  2:35             ` Carl-Daniel Hailfinger
2005-02-04  2:51               ` Nigel Cunningham
2005-02-04  7:18                 ` Jon Smirl
2005-02-04  7:44                   ` Pavel Machek
2005-02-04 17:38                     ` Jon Smirl
2005-02-05  0:52                       ` [RFC] Reliable video POSTing on resume Carl-Daniel Hailfinger
2005-02-05  1:08                         ` Jon Smirl
2005-02-05  9:35                       ` [RFC] Reliable video POSTing on resume (was: Re: [ACPI] Samsung P35, S3, black screen (radeon)) Pavel Machek
2005-02-05 11:35                         ` [RFC] Reliable video POSTing on resume Ondrej Zary
2005-02-06 16:02                         ` [RFC] Reliable video POSTing on resume (was: Re: [ACPI] Samsung P35, S3, black screen (radeon)) Alan Cox
2005-02-07  2:11                           ` Adam Sulmicki
2005-02-07 14:27                             ` [RFC] Reliable video POSTing on resume Paulo Marques
2005-02-07 14:36                               ` Carl-Daniel Hailfinger
2005-02-07 15:39                                 ` Paulo Marques
2005-02-07 16:01                                 ` Pavel Machek
2005-02-07 16:20                                   ` Li-Ta Lo
2005-02-11  1:47                                     ` [ACPI] " Carl-Daniel Hailfinger
2005-02-07 18:04                                 ` Adam Sulmicki
2005-02-07 16:39                               ` Li-Ta Lo
2005-02-07 13:24                           ` [ACPI] Re: [RFC] Reliable video POSTing on resume (was: Re: [ACPI] Samsung P35, S3, black screen (radeon)) Matthew Garrett
2005-02-07 14:09                             ` Pavel Machek
2005-02-10 19:13                           ` Bill Davidsen
2005-02-10 19:25                             ` Ville Syrjälä
2005-02-10 20:08                               ` Matthew Garrett
2005-02-10 20:17                                 ` Jon Smirl
2005-02-10 20:29                                   ` Matthew Garrett
2005-02-10 20:34                                     ` Jon Smirl
2005-02-10 20:46                                       ` [RFC] Reliable video POSTing on resume Kendall Bennett
2005-02-10 21:06                                         ` Matthew Garrett
2005-02-10 21:20                                           ` Kendall Bennett
2005-02-10 21:28                                           ` Jon Smirl
2005-02-10 22:53                                             ` Matthew Garrett
2005-02-11  1:41                                             ` [ACPI] " Carl-Daniel Hailfinger
2005-02-10 20:32                                   ` [RFC] Reliable video POSTing on resume (was: Re: [ACPI] Samsung P35, S3, black screen (radeon)) Ville Syrjälä
2005-02-10 19:31                             ` Pavel Machek
2005-02-10 23:03                             ` Matan Ziv-Av
2005-02-07 19:27                         ` Eric W. Biederman
2005-02-07 20:59                           ` Pavel Machek
2005-02-04  5:03               ` Jon Smirl
2005-02-04  7:49                 ` Pavel Machek
2005-02-04 12:17                 ` [RFC] Reliable video POSTing on resume Carl-Daniel Hailfinger
2005-02-04 13:51                   ` [ACPI] " Matthew Garrett
2005-02-04 16:30                   ` Pavel Machek
2005-02-04 17:31                     ` Jon Smirl
2005-02-04 18:10                       ` Jesse Barnes
2005-02-04 20:29                         ` Jon Smirl
2005-02-04 22:13                           ` James Simmons
2005-02-04 21:56                         ` James Simmons
2005-02-04 22:59                         ` Legacy IO spaces (was Re: [RFC] Reliable video POSTing on resume) Jon Smirl
2005-02-04 23:34                           ` Jesse Barnes
2005-02-05  0:48                             ` Jon Smirl
2005-02-05 22:42                               ` [ACPI] " Benjamin Herrenschmidt
2005-02-06  0:17                                 ` Jon Smirl
2005-02-06  0:07                             ` Jon Smirl
2005-02-06  0:19                               ` Jesse Barnes
2005-02-05  2:04                       ` [RFC] Reliable video POSTing on resume Matthew Garrett
2005-02-05  2:09                         ` Jon Smirl
2005-02-05  2:17                           ` Matthew Garrett
2005-02-05  2:30                             ` Jon Smirl
2005-02-05  8:15                               ` Matthew Garrett
2005-02-05 11:53                                 ` Ondrej Zary
2005-02-05 12:28                                   ` Matthew Garrett
2005-02-05 15:47                                   ` Jon Smirl
2005-02-05 16:48                                     ` [ACPI] " Stefan Dösinger
2005-02-05 17:38                                       ` Jon Smirl
2005-02-06 11:05                                         ` Stefan Dösinger
2005-02-07 10:20                                         ` Helge Hafting
2005-02-07 14:22                                           ` Pavel Machek
2005-02-05 15:55                                 ` Jon Smirl
2005-02-05  9:37                       ` Pavel Machek
2005-02-05  9:49                         ` Nigel Cunningham
2005-02-05 15:49                         ` Jon Smirl
2005-02-04 22:09                     ` James Simmons
2005-02-05  1:07                       ` Carl-Daniel Hailfinger
2005-02-05  1:14                     ` Carl-Daniel Hailfinger
2005-02-04 14:40                 ` [RFC] Reliable video POSTing on resume (was: Re: [ACPI] Samsung P35, S3, black screen (radeon)) Xavier Bestel
2005-02-05  1:10                   ` [RFC] Reliable video POSTing on resume Carl-Daniel Hailfinger
2005-02-04  7:48               ` Pavel Machek [this message]
2005-02-04 10:26                 ` [RFC] Reliable video POSTing on resume (was: Re: [ACPI] Samsung P35, S3, black screen (radeon)) Oliver Neukum
2005-02-04 11:32                   ` [RFC] Reliable video POSTing on resume Carl-Daniel Hailfinger
2005-02-04 12:11                     ` [ACPI] " David Goodenough
2005-02-04 16:15                     ` Pavel Machek

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050204074802.GD1086@elf.ucw.cz \
    --to=pavel@ucw.cz \
    --cc=acpi-devel@lists.sourceforge.net \
    --cc=c-d.hailfinger.devel.2005@gmx.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ncunningham@linuxmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome