From 68144e0cc92125f41157ede7b060f83367bc4fe7 Mon Sep 17 00:00:00 2001 From: Philipp Zabel Date: Mon, 24 Nov 2008 12:01:17 -0800 Subject: USB: otg: add otg_put_transceiver() As Russell King points out, calling put_device(otg_transceiver->dev) directly in driver cleanup paths makes assumptions about otg_transceiver internals. Signed-off-by: Philipp Zabel Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman --- arch/arm/plat-omap/usb.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'arch/arm') diff --git a/arch/arm/plat-omap/usb.c b/arch/arm/plat-omap/usb.c index 67ca1e216df..2f88ca8b8f3 100644 --- a/arch/arm/plat-omap/usb.c +++ b/arch/arm/plat-omap/usb.c @@ -96,6 +96,12 @@ struct otg_transceiver *otg_get_transceiver(void) } EXPORT_SYMBOL(otg_get_transceiver); +void otg_put_transceiver(struct otg_transceiver *x) +{ + put_device(x->dev); +} +EXPORT_SYMBOL(otg_put_transceiver); + int otg_set_transceiver(struct otg_transceiver *x) { if (xceiv && x) -- cgit v1.2.3