Pablo Neira Ayuso <pablo@xxxxxxxxxxxxx> wrote: > > > For the update case, I think we'll have to iterate over the mask and > > > use xchg to update words, thus, we avoid any interference ongoing bit > > > testing. > > > > Could you elaborate? > > Why is memcpy not good enough here? > > while updating the connlabel via memcpy, some test_bit on the > connlabel may be already happening. I was suggesting some way to avoid > racing with it. I don't understand why its racing. Is there a case where we update a word, and test_bit can return "bit is set", even if the bit in the word is neither currently set nor about to be set? If not, then I don't see the race; either the test happens before we copied the word, or afterwards; regardless of copy vs. xchg? -- To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html