> I also worked on that part, although I have to admitt that I did not > got that part of the manpage. Instead I invented the require_context > attribute. Heh. > Here is the second patch. It applies on top of the first one... I don't really have time to look through it right now, sorry. > I hope that we get the good ideas of our two works combined and > accepted into sparse... That would be good :) > +# define __cond_lock(x,c) ((c) ? ({ __acquire(x); 1; }) : 0) > +# define __protected_by(x) __attribute__((require_context(x,1,1,"rdwr"))) > +# define __protected_read_by(x) __attribute__((require_context(x,1,1,"read"))) > +# define __protected_write_by(x) __attribute__((require_context(x,1,1,"write"))) > +# define __must_hold(x) __attribute__((context(x,1,1), require_context(x,1,1,"call"))) What's this "rdwr" etc. for? And "call"? Also, how are you planning to handle nested contexts, where 1,1 doesn't cut it any >0,>0 is really more like what we need? johannes
Attachment:
signature.asc
Description: This is a digitally signed message part