]> err.no Git - linux-2.6/commit
[POWERPC] spufs: fix possible memory corruption is spufs_mem_write
authorArnd Bergmann <arnd.bergmann@de.ibm.com>
Fri, 9 Mar 2007 23:05:35 +0000 (00:05 +0100)
committerArnd Bergmann <arnd@klappe.arndb.de>
Fri, 9 Mar 2007 23:07:48 +0000 (00:07 +0100)
commitaa0ed2bdb663608d5e409faecff3e1e81a3d413a
tree88382df6dec804ae319316753c661c8212cd0832
parentf194bda4ce7e71cc95535f494a4a5515cd91ed85
[POWERPC] spufs: fix possible memory corruption is spufs_mem_write

Due to a buggy unsigned comparison, it was possible to write
beyond the end of the local store file in spufs under some
circumstances.

This rewrites the buggy function to look more like
simple_copy_from_buffer.

Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
Cc: Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
arch/powerpc/platforms/cell/spufs/file.c