diff mbox

[2/3] hostservices: Don't run pollers from hostservices callbacks

Message ID 20150216151527.1774.78577.stgit@thinktux.in.ibm.com
State Accepted
Headers show

Commit Message

Ananth N Mavinakayanahalli Feb. 16, 2015, 3:15 p.m. UTC
Use the _nopoll variant of nanosleep from hostservices, to avoid potential
poller recursion.

Signed-off-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
---
 core/hostservices.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Benjamin Herrenschmidt Feb. 16, 2015, 9:14 p.m. UTC | #1
On Mon, 2015-02-16 at 20:45 +0530, Ananth N Mavinakayanahalli wrote:
> Use the _nopoll variant of nanosleep from hostservices, to avoid potential
> poller recursion.
> 
> Signed-off-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com>

Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>

> ---
>  core/hostservices.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/core/hostservices.c b/core/hostservices.c
> index 9cc3341..952f6b8 100644
> --- a/core/hostservices.c
> +++ b/core/hostservices.c
> @@ -467,7 +467,7 @@ static void hservice_nanosleep(uint64_t i_seconds, uint64_t i_nano_seconds)
>  
>  	ts.tv_sec = i_seconds;
>  	ts.tv_nsec = i_nano_seconds;
> -	nanosleep(&ts, NULL);
> +	nanosleep_nopoll(&ts, NULL);
>  }
>  
>  static int hservice_set_special_wakeup(struct cpu_thread *cpu)
> 
> _______________________________________________
> Skiboot mailing list
> Skiboot@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/skiboot
diff mbox

Patch

diff --git a/core/hostservices.c b/core/hostservices.c
index 9cc3341..952f6b8 100644
--- a/core/hostservices.c
+++ b/core/hostservices.c
@@ -467,7 +467,7 @@  static void hservice_nanosleep(uint64_t i_seconds, uint64_t i_nano_seconds)
 
 	ts.tv_sec = i_seconds;
 	ts.tv_nsec = i_nano_seconds;
-	nanosleep(&ts, NULL);
+	nanosleep_nopoll(&ts, NULL);
 }
 
 static int hservice_set_special_wakeup(struct cpu_thread *cpu)