Bug 445016
Summary: | occasional ASSERT_RTNL with bonding driver | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 5 | Reporter: | nate.dailey |
Component: | kernel | Assignee: | Andy Gospodarek <agospoda> |
Status: | CLOSED DUPLICATE | QA Contact: | Martin Jenner <mjenner> |
Severity: | medium | Docs Contact: | |
Priority: | low | ||
Version: | 5.2 | CC: | agospoda, dzickus, ijc, peterm, simon.mcgrath |
Target Milestone: | rc | ||
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2008-10-07 13:20:46 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
nate.dailey
2008-05-02 18:59:07 UTC
This doesn't look like the same code that I see for the latest RHEL5. I don't see any returns before taking the rtnl_lock so we always need to release it. The latest RHEL5 update 2 code that I have access to is kernel 2.6.18-92.el5. Here's a snippet from the version of bond_sysfs.c from this kernel: 243 static ssize_t bonding_store_slaves(struct class_device *cd, const char *buffer, size_t count) 244 { 245 char command[IFNAMSIZ + 1] = { 0, }; 246 char *ifname; 247 int i, res, found, ret = count; 248 struct slave *slave; 249 struct net_device *dev = NULL; 250 struct bonding *bond = to_bond(cd); 251 252 /* Quick sanity check -- is the bond interface up? */ 253 if (!(bond->dev->flags & IFF_UP)) { 254 printk(KERN_ERR DRV_NAME 255 ": %s: Unable to update slaves because interface is down.\n", 256 bond->dev->name); 257 ret = -EPERM; 258 goto out; 259 } 260 261 /* Note: We can't hold bond->lock here, as bond_create grabs it. */ 262 263 rtnl_lock(); 264 down_write(&(bonding_rwsem)); ,,, 374 out: 375 up_write(&(bonding_rwsem)); 376 rtnl_unlock(); 377 return ret; 378 } Note that the "goto out;" on line 258 happens before taking the rtnl_lock. Aftet the "out" label, the lock is released (though it was never taken). Same thing for the bonding_rwsem. Ah yes, thank you. I was looking at my latest test kernels, but they do not contain this exact code anymore since mine have support for IPoIB + bonding. This should be resolved with the changes for bug 450219. *** This bug has been marked as a duplicate of bug 450219 *** |