#include <linux/kstrtox.h>
#include <linux/slab.h>
#include <linux/pm_qos.h>
#include <linux/component.h>
#include <linux/usb/of.h>
#include "hub.h"
static int usb_port_block_power_off;
static const struct attribute_group *port_dev_group[];
static ssize_t early_stop_show(struct device *dev,
struct device_attribute *attr, char *buf)
{ … }
static ssize_t early_stop_store(struct device *dev, struct device_attribute *attr,
const char *buf, size_t count)
{ … }
static DEVICE_ATTR_RW(early_stop);
static ssize_t disable_show(struct device *dev,
struct device_attribute *attr, char *buf)
{ … }
static ssize_t disable_store(struct device *dev, struct device_attribute *attr,
const char *buf, size_t count)
{ … }
static DEVICE_ATTR_RW(disable);
static ssize_t location_show(struct device *dev,
struct device_attribute *attr, char *buf)
{ … }
static DEVICE_ATTR_RO(location);
static ssize_t connect_type_show(struct device *dev,
struct device_attribute *attr, char *buf)
{ … }
static DEVICE_ATTR_RO(connect_type);
static ssize_t state_show(struct device *dev,
struct device_attribute *attr, char *buf)
{ … }
static DEVICE_ATTR_RO(state);
static ssize_t over_current_count_show(struct device *dev,
struct device_attribute *attr, char *buf)
{ … }
static DEVICE_ATTR_RO(over_current_count);
static ssize_t quirks_show(struct device *dev,
struct device_attribute *attr, char *buf)
{ … }
static ssize_t quirks_store(struct device *dev, struct device_attribute *attr,
const char *buf, size_t count)
{ … }
static DEVICE_ATTR_RW(quirks);
static ssize_t usb3_lpm_permit_show(struct device *dev,
struct device_attribute *attr, char *buf)
{ … }
static ssize_t usb3_lpm_permit_store(struct device *dev,
struct device_attribute *attr,
const char *buf, size_t count)
{ … }
static DEVICE_ATTR_RW(usb3_lpm_permit);
static struct attribute *port_dev_attrs[] = …;
static const struct attribute_group port_dev_attr_grp = …;
static const struct attribute_group *port_dev_group[] = …;
static struct attribute *port_dev_usb3_attrs[] = …;
static const struct attribute_group port_dev_usb3_attr_grp = …;
static const struct attribute_group *port_dev_usb3_group[] = …;
static void usb_port_device_release(struct device *dev)
{ … }
#ifdef CONFIG_PM
static int usb_port_runtime_resume(struct device *dev)
{ … }
static int usb_port_runtime_suspend(struct device *dev)
{ … }
#endif
static void usb_port_shutdown(struct device *dev)
{ … }
static const struct dev_pm_ops usb_port_pm_ops = …;
const struct device_type usb_port_device_type = …;
static struct device_driver usb_port_driver = …;
static int link_peers(struct usb_port *left, struct usb_port *right)
{ … }
static void link_peers_report(struct usb_port *left, struct usb_port *right)
{ … }
static void unlink_peers(struct usb_port *left, struct usb_port *right)
{ … }
static int match_location(struct usb_device *peer_hdev, void *p)
{ … }
static void find_and_link_peer(struct usb_hub *hub, int port1)
{ … }
static int connector_bind(struct device *dev, struct device *connector, void *data)
{ … }
static void connector_unbind(struct device *dev, struct device *connector, void *data)
{ … }
static const struct component_ops connector_ops = …;
int usb_hub_create_port_device(struct usb_hub *hub, int port1)
{ … }
void usb_hub_remove_port_device(struct usb_hub *hub, int port1)
{ … }