From: 黄涛 Date: Tue, 21 Aug 2012 05:11:48 +0000 (+0800) Subject: Merge remote-tracking branch 'stable/linux-3.0.y' into develop-3.0-jb X-Git-Tag: firefly_0821_release~8882^2~2 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=109b0ba09445a8f5ac1c15cccc689f68236f7e41;p=firefly-linux-kernel-4.4.55.git Merge remote-tracking branch 'stable/linux-3.0.y' into develop-3.0-jb Conflicts: Makefile drivers/net/tun.c drivers/net/wireless/rt2x00/rt61pci.c drivers/usb/core/hub.c sound/soc/codecs/wm8994.c --- 109b0ba09445a8f5ac1c15cccc689f68236f7e41 diff --cc drivers/mfd/wm831x-otp.c index f742745ff354,b90f3e06b6c9..b90f3e06b6c9 mode 100755,100644..100755 --- a/drivers/mfd/wm831x-otp.c +++ b/drivers/mfd/wm831x-otp.c diff --cc drivers/net/tun.c index 76b865065679,a631bf71fee5..3cc22b9eda53 --- a/drivers/net/tun.c +++ b/drivers/net/tun.c @@@ -1239,16 -1239,12 +1239,18 @@@ static long __tun_chr_ioctl(struct fil int vnet_hdr_sz; int ret; +#ifdef CONFIG_ANDROID_PARANOID_NETWORK + if (cmd != TUNGETIFF && !capable(CAP_NET_ADMIN)) { + return -EPERM; + } +#endif + - if (cmd == TUNSETIFF || _IOC_TYPE(cmd) == 0x89) + if (cmd == TUNSETIFF || _IOC_TYPE(cmd) == 0x89) { if (copy_from_user(&ifr, argp, ifreq_len)) return -EFAULT; - + } else { + memset(&ifr, 0, sizeof(ifr)); + } if (cmd == TUNGETFEATURES) { /* Currently this just means: "what IFF flags are valid?". * This is needed because we never checked for invalid flags on diff --cc drivers/rtc/rtc-wm831x.c index c919ec3e860c,f3c211099a14..eed33532e8f7 mode 100755,100644..100755 --- a/drivers/rtc/rtc-wm831x.c +++ b/drivers/rtc/rtc-wm831x.c diff --cc drivers/usb/core/hub.c index a33954b424ef,3c0aa028fb3c..37a62d644c81 mode 100755,100644..100755 --- a/drivers/usb/core/hub.c +++ b/drivers/usb/core/hub.c @@@ -1905,11 -1903,15 +1906,19 @@@ int usb_new_device(struct usb_device *u /* Tell the world! */ announce_device(udev); + if (udev->serial) + add_device_randomness(udev->serial, strlen(udev->serial)); + if (udev->product) + add_device_randomness(udev->product, strlen(udev->product)); + if (udev->manufacturer) + add_device_randomness(udev->manufacturer, + strlen(udev->manufacturer)); + - device_enable_async_suspend(&udev->dev); + /* kever@rk 20111205 + * We don't use async suspend in rk29 usb + * to make sure usb1.1 host is suspend before usb 2.0 host. + */ + //device_enable_async_suspend(&udev->dev); /* Register the device. The device driver is responsible * for configuring the device and invoking the add-device * notifier chain (used by usbfs and possibly others).