diff options
Diffstat (limited to 'drivers/input')
-rw-r--r-- | drivers/input/touchscreen/usbtouchscreen.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/input/touchscreen/usbtouchscreen.c b/drivers/input/touchscreen/usbtouchscreen.c index 99330bbdbac7..0b0ae2e17a60 100644 --- a/drivers/input/touchscreen/usbtouchscreen.c +++ b/drivers/input/touchscreen/usbtouchscreen.c | |||
@@ -811,12 +811,11 @@ static int nexio_init(struct usbtouch_usb *usbtouch) | |||
811 | 811 | ||
812 | priv = usbtouch->priv; | 812 | priv = usbtouch->priv; |
813 | 813 | ||
814 | priv->ack_buf = kmalloc(sizeof(nexio_ack_pkt), GFP_KERNEL); | 814 | priv->ack_buf = kmemdup(nexio_ack_pkt, sizeof(nexio_ack_pkt), |
815 | GFP_KERNEL); | ||
815 | if (!priv->ack_buf) | 816 | if (!priv->ack_buf) |
816 | goto err_priv; | 817 | goto err_priv; |
817 | 818 | ||
818 | memcpy(priv->ack_buf, nexio_ack_pkt, sizeof(nexio_ack_pkt)); | ||
819 | |||
820 | priv->ack = usb_alloc_urb(0, GFP_KERNEL); | 819 | priv->ack = usb_alloc_urb(0, GFP_KERNEL); |
821 | if (!priv->ack) { | 820 | if (!priv->ack) { |
822 | dbg("%s - usb_alloc_urb failed: usbtouch->ack", __func__); | 821 | dbg("%s - usb_alloc_urb failed: usbtouch->ack", __func__); |