On Sunday, 9 of December 2007, Borislav Petkov wrote:
> On Sat, Dec 08, 2007 at 11:50:33PM +0100, Rafael J. Wysocki wrote:
> > On Saturday, 8 of December 2007, Borislav Petkov wrote:
> > > On Fri, Dec 07, 2007 at 09:19:09PM +0100, Rafael J. Wysocki wrote:
> > >
> > > ...
> > >
> > > > > > Well, there's a patchset in the current mainline that allows you to use
> > > > > > arbitrary (sufficiently new) kernel to load the image and then restore the
> > > > > > image kernel. So, you can hibernate 2.6.24-rc3 and use 2.6.24-rc2 to restore
> > > > > > it, for example.
> > > > > >
> > > > > > I'm going to do that for i386 too.
> > > > > right, this is d307c4a8e826c44f9633bd3f7e60d0491e7d885a (Hibernation: Arbitrary
> > > > > boot kernel support - generic code), i should've seen that. What's the status of
> > > > > those bits, from a quick scan it seems they need some rewiring (Kconfig, e.g.
> > > > > CONFIG_ARCH_HIBERNATION_HEADER etc..) and arch-specific save and restore
> > > > > functions?
> > > >
> > > > No, this code is fully functional. :-)
> > > >
> > > > The arch save and restore functions are in arch/x86/kernel/suspend_64.c .
> > > >
> > > > As I said, i386 is not yet supported.
> > >
> > > nice, holler if you need a tester when you have some prototypes ready. By the way,
> > > what do you do when the suspend image header mismatches and it is unsafe to continue booting?
> >
> > If the image header doesn't match, we don't load it and return an error code,
> > which usually results in the boot kernel continuing to boot.
>
> But if you continue to boot the filesystems were still mounted and fsck has to
> go over them and check for errors. In the case of ext2 this takes relatively
> long depending on the size of the partition. However, this is only the
> smaller problem, the problem of data loss is what worries me.
The filesystems are synced before the hibernation, so there shouldn't be data
any loss.
> Instead, I'd rather issue a warning that the swsusp header mismatches, say with
> which kernel the machine got suspended with and then start the countdown for reboot.
What exactly would that change? You need to reboot anyway and fsck will run on
the filesystems regardless of which kernel you boot with.
Rafael
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]