Messages in this thread | ![/](/images/icornerl.gif) | | Date | Mon, 13 Oct 2003 11:21:38 +0200 | From | Jörn Engel <> | Subject | Re: include/linux/nfs/nfsfh.h declares a symbol |
| |
On Mon, 13 October 2003 14:43:57 +1000, Neil Brown wrote: > On Wednesday October 1, joern@wohnheim.fh-wedel.de wrote: > > Neil, the function SVCFH_fmt uses a static variable to sprintf into. > > Looks like this variable is declared locally for every .c file > > including nfsfh.h, which is quite a few. > > > > You could remove the static, but that would increase the stack usage, > > which might be a problem too. The buffer could be reduced to 64 > > chars, to reduce that problem. kmalloc()ing it seems a bit expensive, > > but might be an option, too. > > Thanks. I think it is best to simply make SVCFH_fmt a real function > instead of inline, as below. > > NeilBrown > > ======================================= > Move SVCFH_fmt from being 'inline' to being 'extern'. > > This way, the "static char buf" is defined only once instead > of once per file.
Patch looks good. Thanks!
Jörn
-- To recognize individual spam features you have to try to get into the mind of the spammer, and frankly I want to spend as little time inside the minds of spammers as possible. -- Paul Graham - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| ![\](/images/icornerr.gif) |