Host drivers will need to know the port connection type for link PM settings. Move usb_get_hub_port_connect_type() from usb/core/usb.h to include/linux/usb.h Signed-off-by: Mathias Nyman <mathias.nyman@xxxxxxxxxxxxxxx> --- drivers/usb/core/hub.c | 1 + drivers/usb/core/usb.h | 2 -- include/linux/usb.h | 2 ++ 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c index cfb31a2..772901f 100644 --- a/drivers/usb/core/hub.c +++ b/drivers/usb/core/hub.c @@ -5408,6 +5408,7 @@ usb_get_hub_port_connect_type(struct usb_device *hdev, int port1) return hub->ports[port1 - 1]->connect_type; } +EXPORT_SYMBOL_GPL(usb_get_hub_port_connect_type); void usb_hub_adjust_deviceremovable(struct usb_device *hdev, struct usb_hub_descriptor *desc) diff --git a/drivers/usb/core/usb.h b/drivers/usb/core/usb.h index 8238577..8b9b39a 100644 --- a/drivers/usb/core/usb.h +++ b/drivers/usb/core/usb.h @@ -179,8 +179,6 @@ extern void usb_notify_add_device(struct usb_device *udev); extern void usb_notify_remove_device(struct usb_device *udev); extern void usb_notify_add_bus(struct usb_bus *ubus); extern void usb_notify_remove_bus(struct usb_bus *ubus); -extern enum usb_port_connect_type - usb_get_hub_port_connect_type(struct usb_device *hdev, int port1); extern void usb_set_hub_port_connect_type(struct usb_device *hdev, int port1, enum usb_port_connect_type type); extern void usb_hub_adjust_deviceremovable(struct usb_device *hdev, diff --git a/include/linux/usb.h b/include/linux/usb.h index 39cfa0a..2cd4962 100644 --- a/include/linux/usb.h +++ b/include/linux/usb.h @@ -593,6 +593,8 @@ extern struct usb_device *usb_get_dev(struct usb_device *dev); extern void usb_put_dev(struct usb_device *dev); extern struct usb_device *usb_hub_find_child(struct usb_device *hdev, int port1); +extern enum usb_port_connect_type usb_get_hub_port_connect_type( + struct usb_device *hdev, int port1); /** * usb_hub_for_each_child - iterate over all child devices on the hub -- 1.7.10.4 -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html