]> git.karo-electronics.de Git - karo-tx-linux.git/commit
USB: ums_realtek: do not use stack memory for DMA in __do_config_autodelink
authorJosh Boyer <jwboyer@redhat.com>
Mon, 20 Feb 2012 20:34:34 +0000 (15:34 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 2 Apr 2012 16:52:32 +0000 (09:52 -0700)
commit61849d8278208ab8445e6143387b5cfe0219c21d
treed748aa00c73b1e851290ab6a16068b91107d2361
parent727414186307fa88c9240f32cfe45a11b672274e
USB: ums_realtek: do not use stack memory for DMA in __do_config_autodelink

commit 4898e07174b79013afd2b422ef6c4336ef8e6783 upstream.

__do_config_autodelink passes the data variable to the transport function.
If the calling functions pass a stack variable, this will eventually trigger
a DMA-API debug backtrace for mapping stack memory in the DMA buffer.  Fix
this by calling kmemdup for the passed data instead.

Signed-off-by: Josh Boyer <jwboyer@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/storage/realtek_cr.c