#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/kernel.h>
#include <linux/types.h>
#include <linux/slab.h>
#include <linux/pci.h>
#include "shpchp.h"
bool shpchp_debug;
bool shpchp_poll_mode;
int shpchp_poll_time;
#define DRIVER_VERSION …
#define DRIVER_AUTHOR …
#define DRIVER_DESC …
MODULE_AUTHOR(…);
MODULE_DESCRIPTION(…);
module_param(shpchp_debug, bool, 0644);
module_param(shpchp_poll_mode, bool, 0644);
module_param(shpchp_poll_time, int, 0644);
MODULE_PARM_DESC(…) …;
MODULE_PARM_DESC(…) …;
MODULE_PARM_DESC(…) …;
#define SHPC_MODULE_NAME …
static int set_attention_status(struct hotplug_slot *slot, u8 value);
static int enable_slot(struct hotplug_slot *slot);
static int disable_slot(struct hotplug_slot *slot);
static int get_power_status(struct hotplug_slot *slot, u8 *value);
static int get_attention_status(struct hotplug_slot *slot, u8 *value);
static int get_latch_status(struct hotplug_slot *slot, u8 *value);
static int get_adapter_status(struct hotplug_slot *slot, u8 *value);
static const struct hotplug_slot_ops shpchp_hotplug_slot_ops = …;
static int init_slots(struct controller *ctrl)
{ … }
void cleanup_slots(struct controller *ctrl)
{ … }
static int set_attention_status(struct hotplug_slot *hotplug_slot, u8 status)
{ … }
static int enable_slot(struct hotplug_slot *hotplug_slot)
{ … }
static int disable_slot(struct hotplug_slot *hotplug_slot)
{ … }
static int get_power_status(struct hotplug_slot *hotplug_slot, u8 *value)
{ … }
static int get_attention_status(struct hotplug_slot *hotplug_slot, u8 *value)
{ … }
static int get_latch_status(struct hotplug_slot *hotplug_slot, u8 *value)
{ … }
static int get_adapter_status(struct hotplug_slot *hotplug_slot, u8 *value)
{ … }
static bool shpc_capable(struct pci_dev *bridge)
{ … }
static int shpc_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
{ … }
static void shpc_remove(struct pci_dev *dev)
{ … }
static const struct pci_device_id shpcd_pci_tbl[] = …;
MODULE_DEVICE_TABLE(pci, shpcd_pci_tbl);
static struct pci_driver shpc_driver = …;
static int __init shpcd_init(void)
{ … }
static void __exit shpcd_cleanup(void)
{ … }
module_init(…) …;
module_exit(shpcd_cleanup);