Thread (20 messages) 20 messages, 6 authors, 2021-05-30

Re: [PATCH] mm/page_alloc: Work around a pahole limitation with zero-sized struct pagesets

From: Christoph Hellwig <hch@infradead.org>
Date: 2021-05-27 08:05:14
Also in: bpf, linux-mm, lkml

On Wed, May 26, 2021 at 09:07:41AM +0100, Mel Gorman wrote:
+    !defined(CONFIG_DEBUG_LOCK_ALLOC) &&		\
+    !defined(CONFIG_PAHOLE_HAS_ZEROSIZE_PERCPU_SUPPORT)
+	/*
+	 * pahole 1.21 and earlier gets confused by zero-sized per-CPU
+	 * variables and produces invalid BTF. Ensure that
+	 * sizeof(struct pagesets) != 0 for older versions of pahole.
+	 */
+	char __pahole_hack;
+	#warning "pahole too old to support zero-sized struct pagesets"
+#endif
Err, hell no.  We should not mess up the kernel for broken tools that
are not relevant to the kernel build itself ever.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help