Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1264969
| From | Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] tree wide: Use kvfree() than conditional kfree()/vfree() |
| Date | 2015-11-08 06:10 +0100 |
| Message-ID | <qsqoN-438-1@gated-at.bofh.it> (permalink) |
| References | <qsaam-1K0-5@gated-at.bofh.it> <qshYe-6UR-11@gated-at.bofh.it> <qsi7T-6ZB-7@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Andy Shevchenko wrote:
> Like Joe noticed you have left few places like
> void my_func_kvfree(arg)
> {
> kvfree(arg);
> }
>
> Might make sense to remove them completely, especially in case when
> you have changed the callers.
I think we should stop at
#define my_func_kvfree(arg) kvfree(arg)
in case someone want to add some code in future.
Also, we might want to add a helper that does vmalloc() when
kmalloc() failed because locations that do
ptr = kmalloc(size, GFP_NOFS);
if (!ptr)
ptr = vmalloc(size); /* Wrong because GFP_KERNEL is used implicitly */
are found.
> One more thought. Might be good to provide a coccinelle script for
> such places? Julia?
Welcome. I'm sure I'm missing some locations.
--
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/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH] tree wide: Use kvfree() than conditional kfree()/vfree() Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> - 2015-11-07 12:50 +0100
Re: [PATCH] tree wide: Use kvfree() than conditional kfree()/vfree() Joe Perches <joe@perches.com> - 2015-11-07 19:20 +0100
Re: [PATCH] tree wide: Use kvfree() than conditional kfree()/vfree() Andy Shevchenko <andy.shevchenko@gmail.com> - 2015-11-07 21:10 +0100
Re: [PATCH] tree wide: Use kvfree() than conditional kfree()/vfree() Andy Shevchenko <andy.shevchenko@gmail.com> - 2015-11-07 21:20 +0100
Re: [PATCH] tree wide: Use kvfree() than conditional kfree()/vfree() Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> - 2015-11-08 06:10 +0100
Re: [PATCH] tree wide: Use kvfree() than conditional kfree()/vfree() Sergey Senozhatsky <sergey.senozhatsky@gmail.com> - 2015-11-08 06:40 +0100
Re: [PATCH] tree wide: Use kvfree() than conditional kfree()/vfree() Andy Shevchenko <andy.shevchenko@gmail.com> - 2015-11-08 21:20 +0100
Re: [PATCH] tree wide: Use kvfree() than conditional kfree()/vfree() Michal Hocko <mhocko@kernel.org> - 2015-11-09 11:50 +0100
csiph-web