Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 738d7bb8 authored by Anson Jacob's avatar Anson Jacob Committed by Amit Pundir
Browse files

usb: gadget: f_accessory: remove duplicate endpoint alloc



usb_ep_autoconfig is called twice for allocating
bulk out endpoint.

Removed the unwanted call.

Fixes Issue: 67180

Change-Id: Ibced4127bb171076da0eeca3aed07eb1d8739762
Signed-off-by: default avatarAnson Jacob <ansonjacob.aj@gmail.com>
parent 6fea883f
Loading
Loading
Loading
Loading
+0 −9
Original line number Diff line number Diff line
@@ -531,15 +531,6 @@ static int create_bulk_endpoints(struct acc_dev *dev,
	ep->driver_data = dev;		/* claim the endpoint */
	dev->ep_out = ep;

	ep = usb_ep_autoconfig(cdev->gadget, out_desc);
	if (!ep) {
		DBG(cdev, "usb_ep_autoconfig for ep_out failed\n");
		return -ENODEV;
	}
	DBG(cdev, "usb_ep_autoconfig for ep_out got %s\n", ep->name);
	ep->driver_data = dev;		/* claim the endpoint */
	dev->ep_out = ep;

	/* now allocate requests for our endpoints */
	for (i = 0; i < TX_REQ_MAX; i++) {
		req = acc_request_new(dev->ep_in, BULK_BUFFER_SIZE);