PCI: hotplug: Drop superfluous #include directives
authorLukas Wunner <lukas@wunner.de>
Mon, 14 Apr 2025 14:25:21 +0000 (16:25 +0200)
committerBjorn Helgaas <bhelgaas@google.com>
Thu, 17 Apr 2025 19:36:29 +0000 (14:36 -0500)
In February 2003, historic commit

  https://git.kernel.org/tglx/history/c/280c1c9a0ea4
  ("[PATCH] PCI Hotplug: Replace pcihpfs with sysfs.")

removed all invocations of __get_free_page() and free_page() from the PCI
hotplug core without also removing the #include <linux/pagemap.h>
directive.

It removed all invocations of kern_mount(), mntget() and mntput()
without also removing the #include <linux/mount.h> directive.

It removed all invocations of lookup_hash()
without also removing the #include <linux/namei.h> directive.

It removed all invocations of copy_to_user() and copy_from_user()
without also removing the #include <linux/uaccess.h> directive.

These #include directives are still unnecessary today, so drop them.

Signed-off-by: Lukas Wunner <lukas@wunner.de>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Link: https://patch.msgid.link/c19e25bf2cefecc14e0822c6a9bb3a7f546258bc.1744640331.git.lukas@wunner.de
drivers/pci/hotplug/pci_hotplug_core.c

index d7fc3bc039643c1c37940c4ed071c14bf0cfa6d4..fadcf98a8a660061e6e48f9ec3a1819f2d9ccaf3 100644 (file)
 #include <linux/types.h>
 #include <linux/kobject.h>
 #include <linux/sysfs.h>
-#include <linux/pagemap.h>
 #include <linux/init.h>
-#include <linux/mount.h>
-#include <linux/namei.h>
 #include <linux/pci.h>
 #include <linux/pci_hotplug.h>
-#include <linux/uaccess.h>
 #include "../pci.h"
 #include "cpci_hotplug.h"