On Tue, Aug 02, 2016 at 10:32:26AM +1000, Balbir Singh wrote: > From: Balbir singh <bsingharora@xxxxxxxxx> > Date: Tue, 2 Aug 2016 10:26:34 +1000 > Subject: [PATCH] Correct a sample in memorybarriers.tex > > We probably don't want to show GFP_KERNEL allocation > under spin_lock, GFP_ATOMIC seems much better. > > Signed-off-by: Balbir singh <bsingharora@xxxxxxxxx> Good catch, applied, thank you! However, I had to apply this by hand due to some recent mass changes to figures containing code. Could you please move to current perfbook.git for future submissions? Thanx, Paul > --- > advsync/memorybarriers.tex | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/advsync/memorybarriers.tex b/advsync/memorybarriers.tex > index 9eaa0ea..efbd4a2 100644 > --- a/advsync/memorybarriers.tex > +++ b/advsync/memorybarriers.tex > @@ -936,7 +936,7 @@ Then the following code might leak memory! > \begin{verbatim} > spin_lock(&mylock); > if (p == NULL) > - p = kmalloc(sizeof(*p), GFP_KERNEL); > + p = kmalloc(sizeof(*p), GFP_ATOMIC); > spin_unlock(&mylock); > \end{verbatim} > \end{minipage} > -- > 2.7.4 > -- To unsubscribe from this list: send the line "unsubscribe perfbook" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html