From: Jeremy Kerr Date: Mon, 23 Apr 2007 19:08:24 +0000 (+0200) Subject: [POWERPC] spufs: Minor cleanup of spu_wait X-Git-Tag: v2.6.22-rc1~1109^2~72^2~5 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d3764397d07b1e03943edfdcc3fb77af7bdac02b;p=linux-2.6 [POWERPC] spufs: Minor cleanup of spu_wait Change the loop in spu_wait to be a little more straightforward. Signed-off-by: Jeremy Kerr Signed-off-by: Arnd Bergmann --- diff --git a/arch/powerpc/platforms/cell/spufs/spufs.h b/arch/powerpc/platforms/cell/spufs/spufs.h index dd5fc6494e..0a947fd7de 100644 --- a/arch/powerpc/platforms/cell/spufs/spufs.h +++ b/arch/powerpc/platforms/cell/spufs/spufs.h @@ -223,14 +223,13 @@ extern char *isolated_loader; prepare_to_wait(&(wq), &__wait, TASK_INTERRUPTIBLE); \ if (condition) \ break; \ - if (!signal_pending(current)) { \ - spu_release(ctx); \ - schedule(); \ - spu_acquire(ctx); \ - continue; \ + if (signal_pending(current)) { \ + __ret = -ERESTARTSYS; \ + break; \ } \ - __ret = -ERESTARTSYS; \ - break; \ + spu_release(ctx); \ + schedule(); \ + spu_acquire(ctx); \ } \ finish_wait(&(wq), &__wait); \ __ret; \