[Cbe-oss-dev] PATCH [2/7] class 0 and 1 rework [Updated]

Arnd Bergmann arnd at arndb.de
Wed Nov 7 20:30:11 EST 2007


On Wednesday 07 November 2007, Jeremy Kerr wrote:
> > +     if (stat) {
> > +             if (ctx->flags & SPU_CREATE_EVENTS_ENABLED) {
> > +                     if (stat & 1)           /* invalid DMA alignment */
> > +                             ctx->event_return |= SPE_EVENT_DMA_ALIGNMENT;
> > +
> > +                     if (stat & 2)           /* invalid MFC DMA */
> > +                             ctx->event_return |= SPE_EVENT_INVALID_DMA;
> > +
> > +                     if (stat & 4)           /* error on SPU */
> > +                             ctx->event_return |= SPE_EVENT_SPE_ERROR;
> > +
> > +                     wake_up_all(&ctx->stop_wq);
> 
> Also, what do we expect to have on the stop_wq at this point? To get to 
> this code, we have already hit the spufs_stop_callback, which has just 
> done a wake_up_all(&ctx->stop_wq). In fact, that's what woke this 
> thread up.
> 
> Or is this intended to catch anything that's added to the stop_wq 
> between these events? If so, I'll add a comment here.
> 

I would guess that it's a cut+paste error that was present in my original
patch. It looks harmless but should be removed AFAICS.

Good catch!

	Arnd <><


More information about the cbe-oss-dev mailing list