Re: Suspend 2 merge: 21/51: Refrigerator upgrade.

From: Pavel Machek
Date: Sat Nov 27 2004 - 00:39:57 EST


Hi!

> > > Included in this patch is a new try_to_freeze() macro Andrew M suggested
> > > a while back. The refrigerator declarations are put in sched.h to save
> > > extra includes of suspend.h.
> >
> > try_to_freeze looks nice. Could we get it in after 2.6.10 opens?
>
> I'm hoping to get the whole thing in mm once all these replies are dealt
> with. Does that sound unrealistic?

Yes, a little ;-).

> > > */
> > > int fsync_super(struct super_block *sb)
> > > {
> > > + int ret;
> > > +
> > > + /* A safety net. During suspend, we might overwrite
> > > + * memory containing filesystem info. We don't then
> > > + * want to sync it to disk. */
> > > + if (unlikely(test_suspend_state(SUSPEND_DISABLE_SYNCING)))
> > > + return 0;
> > > +
> >
> > If it is safety net, do BUG_ON().
>
> Could get triggered by user pressing SysRq. (Or via a panic?). I don't
> think the SysRq should result in a panic; nor should a panic result in a
> recursive call to panic (although I'm wondering here, wasn't the call to
> syncing in panic taken out?).

Silently doing nothing when user asked for sync is not nice,
either. BUG() is better solution than that.
Pavel
--
People were complaining that M$ turns users into beta-testers...
...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/