linux/drivers/usb/gadget/udc/aspeed-vhub/epn.c

// SPDX-License-Identifier: GPL-2.0+
/*
 * aspeed-vhub -- Driver for Aspeed SoC "vHub" USB gadget
 *
 * epn.c - Generic endpoints management
 *
 * Copyright 2017 IBM Corporation
 */

#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/platform_device.h>
#include <linux/delay.h>
#include <linux/ioport.h>
#include <linux/slab.h>
#include <linux/errno.h>
#include <linux/list.h>
#include <linux/interrupt.h>
#include <linux/proc_fs.h>
#include <linux/prefetch.h>
#include <linux/clk.h>
#include <linux/usb/gadget.h>
#include <linux/of.h>
#include <linux/regmap.h>
#include <linux/dma-mapping.h>

#include "vhub.h"

#define EXTRA_CHECKS

#ifdef EXTRA_CHECKS
#define CHECK(ep, expr, fmt...)
#else
#define CHECK
#endif

static void ast_vhub_epn_kick(struct ast_vhub_ep *ep, struct ast_vhub_req *req)
{}

static void ast_vhub_epn_handle_ack(struct ast_vhub_ep *ep)
{}

static inline unsigned int ast_vhub_count_free_descs(struct ast_vhub_ep *ep)
{}

static void ast_vhub_epn_kick_desc(struct ast_vhub_ep *ep,
				   struct ast_vhub_req *req)
{}

static void ast_vhub_epn_handle_ack_desc(struct ast_vhub_ep *ep)
{}

void ast_vhub_epn_ack_irq(struct ast_vhub_ep *ep)
{}

static int ast_vhub_epn_queue(struct usb_ep* u_ep, struct usb_request *u_req,
			      gfp_t gfp_flags)
{}

static void ast_vhub_stop_active_req(struct ast_vhub_ep *ep,
				     bool restart_ep)
{}

static int ast_vhub_epn_dequeue(struct usb_ep* u_ep, struct usb_request *u_req)
{}

void ast_vhub_update_epn_stall(struct ast_vhub_ep *ep)
{}

static int ast_vhub_set_halt_and_wedge(struct usb_ep* u_ep, bool halt,
				      bool wedge)
{}

static int ast_vhub_epn_set_halt(struct usb_ep *u_ep, int value)
{}

static int ast_vhub_epn_set_wedge(struct usb_ep *u_ep)
{}

static int ast_vhub_epn_disable(struct usb_ep* u_ep)
{}

static int ast_vhub_epn_enable(struct usb_ep* u_ep,
			       const struct usb_endpoint_descriptor *desc)
{}

static void ast_vhub_epn_dispose(struct usb_ep *u_ep)
{}

static const struct usb_ep_ops ast_vhub_epn_ops =;

struct ast_vhub_ep *ast_vhub_alloc_epn(struct ast_vhub_dev *d, u8 addr)
{}