* [PATCH v1 1/1] xarray: Replace kernel.h with the necessary inclusions
@ 2022-06-03 17:11 Andy Shevchenko
2022-06-03 17:17 ` Matthew Wilcox
0 siblings, 1 reply; 3+ messages in thread
From: Andy Shevchenko @ 2022-06-03 17:11 UTC (permalink / raw)
To: linux-fsdevel, linux-kernel
Cc: Matthew Wilcox, Andrew Morton, Andy Shevchenko
When kernel.h is used in the headers it adds a lot into dependency hell,
especially when there are circular dependencies are involved.
Replace kernel.h inclusion with the list of what is really being used.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
include/linux/xarray.h | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/include/linux/xarray.h b/include/linux/xarray.h
index 72feab5ea8d4..e9fedaa3498a 100644
--- a/include/linux/xarray.h
+++ b/include/linux/xarray.h
@@ -12,13 +12,18 @@
#include <linux/bitmap.h>
#include <linux/bug.h>
#include <linux/compiler.h>
+#include <linux/err.h>
#include <linux/gfp.h>
#include <linux/kconfig.h>
-#include <linux/kernel.h>
+#include <linux/limits.h>
+#include <linux/lockdep.h>
+#include <linux/math.h>
#include <linux/rcupdate.h>
#include <linux/spinlock.h>
#include <linux/types.h>
+#include <asm/bitsperlong.h>
+
/*
* The bottom two bits of the entry determine how the XArray interprets
* the contents:
--
2.35.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH v1 1/1] xarray: Replace kernel.h with the necessary inclusions
2022-06-03 17:11 [PATCH v1 1/1] xarray: Replace kernel.h with the necessary inclusions Andy Shevchenko
@ 2022-06-03 17:17 ` Matthew Wilcox
2022-06-03 19:54 ` Andy Shevchenko
0 siblings, 1 reply; 3+ messages in thread
From: Matthew Wilcox @ 2022-06-03 17:17 UTC (permalink / raw)
To: Andy Shevchenko; +Cc: linux-fsdevel, linux-kernel, Andrew Morton
On Fri, Jun 03, 2022 at 08:11:53PM +0300, Andy Shevchenko wrote:
> When kernel.h is used in the headers it adds a lot into dependency hell,
> especially when there are circular dependencies are involved.
>
> Replace kernel.h inclusion with the list of what is really being used.
Thanks. Can you fix the test suite too?
(cd tools/testing/radix-tree; make)
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH v1 1/1] xarray: Replace kernel.h with the necessary inclusions
2022-06-03 17:17 ` Matthew Wilcox
@ 2022-06-03 19:54 ` Andy Shevchenko
0 siblings, 0 replies; 3+ messages in thread
From: Andy Shevchenko @ 2022-06-03 19:54 UTC (permalink / raw)
To: Matthew Wilcox; +Cc: linux-fsdevel, linux-kernel, Andrew Morton
On Fri, Jun 03, 2022 at 06:17:22PM +0100, Matthew Wilcox wrote:
> On Fri, Jun 03, 2022 at 08:11:53PM +0300, Andy Shevchenko wrote:
> > When kernel.h is used in the headers it adds a lot into dependency hell,
> > especially when there are circular dependencies are involved.
> >
> > Replace kernel.h inclusion with the list of what is really being used.
>
> Thanks. Can you fix the test suite too?
>
> (cd tools/testing/radix-tree; make)
Works for me. Anything special I should try?
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-06-03 19:54 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-06-03 17:11 [PATCH v1 1/1] xarray: Replace kernel.h with the necessary inclusions Andy Shevchenko
2022-06-03 17:17 ` Matthew Wilcox
2022-06-03 19:54 ` Andy Shevchenko
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox