Am 22.01.2018 um 14:24 schrieb Johannes Berg: > On Mon, 2018-01-15 at 15:28 +0100, Benjamin Beichler wrote: >> Am 15.01.2018 um 13:08 schrieb Johannes Berg: >>> On Wed, 2018-01-10 at 17:42 +0100, Benjamin Beichler wrote: >>>> Change the dump iteration to be independent from >>>> increasing radio indices on radio list. >>> You can't do that, data structures can be deleted while the dump is >>> ongoing. >> That's what I try to address with this patch. In the past there were >> corner cases, which might have failed while deletion. > Hah, ok. > >> Nonetheless, the radio count is in the current version strictly >> monotonic, maybe the description is misleading. :-) >> So in the inner loop there is no deletion possible because of the >> spinlock, and multiple calls of nl_dump check the generation count and >> cancel if it have changed. > Ah, I missed that you cancel when it's changed, we don't usually do > that normally. > > I'd still prefer if you could have the code not rely on the pointers, > because if somebody gets it wrong (forgets to update the generation > count) I'm not sure I want that to crash in some corner cases... Mkay, I saw the same pattern in other parts of the kernel, that's why I adopted it. Then I restore the magic with searching the next radio id bigger then the last one. Since on my machine, It needs several hundreds of radios for a full message to cause interruptions, I think the code is really rarely used and should be fail safe :-) > johannes > -- M.Sc. Benjamin Beichler Universität Rostock, Fakultät für Informatik und Elektrotechnik Institut für Angewandte Mikroelektronik und Datentechnik University of Rostock, Department of CS and EE Institute of Applied Microelectronics and CE Richard-Wagner-Straße 31 18119 Rostock Deutschland/Germany phone: +49 (0) 381 498 - 7278 email: Benjamin.Beichler@xxxxxxxxxxxxxx www: http://www.imd.uni-rostock.de/
Attachment:
smime.p7s
Description: S/MIME Cryptographic Signature