Hi, I was thinking the same mechanism for lock checks (lock() has matching unlock()) could be used for detecting refcount leaks (get() has matching put()). This could be used to catch bugs like that: https://lore.kernel.org/linux-cifs/CAH2r5mtJg0OONLuAYmcggj=M3euDDxRa3Y5-_W1=qxwbeZypqA@xxxxxxxxxxxxxx/T/#mf0e0397aa0b63043d7b3bb0981f0b7323713bfdc Cheers, -- Aurélien Aptel / SUSE Labs Samba Team GPG: 1839 CB5F 9F5B FB9B AA97 8C99 03C8 A49B 521B D5D3 SUSE Software Solutions Germany GmbH, Maxfeldstr. 5, 90409 Nürnberg, DE GF: Felix Imendörffer, Mary Higgins, Sri Rasiah HRB 247165 (AG München)