Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

kfifo: don't use "proxy" headers

Update header inclusions to follow IWYU (Include What You Use) principle.

Link: https://lkml.kernel.org/r/20240423192529.3249134-4-andriy.shevchenko@linux.intel.com
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: Alain Volmat <alain.volmat@foss.st.com>
Cc: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Cc: Chen-Yu Tsai <wens@csie.org>
Cc: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Cc: Jernej Skrabec <jernej.skrabec@gmail.com>
Cc: Matthias Brugger <matthias.bgg@gmail.com>
Cc: Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: Patrice Chotard <patrice.chotard@foss.st.com>
Cc: Rob Herring <robh@kernel.org>
Cc: Samuel Holland <samuel@sholland.org>
Cc: Sean Wang <sean.wang@mediatek.com>
Cc: Sean Young <sean@mess.org>
Cc: Stefani Seibold <stefani@seibold.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>

authored by

Andy Shevchenko and committed by
Andrew Morton
22bcc915 495ae16a

+14 -8
+7 -2
include/linux/kfifo.h
··· 36 36 * to lock the reader. 37 37 */ 38 38 39 - #include <linux/kernel.h> 39 + #include <linux/array_size.h> 40 40 #include <linux/spinlock.h> 41 41 #include <linux/stddef.h> 42 - #include <linux/scatterlist.h> 42 + #include <linux/types.h> 43 + 44 + #include <asm/barrier.h> 45 + #include <asm/errno.h> 46 + 47 + struct scatterlist; 43 48 44 49 struct __kfifo { 45 50 unsigned int in;
+5 -5
lib/kfifo.c
··· 5 5 * Copyright (C) 2009/2010 Stefani Seibold <stefani@seibold.net> 6 6 */ 7 7 8 - #include <linux/kernel.h> 9 - #include <linux/export.h> 10 - #include <linux/slab.h> 11 8 #include <linux/err.h> 12 - #include <linux/log2.h> 13 - #include <linux/uaccess.h> 9 + #include <linux/export.h> 14 10 #include <linux/kfifo.h> 11 + #include <linux/log2.h> 12 + #include <linux/scatterlist.h> 13 + #include <linux/slab.h> 14 + #include <linux/uaccess.h> 15 15 16 16 /* 17 17 * internal helper to calculate the unused elements in a fifo
+2 -1
samples/kfifo/dma-example.c
··· 6 6 */ 7 7 8 8 #include <linux/init.h> 9 - #include <linux/module.h> 10 9 #include <linux/kfifo.h> 10 + #include <linux/module.h> 11 + #include <linux/scatterlist.h> 11 12 12 13 /* 13 14 * This module shows how to handle fifo dma operations.