]> git.karo-electronics.de Git - karo-tx-linux.git/commit
pnfs-block: removing DM device maybe cause oops when call dev_remove
authorfanchaoting <fanchaoting@cn.fujitsu.com>
Thu, 21 Mar 2013 01:15:30 +0000 (09:15 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 5 Apr 2013 16:25:51 +0000 (09:25 -0700)
commit880a4e09e465c4fbb3f2f773803240f58d5ef078
tree688bb609ba1ab64562ccaf6eefe4beea9b42b7a7
parent1d50fe196140b67c14c5f969e67e0b8583e3ead8
pnfs-block: removing DM device maybe cause oops when call dev_remove

commit 4376c94618c26225e69e17b7c91169c45a90b292 upstream.

when pnfs block using device mapper,if umounting later,it maybe
cause oops. we apply "1 + sizeof(bl_umount_request)" memory for
msg->data, the memory maybe overflow when we do "memcpy(&dataptr
[sizeof(bl_msg)], &bl_umount_request, sizeof(bl_umount_request))",
because the size of bl_msg is more than 1 byte.

Signed-off-by: fanchaoting<fanchaoting@cn.fujitsu.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/nfs/blocklayout/blocklayoutdm.c