[RFC PATCH 1/3] USB HOST CORE:probed devices collect anyplatform_data waiting for them

From: Andy Green
Date: Sat Mar 12 2011 - 17:40:07 EST


This causes all usb devices created during USB probe to
check with the aysnc platform_data api to see if they should
get tagged with waiting platform data based on their device
path.

Signed-off-by: Andy Green <andy.green@xxxxxxxxxx>
---

drivers/usb/core/usb.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/drivers/usb/core/usb.c b/drivers/usb/core/usb.c
index 079cb57..03d9049 100644
--- a/drivers/usb/core/usb.c
+++ b/drivers/usb/core/usb.c
@@ -36,6 +36,7 @@
#include <linux/mutex.h>
#include <linux/workqueue.h>
#include <linux/debugfs.h>
+#include <linux/platform_device.h>

#include <asm/io.h>
#include <linux/scatterlist.h>
@@ -444,6 +445,8 @@ struct usb_device *usb_alloc_dev(struct usb_device *parent,
dev->parent = parent;
INIT_LIST_HEAD(&dev->filelist);

+ platform_async_platform_data_attach(&dev->dev);
+
#ifdef CONFIG_PM
pm_runtime_set_autosuspend_delay(&dev->dev,
usb_autosuspend_delay * 1000);

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/