Re: [linux-pm] [TuxOnIce-devel] [RFC] TuxOnIce

From: Len Brown
Date: Wed May 27 2009 - 15:19:53 EST


> > > The possibilities I see are:
> > >
> > > 1) Assume we can't know exactly how much but can allow a ball-park
> > > figure (current method)
> > > 2) Implement a means by which components that might allocate memory can
> > > tell us how much they might allocate (currently used internally by
> > > tuxonice - part of the modular design). I'd love to see this for the
> > > drivers' suspend code.
> >
> > The drivers' suspend code is too late, we need to know that before the drivers'
> > suspend callbacks are run.
>
> Yeah, sorry for not being clear enough. I meant I'd like to see a new
> function in the API that lets us enquire early on as to how much memory
> will be needed. That said, I like the idea of just asking them to
> allocate memory earlier better.

The more we require of driver writers, the more likely it is that
they'll get it wrong and we will fail.

I believe it must remain a fundamental design goal that
the correctness burden on driver writers be as small as possible.

Of couse if optional hooks are availalble for an unusual driver that has
special requirements, that is fine, as long as unusual really is unusual.

thanks,
Len Brown, Intel Open Source Technology Center
--
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/