aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/core/hub.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/core/hub.c')
-rw-r--r--drivers/usb/core/hub.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
index 25a7422ee657..7f380ff1f786 100644
--- a/drivers/usb/core/hub.c
+++ b/drivers/usb/core/hub.c
@@ -24,6 +24,7 @@
24#include <linux/kthread.h> 24#include <linux/kthread.h>
25#include <linux/mutex.h> 25#include <linux/mutex.h>
26#include <linux/freezer.h> 26#include <linux/freezer.h>
27#include <linux/random.h>
27 28
28#include <asm/uaccess.h> 29#include <asm/uaccess.h>
29#include <asm/byteorder.h> 30#include <asm/byteorder.h>
@@ -2173,6 +2174,14 @@ int usb_new_device(struct usb_device *udev)
2173 /* Tell the world! */ 2174 /* Tell the world! */
2174 announce_device(udev); 2175 announce_device(udev);
2175 2176
2177 if (udev->serial)
2178 add_device_randomness(udev->serial, strlen(udev->serial));
2179 if (udev->product)
2180 add_device_randomness(udev->product, strlen(udev->product));
2181 if (udev->manufacturer)
2182 add_device_randomness(udev->manufacturer,
2183 strlen(udev->manufacturer));
2184
2176 device_enable_async_suspend(&udev->dev); 2185 device_enable_async_suspend(&udev->dev);
2177 2186
2178 /* 2187 /*