OSDN Git Service

USB: gadget: validate endpoint index for xilinx udc
authorSzymon Heidrich <szymon.heidrich@gmail.com>
Mon, 21 Feb 2022 12:24:56 +0000 (13:24 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 24 Feb 2022 10:00:07 +0000 (11:00 +0100)
commit7f14c7227f342d9932f9b918893c8814f86d2a0d
tree2a5e1772a1c7477223f9a4ac54dee6f62dcbe1f2
parent32fde84362c40961726a5c91f35ad37355ccc0c6
USB: gadget: validate endpoint index for xilinx udc

Assure that host may not manipulate the index to point
past endpoint array.

Signed-off-by: Szymon Heidrich <szymon.heidrich@gmail.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/gadget/udc/udc-xilinx.c