summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorJeroen Hofstee <jeroen@myspectrum.nl>2014-06-09 15:28:58 +0200
committerMarek Vasut <marex@denx.de>2014-06-25 22:42:40 +0200
commit19a2a67fa27ac5bf50808bbded5c19279c7d86e5 (patch)
tree1e5067d55b8bee7d38e943278fda36bf0281b4ae /drivers
parent933611f7bbeb1b29218dca74cf1acfa910006cef (diff)
downloadu-boot-imx-19a2a67fa27ac5bf50808bbded5c19279c7d86e5.zip
u-boot-imx-19a2a67fa27ac5bf50808bbded5c19279c7d86e5.tar.gz
u-boot-imx-19a2a67fa27ac5bf50808bbded5c19279c7d86e5.tar.bz2
usb:g_dnl:f_thor: remove memset before memcpy
since ALLOC_CACHE_ALIGN_BUFFER defines a pointer and not a buffer, the memset with sizeof(rqt) likely does something else then intended. Since there is a memcpy directly after it with the full size, drop the memset completely. Cc: Lukasz Majewski <l.majewski@samsung.com> Cc: Marek Vasut <marex@denx.de> Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl> Acked-by: Lukasz Majewski <l.majewski@samsung.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/usb/gadget/f_thor.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/usb/gadget/f_thor.c b/drivers/usb/gadget/f_thor.c
index 28f215e..4e06273 100644
--- a/drivers/usb/gadget/f_thor.c
+++ b/drivers/usb/gadget/f_thor.c
@@ -306,7 +306,6 @@ static int process_data(void)
ALLOC_CACHE_ALIGN_BUFFER(struct rqt_box, rqt, sizeof(struct rqt_box));
int ret = -EINVAL;
- memset(rqt, 0, sizeof(rqt));
memcpy(rqt, thor_rx_data_buf, sizeof(struct rqt_box));
debug("+RQT: %d, %d\n", rqt->rqt, rqt->rqt_data);