aboutsummaryrefslogtreecommitdiffstats
path: root/arch/ia64/sn
diff options
context:
space:
mode:
authorLai Jiangshan <laijs@cn.fujitsu.com>2011-03-17 23:48:01 -0400
committerPaul E. McKenney <paulmck@linux.vnet.ibm.com>2011-07-20 17:10:13 -0400
commitf218a7ee7a1c37058eef4bb5fefff9bdb0f52766 (patch)
tree1716da3394d55296750a49f3f46fb75f8640b8c7 /arch/ia64/sn
parent57bdfbf9ee2b0856d8b62180c3b3f8fa1533b8d1 (diff)
ia64,rcu: Convert call_rcu(sn_irq_info_free) to kfree_rcu()
The rcu callback sn_irq_info_free() just calls a kfree(), so we use kfree_rcu() instead of the call_rcu(sn_irq_info_free). Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Jes Sorensen <jes@sgi.com> Cc: Tony Luck <tony.luck@intel.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Diffstat (limited to 'arch/ia64/sn')
-rw-r--r--arch/ia64/sn/kernel/irq.c14
1 files changed, 2 insertions, 12 deletions
diff --git a/arch/ia64/sn/kernel/irq.c b/arch/ia64/sn/kernel/irq.c
index 81a1f4e6bcd8..485c42d97e83 100644
--- a/arch/ia64/sn/kernel/irq.c
+++ b/arch/ia64/sn/kernel/irq.c
@@ -112,8 +112,6 @@ static void sn_ack_irq(struct irq_data *data)
112 irq_move_irq(data); 112 irq_move_irq(data);
113} 113}
114 114
115static void sn_irq_info_free(struct rcu_head *head);
116
117struct sn_irq_info *sn_retarget_vector(struct sn_irq_info *sn_irq_info, 115struct sn_irq_info *sn_retarget_vector(struct sn_irq_info *sn_irq_info,
118 nasid_t nasid, int slice) 116 nasid_t nasid, int slice)
119{ 117{
@@ -177,7 +175,7 @@ struct sn_irq_info *sn_retarget_vector(struct sn_irq_info *sn_irq_info,
177 spin_lock(&sn_irq_info_lock); 175 spin_lock(&sn_irq_info_lock);
178 list_replace_rcu(&sn_irq_info->list, &new_irq_info->list); 176 list_replace_rcu(&sn_irq_info->list, &new_irq_info->list);
179 spin_unlock(&sn_irq_info_lock); 177 spin_unlock(&sn_irq_info_lock);
180 call_rcu(&sn_irq_info->rcu, sn_irq_info_free); 178 kfree_rcu(sn_irq_info, rcu);
181 179
182 180
183finish_up: 181finish_up:
@@ -338,14 +336,6 @@ static void unregister_intr_pda(struct sn_irq_info *sn_irq_info)
338 rcu_read_unlock(); 336 rcu_read_unlock();
339} 337}
340 338
341static void sn_irq_info_free(struct rcu_head *head)
342{
343 struct sn_irq_info *sn_irq_info;
344
345 sn_irq_info = container_of(head, struct sn_irq_info, rcu);
346 kfree(sn_irq_info);
347}
348
349void sn_irq_fixup(struct pci_dev *pci_dev, struct sn_irq_info *sn_irq_info) 339void sn_irq_fixup(struct pci_dev *pci_dev, struct sn_irq_info *sn_irq_info)
350{ 340{
351 nasid_t nasid = sn_irq_info->irq_nasid; 341 nasid_t nasid = sn_irq_info->irq_nasid;
@@ -399,7 +389,7 @@ void sn_irq_unfixup(struct pci_dev *pci_dev)
399 spin_unlock(&sn_irq_info_lock); 389 spin_unlock(&sn_irq_info_lock);
400 if (list_empty(sn_irq_lh[sn_irq_info->irq_irq])) 390 if (list_empty(sn_irq_lh[sn_irq_info->irq_irq]))
401 free_irq_vector(sn_irq_info->irq_irq); 391 free_irq_vector(sn_irq_info->irq_irq);
402 call_rcu(&sn_irq_info->rcu, sn_irq_info_free); 392 kfree_rcu(sn_irq_info, rcu);
403 pci_dev_put(pci_dev); 393 pci_dev_put(pci_dev);
404 394
405} 395}