Module Name:    src
Committed By:   riastradh
Date:           Sun Dec 19 11:58:02 UTC 2021

Modified Files:
        src/sys/external/bsd/common/include/linux: slab.h

Log Message:
Fix inverted notion of whether to wait for allocation

Author: Maya Rashish <m...@netbsd.org>
Committer: Taylor R Campbell <riastr...@netbsd.org>


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/external/bsd/common/include/linux/slab.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/external/bsd/common/include/linux/slab.h
diff -u src/sys/external/bsd/common/include/linux/slab.h:1.4 src/sys/external/bsd/common/include/linux/slab.h:1.5
--- src/sys/external/bsd/common/include/linux/slab.h:1.4	Sun Dec 19 01:39:05 2021
+++ src/sys/external/bsd/common/include/linux/slab.h	Sun Dec 19 11:58:02 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: slab.h,v 1.4 2021/12/19 01:39:05 riastradh Exp $	*/
+/*	$NetBSD: slab.h,v 1.5 2021/12/19 11:58:02 riastradh Exp $	*/
 
 /*-
  * Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -208,9 +208,9 @@ kmem_cache_alloc(struct kmem_cache *kc, 
 	void *ptr;
 
 	if (gfp & __GFP_WAIT)
-		flags |= PR_NOWAIT;
-	else
 		flags |= PR_WAITOK;
+	else
+		flags |= PR_NOWAIT;
 
 	ptr = pool_cache_get(kc->kc_pool_cache, flags);
 	if (ptr == NULL)

Reply via email to