From: Renaud L. <Ren...@ke...> - 2008-02-25 11:59:37
|
Hi ! > It would be foolish to say that it won´t be of any interest. It is > definitely very important to make all LTP test cases SMP safe. Thank you > very much for pointing that out. Thanks for your interrest ! But I thing there is a little misunderstood. When talking about SMP safeness, I was not saying that current tests are not SMP-safe. I mean, the code is correct if you run just one instance of each test. But, if you run multiple instances of the same test at the same time, you can encounter problems. Mainly because of object naming conflicts (with IPCs), port conflicts, etc. For instance, doing the following is correct : renaud@leodagan:$ ./sendfile02 sendfile02 1 PASS : functionality of sendfile() is correct sendfile02 2 PASS : functionality of sendfile() is correct sendfile02 3 PASS : functionality of sendfile() is correct sendfile02 4 PASS : functionality of sendfile() is correct But doing the following fails : renaud@leodagan:$ for i in `seq 1 2`; do ./sendfile02 & done sendfile02 1 PASS : functionality of sendfile() is correct sendfile02 1 PASS : functionality of sendfile() is correct sendfile02 2 BROK : call to bind() failed: Address already in use sendfile02 3 BROK : Remaining cases broken sendfile02 2 PASS : functionality of sendfile() is correct sendfile02 4 BROK : Remaining cases broken sendfile02 3 PASS : functionality of sendfile() is correct sendfile02 4 PASS : functionality of sendfile() is correct We do this kind of "parallel" executions of the same test to stress kernel level SMP sensitive code. So, if this particular issue is of interrest, I can send other patches. Regards. R. -- Renaud Lottiaux Kerlabs Bâtiment Germanium 80, avenue des buttes de Coësmes 35700 Rennes - France Phone : (+33|0)6 80 89 19 34 Fax : (+33|0)2 99 84 71 71 Email : Ren...@ke... Web : http://www.kerlabs.com/ |