lkml.org 
[lkml]   [2006]   [Feb]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] 2.6 Altix : more ioc3 cleanups
Date
Some "inline" removing that Andrew suggested, removed some locking on
add/remove at this level - we'll let the callees decide.

This is a resend.


Signed-off-by: Patrick Gefre <pfg@sgi.com>


ioc3.c | 11 +++--------
1 files changed, 3 insertions(+), 8 deletions(-)



Index: linux-2.6/drivers/sn/ioc3.c
===================================================================
--- linux-2.6.orig/drivers/sn/ioc3.c 2006-02-10 14:45:25.644934864 -0600
+++ linux-2.6/drivers/sn/ioc3.c 2006-02-10 14:48:59.455007147 -0600
@@ -62,7 +62,7 @@
return presence;
}

-static inline int nic_read_bit(struct ioc3_driver_data *idd)
+static int nic_read_bit(struct ioc3_driver_data *idd)
{
int result;
unsigned long flags;
@@ -77,7 +77,7 @@
return result;
}

-static inline void nic_write_bit(struct ioc3_driver_data *idd, int bit)
+static void nic_write_bit(struct ioc3_driver_data *idd, int bit)
{
if (bit)
idd->vma->mcr = mcr_pack(6, 110);
@@ -371,8 +371,7 @@

/* Interrupts */

-static inline void
-write_ireg(struct ioc3_driver_data *idd, uint32_t val, int which)
+static void write_ireg(struct ioc3_driver_data *idd, uint32_t val, int which)
{
unsigned long flags;

@@ -735,14 +734,12 @@
}

/* Add this IOC3 to all submodules */
- read_lock(&ioc3_submodules_lock);
for(id=0;id<IOC3_MAX_SUBMODULES;id++)
if(ioc3_submodules[id] && ioc3_submodules[id]->probe) {
idd->active[id] = 1;
idd->active[id] = !ioc3_submodules[id]->probe
(ioc3_submodules[id], idd);
}
- read_unlock(&ioc3_submodules_lock);

printk(KERN_INFO "IOC3 Master Driver loaded for %s\n", pci_name(pdev));

@@ -767,7 +764,6 @@
idd = pci_get_drvdata(pdev);

/* Remove this IOC3 from all submodules */
- read_lock(&ioc3_submodules_lock);
for(id=0;id<IOC3_MAX_SUBMODULES;id++)
if(idd->active[id]) {
if(ioc3_submodules[id] && ioc3_submodules[id]->remove)
@@ -781,7 +777,6 @@
pci_name(pdev));
idd->active[id] = 0;
}
- read_unlock(&ioc3_submodules_lock);

/* Clear and disable all IRQs */
write_ireg(idd, ~0, IOC3_W_IEC);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2006-02-10 23:21    [W:0.052 / U:0.208 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site