On Wed, 13 May 2009, Dmitry Torokhov wrote: > > > > /* Must be called with ts->lock held */ > > > > static void ads7846_disable(struct ads7846 *ts) > > > > +__releases(&ts->lock) > > > > +__acquires(&ts->lock) > > > > { > > > I still haven't gotten any explanation why this is needed and also I am > > > still getting sparce warnings with this patch applied. Please drop. > > Sorry, I didn't realize I had a local patchset doing extra context > > checking of what lock is passed in to spin_lock/unlock...it helps to > > document when a function requires a lock held (see the comment) > I understand the comment ;) The annotation syntax is confusing though... > Maybe if instead of __releases and __acquires it said __needs_lock() and > __leaves_locked() that would make more sense... I fully agree. __acquires() and __releases() is used to annotate a completely different thing -- it should be used solely to avoid false positives about locking inbalances across functions (i.e. one function deliberately not unlocking lock that it has locked), shoudldn't it? -- Jiri Kosina SUSE Labs -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html