On Sun, Jul 10, 2022 at 11:59:24PM -0700, Christoph Hellwig wrote: > On Fri, Jul 08, 2022 at 11:55:58AM +1000, Dave Chinner wrote: > > +void > > xlog_grant_sub_space( > > struct xlog *log, > > struct xlog_grant_head *head, > > int bytes) > > { > > + atomic64_sub(bytes, &head->grant); > > } > > > > static void > > @@ -165,93 +144,34 @@ xlog_grant_add_space( > > struct xlog_grant_head *head, > > int bytes) > > { > > + atomic64_add(bytes, &head->grant); > > } > > These probably make more senses as inlines and can you can drop their log > agument as well. Or maybe just drop these helpers entirely? I didn't want to make the change even more complex by dropping the wrappers entirely. They do add some value as code documentation, and can probably become inlines in the end, but I've been holding off doing API cleanups because there's much bigger code restructuring and cleanups needed around this code... Cheers, Dave. -- Dave Chinner david@xxxxxxxxxxxxx