/* kill_all_requests - remove all requests from the endpoint's queue @hsotg: The device state. @ep: The endpoint the requests may be on.  */
static void kill_all_requests(struct s3c_hsotg *hsotg, struct s3c_hsotg_ep *ep, int result, bool force)
/* kill_all_requests - remove all requests from the endpoint's queue @hsotg: The device state. @ep: The endpoint the requests may be on.  */
static void kill_all_requests(struct s3c_hsotg *hsotg, struct s3c_hsotg_ep *ep, int result, bool force)
{
	struct s3c_hsotg_req *req, *treq;
	unsigned long flags;
	spin_lock_irqsave(&ep->lock, flags);
	list_for_each_entry_safe(req, treq, &ep->queue, queue) {
		if (ep->req == req && ep->dir_in && !force)
			continue;
		s3c_hsotg_complete_request(hsotg, ep, req,
					   result);
	}
	spin_unlock_irqrestore(&ep->lock, flags);
}