diff options
author | Akinobu Mita <mita@fixstars.com> | 2007-04-23 21:08:18 +0200 |
---|---|---|
committer | Arnd Bergmann <arnd@klappe.arndb.de> | 2007-04-23 21:18:56 +0200 |
commit | 577f8f1021f9ee6ef2a98a142652759ec122d27f (patch) | |
tree | 4d83409765bca551223ead236733e69d6998a111 /arch/powerpc/platforms | |
parent | [POWERPC] spufs: turn run_sema into run_mutex (diff) | |
download | linux-577f8f1021f9ee6ef2a98a142652759ec122d27f.tar.xz linux-577f8f1021f9ee6ef2a98a142652759ec122d27f.zip |
[POWERPC] spufs: check spu_acquire_runnable() return value
This patch checks return value of spu_acquire_runnable() in
spufs_mfc_write().
Signed-off-by: Akinobu Mita <mita@fixstars.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
Diffstat (limited to 'arch/powerpc/platforms')
-rw-r--r-- | arch/powerpc/platforms/cell/spufs/file.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/powerpc/platforms/cell/spufs/file.c b/arch/powerpc/platforms/cell/spufs/file.c index deb340e6e0ae..525d6b00cba2 100644 --- a/arch/powerpc/platforms/cell/spufs/file.c +++ b/arch/powerpc/platforms/cell/spufs/file.c @@ -1443,7 +1443,10 @@ static ssize_t spufs_mfc_write(struct file *file, const char __user *buffer, if (ret) goto out; - spu_acquire_runnable(ctx, 0); + ret = spu_acquire_runnable(ctx, 0); + if (ret) + goto out; + if (file->f_flags & O_NONBLOCK) { ret = ctx->ops->send_mfc_command(ctx, &cmd); } else { |