Re: [PATCH] libata: device suspend/resume

Jens Axboe
2005-05-27T06:55:26Z

On Fri, May 27 2005, Benjamin Herrenschmidt wrote:
> On Wed, 2005-05-25 at 11:29 +0200, Jens Axboe wrote:
> > On Tue, May 24 2005, Jeff Garzik wrote:
> > > Jens Axboe wrote:
> > > >I agree, it's a cleaner approach, with the rq being a container for
> > > >generel messages as well not just SCSI commands. The one missing piece
> > > >for that was the rq->end_io() callback so everything doesn't have to go
> > > >down sync, but that is in now as well.
> > > >
> > > >I'll try and cook something up.
> > >
> > > Very cool ;)
> >
> > This is the base for it. It splits request->flags into two variables:
> >
> > - cmd_type. this is not a bitmask, but a value indicating what type of
> > request this is.
> >
> > - cmd_flags. various command modified flags.
>
> I like it too. It's a long overdue cleanup :)

Indeed, it is something I wish I had done originally when moving away
from the 2.4 rq->cmd setup. Better late than never :)

> Another thing is we should/could probably move some of the other fields
> in the struct request into a union of structs. Some of them are never
> present simultaneously ...

Yes, that would be a nice way to save some space.

--
Jens Axboe