lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 27 Jul 2015 16:01:09 +0000
From:	"Kershner, David A" <David.Kershner@...sys.com>
To:	Neil Horman <nhorman@...hat.com>, Ingo Molnar <mingo@...nel.org>
CC:	"akpm@...ux-foundation.org" <akpm@...ux-foundation.org>,
	"tj@...nel.org" <tj@...nel.org>,
	"laijs@...fujitsu.com" <laijs@...fujitsu.com>,
	"nacc@...ux.vnet.ibm.com" <nacc@...ux.vnet.ibm.com>,
	"tglx@...utronix.de" <tglx@...utronix.de>,
	"mingo@...hat.com" <mingo@...hat.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"jes.sorensen@...hat.com" <jes.sorensen@...hat.com>,
	*S-Par-Maintainer <SParMaintainer@...sys.com>
Subject: RE: [PATCH] kthread: Export kthread functions



> -----Original Message-----
> From: Neil Horman [mailto:nhorman@...hat.com]
> Sent: Monday, July 27, 2015 11:49 AM
> To: Ingo Molnar
> Cc: Kershner, David A; akpm@...ux-foundation.org; tj@...nel.org;
> laijs@...fujitsu.com; nacc@...ux.vnet.ibm.com; tglx@...utronix.de;
> mingo@...hat.com; linux-kernel@...r.kernel.org;
> jes.sorensen@...hat.com; *S-Par-Maintainer
> Subject: Re: [PATCH] kthread: Export kthread functions
> 
> On Mon, Jul 27, 2015 at 05:45:50PM +0200, Ingo Molnar wrote:
> >
> > * David Kershner <david.kershner@...sys.com> wrote:
> >
> > > The s-Par visornic driver, currently in staging, processes a queue
> > > being serviced by the an s-Par service partition. We can get a message
> > > that something has happened with the Service Partition, when that
> > > happens, we must not access the channel until we get a message that the
> > > service partition is back again.
> > >
> > > The visornic driver has a thread for processing the channel, when we
> > > get the message, we need to be able to park the thread and then resume
> > > it when the problem clears.
> > >
> > > We can do this with kthread_park and unpark but they are not exported
> > > from the kernel, this patch exports the needed functions.
> > >
> > > Signed-off-by: David Kershner <david.kershner@...sys.com>
> > > ---
> > >  kernel/kthread.c | 4 ++++
> > >  1 file changed, 4 insertions(+)
> > >
> > > diff --git a/kernel/kthread.c b/kernel/kthread.c
> > > index 10e489c..bad80c1 100644
> > > --- a/kernel/kthread.c
> > > +++ b/kernel/kthread.c
> > > @@ -97,6 +97,7 @@ bool kthread_should_park(void)
> > >  {
> > >  	return test_bit(KTHREAD_SHOULD_PARK, &to_kthread(current)-
> >flags);
> > >  }
> > > +EXPORT_SYMBOL(kthread_should_park);
> > >
> > >  /**
> > >   * kthread_freezable_should_stop - should this freezable kthread return
> now?
> > > @@ -171,6 +172,7 @@ void kthread_parkme(void)
> > >  {
> > >  	__kthread_parkme(to_kthread(current));
> > >  }
> > > +EXPORT_SYMBOL(kthread_parkme);
> > >
> > >  static int kthread(void *_create)
> > >  {
> > > @@ -411,6 +413,7 @@ void kthread_unpark(struct task_struct *k)
> > >  	if (kthread)
> > >  		__kthread_unpark(k, kthread);
> > >  }
> > > +EXPORT_SYMBOL(kthread_unpark);
> > >
> > >  /**
> > >   * kthread_park - park a thread created by kthread_create().
> > > @@ -441,6 +444,7 @@ int kthread_park(struct task_struct *k)
> > >  	}
> > >  	return ret;
> > >  }
> > > +EXPORT_SYMBOL(kthread_park);
> > >
> > >  /**
> > >   * kthread_stop - stop a thread created by kthread_create().
> >
> > Please make these EXPORT_SYMBOL_GPL(), as
> kthread_freezable_should_stop() is
> > already _GPL(), and generally new kthread APIs are exported via
> > EXPORT_SYMBOL_GPL().
> >
> Im ok with that.  David?
> Neil
> 

Fine with that as well.

David 
> > With that change:
> >
> >   Acked-by: Ingo Molnar <mingo@...nel.org>
> >
> > Thanks,
> >
> > 	Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ