Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1555904
| From | "Luis R. Rodriguez" <mcgrof@kernel.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: kmod: provide wrappers for kmod_concurrent inc/dec |
| Date | 2017-01-10 21:40 +0100 |
| Message-ID | <sYbn3-5V0-7@gated-at.bofh.it> (permalink) |
| References | <sMbVv-188-1@gated-at.bofh.it> <sMcRA-1I2-21@gated-at.bofh.it> <sR3ND-4Wt-9@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Wed, Dec 21, 2016 at 09:07:21PM -0800, Jessica Yu wrote:
> +++ Luis R. Rodriguez [08/12/16 11:48 -0800]:
> > diff --git a/kernel/kmod.c b/kernel/kmod.c
> > index cb6f7ca7b8a5..049d7eabda38 100644
> > --- a/kernel/kmod.c
> > +++ b/kernel/kmod.c
> > @@ -108,6 +111,20 @@ static int call_modprobe(char *module_name, int wait)
> > return -ENOMEM;
> > }
> >
> > +static int kmod_umh_threads_get(void)
> > +{
> > + atomic_inc(&kmod_concurrent);
> > + if (atomic_read(&kmod_concurrent) < max_modprobes)
>
> Should this not be <=? I think this only allows up to max_modprobes-1 concurrent threads.
True, fixed!
Luis
Back to linux.kernel | Previous | Next | Find similar | Unroll thread
Re: kmod: provide wrappers for kmod_concurrent inc/dec "Luis R. Rodriguez" <mcgrof@kernel.org> - 2017-01-10 21:40 +0100
csiph-web