]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
.32 stuff
authorGreg Kroah-Hartman <gregkh@suse.de>
Tue, 6 Apr 2010 19:08:36 +0000 (12:08 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 6 Apr 2010 19:08:36 +0000 (12:08 -0700)
queue-2.6.32/freezer-fix-buggy-resume-test-for-tasks-frozen-with-cgroup-freezer.patch [new file with mode: 0644]
queue-2.6.32/iwlwifi-counting-number-of-tfds-can-be-free-for-4965.patch [new file with mode: 0644]
queue-2.6.32/iwlwifi-fix-nfreed.patch [new file with mode: 0644]
queue-2.6.32/iwlwifi-range-checking-issue.patch [new file with mode: 0644]
queue-2.6.32/libiscsi-fix-recovery-slowdown-regression.patch [new file with mode: 0644]
queue-2.6.32/mac80211-move-netdev-queue-enabling-to-correct-spot.patch [new file with mode: 0644]
queue-2.6.32/mac80211-tear-down-all-agg-queues-when-restart-reconfig-hw.patch [new file with mode: 0644]
queue-2.6.32/series
queue-2.6.32/setup-correct-int-pipe-type-in-ar9170_usb_exec_cmd.patch [new file with mode: 0644]
queue-2.6.32/sh-enable-the-mmu-in-start_secondary.patch [new file with mode: 0644]
queue-2.6.32/sh-fix-fdpic-binary-loader.patch [new file with mode: 0644]

diff --git a/queue-2.6.32/freezer-fix-buggy-resume-test-for-tasks-frozen-with-cgroup-freezer.patch b/queue-2.6.32/freezer-fix-buggy-resume-test-for-tasks-frozen-with-cgroup-freezer.patch
new file mode 100644 (file)
index 0000000..0aa3580
--- /dev/null
@@ -0,0 +1,101 @@
+From 5a7aadfe2fcb0f69e2acc1fbefe22a096e792fc9 Mon Sep 17 00:00:00 2001
+From: Matt Helsley <matthltc@us.ibm.com>
+Date: Fri, 26 Mar 2010 23:51:44 +0100
+Subject: Freezer: Fix buggy resume test for tasks frozen with cgroup freezer
+
+From: Matt Helsley <matthltc@us.ibm.com>
+
+commit 5a7aadfe2fcb0f69e2acc1fbefe22a096e792fc9 upstream.
+
+When the cgroup freezer is used to freeze tasks we do not want to thaw
+those tasks during resume. Currently we test the cgroup freezer
+state of the resuming tasks to see if the cgroup is FROZEN.  If so
+then we don't thaw the task. However, the FREEZING state also indicates
+that the task should remain frozen.
+
+This also avoids a problem pointed out by Oren Ladaan: the freezer state
+transition from FREEZING to FROZEN is updated lazily when userspace reads
+or writes the freezer.state file in the cgroup filesystem. This means that
+resume will thaw tasks in cgroups which should be in the FROZEN state if
+there is no read/write of the freezer.state file to trigger this
+transition before suspend.
+
+NOTE: Another "simple" solution would be to always update the cgroup
+freezer state during resume. However it's a bad choice for several reasons:
+Updating the cgroup freezer state is somewhat expensive because it requires
+walking all the tasks in the cgroup and checking if they are each frozen.
+Worse, this could easily make resume run in N^2 time where N is the number
+of tasks in the cgroup. Finally, updating the freezer state from this code
+path requires trickier locking because of the way locks must be ordered.
+
+Instead of updating the freezer state we rely on the fact that lazy
+updates only manage the transition from FREEZING to FROZEN. We know that
+a cgroup with the FREEZING state may actually be FROZEN so test for that
+state too. This makes sense in the resume path even for partially-frozen
+cgroups -- those that really are FREEZING but not FROZEN.
+
+Reported-by: Oren Ladaan <orenl@cs.columbia.edu>
+Signed-off-by: Matt Helsley <matthltc@us.ibm.com>
+Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ include/linux/freezer.h |    7 +++++--
+ kernel/cgroup_freezer.c |    9 ++++++---
+ kernel/power/process.c  |    2 +-
+ 3 files changed, 12 insertions(+), 6 deletions(-)
+
+--- a/include/linux/freezer.h
++++ b/include/linux/freezer.h
+@@ -64,9 +64,12 @@ extern bool freeze_task(struct task_stru
+ extern void cancel_freezing(struct task_struct *p);
+ #ifdef CONFIG_CGROUP_FREEZER
+-extern int cgroup_frozen(struct task_struct *task);
++extern int cgroup_freezing_or_frozen(struct task_struct *task);
+ #else /* !CONFIG_CGROUP_FREEZER */
+-static inline int cgroup_frozen(struct task_struct *task) { return 0; }
++static inline int cgroup_freezing_or_frozen(struct task_struct *task)
++{
++      return 0;
++}
+ #endif /* !CONFIG_CGROUP_FREEZER */
+ /*
+--- a/kernel/cgroup_freezer.c
++++ b/kernel/cgroup_freezer.c
+@@ -47,17 +47,20 @@ static inline struct freezer *task_freez
+                           struct freezer, css);
+ }
+-int cgroup_frozen(struct task_struct *task)
++int cgroup_freezing_or_frozen(struct task_struct *task)
+ {
+       struct freezer *freezer;
+       enum freezer_state state;
+       task_lock(task);
+       freezer = task_freezer(task);
+-      state = freezer->state;
++      if (!freezer->css.cgroup->parent)
++              state = CGROUP_THAWED; /* root cgroup can't be frozen */
++      else
++              state = freezer->state;
+       task_unlock(task);
+-      return state == CGROUP_FROZEN;
++      return (state == CGROUP_FREEZING) || (state == CGROUP_FROZEN);
+ }
+ /*
+--- a/kernel/power/process.c
++++ b/kernel/power/process.c
+@@ -139,7 +139,7 @@ static void thaw_tasks(bool nosig_only)
+               if (nosig_only && should_send_signal(p))
+                       continue;
+-              if (cgroup_frozen(p))
++              if (cgroup_freezing_or_frozen(p))
+                       continue;
+               thaw_process(p);
diff --git a/queue-2.6.32/iwlwifi-counting-number-of-tfds-can-be-free-for-4965.patch b/queue-2.6.32/iwlwifi-counting-number-of-tfds-can-be-free-for-4965.patch
new file mode 100644 (file)
index 0000000..d1485d5
--- /dev/null
@@ -0,0 +1,42 @@
+From be6b38bcb175613f239e0b302607db346472c6b6 Mon Sep 17 00:00:00 2001
+From: Wey-Yi Guy <wey-yi.w.guy@intel.com>
+Date: Thu, 18 Mar 2010 09:05:00 -0700
+Subject: iwlwifi: counting number of tfds can be free for 4965
+
+From: Wey-Yi Guy <wey-yi.w.guy@intel.com>
+
+commit be6b38bcb175613f239e0b302607db346472c6b6 upstream.
+
+Forget one hunk in 4965 during "iwlwifi: error checking for number of tfds
+in queue" patch.
+
+Reported-by: Shanyu Zhao <shanyu.zhao@intel.com>
+Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
+Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/net/wireless/iwlwifi/iwl-4965.c |    6 ++----
+ 1 file changed, 2 insertions(+), 4 deletions(-)
+
+--- a/drivers/net/wireless/iwlwifi/iwl-4965.c
++++ b/drivers/net/wireless/iwlwifi/iwl-4965.c
+@@ -2161,16 +2161,14 @@ static void iwl4965_rx_reply_tx(struct i
+                                  tx_resp->failure_frame);
+               freed = iwl_tx_queue_reclaim(priv, txq_id, index);
+-              if (qc && likely(sta_id != IWL_INVALID_STATION))
+-                      priv->stations[sta_id].tid[tid].tfds_in_queue -= freed;
++              iwl_free_tfds_in_queue(priv, sta_id, tid, freed);
+               if (priv->mac80211_registered &&
+                   (iwl_queue_space(&txq->q) > txq->q.low_mark))
+                       iwl_wake_queue(priv, txq_id);
+       }
+-      if (qc && likely(sta_id != IWL_INVALID_STATION))
+-              iwl_txq_check_empty(priv, sta_id, tid, txq_id);
++      iwl_txq_check_empty(priv, sta_id, tid, txq_id);
+       if (iwl_check_bits(status, TX_ABORT_REQUIRED_MSK))
+               IWL_ERR(priv, "TODO:  Implement Tx ABORT REQUIRED!!!\n");
diff --git a/queue-2.6.32/iwlwifi-fix-nfreed.patch b/queue-2.6.32/iwlwifi-fix-nfreed.patch
new file mode 100644 (file)
index 0000000..38100f4
--- /dev/null
@@ -0,0 +1,30 @@
+From 5d96faae63f4af4ff4d1effe46d18cc9ba203d00 Mon Sep 17 00:00:00 2001
+From: Stanislaw Gruszka <sgruszka@redhat.com>
+Date: Thu, 18 Mar 2010 14:29:33 +0000
+Subject: iwlwifi: fix nfreed--
+
+During backporting of a120e912eb51e347f36c71b60a1d13af74d30e83
+("iwlwifi: sanity check before counting number of tfds can be free")
+we forget one hunk, what make lot of messages "free more than
+tfds_in_queue" show up in dmesg.
+
+Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
+Tested-by: Adel Gadllah <adel.gadllah@gmail.com>
+(picked from https://patchwork.kernel.org/patch/86722/)
+Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/net/wireless/iwlwifi/iwl-tx.c |    1 -
+ 1 file changed, 1 deletion(-)
+
+--- a/drivers/net/wireless/iwlwifi/iwl-tx.c
++++ b/drivers/net/wireless/iwlwifi/iwl-tx.c
+@@ -1097,7 +1097,6 @@ int iwl_tx_queue_reclaim(struct iwl_priv
+                       priv->cfg->ops->lib->txq_inval_byte_cnt_tbl(priv, txq);
+               priv->cfg->ops->lib->txq_free_tfd(priv, txq);
+-              nfreed++;
+       }
+       return nfreed;
+ }
diff --git a/queue-2.6.32/iwlwifi-range-checking-issue.patch b/queue-2.6.32/iwlwifi-range-checking-issue.patch
new file mode 100644 (file)
index 0000000..5a9284d
--- /dev/null
@@ -0,0 +1,38 @@
+From 8e1a53c615e8efe0fac670f2973da64758748a8a Mon Sep 17 00:00:00 2001
+From: Dan Carpenter <error27@gmail.com>
+Date: Sun, 28 Mar 2010 14:55:00 +0300
+Subject: iwlwifi: range checking issue
+
+From: Dan Carpenter <error27@gmail.com>
+
+commit 8e1a53c615e8efe0fac670f2973da64758748a8a upstream.
+
+IWL_RATE_COUNT is 13 and IWL_RATE_COUNT_LEGACY is 12.
+
+IWL_RATE_COUNT_LEGACY is the right one here because iwl3945_rates
+doesn't support 60M and also that's how "rates" is defined in
+iwlcore_init_geos() from drivers/net/wireless/iwlwifi/iwl-core.c.
+
+        rates = kzalloc((sizeof(struct ieee80211_rate) * IWL_RATE_COUNT_LEGACY),
+                        GFP_KERNEL);
+
+Signed-off-by: Dan Carpenter <error27@gmail.com>
+Acked-by: Zhu Yi <yi.zhu@intel.com>
+Signed-off-by: John W. Linville <linville@tuxdriver.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/net/wireless/iwlwifi/iwl3945-base.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
++++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
+@@ -1904,7 +1904,7 @@ static void iwl3945_init_hw_rates(struct
+ {
+       int i;
+-      for (i = 0; i < IWL_RATE_COUNT; i++) {
++      for (i = 0; i < IWL_RATE_COUNT_LEGACY; i++) {
+               rates[i].bitrate = iwl3945_rates[i].ieee * 5;
+               rates[i].hw_value = i; /* Rate scaling will work on indexes */
+               rates[i].hw_value_short = i;
diff --git a/queue-2.6.32/libiscsi-fix-recovery-slowdown-regression.patch b/queue-2.6.32/libiscsi-fix-recovery-slowdown-regression.patch
new file mode 100644 (file)
index 0000000..e78b9be
--- /dev/null
@@ -0,0 +1,51 @@
+From 4ae0a6c15efcc37e94e3f30e3533bdec03c53126 Mon Sep 17 00:00:00 2001
+From: Mike Christie <michaelc@cs.wisc.edu>
+Date: Tue, 9 Mar 2010 14:14:51 -0600
+Subject: [SCSI] libiscsi: Fix recovery slowdown regression
+
+From: Mike Christie <michaelc@cs.wisc.edu>
+
+commit 4ae0a6c15efcc37e94e3f30e3533bdec03c53126 upstream.
+
+We could be failing/stopping a connection due to libiscsi starting
+recovery/cleanup, but the xmit path or scsi eh thread path
+could be dropping the connection at the same time.
+
+As a result the session->state gets set to failed instead of in
+recovery. We end up not blocking the session
+and so the replacement timeout never gets started and we only end up
+failing the IO when scsi_softirq_done sees that the
+cmd has been running for (cmd->allowed + 1) * rq->timeout secs.
+
+We used to fail the IO right away so users are seeing a long
+delay when using dm-multipath. This problem was added in
+2.6.28.
+
+Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
+Signed-off-by: James Bottomley <James.Bottomley@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/scsi/libiscsi.c |    5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+--- a/drivers/scsi/libiscsi.c
++++ b/drivers/scsi/libiscsi.c
+@@ -2823,14 +2823,15 @@ static void iscsi_start_session_recovery
+               session->state = ISCSI_STATE_TERMINATE;
+       else if (conn->stop_stage != STOP_CONN_RECOVER)
+               session->state = ISCSI_STATE_IN_RECOVERY;
++
++      old_stop_stage = conn->stop_stage;
++      conn->stop_stage = flag;
+       spin_unlock_bh(&session->lock);
+       del_timer_sync(&conn->transport_timer);
+       iscsi_suspend_tx(conn);
+       spin_lock_bh(&session->lock);
+-      old_stop_stage = conn->stop_stage;
+-      conn->stop_stage = flag;
+       conn->c_stage = ISCSI_CONN_STOPPED;
+       spin_unlock_bh(&session->lock);
diff --git a/queue-2.6.32/mac80211-move-netdev-queue-enabling-to-correct-spot.patch b/queue-2.6.32/mac80211-move-netdev-queue-enabling-to-correct-spot.patch
new file mode 100644 (file)
index 0000000..6b46007
--- /dev/null
@@ -0,0 +1,76 @@
+From 7236fe29fd72d17074574ba312e7f1bb9d10abaa Mon Sep 17 00:00:00 2001
+From: Johannes Berg <johannes.berg@intel.com>
+Date: Mon, 22 Mar 2010 13:42:43 -0700
+Subject: mac80211: move netdev queue enabling to correct spot
+
+From: Johannes Berg <johannes.berg@intel.com>
+
+commit 7236fe29fd72d17074574ba312e7f1bb9d10abaa upstream.
+
+"mac80211: fix skb buffering issue" still left a race
+between enabling the hardware queues and the virtual
+interface queues. In hindsight it's totally obvious
+that enabling the netdev queues for a hardware queue
+when the hardware queue is enabled is wrong, because
+it could well possible that we can fill the hw queue
+with packets we already have pending. Thus, we must
+only enable the netdev queues once all the pending
+packets have been processed and sent off to the device.
+
+In testing, I haven't been able to trigger this race
+condition, but it's clearly there, possibly only when
+aggregation is being enabled.
+
+Signed-off-by: Johannes Berg <johannes.berg@intel.com>
+Signed-off-by: John W. Linville <linville@tuxdriver.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ net/mac80211/tx.c   |    6 ++++++
+ net/mac80211/util.c |   12 ++++++------
+ 2 files changed, 12 insertions(+), 6 deletions(-)
+
+--- a/net/mac80211/tx.c
++++ b/net/mac80211/tx.c
+@@ -1881,6 +1881,7 @@ static bool ieee80211_tx_pending_skb(str
+ void ieee80211_tx_pending(unsigned long data)
+ {
+       struct ieee80211_local *local = (struct ieee80211_local *)data;
++      struct ieee80211_sub_if_data *sdata;
+       unsigned long flags;
+       int i;
+       bool txok;
+@@ -1921,6 +1922,11 @@ void ieee80211_tx_pending(unsigned long
+                       if (!txok)
+                               break;
+               }
++
++              if (skb_queue_empty(&local->pending[i]))
++                      list_for_each_entry_rcu(sdata, &local->interfaces, list)
++                              netif_tx_wake_queue(
++                                      netdev_get_tx_queue(sdata->dev, i));
+       }
+       spin_unlock_irqrestore(&local->queue_stop_reason_lock, flags);
+--- a/net/mac80211/util.c
++++ b/net/mac80211/util.c
+@@ -280,13 +280,13 @@ static void __ieee80211_wake_queue(struc
+               /* someone still has this queue stopped */
+               return;
+-      if (!skb_queue_empty(&local->pending[queue]))
++      if (skb_queue_empty(&local->pending[queue])) {
++              rcu_read_lock();
++              list_for_each_entry_rcu(sdata, &local->interfaces, list)
++                      netif_tx_wake_queue(netdev_get_tx_queue(sdata->dev, queue));
++              rcu_read_unlock();
++      } else
+               tasklet_schedule(&local->tx_pending_tasklet);
+-
+-      rcu_read_lock();
+-      list_for_each_entry_rcu(sdata, &local->interfaces, list)
+-              netif_tx_wake_queue(netdev_get_tx_queue(sdata->dev, queue));
+-      rcu_read_unlock();
+ }
+ void ieee80211_wake_queue_by_reason(struct ieee80211_hw *hw, int queue,
diff --git a/queue-2.6.32/mac80211-tear-down-all-agg-queues-when-restart-reconfig-hw.patch b/queue-2.6.32/mac80211-tear-down-all-agg-queues-when-restart-reconfig-hw.patch
new file mode 100644 (file)
index 0000000..355d8d1
--- /dev/null
@@ -0,0 +1,44 @@
+From 74e2bd1fa3ae9695af566ad5a7a288898787b909 Mon Sep 17 00:00:00 2001
+From: Wey-Yi Guy <wey-yi.w.guy@intel.com>
+Date: Wed, 3 Feb 2010 09:28:55 -0800
+Subject: mac80211: tear down all agg queues when restart/reconfig hw
+
+From: Wey-Yi Guy <wey-yi.w.guy@intel.com>
+
+commit 74e2bd1fa3ae9695af566ad5a7a288898787b909 upstream.
+
+When there is a need to restart/reconfig hw, tear down all the
+aggregation queues and let the mac80211 and driver get in-sync to have
+the opportunity to re-establish the aggregation queues again.
+
+Need to wait until driver re-establish all the station information before tear
+down the aggregation queues, driver(at least iwlwifi driver) will reject the
+stop aggregation queue request if station is not ready. But also need to make
+sure the aggregation queues are tear down before waking up the queues, so
+mac80211 will not sending frames with aggregation bit set.
+
+Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
+Signed-off-by: John W. Linville <linville@tuxdriver.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ net/mac80211/util.c |    8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+--- a/net/mac80211/util.c
++++ b/net/mac80211/util.c
+@@ -1137,6 +1137,14 @@ int ieee80211_reconfig(struct ieee80211_
+               }
+       }
++      rcu_read_lock();
++      if (hw->flags & IEEE80211_HW_AMPDU_AGGREGATION) {
++              list_for_each_entry_rcu(sta, &local->sta_list, list) {
++                      ieee80211_sta_tear_down_BA_sessions(sta);
++              }
++      }
++      rcu_read_unlock();
++
+       /* add back keys */
+       list_for_each_entry(sdata, &local->interfaces, list)
+               if (netif_running(sdata->dev))
index f15d7868dc1950e4f95e803f90a07083b23d505d..c2c18e53cd6aae9efadf9dc1517d19679c8180b1 100644 (file)
@@ -25,3 +25,13 @@ xfs-don-t-hold-onto-reserved-blocks-on-remount-ro.patch
 xfs-remove-invalid-barrier-optimization-from-xfs_fsync.patch
 xfs-non-blocking-inode-locking-in-io-completion.patch
 xfs-fix-locking-for-inode-cache-radix-tree-tag-updates.patch
+sh-enable-the-mmu-in-start_secondary.patch
+sh-fix-fdpic-binary-loader.patch
+libiscsi-fix-recovery-slowdown-regression.patch
+freezer-fix-buggy-resume-test-for-tasks-frozen-with-cgroup-freezer.patch
+iwlwifi-counting-number-of-tfds-can-be-free-for-4965.patch
+iwlwifi-fix-nfreed.patch
+iwlwifi-range-checking-issue.patch
+setup-correct-int-pipe-type-in-ar9170_usb_exec_cmd.patch
+mac80211-move-netdev-queue-enabling-to-correct-spot.patch
+mac80211-tear-down-all-agg-queues-when-restart-reconfig-hw.patch
diff --git a/queue-2.6.32/setup-correct-int-pipe-type-in-ar9170_usb_exec_cmd.patch b/queue-2.6.32/setup-correct-int-pipe-type-in-ar9170_usb_exec_cmd.patch
new file mode 100644 (file)
index 0000000..ccb4d13
--- /dev/null
@@ -0,0 +1,38 @@
+From 2d20c72c021d96f8b9230396c8e3782f204214ec Mon Sep 17 00:00:00 2001
+From: Valentin Longchamp <valentin.longchamp@epfl.ch>
+Date: Fri, 26 Mar 2010 11:44:33 +0100
+Subject: setup correct int pipe type in ar9170_usb_exec_cmd
+
+From: Valentin Longchamp <valentin.longchamp@epfl.ch>
+
+commit 2d20c72c021d96f8b9230396c8e3782f204214ec upstream.
+
+An int urb is constructed but we fill it in with a bulk pipe type.
+
+Commit f661c6f8c67bd55e93348f160d590ff9edf08904 implemented a pipe type
+check when CONFIG_USB_DEBUG is enabled. The check failed for all the ar9170
+usb transfers and the driver could not configure the wifi dongle.
+
+This went unnoticed until now because most people don't have
+CONFIG_USB_DEBUG enabled.
+
+Signed-off-by: Valentin Longchamp <valentin.longchamp@epfl.ch>
+Acked-by: Christian Lamparter <chunkeey@googlemail.com>
+Signed-off-by: John W. Linville <linville@tuxdriver.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/net/wireless/ath/ar9170/usb.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/net/wireless/ath/ar9170/usb.c
++++ b/drivers/net/wireless/ath/ar9170/usb.c
+@@ -414,7 +414,7 @@ static int ar9170_usb_exec_cmd(struct ar
+       spin_unlock_irqrestore(&aru->common.cmdlock, flags);
+       usb_fill_int_urb(urb, aru->udev,
+-                       usb_sndbulkpipe(aru->udev, AR9170_EP_CMD),
++                       usb_sndintpipe(aru->udev, AR9170_EP_CMD),
+                        aru->common.cmdbuf, plen + 4,
+                        ar9170_usb_tx_urb_complete, NULL, 1);
diff --git a/queue-2.6.32/sh-enable-the-mmu-in-start_secondary.patch b/queue-2.6.32/sh-enable-the-mmu-in-start_secondary.patch
new file mode 100644 (file)
index 0000000..d7d5e45
--- /dev/null
@@ -0,0 +1,33 @@
+From 4bea3418c737891894b9d3d3e9f8bbd67d66fa38 Mon Sep 17 00:00:00 2001
+From: Matt Fleming <matt@console-pimps.org>
+Date: Sun, 28 Mar 2010 20:08:25 +0000
+Subject: sh: Enable the mmu in start_secondary()
+
+From: Matt Fleming <matt@console-pimps.org>
+
+commit 4bea3418c737891894b9d3d3e9f8bbd67d66fa38 upstream.
+
+For the boot, enable_mmu() is called from setup_arch() but we don't call
+setup_arch() for any of the other cpus. So turn on the non-boot cpu's
+mmu inside of start_secondary().
+
+I noticed this bug on an SMP board when trying to map I/O memory
+(smsc911x registers) into the kernel address space. Since the Address
+Translation bit in MMUCR wasn't set, accessing the virtual address where
+the smsc911x registers were supposedly mapped actually performed a
+physical address access.
+
+Signed-off-by: Matt Fleming <matt@console-pimps.org>
+Signed-off-by: Paul Mundt <lethal@linux-sh.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+--- a/arch/sh/kernel/smp.c
++++ b/arch/sh/kernel/smp.c
+@@ -69,6 +69,7 @@ asmlinkage void __cpuinit start_secondary(void)
+       unsigned int cpu;
+       struct mm_struct *mm = &init_mm;
++      enable_mmu();
+       atomic_inc(&mm->mm_count);
+       atomic_inc(&mm->mm_users);
+       current->active_mm = mm;
diff --git a/queue-2.6.32/sh-fix-fdpic-binary-loader.patch b/queue-2.6.32/sh-fix-fdpic-binary-loader.patch
new file mode 100644 (file)
index 0000000..2810d15
--- /dev/null
@@ -0,0 +1,42 @@
+From d5ab780305bb6d60a7b5a74f18cf84eb6ad153b1 Mon Sep 17 00:00:00 2001
+From: Andrew Stubbs <ams@codesourcery.com>
+Date: Mon, 29 Mar 2010 12:04:19 +0900
+Subject: sh: Fix FDPIC binary loader
+
+From: Andrew Stubbs <ams@codesourcery.com>
+
+commit d5ab780305bb6d60a7b5a74f18cf84eb6ad153b1 upstream.
+
+Ensure that the aux table is properly initialized, even when optional
+features are missing. Without this, the FDPIC loader did not work.
+
+Signed-off-by: Andrew Stubbs <ams@codesourcery.com>
+Signed-off-by: Paul Mundt <lethal@linux-sh.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ arch/sh/include/asm/elf.h |    6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+--- a/arch/sh/include/asm/elf.h
++++ b/arch/sh/include/asm/elf.h
+@@ -212,7 +212,9 @@ extern void __kernel_vsyscall;
+ #define VSYSCALL_AUX_ENT                                      \
+       if (vdso_enabled)                                       \
+-              NEW_AUX_ENT(AT_SYSINFO_EHDR, VDSO_BASE);
++              NEW_AUX_ENT(AT_SYSINFO_EHDR, VDSO_BASE);        \
++      else                                                    \
++              NEW_AUX_ENT(AT_IGNORE, 0);
+ #else
+ #define VSYSCALL_AUX_ENT
+ #endif /* CONFIG_VSYSCALL */
+@@ -220,7 +222,7 @@ extern void __kernel_vsyscall;
+ #ifdef CONFIG_SH_FPU
+ #define FPU_AUX_ENT   NEW_AUX_ENT(AT_FPUCW, FPSCR_INIT)
+ #else
+-#define FPU_AUX_ENT
++#define FPU_AUX_ENT   NEW_AUX_ENT(AT_IGNORE, 0)
+ #endif
+ extern int l1i_cache_shape, l1d_cache_shape, l2_cache_shape;