Subject: Re: request_module while holding rtnl semaphore

From: Patrick McHardy <[email-masked]>
Date: Wed, 10 Nov 2004 02:29:47 +0100

Thomas Graf wrote:

>* Patrick McHardy <[email-masked]> 2004-11-10 02:10
>  
>
>>Can you please show an example of a case where this is needed ?
>>Just to help me understand.
>>    
>>
>
>The action code might load modules in the middle of a classifier
>configuration and it will be very hard to reverse those changes.
>Right now we could move it to the top of all configurations and it
>would probably be possible to get back where we fetch the device
>but it will get impossible once a classifier requires module
>loading which is not unlikely.
>  
>
Assuming all error-paths do proper cleanup, returning -EAGAIN
should always result in the same configuration state as before.
Module-loading as a side-effect is exactly why this is done,
the replay will have all modules available.

>Well, it's not impossible but it would mean to have the action
>code parse the TLV and just try to load the module, then report
>to the classifier so it can try to load its own modules and then do
>the actual action and classifier configuration. I don't even want to
>think of how nasty it gets once a action module requests modules itself ;->
>  
>
I still don't understand the problem.

Regards
Patrick