On Monday, 25 September 2006 09:42, Stefan Seyfried wrote: > On Mon, Sep 25, 2006 at 09:18:16AM +0200, Rafael J. Wysocki wrote: > > On Monday, 25 September 2006 08:32, Stefan Seyfried wrote: > > > On Sun, Sep 24, 2006 at 10:09:44AM +0200, Pavel Machek wrote: > > > > Hi! > > > > > > > > > Make it possible to set the s2disk shutdown method in the config > > > > > file. > > > > > > > > Thanks, applied. > > > > > > Now somebody please write a parser that overrides the config-file from > > > the command line :-) > > > > > > Since probably nobody (besides testing from init=/bin/bash) will be > > > using s2disk without some wrapper, this config-file stuff is a major > > > PITA (i'll probably need to generate it dynamically etc). > > > > Why exactly? > > Regular users will use powersaved, acpid or HAL to suspend via some nice > graphical frontend or a button press, not become root and type "s2disk".
Right. > It is a PITA since i have to (for example), in order to port the "retry > suspend with smaller image if we were 'out of swap' in the first round" > or the "if there is only 300mb swap free, it does not make sense to request > a 350mb image, so in this case only request 270mb" features from in-kernel > to uswsusp, write the config file dynamically with my calculated "best" > image size. First, s2disk will automatically set image_size to 0 if it cannot suspend with the user-provided one. :-) Second, you have given a very specific example. Generally the settings don't change between subsequent invocations of s2disk, so the need to stay in a config file, and it really doesn't matter in which one. > Also, i taught my users to use "resume=" kernel parameter and they took > a long time to learn this, so i will use "resume=" in the future, and since > i cannot give it on the command line (only for resume, not for s2disk), i > will need to write the config file dynamically with this info. This also > makes the update case easier. (the latest SUSE mkinitrd is already just > using resume= for resuming and not adding the config file to the initrd > at all) > > Oops. I just checked the code. Apparently i can give s2disk the device > also on the command line. But anyway, still applies at least for the image > size. I think we can add command line options for the parameters that can be set via sysfs or the kernel command line when the in-kernel swsusp is used. Greetings, Rafael -- You never change things by fighting the existing reality. R. Buckminster Fuller ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Suspend-devel mailing list Suspend-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/suspend-devel