Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread Willy Tarreau
> It is linux-2.2, guy. 8) "threads" are not threaded there. > > Semaphores (rtnl_lock, particularly) protects only areas, which > are going to _schedule_ excplicitly or implicitly. ok, thanks a lot Alexey, now I understand. > Please, read comments. People used to consider comments as

Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread kuznet
Hello! >- it will nearly never allow concurrent accesses (seems to be what was > intented when it was written) Never, to be more exact. Concurrent accesses are allowed only with rtnetlink. In 2.4 it is always exclusive, because shared access turned out to be mostly useless. >-

Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread Willy Tarreau
> No, it guarentees that only one process may be in the middle > of modifying interface configuration state, the same and only > guarentee it makes in 2.4.x as well. ok, Dave. But the code in dev_ioctl() actually is : rtnl_lock(); ret = dev_ifsioc(, cmd); rtnl_unlock(); if only these

Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread David S. Miller
Date:Wed, 22 Nov 2000 12:27:57 +0100 (MET) From: Willy Tarreau <[EMAIL PROTECTED]> Quoting "David S. Miller" <[EMAIL PROTECTED]>: > All of this is protected by lock_kernel() so none of the > A,B,C,whatever spots can be interrupted in 2.2.x so, does this mean that

Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread Willy Tarreau
Quoting "David S. Miller" <[EMAIL PROTECTED]>: >Date: Wed, 22 Nov 2000 10:39:03 +0100 (MET) >From: Willy Tarreau <[EMAIL PROTECTED]> > >Thanks in advance for any comment, > > All of this is protected by lock_kernel() so none of the > A,B,C,whatever spots can be interrupted in

Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread David S. Miller
Date:Wed, 22 Nov 2000 10:39:03 +0100 (MET) From: Willy Tarreau <[EMAIL PROTECTED]> Thanks in advance for any comment, All of this is protected by lock_kernel() so none of the A,B,C,whatever spots can be interrupted in 2.2.x Later, David S. Miller [EMAIL PROTECTED] - To

[BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread Willy Tarreau
Hello ! while I was searching how to implement an rtnl_lock() in the bonding code, I discovered that the rtnl_shlock() function in 2.2.1[78] could misbehave if CONFIG_RTNETLINK is not set : - it will nearly never allow concurrent accesses (seems to be what was intented when it was

[BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread Willy Tarreau
Hello ! while I was searching how to implement an rtnl_lock() in the bonding code, I discovered that the rtnl_shlock() function in 2.2.1[78] could misbehave if CONFIG_RTNETLINK is not set : - it will nearly never allow concurrent accesses (seems to be what was intented when it was

Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread kuznet
Hello! - it will nearly never allow concurrent accesses (seems to be what was intented when it was written) Never, to be more exact. Concurrent accesses are allowed only with rtnetlink. In 2.4 it is always exclusive, because shared access turned out to be mostly useless. - it

Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread Willy Tarreau
It is linux-2.2, guy. 8) "threads" are not threaded there. Semaphores (rtnl_lock, particularly) protects only areas, which are going to _schedule_ excplicitly or implicitly. ok, thanks a lot Alexey, now I understand. Please, read comments. People used to consider comments as something

Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread Willy Tarreau
Quoting "David S. Miller" [EMAIL PROTECTED]: Date: Wed, 22 Nov 2000 10:39:03 +0100 (MET) From: Willy Tarreau [EMAIL PROTECTED] Thanks in advance for any comment, All of this is protected by lock_kernel() so none of the A,B,C,whatever spots can be interrupted in 2.2.x so,

Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread Willy Tarreau
No, it guarentees that only one process may be in the middle of modifying interface configuration state, the same and only guarentee it makes in 2.4.x as well. ok, Dave. But the code in dev_ioctl() actually is : rtnl_lock(); ret = dev_ifsioc(ifr, cmd); rtnl_unlock(); if only these

Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread David S. Miller
Date:Wed, 22 Nov 2000 10:39:03 +0100 (MET) From: Willy Tarreau [EMAIL PROTECTED] Thanks in advance for any comment, All of this is protected by lock_kernel() so none of the A,B,C,whatever spots can be interrupted in 2.2.x Later, David S. Miller [EMAIL PROTECTED] - To

Re: [BUG] 2.2.1[78] : RTNETLINK lock not properly locking ?

2000-11-22 Thread David S. Miller
Date:Wed, 22 Nov 2000 12:27:57 +0100 (MET) From: Willy Tarreau [EMAIL PROTECTED] Quoting "David S. Miller" [EMAIL PROTECTED]: All of this is protected by lock_kernel() so none of the A,B,C,whatever spots can be interrupted in 2.2.x so, does this mean that