fix up includes of linux/major.h
Subsystems (63)
cover fix up includes of linux/major.h
Hi all,
[This is not cc'd very widely, but get_maintainers produces a very long list ...]
I have been looking at our include file mess off and on over time and have finally decided to start with something easy. linux/major.h (actually uapi/linux/major.h) is included in quite a few places that are unnecessary and not included in pleaces it should be. It also does not include (or depend on) any other file. I was lead here while looking at reducding the size of linux/tty.h (which this patch series accomplishes).
Just 2 patches currently:
1/2 Explicitly include linux/major.h where it is needed 2/2 Remove the include of linux/major.h from files that do not need it
arch/alpha/kernel/osf_sys.c | 1 - arch/alpha/kernel/process.c | 1 - arch/arm/mach-iop32x/i2c.c | 1 - arch/arm/mach-omap1/board-h3.c | 1 - arch/arm/mach-pxa/corgi.c | 1 - arch/arm/mach-pxa/lubbock.c | 1 - arch/arm/mach-pxa/tosa.c | 1 - arch/arm/mach-pxa/viper.c | 1 - arch/m68k/atari/atasound.c | 1 - arch/m68k/atari/stram.c | 1 - arch/m68k/bvme6000/config.c | 1 - arch/m68k/mvme147/config.c | 1 - arch/m68k/mvme16x/config.c | 1 - arch/m68k/q40/config.c | 1 - arch/mips/fw/arc/arc_con.c | 1 - arch/powerpc/platforms/83xx/km83xx.c | 1 - arch/powerpc/platforms/83xx/mpc832x_mds.c | 1 - arch/powerpc/platforms/83xx/mpc834x_itx.c | 1 - arch/powerpc/platforms/83xx/mpc834x_mds.c | 1 - arch/powerpc/platforms/83xx/mpc836x_mds.c | 1 - arch/powerpc/platforms/85xx/mpc85xx_cds.c | 1 - arch/powerpc/platforms/85xx/mpc85xx_mds.c | 1 - arch/powerpc/platforms/85xx/sbc8548.c | 1 - arch/powerpc/platforms/chrp/setup.c | 1 - arch/powerpc/platforms/maple/setup.c | 1 - arch/powerpc/platforms/powermac/setup.c | 1 - arch/powerpc/platforms/pseries/setup.c | 1 - arch/powerpc/sysdev/fsl_soc.c | 1 - arch/powerpc/sysdev/tsi108_dev.c | 1 - arch/sparc/kernel/setup_32.c | 1 - arch/sparc/kernel/setup_64.c | 1 - arch/um/drivers/ubd_kern.c | 1 + arch/xtensa/platforms/xt2000/setup.c | 1 - arch/xtensa/platforms/xtfpga/setup.c | 1 - block/genhd.c | 1 + block/partitions/efi.h | 1 - drivers/android/binderfs.c | 1 - drivers/block/amiflop.c | 1 + drivers/block/ataflop.c | 1 + drivers/block/drbd/drbd_int.h | 1 - drivers/block/drbd/drbd_main.c | 1 + drivers/block/floppy.c | 1 + drivers/block/swim.c | 1 + drivers/block/swim3.c | 1 + drivers/block/xen-blkfront.c | 1 + drivers/cdrom/cdrom.c | 1 - drivers/char/hpet.c | 1 - drivers/char/mem.c | 1 + drivers/char/mwave/mwavedd.c | 1 - drivers/char/pcmcia/synclink_cs.c | 1 - drivers/char/random.c | 1 - drivers/char/ttyprintk.c | 1 + drivers/hid/hidraw.c | 1 - drivers/ide/ide-cs.c | 1 - drivers/ide/ide-disk.c | 1 - drivers/ide/ide-floppy.c | 1 - drivers/ide/ide-io.c | 1 - drivers/ide/ide-iops.c | 1 - drivers/ide/ide.c | 1 - drivers/input/serio/serio_raw.c | 1 - drivers/isdn/capi/capi.c | 1 - drivers/md/md.c | 1 + drivers/message/fusion/mptctl.c | 1 + drivers/misc/vmw_vmci/vmci_host.c | 1 + drivers/mmc/core/block.c | 1 + drivers/mmc/host/android-goldfish.c | 1 - drivers/mtd/devices/pmc551.c | 1 - drivers/mtd/devices/slram.c | 1 - drivers/mtd/ftl.c | 1 - drivers/mtd/maps/uclinux.c | 1 - drivers/net/hamradio/mkiss.c | 1 - drivers/net/tun.c | 1 - drivers/parport/parport_cs.c | 1 - drivers/pcmcia/cistpl.c | 1 - drivers/pcmcia/cs.c | 1 - drivers/pcmcia/socket_sysfs.c | 1 - drivers/s390/block/dasd.c | 1 - drivers/s390/block/dasd_genhd.c | 1 + drivers/s390/block/dasd_ioctl.c | 1 - drivers/s390/block/xpram.c | 1 + drivers/s390/char/con3215.c | 1 + drivers/s390/char/fs3270.c | 1 + drivers/s390/char/raw3270.c | 1 - drivers/s390/char/sclp_tty.c | 1 + drivers/s390/char/tape_class.h | 1 - drivers/s390/char/tty3270.c | 1 + drivers/s390/scsi/zfcp_def.h | 1 - drivers/sbus/char/display7seg.c | 1 - drivers/scsi/nsp32.c | 1 - drivers/scsi/pcmcia/aha152x_stub.c | 1 - drivers/scsi/pcmcia/nsp_cs.c | 1 - drivers/scsi/pcmcia/qlogic_stub.c | 1 - drivers/scsi/sd.c | 1 + drivers/scsi/sg.c | 1 + drivers/scsi/sr.c | 1 + drivers/scsi/st.c | 1 + drivers/staging/kpc2000/kpc_dma/kpc_dma_driver.c | 1 + drivers/staging/speakup/devsynth.c | 1 + drivers/tty/hvc/hvc_console.c | 1 - drivers/tty/hvc/hvcs.c | 1 - drivers/tty/hvc/hvsi.c | 1 - drivers/tty/moxa.c | 1 - drivers/tty/mxser.c | 1 - drivers/tty/n_gsm.c | 1 - drivers/tty/n_tty.c | 1 - drivers/tty/rocket.c | 1 - drivers/tty/serial/8250/8250_core.c | 1 + drivers/tty/serial/8250/serial_cs.c | 1 - drivers/tty/serial/apbuart.c | 1 + drivers/tty/serial/atmel_serial.c | 1 + drivers/tty/serial/bcm63xx_uart.c | 1 + drivers/tty/serial/icom.c | 1 - drivers/tty/serial/mcf.c | 1 + drivers/tty/serial/mux.c | 1 + drivers/tty/serial/pxa.c | 1 + drivers/tty/serial/serial_txx9.c | 1 + drivers/tty/serial/sh-sci.c | 1 - drivers/tty/synclink.c | 1 - drivers/tty/synclink_gt.c | 1 - drivers/tty/synclinkmp.c | 1 - drivers/tty/sysrq.c | 1 - drivers/tty/tty_ioctl.c | 1 - drivers/tty/vt/vt_ioctl.c | 1 - drivers/watchdog/cpwd.c | 1 - drivers/watchdog/watchdog_dev.c | 1 + drivers/xen/evtchn.c | 1 - drivers/xen/gntalloc.c | 1 + fs/block_dev.c | 1 - fs/char_dev.c | 1 - fs/coda/psdev.c | 1 - fs/devpts/inode.c | 1 + fs/proc/proc_tty.c | 1 + fs/xfs/xfs_linux.h | 1 - include/linux/blkdev.h | 1 - include/linux/genhd.h | 1 - include/linux/tty.h | 1 - include/uapi/linux/raid/md_u.h | 2 ++ init/do_mounts.c | 1 + init/do_mounts.h | 1 - init/do_mounts_md.c | 1 + init/do_mounts_rd.c | 1 + kernel/bpf/inode.c | 1 - net/ipv4/ipconfig.c | 1 - tools/hv/hv_vss_daemon.c | 1 - 144 files changed, 44 insertions(+), 101 deletions(-)
Signature · 2 lines
Cheers, Stephen Rothwell
RFC PATCH 1/2 Explicitly include linux/major.h where it is needed
This is in preparation for removing the include of major.h where it is not needed.
These files were found using
grep -E -L '[<"](uapi/)?linux/major\.h' $(git grep -l -w -f /tmp/xx)
where /tmp/xx contains all the symbols defined in major.h. There were a couple of files in that list that did not need the include since the references are in comments.
--- arch/um/drivers/ubd_kern.c | 1 + block/genhd.c | 1 + drivers/block/amiflop.c | 1 + drivers/block/ataflop.c | 1 + drivers/block/drbd/drbd_main.c | 1 + drivers/block/floppy.c | 1 + drivers/block/swim.c | 1 + drivers/block/swim3.c | 1 + drivers/block/xen-blkfront.c | 1 + drivers/char/mem.c | 1 + drivers/char/ttyprintk.c | 1 + drivers/md/md.c | 1 + drivers/message/fusion/mptctl.c | 1 + drivers/misc/vmw_vmci/vmci_host.c | 1 + drivers/mmc/core/block.c | 1 + drivers/s390/block/dasd_genhd.c | 1 + drivers/s390/block/xpram.c | 1 + drivers/s390/char/con3215.c | 1 + drivers/s390/char/fs3270.c | 1 + drivers/s390/char/sclp_tty.c | 1 + drivers/s390/char/tty3270.c | 1 + drivers/scsi/sd.c | 1 + drivers/scsi/sg.c | 1 + drivers/scsi/sr.c | 1 + drivers/scsi/st.c | 1 + drivers/staging/kpc2000/kpc_dma/kpc_dma_driver.c | 1 + drivers/staging/speakup/devsynth.c | 1 + drivers/tty/serial/8250/8250_core.c | 1 + drivers/tty/serial/apbuart.c | 1 + drivers/tty/serial/atmel_serial.c | 1 + drivers/tty/serial/bcm63xx_uart.c | 1 + drivers/tty/serial/mcf.c | 1 + drivers/tty/serial/mux.c | 1 + drivers/tty/serial/pxa.c | 1 + drivers/tty/serial/serial_txx9.c | 1 + drivers/watchdog/watchdog_dev.c | 1 + drivers/xen/gntalloc.c | 1 + fs/devpts/inode.c | 1 + fs/proc/proc_tty.c | 1 + include/uapi/linux/raid/md_u.h | 2 ++ init/do_mounts.c | 1 + init/do_mounts_md.c | 1 + init/do_mounts_rd.c | 1 + 43 files changed, 44 insertions(+)
arch/um/drivers/ubd_kern.c +1 -0
@@ -35,6 +35,7 @@#include <linux/vmalloc.h> #include <linux/platform_device.h> #include <linux/scatterlist.h> +#include <linux/major.h> #include <asm/tlbflush.h> #include <kern_util.h> #include "mconsole_kern.h"
block/genhd.c +1 -0
@@ -23,6 +23,7 @@#include <linux/log2.h> #include <linux/pm_runtime.h> #include <linux/badblocks.h> +#include <linux/major.h> #include "blk.h"
drivers/block/amiflop.c +1 -0
@@ -67,6 +67,7 @@#include <linux/elevator.h> #include <linux/interrupt.h> #include <linux/platform_device.h> +#include <linux/major.h> #include <asm/setup.h> #include <linux/uaccess.h>
drivers/block/ataflop.c +1 -0
@@ -71,6 +71,7 @@#include <linux/mutex.h> #include <linux/completion.h> #include <linux/wait.h> +#include <linux/major.h> #include <asm/atariints.h> #include <asm/atari_stdma.h>
drivers/block/drbd/drbd_main.c +1 -0
@@ -41,6 +41,7 @@#include <linux/unistd.h> #include <linux/vmalloc.h> #include <linux/sched/signal.h> +#include <linux/major.h> #include <linux/drbd_limits.h> #include "drbd_int.h"
drivers/block/floppy.c +1 -0
@@ -193,6 +193,7 @@ static int print_unex = 1;#include <linux/uaccess.h> #include <linux/async.h> #include <linux/compat.h> +#include <linux/major.h> /* * PS/2 floppies have much slower step rates than regular floppies.
drivers/block/swim.c +1 -0
@@ -21,6 +21,7 @@#include <linux/kernel.h> #include <linux/delay.h> #include <linux/platform_device.h> +#include <linux/major.h> #include <asm/mac_via.h>
drivers/block/swim3.c +1 -0
@@ -27,6 +27,7 @@#include <linux/module.h> #include <linux/spinlock.h> #include <linux/wait.h> +#include <linux/major.h> #include <asm/io.h> #include <asm/dbdma.h> #include <asm/prom.h>
drivers/block/xen-blkfront.c +1 -0
@@ -48,6 +48,7 @@#include <linux/list.h> #include <linux/workqueue.h> #include <linux/sched/mm.h> +#include <linux/major.h> #include <xen/xen.h> #include <xen/xenbus.h>
drivers/char/mem.c +1 -0
@@ -34,6 +34,7 @@#include <linux/pseudo_fs.h> #include <uapi/linux/magic.h> #include <linux/mount.h> +#include <linux/major.h> #ifdef CONFIG_IA64 # include <linux/efi.h>
drivers/char/ttyprintk.c +1 -0
@@ -16,6 +16,7 @@#include <linux/tty.h> #include <linux/module.h> #include <linux/spinlock.h> +#include <linux/major.h> struct ttyprintk_port {struct tty_port port;
drivers/md/md.c +1 -0
@@ -62,6 +62,7 @@#include <linux/slab.h> #include <linux/percpu-refcount.h> #include <linux/part_stat.h> +#include <linux/major.h> #include <trace/events/block.h> #include "md.h"
drivers/message/fusion/mptctl.c +1 -0
@@ -56,6 +56,7 @@#include <linux/miscdevice.h> #include <linux/mutex.h> #include <linux/compat.h> +#include <linux/major.h> #include <asm/io.h> #include <linux/uaccess.h>
drivers/misc/vmw_vmci/vmci_host.c +1 -0
@@ -24,6 +24,7 @@#include <linux/smp.h> #include <linux/fs.h> #include <linux/io.h> +#include <linux/major.h> #include "vmci_handle_array.h" #include "vmci_queue_pair.h"
drivers/mmc/core/block.c +1 -0
@@ -38,6 +38,7 @@#include <linux/pm_runtime.h> #include <linux/idr.h> #include <linux/debugfs.h> +#include <linux/major.h> #include <linux/mmc/ioctl.h> #include <linux/mmc/card.h>
drivers/s390/block/dasd_genhd.c +1 -0
@@ -16,6 +16,7 @@#include <linux/interrupt.h> #include <linux/fs.h> #include <linux/blkpg.h> +#include <linux/major.h> #include <linux/uaccess.h>
drivers/s390/block/xpram.c +1 -0
@@ -43,6 +43,7 @@#include <linux/platform_device.h> #include <linux/gfp.h> #include <linux/uaccess.h> +#include <linux/major.h> #define XPRAM_NAME "xpram"#define XPRAM_DEVS 1/* one partition */
drivers/s390/char/con3215.c +1 -0
@@ -22,6 +22,7 @@#include <linux/reboot.h> #include <linux/serial.h> /* ASYNC_* flags */ #include <linux/slab.h> +#include <linux/major.h> #include <asm/ccwdev.h> #include <asm/cio.h> #include <asm/io.h>
drivers/s390/char/fs3270.c +1 -0
@@ -18,6 +18,7 @@#include <linux/list.h> #include <linux/slab.h> #include <linux/types.h> +#include <linux/major.h> #include <asm/ccwdev.h> #include <asm/cio.h>
drivers/s390/char/sclp_tty.c +1 -0
@@ -17,6 +17,7 @@#include <linux/interrupt.h> #include <linux/gfp.h> #include <linux/uaccess.h> +#include <linux/major.h> #include "ctrlchar.h" #include "sclp.h"
drivers/s390/char/tty3270.c +1 -0
@@ -17,6 +17,7 @@#include <linux/console.h> #include <linux/interrupt.h> #include <linux/workqueue.h> +#include <linux/major.h> #include <linux/slab.h> #include <linux/memblock.h>
drivers/scsi/sd.c +1 -0
@@ -57,6 +57,7 @@#include <linux/pr.h> #include <linux/t10-pi.h> #include <linux/uaccess.h> +#include <linux/major.h> #include <asm/unaligned.h> #include <scsi/scsi.h>
drivers/scsi/sg.c +1 -0
@@ -47,6 +47,7 @@ static int sg_version_num = 30536; /* 2 digits for each component */#include <linux/ratelimit.h> #include <linux/uio.h> #include <linux/cred.h> /* for sg_check_file_access() */ +#include <linux/major.h> #include "scsi.h" #include <scsi/scsi_dbg.h>
drivers/scsi/sr.c +1 -0
@@ -50,6 +50,7 @@#include <linux/slab.h> #include <linux/pm_runtime.h> #include <linux/uaccess.h> +#include <linux/major.h> #include <asm/unaligned.h>
drivers/scsi/st.c +1 -0
@@ -42,6 +42,7 @@ static const char *verstr = "20160209";#include <linux/idr.h> #include <linux/delay.h> #include <linux/mutex.h> +#include <linux/major.h> #include <linux/uaccess.h> #include <asm/dma.h>
drivers/staging/kpc2000/kpc_dma/kpc_dma_driver.c +1 -0
@@ -8,6 +8,7 @@#include <linux/platform_device.h> #include <linux/fs.h> #include <linux/rwsem.h> +#include <linux/major.h> #include "kpc_dma_driver.h" MODULE_LICENSE ("GPL" );
drivers/staging/speakup/devsynth.c +1 -0
@@ -3,6 +3,7 @@#include <linux/miscdevice.h> /* for misc_register, and MISC_DYNAMIC_MINOR */ #include <linux/types.h> #include <linux/uaccess.h> +#include <linux/major.h> #include "speakup.h" #include "spk_priv.h"
drivers/tty/serial/8250/8250_core.c +1 -0
@@ -37,6 +37,7 @@#ifdef CONFIG_SPARC #include <linux/sunserialcore.h> #endif +#include <linux/major.h> #include <asm/irq.h>
drivers/tty/serial/apbuart.c +1 -0
@@ -28,6 +28,7 @@#include <linux/platform_device.h> #include <linux/io.h> #include <linux/serial_core.h> +#include <linux/major.h> #include <asm/irq.h> #include "apbuart.h"
drivers/tty/serial/atmel_serial.c +1 -0
@@ -30,6 +30,7 @@#include <linux/irq.h> #include <linux/suspend.h> #include <linux/mm.h> +#include <linux/major.h> #include <asm/div64.h> #include <asm/io.h>
drivers/tty/serial/bcm63xx_uart.c +1 -0
@@ -25,6 +25,7 @@#include <linux/serial_bcm63xx.h> #include <linux/io.h> #include <linux/of.h> +#include <linux/major.h> #define BCM63XX_NR_UARTS 2
drivers/tty/serial/mcf.c +1 -0
@@ -21,6 +21,7 @@#include <linux/io.h> #include <linux/uaccess.h> #include <linux/platform_device.h> +#include <linux/major.h> #include <asm/coldfire.h> #include <asm/mcfsim.h> #include <asm/mcfuart.h>
drivers/tty/serial/mux.c +1 -0
@@ -21,6 +21,7 @@#include <linux/console.h> #include <linux/delay.h> /* for udelay */ #include <linux/device.h> +#include <linux/major.h> #include <asm/io.h> #include <asm/irq.h> #include <asm/parisc-device.h>
drivers/tty/serial/pxa.c +1 -0
@@ -35,6 +35,7 @@#include <linux/clk.h> #include <linux/io.h> #include <linux/slab.h> +#include <linux/major.h> #define PXA_NAME_LEN 8
drivers/tty/serial/serial_txx9.c +1 -0
@@ -23,6 +23,7 @@#include <linux/serial.h> #include <linux/tty.h> #include <linux/tty_flip.h> +#include <linux/major.h> #include <asm/io.h>
drivers/watchdog/watchdog_dev.c +1 -0
@@ -42,6 +42,7 @@#include <linux/types.h> /* For standard types (like size_t) */ #include <linux/watchdog.h> /* For watchdog specific items */ #include <linux/uaccess.h> /* For copy_to_user/put_user/... */ +#include <linux/major.h> #include <uapi/linux/sched/types.h> /* For struct sched_param */
drivers/xen/gntalloc.c +1 -0
@@ -63,6 +63,7 @@#include <linux/types.h> #include <linux/list.h> #include <linux/highmem.h> +#include <linux/major.h> #include <xen/xen.h> #include <xen/page.h>
fs/devpts/inode.c +1 -0
@@ -24,6 +24,7 @@#include <linux/parser.h> #include <linux/fsnotify.h> #include <linux/seq_file.h> +#include <linux/major.h> #define DEVPTS_DEFAULT_MODE 0600/*
fs/proc/proc_tty.c +1 -0
@@ -15,6 +15,7 @@#include <linux/tty.h> #include <linux/seq_file.h> #include <linux/bitops.h> +#include <linux/major.h> #include "internal.h" /*
include/uapi/linux/raid/md_u.h +2 -0
@@ -16,6 +16,8 @@#ifndef _UAPI_MD_U_H#define _UAPI_MD_U_H +#include <linux/major.h> +/* * Different major versions are not compatible. * Different minor versions are only downward compatible.
init/do_mounts.c +1 -0
@@ -19,6 +19,7 @@#include <linux/slab.h> #include <linux/ramfs.h> #include <linux/shmem_fs.h> +#include <linux/major.h> #include <linux/nfs_fs.h> #include <linux/nfs_fs_sb.h>
init/do_mounts_md.c +1 -0
@@ -2,6 +2,7 @@#include <linux/delay.h> #include <linux/raid/md_u.h> #include <linux/raid/md_p.h> +#include <linux/major.h> #include "do_mounts.h"
init/do_mounts_rd.c +1 -0
@@ -8,6 +8,7 @@#include <linux/initrd.h> #include <linux/string.h> #include <linux/slab.h> +#include <linux/major.h> #include "do_mounts.h" #include "../fs/squashfs/squashfs_fs.h"
Signature · 1 line
2.27.0
Greg KH
maintainerRe: [RFC PATCH 1/2] Explicitly include linux/major.h where it is needed
Quoted 5 lines · Stephen Rothwell
This is in preparation for removing the include of
major.hwhere it is not needed.These files were found using
Quoted 7 lines
grep -E -L '[<"](uapi/)?linux/major\.h' $(git grep -l -w -f /tmp/xx)where
/tmp/xxcontains all the symbols defined inmajor.h. There were a couple of files in that list that did not need the include since the references are in comments.Signed-off-by Stephen Rothwell <[email protected]>
Any reason this had an RFC, but patch 2/2 did not?
They look good to me, I will be glad to take these, but do you still want reviews from others for this? It seems simple enough to me...
thanks,
greg k-h
Re: [RFC PATCH 1/2] Explicitly include linux/major.h where it is needed
Hi Greg,
Quoted 9 lines · On Wed, 17 Jun 2020 07:58:43 +0200 Greg KH <[email protected]> wrote:
Quoted 7 lines · Stephen Rothwell
This is in preparation for removing the include of
major.hwhere it is not needed.These files were found using
grep -E -L '[<"](uapi/)?linux/major\.h' $(git grep -l -w -f /tmp/xx)
Quoted 7 lines
Quoted 5 lines
where
/tmp/xxcontains all the symbols defined inmajor.h. There were a couple of files in that list that did not need the include since the references are in comments.Signed-off-by Stephen Rothwell <[email protected]>Any reason this had an RFC, but patch 2/2 did not?
I forgot :-) I added RFC just to hopefully get some attention as this is just the start of a long slow use of my "spare" time.
Quoted 2 lines
They look good to me, I will be glad to take these, but do you still want reviews from others for this? It seems simple enough to me...
Yeah, well, we all know the simplest patches usually cause the most pain :-)
However, I have been fairly careful and it is an easy include file to work with. And I have done my usual build checks, so the linux-next maintainer won't complain about build problems :-)
I would like to hear from Arnd, at least, as I don't want to step on his toes (he is having a larger look at our include files).
Signature · 2 lines
Cheers, Stephen Rothwell
Re: [RFC PATCH 1/2] Explicitly include linux/major.h where it is needed
Hi Arnd,
Quoted 25 lines · On Wed, 17 Jun 2020 16:18:10 +1000 Stephen Rothwell <[email protected]>…
Quoted 9 lines · On Wed, 17 Jun 2020 07:58:43 +0200 Greg KH <[email protected]> wrote:
Quoted 7 lines · Stephen Rothwell
This is in preparation for removing the include of
major.hwhere it is not needed.These files were found using
grep -E -L '[<"](uapi/)?linux/major\.h' $(git grep -l -w -f /tmp/xx)Quoted 7 lines
Quoted 5 lines
where
/tmp/xxcontains all the symbols defined inmajor.h. There were a couple of files in that list that did not need the include since the references are in comments.Signed-off-by Stephen Rothwell <[email protected]>Any reason this had an RFC, but patch 2/2 did not?
I forgot :-) I added RFC just to hopefully get some attention as this is just the start of a long slow use of my "spare" time.
Quoted 2 lines
They look good to me, I will be glad to take these, but do you still want reviews from others for this? It seems simple enough to me...
Quoted 8 lines
Yeah, well, we all know the simplest patches usually cause the most pain :-)
However, I have been fairly careful and it is an easy include file to work with. And I have done my usual build checks, so the linux-next maintainer won't complain about build problems :-)
I would like to hear from Arnd, at least, as I don't want to step on his toes (he is having a larger look at our include files).
Any comment?
Signature · 2 lines
Cheers, Stephen Rothwell
Arnd Bergmann
maintainerRe: [RFC PATCH 1/2] Explicitly include linux/major.h where it is needed
Quoted 26 lines · Stephen Rothwell
Quoted 25 lines · On Wed, 17 Jun 2020 16:18:10 +1000 Stephen Rothwell <[email protected]>…
Quoted 8 lines · On Wed, 17 Jun 2020 07:58:43 +0200 Greg KH <[email protected]> wrote:
Quoted 7 lines · Stephen Rothwell
This is in preparation for removing the include of
major.hwhere it is not needed.These files were found using
grep -E -L '[<"](uapi/)?linux/major\.h' $(git grep -l -w -f /tmp/xx)Quoted 7 lines
Quoted 5 lines
where
/tmp/xxcontains all the symbols defined inmajor.h. There were a couple of files in that list that did not need the include since the references are in comments.Signed-off-by Stephen Rothwell <[email protected]>Any reason this had an RFC, but patch 2/2 did not?
I forgot :-) I added RFC just to hopefully get some attention as this is just the start of a long slow use of my "spare" time.
Quoted 2 lines
They look good to me, I will be glad to take these, but do you still want reviews from others for this? It seems simple enough to me...
Yeah, well, we all know the simplest patches usually cause the most pain :-)
Quoted 8 lines
Quoted 6 lines
However, I have been fairly careful and it is an easy include file to work with. And I have done my usual build checks, so the linux-next maintainer won't complain about build problems :-)
I would like to hear from Arnd, at least, as I don't want to step on his toes (he is having a larger look at our include files).
Any comment?
I now have a set of regex/header file pairs and a script that automatically adds the #include statements to any source file that needs them as a preparation for a larger-scale cleanup. Your change is going in the same direction, and linux/major.h is a header that was not on my list yet, so I'm completely happy with this.
One thing that I did differently in my script is to insert the new #include statement in a way that retains alphabetical ordering of the other inclusions rather than adding it at the end.
If the headers were not sorted before, it just tries a trivial nearest match, adding it somewhat randomly, but it would still avoid some clashes with patches that add different headers at the end or that add the same header using the same method.
Arnd
Re: [RFC PATCH 1/2] Explicitly include linux/major.h where it is needed
In reply to Greg KHHi Greg,
Quoted 13 lines · On Wed, 17 Jun 2020 07:58:43 +0200 Greg KH <[email protected]> wrote:
Quoted 11 lines · Stephen Rothwell
This is in preparation for removing the include of
major.hwhere it is not needed.These files were found using
grep -E -L '[<"](uapi/)?linux/major\.h' $(git grep -l -w -f /tmp/xx)where
/tmp/xxcontains all the symbols defined inmajor.h. There were a couple of files in that list that did not need the include since the references are in comments.
Quoted 6 lines
Quoted 1 line
Signed-off-by Stephen Rothwell <[email protected]>Any reason this had an RFC, but patch 2/2 did not?
They look good to me, I will be glad to take these, but do you still want reviews from others for this? It seems simple enough to me...
I am going to do another round of this patchset splitting out most of the "safe" removals that can be done anytime so other maintainers can take them. Then there will be the left over order dependent changes at the end.
Signature · 2 lines
Cheers, Stephen Rothwell
Greg KH
maintainerRe: [RFC PATCH 1/2] Explicitly include linux/major.h where it is needed
Quoted 20 lines · Stephen Rothwell
Hi Greg,
Quoted 17 lines · On Wed, 17 Jun 2020 07:58:43 +0200 Greg KH <[email protected]> wrote:
Quoted 5 lines · Stephen Rothwell
This is in preparation for removing the include of
major.hwhere it is not needed.These files were found using
Quoted 7 lines
grep -E -L '[<"](uapi/)?linux/major\.h' $(git grep -l -w -f /tmp/xx)where
/tmp/xxcontains all the symbols defined inmajor.h. There were a couple of files in that list that did not need the include since the references are in comments.Signed-off-by Stephen Rothwell <[email protected]>Any reason this had an RFC, but patch 2/2 did not?
Quoted 7 lines
Quoted 2 lines
They look good to me, I will be glad to take these, but do you still want reviews from others for this? It seems simple enough to me...
I am going to do another round of this patchset splitting out most of the "safe" removals that can be done anytime so other maintainers can take them. Then there will be the left over order dependent changes at the end.
Ok, I'll wait for the next round of patches, thanks.
greg k-h
PATCH 2/2 Remove the include of linux/major.h from files that do not need it
In reply to Stephen RothwellThis is fairly safe because major.h does not include any other files. The only real risk is if a symbol defined in major.h is constructed by concatenation in the preprocessor.
The actual change was done using the following command:
sed -i -E '/[<"](uapi\/)?linux\/major\.h/d' \ $(grep -L -w -f /tmp/xx \ $(git grep -E -l '[<"](uapi/)?linux/major\.h'))
Where the file /tmp/xx contians all the symbols defined in major.h
(genhd.h was added by inspection.)
The win here is really just the number of lines to be parsed by the preprocessor. major.h is 180 lines long and was being included by these 101 files unnecessarily. In particular, there are 3 global include files here (tty.h, genhd.h and blkdev.h) that are also included by 354, 68 and 554 other files, repectively.
After this, major.h is only included by 4 global include files (which are in turn included by 297 other files), so its indirect inclusion is hopefully much reduced.
--- arch/alpha/kernel/osf_sys.c | 1 - arch/alpha/kernel/process.c | 1 - arch/arm/mach-iop32x/i2c.c | 1 - arch/arm/mach-omap1/board-h3.c | 1 - arch/arm/mach-pxa/corgi.c | 1 - arch/arm/mach-pxa/lubbock.c | 1 - arch/arm/mach-pxa/tosa.c | 1 - arch/arm/mach-pxa/viper.c | 1 - arch/m68k/atari/atasound.c | 1 - arch/m68k/atari/stram.c | 1 - arch/m68k/bvme6000/config.c | 1 - arch/m68k/mvme147/config.c | 1 - arch/m68k/mvme16x/config.c | 1 - arch/m68k/q40/config.c | 1 - arch/mips/fw/arc/arc_con.c | 1 - arch/powerpc/platforms/83xx/km83xx.c | 1 - arch/powerpc/platforms/83xx/mpc832x_mds.c | 1 - arch/powerpc/platforms/83xx/mpc834x_itx.c | 1 - arch/powerpc/platforms/83xx/mpc834x_mds.c | 1 - arch/powerpc/platforms/83xx/mpc836x_mds.c | 1 - arch/powerpc/platforms/85xx/mpc85xx_cds.c | 1 - arch/powerpc/platforms/85xx/mpc85xx_mds.c | 1 - arch/powerpc/platforms/85xx/sbc8548.c | 1 - arch/powerpc/platforms/chrp/setup.c | 1 - arch/powerpc/platforms/maple/setup.c | 1 - arch/powerpc/platforms/powermac/setup.c | 1 - arch/powerpc/platforms/pseries/setup.c | 1 - arch/powerpc/sysdev/fsl_soc.c | 1 - arch/powerpc/sysdev/tsi108_dev.c | 1 - arch/sparc/kernel/setup_32.c | 1 - arch/sparc/kernel/setup_64.c | 1 - arch/xtensa/platforms/xt2000/setup.c | 1 - arch/xtensa/platforms/xtfpga/setup.c | 1 - block/partitions/efi.h | 1 - drivers/android/binderfs.c | 1 - drivers/block/drbd/drbd_int.h | 1 - drivers/cdrom/cdrom.c | 1 - drivers/char/hpet.c | 1 - drivers/char/mwave/mwavedd.c | 1 - drivers/char/pcmcia/synclink_cs.c | 1 - drivers/char/random.c | 1 - drivers/hid/hidraw.c | 1 - drivers/ide/ide-cs.c | 1 - drivers/ide/ide-disk.c | 1 - drivers/ide/ide-floppy.c | 1 - drivers/ide/ide-io.c | 1 - drivers/ide/ide-iops.c | 1 - drivers/ide/ide.c | 1 - drivers/input/serio/serio_raw.c | 1 - drivers/isdn/capi/capi.c | 1 - drivers/mmc/host/android-goldfish.c | 1 - drivers/mtd/devices/pmc551.c | 1 - drivers/mtd/devices/slram.c | 1 - drivers/mtd/ftl.c | 1 - drivers/mtd/maps/uclinux.c | 1 - drivers/net/hamradio/mkiss.c | 1 - drivers/net/tun.c | 1 - drivers/parport/parport_cs.c | 1 - drivers/pcmcia/cistpl.c | 1 - drivers/pcmcia/cs.c | 1 - drivers/pcmcia/socket_sysfs.c | 1 - drivers/s390/block/dasd.c | 1 - drivers/s390/block/dasd_ioctl.c | 1 - drivers/s390/char/raw3270.c | 1 - drivers/s390/char/tape_class.h | 1 - drivers/s390/scsi/zfcp_def.h | 1 - drivers/sbus/char/display7seg.c | 1 - drivers/scsi/nsp32.c | 1 - drivers/scsi/pcmcia/aha152x_stub.c | 1 - drivers/scsi/pcmcia/nsp_cs.c | 1 - drivers/scsi/pcmcia/qlogic_stub.c | 1 - drivers/tty/hvc/hvc_console.c | 1 - drivers/tty/hvc/hvcs.c | 1 - drivers/tty/hvc/hvsi.c | 1 - drivers/tty/moxa.c | 1 - drivers/tty/mxser.c | 1 - drivers/tty/n_gsm.c | 1 - drivers/tty/n_tty.c | 1 - drivers/tty/rocket.c | 1 - drivers/tty/serial/8250/serial_cs.c | 1 - drivers/tty/serial/icom.c | 1 - drivers/tty/serial/sh-sci.c | 1 - drivers/tty/synclink.c | 1 - drivers/tty/synclink_gt.c | 1 - drivers/tty/synclinkmp.c | 1 - drivers/tty/sysrq.c | 1 - drivers/tty/tty_ioctl.c | 1 - drivers/tty/vt/vt_ioctl.c | 1 - drivers/watchdog/cpwd.c | 1 - drivers/xen/evtchn.c | 1 - fs/block_dev.c | 1 - fs/char_dev.c | 1 - fs/coda/psdev.c | 1 - fs/xfs/xfs_linux.h | 1 - include/linux/blkdev.h | 1 - include/linux/genhd.h | 1 - include/linux/tty.h | 1 - init/do_mounts.h | 1 - kernel/bpf/inode.c | 1 - net/ipv4/ipconfig.c | 1 - tools/hv/hv_vss_daemon.c | 1 - 101 files changed, 101 deletions(-)
arch/alpha/kernel/osf_sys.c +0 -1
@@ -27,7 +27,6 @@#include <linux/utsname.h> #include <linux/time.h> #include <linux/timex.h> -#include <linux/major.h> #include <linux/stat.h> #include <linux/mman.h> #include <linux/shm.h>
arch/alpha/kernel/process.c +0 -1
@@ -23,7 +23,6 @@#include <linux/ptrace.h> #include <linux/user.h> #include <linux/time.h> -#include <linux/major.h> #include <linux/stat.h> #include <linux/vt.h> #include <linux/mman.h>
arch/arm/mach-iop32x/i2c.c +0 -1
@@ -9,7 +9,6 @@#include <linux/mm.h> #include <linux/init.h> -#include <linux/major.h> #include <linux/fs.h> #include <linux/platform_device.h> #include <linux/serial.h>
arch/arm/mach-omap1/board-h3.c +0 -1
@@ -13,7 +13,6 @@#include <linux/gpio.h> #include <linux/types.h> #include <linux/init.h> -#include <linux/major.h> #include <linux/kernel.h> #include <linux/platform_device.h> #include <linux/errno.h>
arch/arm/mach-pxa/corgi.c +0 -1
@@ -12,7 +12,6 @@#include <linux/module.h> /* symbol_get ; symbol_put */ #include <linux/init.h> #include <linux/platform_device.h> -#include <linux/major.h> #include <linux/fs.h> #include <linux/interrupt.h> #include <linux/leds.h>
arch/arm/mach-pxa/lubbock.c +0 -1
@@ -18,7 +18,6 @@#include <linux/io.h> #include <linux/platform_device.h> #include <linux/syscore_ops.h> -#include <linux/major.h> #include <linux/fb.h> #include <linux/interrupt.h> #include <linux/mtd/mtd.h>
arch/arm/mach-pxa/tosa.c +0 -1
@@ -12,7 +12,6 @@#include <linux/kernel.h> #include <linux/init.h> #include <linux/platform_device.h> -#include <linux/major.h> #include <linux/fs.h> #include <linux/interrupt.h> #include <linux/delay.h>
arch/arm/mach-pxa/viper.c +0 -1
@@ -26,7 +26,6 @@#include <linux/init.h> #include <linux/slab.h> #include <linux/interrupt.h> -#include <linux/major.h> #include <linux/module.h> #include <linux/pm.h> #include <linux/sched.h>
arch/m68k/atari/atasound.c +0 -1
@@ -18,7 +18,6 @@#include <linux/sched.h> #include <linux/timer.h> -#include <linux/major.h> #include <linux/fcntl.h> #include <linux/errno.h> #include <linux/mm.h>
arch/m68k/atari/stram.c +0 -1
@@ -12,7 +12,6 @@#include <linux/kernel.h> #include <linux/mm.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/init.h> #include <linux/slab.h> #include <linux/vmalloc.h>
arch/m68k/bvme6000/config.c +0 -1
@@ -22,7 +22,6 @@#include <linux/console.h> #include <linux/linkage.h> #include <linux/init.h> -#include <linux/major.h> #include <linux/genhd.h> #include <linux/rtc.h> #include <linux/interrupt.h>
arch/m68k/mvme147/config.c +0 -1
@@ -21,7 +21,6 @@#include <linux/console.h> #include <linux/linkage.h> #include <linux/init.h> -#include <linux/major.h> #include <linux/genhd.h> #include <linux/rtc.h> #include <linux/interrupt.h>
arch/m68k/mvme16x/config.c +0 -1
@@ -23,7 +23,6 @@#include <linux/console.h> #include <linux/linkage.h> #include <linux/init.h> -#include <linux/major.h> #include <linux/genhd.h> #include <linux/rtc.h> #include <linux/interrupt.h>
arch/m68k/q40/config.c +0 -1
@@ -20,7 +20,6 @@#include <linux/console.h> #include <linux/linkage.h> #include <linux/init.h> -#include <linux/major.h> #include <linux/serial_reg.h> #include <linux/rtc.h> #include <linux/vt_kern.h>
arch/mips/fw/arc/arc_con.c +0 -1
@@ -8,7 +8,6 @@* Copyright (c) 2002 Thiemo Seufer */ #include <linux/tty.h> -#include <linux/major.h> #include <linux/init.h> #include <linux/console.h> #include <linux/fs.h>
arch/powerpc/platforms/83xx/km83xx.c +0 -1
@@ -14,7 +14,6 @@#include <linux/reboot.h> #include <linux/pci.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/console.h> #include <linux/delay.h> #include <linux/seq_file.h>
arch/powerpc/platforms/83xx/mpc832x_mds.c +0 -1
@@ -13,7 +13,6 @@#include <linux/reboot.h> #include <linux/pci.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/console.h> #include <linux/delay.h> #include <linux/seq_file.h>
arch/powerpc/platforms/83xx/mpc834x_itx.c +0 -1
@@ -14,7 +14,6 @@#include <linux/reboot.h> #include <linux/pci.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/console.h> #include <linux/delay.h> #include <linux/seq_file.h>
arch/powerpc/platforms/83xx/mpc834x_mds.c +0 -1
@@ -14,7 +14,6 @@#include <linux/reboot.h> #include <linux/pci.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/console.h> #include <linux/delay.h> #include <linux/seq_file.h>
arch/powerpc/platforms/83xx/mpc836x_mds.c +0 -1
@@ -20,7 +20,6 @@#include <linux/reboot.h> #include <linux/pci.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/console.h> #include <linux/delay.h> #include <linux/seq_file.h>
arch/powerpc/platforms/85xx/mpc85xx_cds.c +0 -1
@@ -14,7 +14,6 @@#include <linux/reboot.h> #include <linux/pci.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/console.h> #include <linux/delay.h> #include <linux/seq_file.h>
arch/powerpc/platforms/85xx/mpc85xx_mds.c +0 -1
@@ -20,7 +20,6 @@#include <linux/reboot.h> #include <linux/pci.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/console.h> #include <linux/delay.h> #include <linux/seq_file.h>
arch/powerpc/platforms/85xx/sbc8548.c +0 -1
@@ -16,7 +16,6 @@#include <linux/reboot.h> #include <linux/pci.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/console.h> #include <linux/delay.h> #include <linux/seq_file.h>
arch/powerpc/platforms/chrp/setup.c +0 -1
@@ -18,7 +18,6 @@#include <linux/ptrace.h> #include <linux/user.h> #include <linux/tty.h> -#include <linux/major.h> #include <linux/interrupt.h> #include <linux/reboot.h> #include <linux/init.h>
arch/powerpc/platforms/maple/setup.c +0 -1
@@ -22,7 +22,6 @@#include <linux/string.h> #include <linux/delay.h> #include <linux/ioport.h> -#include <linux/major.h> #include <linux/initrd.h> #include <linux/vt_kern.h> #include <linux/console.h>
arch/powerpc/platforms/powermac/setup.c +0 -1
@@ -32,7 +32,6 @@#include <linux/string.h> #include <linux/delay.h> #include <linux/ioport.h> -#include <linux/major.h> #include <linux/initrd.h> #include <linux/vt_kern.h> #include <linux/console.h>
arch/powerpc/platforms/pseries/setup.c +0 -1
@@ -21,7 +21,6 @@#include <linux/unistd.h> #include <linux/user.h> #include <linux/tty.h> -#include <linux/major.h> #include <linux/interrupt.h> #include <linux/reboot.h> #include <linux/init.h>
arch/powerpc/sysdev/fsl_soc.c +0 -1
@@ -12,7 +12,6 @@#include <linux/kernel.h> #include <linux/init.h> #include <linux/errno.h> -#include <linux/major.h> #include <linux/delay.h> #include <linux/irq.h> #include <linux/export.h>
arch/powerpc/sysdev/tsi108_dev.c +0 -1
@@ -9,7 +9,6 @@#include <linux/kernel.h> #include <linux/init.h> #include <linux/errno.h> -#include <linux/major.h> #include <linux/delay.h> #include <linux/irq.h> #include <linux/export.h>
arch/sparc/kernel/setup_32.c +0 -1
@@ -23,7 +23,6 @@#include <linux/seq_file.h> #include <linux/syscalls.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/string.h> #include <linux/init.h> #include <linux/interrupt.h>
arch/sparc/kernel/setup_64.c +0 -1
@@ -21,7 +21,6 @@#include <linux/seq_file.h> #include <linux/syscalls.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/string.h> #include <linux/init.h> #include <linux/inet.h>
arch/xtensa/platforms/xt2000/setup.c +0 -1
@@ -16,7 +16,6 @@#include <linux/reboot.h> #include <linux/kdev_t.h> #include <linux/types.h> -#include <linux/major.h> #include <linux/console.h> #include <linux/delay.h> #include <linux/stringify.h>
arch/xtensa/platforms/xtfpga/setup.c +0 -1
@@ -18,7 +18,6 @@#include <linux/reboot.h> #include <linux/kdev_t.h> #include <linux/types.h> -#include <linux/major.h> #include <linux/console.h> #include <linux/delay.h> #include <linux/of.h>
block/partitions/efi.h +0 -1
@@ -15,7 +15,6 @@#include <linux/fs.h> #include <linux/genhd.h> #include <linux/kernel.h> -#include <linux/major.h> #include <linux/string.h> #include <linux/efi.h> #include <linux/compiler.h>
drivers/android/binderfs.c +0 -1
@@ -13,7 +13,6 @@#include <linux/list.h> #include <linux/namei.h> #include <linux/magic.h> -#include <linux/major.h> #include <linux/miscdevice.h> #include <linux/module.h> #include <linux/mutex.h>
drivers/block/drbd/drbd_int.h +0 -1
@@ -24,7 +24,6 @@#include <linux/ratelimit.h> #include <linux/tcp.h> #include <linux/mutex.h> -#include <linux/major.h> #include <linux/blkdev.h> #include <linux/backing-dev.h> #include <linux/genhd.h>
drivers/cdrom/cdrom.c +0 -1
@@ -268,7 +268,6 @@#include <linux/atomic.h> #include <linux/module.h> #include <linux/fs.h> -#include <linux/major.h> #include <linux/types.h> #include <linux/errno.h> #include <linux/kernel.h>
drivers/char/hpet.c +0 -1
@@ -12,7 +12,6 @@#include <linux/kernel.h> #include <linux/types.h> #include <linux/miscdevice.h> -#include <linux/major.h> #include <linux/ioport.h> #include <linux/fcntl.h> #include <linux/init.h>
drivers/char/mwave/mwavedd.c +0 -1
@@ -50,7 +50,6 @@#include <linux/kernel.h> #include <linux/fs.h> #include <linux/init.h> -#include <linux/major.h> #include <linux/miscdevice.h> #include <linux/device.h> #include <linux/serial.h>
drivers/char/pcmcia/synclink_cs.c +0 -1
@@ -45,7 +45,6 @@#include <linux/tty.h> #include <linux/tty_flip.h> #include <linux/serial.h> -#include <linux/major.h> #include <linux/string.h> #include <linux/fcntl.h> #include <linux/ptrace.h>
drivers/char/random.c +0 -1
@@ -312,7 +312,6 @@#include <linux/utsname.h> #include <linux/module.h> #include <linux/kernel.h> -#include <linux/major.h> #include <linux/string.h> #include <linux/fcntl.h> #include <linux/slab.h>
drivers/hid/hidraw.c +0 -1
@@ -21,7 +21,6 @@#include <linux/cdev.h> #include <linux/poll.h> #include <linux/device.h> -#include <linux/major.h> #include <linux/slab.h> #include <linux/hid.h> #include <linux/mutex.h>
drivers/ide/ide-cs.c +0 -1
@@ -38,7 +38,6 @@#include <linux/timer.h> #include <linux/ioport.h> #include <linux/ide.h> -#include <linux/major.h> #include <linux/delay.h> #include <asm/io.h>
drivers/ide/ide-disk.c +0 -1
@@ -21,7 +21,6 @@#include <linux/timer.h> #include <linux/mm.h> #include <linux/interrupt.h> -#include <linux/major.h> #include <linux/errno.h> #include <linux/genhd.h> #include <linux/slab.h>
drivers/ide/ide-floppy.c +0 -1
@@ -24,7 +24,6 @@#include <linux/timer.h> #include <linux/mm.h> #include <linux/interrupt.h> -#include <linux/major.h> #include <linux/errno.h> #include <linux/genhd.h> #include <linux/cdrom.h>
drivers/ide/ide-io.c +0 -1
@@ -31,7 +31,6 @@#include <linux/timer.h> #include <linux/mm.h> #include <linux/interrupt.h> -#include <linux/major.h> #include <linux/errno.h> #include <linux/genhd.h> #include <linux/blkpg.h>
drivers/ide/ide-iops.c +0 -1
@@ -12,7 +12,6 @@#include <linux/timer.h> #include <linux/mm.h> #include <linux/interrupt.h> -#include <linux/major.h> #include <linux/errno.h> #include <linux/genhd.h> #include <linux/blkpg.h>
drivers/ide/ide.c +0 -1
@@ -50,7 +50,6 @@#include <linux/string.h> #include <linux/kernel.h> #include <linux/interrupt.h> -#include <linux/major.h> #include <linux/errno.h> #include <linux/genhd.h> #include <linux/init.h>
drivers/input/serio/serio_raw.c +0 -1
@@ -12,7 +12,6 @@#include <linux/poll.h> #include <linux/module.h> #include <linux/serio.h> -#include <linux/major.h> #include <linux/device.h> #include <linux/miscdevice.h> #include <linux/wait.h>
drivers/isdn/capi/capi.c +0 -1
@@ -13,7 +13,6 @@#include <linux/module.h> #include <linux/errno.h> #include <linux/kernel.h> -#include <linux/major.h> #include <linux/sched.h> #include <linux/slab.h> #include <linux/fcntl.h>
drivers/mmc/host/android-goldfish.c +0 -1
@@ -12,7 +12,6 @@#include <linux/module.h> #include <linux/platform_device.h> -#include <linux/major.h> #include <linux/types.h> #include <linux/pci.h>
drivers/mtd/devices/pmc551.c +0 -1
@@ -85,7 +85,6 @@#include <linux/slab.h> #include <linux/string.h> #include <linux/timer.h> -#include <linux/major.h> #include <linux/fs.h> #include <linux/ioctl.h> #include <asm/io.h>
drivers/mtd/devices/slram.c +0 -1
@@ -38,7 +38,6 @@#include <linux/slab.h> #include <linux/string.h> #include <linux/timer.h> -#include <linux/major.h> #include <linux/fs.h> #include <linux/ioctl.h> #include <linux/init.h>
drivers/mtd/ftl.c +0 -1
@@ -64,7 +64,6 @@#include <linux/slab.h> #include <linux/string.h> #include <linux/timer.h> -#include <linux/major.h> #include <linux/fs.h> #include <linux/init.h> #include <linux/hdreg.h>
drivers/mtd/maps/uclinux.c +0 -1
@@ -16,7 +16,6 @@#include <linux/kernel.h> #include <linux/fs.h> #include <linux/mm.h> -#include <linux/major.h> #include <linux/mtd/mtd.h> #include <linux/mtd/map.h> #include <linux/mtd/partitions.h>
drivers/net/hamradio/mkiss.c +0 -1
@@ -18,7 +18,6 @@#include <linux/tty.h> #include <linux/errno.h> #include <linux/netdevice.h> -#include <linux/major.h> #include <linux/init.h> #include <linux/rtnetlink.h> #include <linux/etherdevice.h>
drivers/net/tun.c +0 -1
@@ -36,7 +36,6 @@#include <linux/errno.h> #include <linux/kernel.h> #include <linux/sched/signal.h> -#include <linux/major.h> #include <linux/slab.h> #include <linux/poll.h> #include <linux/fcntl.h>
drivers/parport/parport_cs.c +0 -1
@@ -42,7 +42,6 @@#include <linux/string.h> #include <linux/timer.h> #include <linux/ioport.h> -#include <linux/major.h> #include <linux/interrupt.h> #include <linux/parport.h>
drivers/pcmcia/cistpl.c +0 -1
@@ -13,7 +13,6 @@#include <linux/moduleparam.h> #include <linux/kernel.h> #include <linux/string.h> -#include <linux/major.h> #include <linux/errno.h> #include <linux/timer.h> #include <linux/slab.h>
drivers/pcmcia/cs.c +0 -1
@@ -14,7 +14,6 @@#include <linux/init.h> #include <linux/kernel.h> #include <linux/string.h> -#include <linux/major.h> #include <linux/errno.h> #include <linux/slab.h> #include <linux/mm.h>
drivers/pcmcia/socket_sysfs.c +0 -1
@@ -10,7 +10,6 @@#include <linux/init.h> #include <linux/kernel.h> #include <linux/string.h> -#include <linux/major.h> #include <linux/errno.h> #include <linux/mm.h> #include <linux/interrupt.h>
drivers/s390/block/dasd.c +0 -1
@@ -15,7 +15,6 @@#include <linux/init.h> #include <linux/interrupt.h> #include <linux/ctype.h> -#include <linux/major.h> #include <linux/slab.h> #include <linux/hdreg.h> #include <linux/async.h>
drivers/s390/block/dasd_ioctl.c +0 -1
@@ -14,7 +14,6 @@#include <linux/interrupt.h> #include <linux/compat.h> -#include <linux/major.h> #include <linux/fs.h> #include <linux/blkpg.h> #include <linux/slab.h>
drivers/s390/char/raw3270.c +0 -1
@@ -24,7 +24,6 @@#include "raw3270.h" -#include <linux/major.h> #include <linux/kdev_t.h> #include <linux/device.h> #include <linux/mutex.h>
drivers/s390/char/tape_class.h +0 -1
@@ -13,7 +13,6 @@#include <linux/init.h> #include <linux/module.h> #include <linux/fs.h> -#include <linux/major.h> #include <linux/cdev.h> #include <linux/device.h>
drivers/s390/scsi/zfcp_def.h +0 -1
@@ -14,7 +14,6 @@#include <linux/init.h> #include <linux/moduleparam.h> -#include <linux/major.h> #include <linux/blkdev.h> #include <linux/delay.h> #include <linux/timer.h>
drivers/sbus/char/display7seg.c +0 -1
@@ -10,7 +10,6 @@#include <linux/module.h> #include <linux/fs.h> #include <linux/errno.h> -#include <linux/major.h> #include <linux/miscdevice.h> #include <linux/ioport.h> /* request_region */ #include <linux/slab.h>
drivers/scsi/nsp32.c +0 -1
@@ -19,7 +19,6 @@#include <linux/string.h> #include <linux/timer.h> #include <linux/ioport.h> -#include <linux/major.h> #include <linux/blkdev.h> #include <linux/interrupt.h> #include <linux/pci.h>
drivers/scsi/pcmcia/aha152x_stub.c +0 -1
@@ -41,7 +41,6 @@#include <linux/string.h> #include <linux/ioport.h> #include <scsi/scsi.h> -#include <linux/major.h> #include <linux/blkdev.h> #include <scsi/scsi_ioctl.h>
drivers/scsi/pcmcia/nsp_cs.c +0 -1
@@ -34,7 +34,6 @@#include <linux/ioport.h> #include <linux/delay.h> #include <linux/interrupt.h> -#include <linux/major.h> #include <linux/blkdev.h> #include <linux/stat.h>
drivers/scsi/pcmcia/qlogic_stub.c +0 -1
@@ -39,7 +39,6 @@#include <linux/ioport.h> #include <asm/io.h> #include <scsi/scsi.h> -#include <linux/major.h> #include <linux/blkdev.h> #include <scsi/scsi_ioctl.h> #include <linux/interrupt.h>
drivers/tty/hvc/hvc_console.c +0 -1
@@ -16,7 +16,6 @@#include <linux/kernel.h> #include <linux/kthread.h> #include <linux/list.h> -#include <linux/major.h> #include <linux/atomic.h> #include <linux/sysrq.h> #include <linux/tty.h>
drivers/tty/hvc/hvcs.c +0 -1
@@ -57,7 +57,6 @@#include <linux/kref.h> #include <linux/kthread.h> #include <linux/list.h> -#include <linux/major.h> #include <linux/module.h> #include <linux/moduleparam.h> #include <linux/sched.h>
drivers/tty/hvc/hvsi.c +0 -1
@@ -24,7 +24,6 @@#include <linux/init.h> #include <linux/interrupt.h> #include <linux/module.h> -#include <linux/major.h> #include <linux/kernel.h> #include <linux/spinlock.h> #include <linux/sysrq.h>
drivers/tty/moxa.c +0 -1
@@ -29,7 +29,6 @@#include <linux/interrupt.h> #include <linux/tty.h> #include <linux/tty_flip.h> -#include <linux/major.h> #include <linux/string.h> #include <linux/fcntl.h> #include <linux/ptrace.h>
drivers/tty/mxser.c +0 -1
@@ -25,7 +25,6 @@#include <linux/tty_flip.h> #include <linux/serial.h> #include <linux/serial_reg.h> -#include <linux/major.h> #include <linux/string.h> #include <linux/fcntl.h> #include <linux/ptrace.h>
drivers/tty/n_gsm.c +0 -1
@@ -23,7 +23,6 @@*/ #include <linux/types.h> -#include <linux/major.h> #include <linux/errno.h> #include <linux/signal.h> #include <linux/fcntl.h>
drivers/tty/n_tty.c +0 -1
@@ -29,7 +29,6 @@*/ #include <linux/types.h> -#include <linux/major.h> #include <linux/errno.h> #include <linux/signal.h> #include <linux/fcntl.h>
drivers/tty/rocket.c +0 -1
@@ -48,7 +48,6 @@#include <linux/module.h> #include <linux/errno.h> -#include <linux/major.h> #include <linux/kernel.h> #include <linux/signal.h> #include <linux/slab.h>
drivers/tty/serial/8250/serial_cs.c +0 -1
@@ -41,7 +41,6 @@#include <linux/timer.h> #include <linux/serial_core.h> #include <linux/delay.h> -#include <linux/major.h> #include <asm/io.h> #include <pcmcia/cistpl.h>
drivers/tty/serial/icom.c +0 -1
@@ -20,7 +20,6 @@#include <linux/tty_flip.h> #include <linux/serial.h> #include <linux/serial_reg.h> -#include <linux/major.h> #include <linux/string.h> #include <linux/fcntl.h> #include <linux/ptrace.h>
drivers/tty/serial/sh-sci.c +0 -1
@@ -30,7 +30,6 @@#include <linux/interrupt.h> #include <linux/ioport.h> #include <linux/ktime.h> -#include <linux/major.h> #include <linux/module.h> #include <linux/mm.h> #include <linux/of.h>
drivers/tty/synclink.c +0 -1
@@ -70,7 +70,6 @@#include <linux/tty.h> #include <linux/tty_flip.h> #include <linux/serial.h> -#include <linux/major.h> #include <linux/string.h> #include <linux/fcntl.h> #include <linux/ptrace.h>
drivers/tty/synclink_gt.c +0 -1
@@ -53,7 +53,6 @@#include <linux/tty.h> #include <linux/tty_flip.h> #include <linux/serial.h> -#include <linux/major.h> #include <linux/string.h> #include <linux/fcntl.h> #include <linux/ptrace.h>
drivers/tty/synclinkmp.c +0 -1
@@ -44,7 +44,6 @@#include <linux/tty.h> #include <linux/tty_flip.h> #include <linux/serial.h> -#include <linux/major.h> #include <linux/string.h> #include <linux/fcntl.h> #include <linux/ptrace.h>
drivers/tty/sysrq.c +0 -1
@@ -24,7 +24,6 @@#include <linux/fs.h> #include <linux/mount.h> #include <linux/kdev_t.h> -#include <linux/major.h> #include <linux/reboot.h> #include <linux/sysrq.h> #include <linux/kbd_kern.h>
drivers/tty/tty_ioctl.c +0 -1
@@ -12,7 +12,6 @@#include <linux/errno.h> #include <linux/sched/signal.h> #include <linux/kernel.h> -#include <linux/major.h> #include <linux/tty.h> #include <linux/fcntl.h> #include <linux/string.h>
drivers/tty/vt/vt_ioctl.c +0 -1
@@ -21,7 +21,6 @@#include <linux/vt.h> #include <linux/string.h> #include <linux/slab.h> -#include <linux/major.h> #include <linux/fs.h> #include <linux/console.h> #include <linux/consolemap.h>
drivers/watchdog/cpwd.c +0 -1
@@ -21,7 +21,6 @@#include <linux/module.h> #include <linux/fs.h> #include <linux/errno.h> -#include <linux/major.h> #include <linux/miscdevice.h> #include <linux/interrupt.h> #include <linux/ioport.h>
drivers/xen/evtchn.c +0 -1
@@ -41,7 +41,6 @@#include <linux/errno.h> #include <linux/fs.h> #include <linux/miscdevice.h> -#include <linux/major.h> #include <linux/proc_fs.h> #include <linux/stat.h> #include <linux/poll.h>
fs/block_dev.c +0 -1
@@ -11,7 +11,6 @@#include <linux/fcntl.h> #include <linux/slab.h> #include <linux/kmod.h> -#include <linux/major.h> #include <linux/device_cgroup.h> #include <linux/highmem.h> #include <linux/blkdev.h>
fs/char_dev.c +0 -1
@@ -11,7 +11,6 @@#include <linux/slab.h> #include <linux/string.h> -#include <linux/major.h> #include <linux/errno.h> #include <linux/module.h> #include <linux/seq_file.h>
fs/coda/psdev.c +0 -1
@@ -16,7 +16,6 @@#include <linux/module.h> #include <linux/errno.h> #include <linux/kernel.h> -#include <linux/major.h> #include <linux/time.h> #include <linux/sched/signal.h> #include <linux/slab.h>
fs/xfs/xfs_linux.h +0 -1
@@ -38,7 +38,6 @@ typedef __u32 xfs_nlink_t;#include <linux/errno.h> #include <linux/sched/signal.h> #include <linux/bitops.h> -#include <linux/major.h> #include <linux/pagemap.h> #include <linux/vfs.h> #include <linux/seq_file.h>
include/linux/blkdev.h +0 -1
@@ -7,7 +7,6 @@#ifdef CONFIG_BLOCK -#include <linux/major.h> #include <linux/genhd.h> #include <linux/list.h> #include <linux/llist.h>
include/linux/genhd.h +0 -1
@@ -32,7 +32,6 @@ extern struct class block_class;#define DISK_MAX_PARTS 256#define DISK_NAME_LEN 32 -#include <linux/major.h> #include <linux/device.h> #include <linux/smp.h> #include <linux/string.h>
include/linux/tty.h +0 -1
@@ -3,7 +3,6 @@#define _LINUX_TTY_H#include <linux/fs.h> -#include <linux/major.h> #include <linux/termios.h> #include <linux/workqueue.h> #include <linux/tty_driver.h>
init/do_mounts.h +0 -1
@@ -6,7 +6,6 @@#include <linux/unistd.h> #include <linux/slab.h> #include <linux/mount.h> -#include <linux/major.h> #include <linux/root_dev.h> void change_floppy (char *fmt, ...);
kernel/bpf/inode.c +0 -1
@@ -10,7 +10,6 @@#include <linux/init.h> #include <linux/magic.h> -#include <linux/major.h> #include <linux/mount.h> #include <linux/namei.h> #include <linux/fs.h>
net/ipv4/ipconfig.c +0 -1
@@ -53,7 +53,6 @@#include <linux/udp.h> #include <linux/proc_fs.h> #include <linux/seq_file.h> -#include <linux/major.h> #include <linux/root_dev.h> #include <linux/delay.h> #include <linux/nfs_fs.h>
tools/hv/hv_vss_daemon.c +0 -1
@@ -21,7 +21,6 @@#include <ctype.h> #include <errno.h> #include <linux/fs.h> -#include <linux/major.h> #include <linux/hyperv.h> #include <syslog.h> #include <getopt.h>
Signature · 1 line
2.27.0