Fedora kernel-2.6.17-1.2142_FC4 patched with stable patch-2.6.17.4-vs2.0.2-rc26.diff
[linux-2.6.git] / drivers / mtd / chips / chipreg.c
index 1e45df0..c212784 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * $Id: chipreg.c,v 1.16 2003/05/29 09:36:15 dwmw2 Exp $
+ * $Id: chipreg.c,v 1.17 2004/11/16 18:29:00 dwmw2 Exp $
  *
  * Registration for chip drivers
  *
@@ -15,7 +15,7 @@
 #include <linux/mtd/mtd.h>
 #include <linux/mtd/compatmac.h>
 
-spinlock_t chip_drvs_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(chip_drvs_lock);
 static LIST_HEAD(chip_drvs_list);
 
 void register_mtd_chip_driver(struct mtd_chip_driver *drv)
@@ -41,7 +41,7 @@ static struct mtd_chip_driver *get_mtd_chip_driver (const char *name)
 
        list_for_each(pos, &chip_drvs_list) {
                this = list_entry(pos, typeof(*this), list);
-               
+
                if (!strcmp(this->name, name)) {
                        ret = this;
                        break;
@@ -73,7 +73,7 @@ struct mtd_info *do_map_probe(const char *name, struct map_info *map)
 
        ret = drv->probe(map);
 
-       /* We decrease the use count here. It may have been a 
+       /* We decrease the use count here. It may have been a
           probe-only module, which is no longer required from this
           point, having given us a handle on (and increased the use
           count of) the actual driver code.
@@ -82,7 +82,7 @@ struct mtd_info *do_map_probe(const char *name, struct map_info *map)
 
        if (ret)
                return ret;
-       
+
        return NULL;
 }
 /*