--- /dev/null
+From 3bad28ec006ad6ab2bca4e5103860b75391e3c9d Mon Sep 17 00:00:00 2001
+From: Greg Kroah-Hartman <gregkh@suse.de>
+Date: Tue, 16 Nov 2010 11:18:33 -0800
+Subject: Staging: frontier: fix up some sysfs attribute permissions
+
+From: Greg Kroah-Hartman <gregkh@suse.de>
+
+commit 3bad28ec006ad6ab2bca4e5103860b75391e3c9d and
+2a767fda5d0d8dcff465724dfad6ee131489b3f2 upstream merged together.
+
+They should not be writable by any user
+
+Reported-by: Linus Torvalds <torvalds@linux-foundation.org>
+Cc: David Taht <d@teklibre.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/staging/frontier/tranzport.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/staging/frontier/tranzport.c
++++ b/drivers/staging/frontier/tranzport.c
+@@ -202,7 +202,7 @@ static void usb_tranzport_abort_transfer
+ t->value = temp; \
+ return count; \
+ } \
+- static DEVICE_ATTR(value, S_IWUGO | S_IRUGO, show_##value, set_##value);
++ static DEVICE_ATTR(value, S_IWUSR | S_IRUGO, show_##value, set_##value);
+
+ show_int(enable);
+ show_int(offline);
--- /dev/null
+From f36d83a8cb7224f45fdfa1129a616dff56479a09 Mon Sep 17 00:00:00 2001
+From: Larry Finger <Larry.Finger@lwfinger.net>
+Date: Sat, 13 Nov 2010 13:01:56 -0600
+Subject: staging: rtl8187se: Change panic to warn when RF switch turned off
+
+From: Larry Finger <Larry.Finger@lwfinger.net>
+
+commit f36d83a8cb7224f45fdfa1129a616dff56479a09 upstream.
+
+This driver issues a kernel panic over conditions that do not
+justify such drastic action. Change these to log entries with
+a stack dump.
+
+This patch fixes the system crash reported in
+https://bugs.launchpad.net/ubuntu/+source/linux/+bug/674285.
+
+Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
+Reported-and-Tested-by: Robie Basik <rb-oss-3@justgohome.co.uk>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/staging/rtl8187se/r8185b_init.c | 32 +++++++++++++++++++++++---------
+ 1 file changed, 23 insertions(+), 9 deletions(-)
+
+--- a/drivers/staging/rtl8187se/r8185b_init.c
++++ b/drivers/staging/rtl8187se/r8185b_init.c
+@@ -356,8 +356,12 @@ HwHSSIThreeWire(
+ }
+ udelay(10);
+ }
+- if (TryCnt == TC_3W_POLL_MAX_TRY_CNT)
+- panic("HwThreeWire(): CmdReg: %#X RE|WE bits are not clear!!\n", u1bTmp);
++ if (TryCnt == TC_3W_POLL_MAX_TRY_CNT) {
++ printk(KERN_ERR "rtl8187se: HwThreeWire(): CmdReg:"
++ " %#X RE|WE bits are not clear!!\n", u1bTmp);
++ dump_stack();
++ return 0;
++ }
+
+ // RTL8187S HSSI Read/Write Function
+ u1bTmp = read_nic_byte(dev, RF_SW_CONFIG);
+@@ -397,13 +401,23 @@ HwHSSIThreeWire(
+ int idx;
+ int ByteCnt = nDataBufBitCnt / 8;
+ //printk("%d\n",nDataBufBitCnt);
+- if ((nDataBufBitCnt % 8) != 0)
+- panic("HwThreeWire(): nDataBufBitCnt(%d) should be multiple of 8!!!\n",
+- nDataBufBitCnt);
+-
+- if (nDataBufBitCnt > 64)
+- panic("HwThreeWire(): nDataBufBitCnt(%d) should <= 64!!!\n",
+- nDataBufBitCnt);
++ if ((nDataBufBitCnt % 8) != 0) {
++ printk(KERN_ERR "rtl8187se: "
++ "HwThreeWire(): nDataBufBitCnt(%d)"
++ " should be multiple of 8!!!\n",
++ nDataBufBitCnt);
++ dump_stack();
++ nDataBufBitCnt += 8;
++ nDataBufBitCnt &= ~7;
++ }
++
++ if (nDataBufBitCnt > 64) {
++ printk(KERN_ERR "rtl8187se: HwThreeWire():"
++ " nDataBufBitCnt(%d) should <= 64!!!\n",
++ nDataBufBitCnt);
++ dump_stack();
++ nDataBufBitCnt = 64;
++ }
+
+ for(idx = 0; idx < ByteCnt; idx++)
+ {