Fix the sparse error generated by bonding_mutex being declared in bond_sysfs.c but used in bond_main.c by declaring an 'extern' in bond_main.c. Fix this by moving the bond_main decleration to bonding.h. The sparse warning is as follows: bond_sysfs.c:67:14: warning: symbol 'bonding_mutex' was not declared. Should it be static? Signed-off-by: Ben Dooks Index: linux-git-test-next-cats/drivers/net/bonding/bond_main.c =================================================================== --- linux-git-test-next-cats.orig/drivers/net/bonding/bond_main.c 2008-09-14 16:51:54.000000000 +0100 +++ linux-git-test-next-cats/drivers/net/bonding/bond_main.c 2008-09-14 16:51:59.000000000 +0100 @@ -151,7 +151,6 @@ LIST_HEAD(bond_dev_list); static struct proc_dir_entry *bond_proc_dir = NULL; #endif -extern struct mutex bonding_mutex; static __be32 arp_target[BOND_MAX_ARP_TARGETS] = { 0, } ; static int arp_ip_count = 0; static int bond_mode = BOND_MODE_ROUNDROBIN; Index: linux-git-test-next-cats/drivers/net/bonding/bonding.h =================================================================== --- linux-git-test-next-cats.orig/drivers/net/bonding/bonding.h 2008-09-14 16:51:04.000000000 +0100 +++ linux-git-test-next-cats/drivers/net/bonding/bonding.h 2008-09-14 16:51:21.000000000 +0100 @@ -342,5 +342,8 @@ extern struct bond_parm_tbl xmit_hashtyp extern struct bond_parm_tbl arp_validate_tbl[]; extern struct bond_parm_tbl fail_over_mac_tbl[]; +/* exported from bond_sysfs.c */ +extern struct mutex bonding_mutex; + #endif /* _LINUX_BONDING_H */ -- Ben (ben@fluff.org, http://www.fluff.org/) 'a smiley only costs 4 bytes' -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html