Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions | Variables
rpaphp_core.c File Reference
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/pci.h>
#include <linux/pci_hotplug.h>
#include <linux/smp.h>
#include <linux/init.h>
#include <linux/vmalloc.h>
#include <asm/eeh.h>
#include <asm/rtas.h>
#include <asm/pci-bridge.h>
#include "../pci.h"
#include "rpaphp.h"

Go to the source code of this file.


#define DRIVER_VERSION   "0.1"
#define DRIVER_AUTHOR   "Linda Xie <[email protected]>"
#define DRIVER_DESC   "RPA HOT Plug PCI Controller Driver"
#define MAX_LOC_CODE   128


 LIST_HEAD (rpaphp_slot_head)
 module_param_named (debug, rpaphp_debug, bool, 0644)
int rpaphp_get_drc_props (struct device_node *dn, int *drc_index, char **drc_name, char **drc_type, int *drc_power_domain)
int rpaphp_add_slot (struct device_node *dn)
 module_init (rpaphp_init)
 module_exit (rpaphp_exit)
 EXPORT_SYMBOL_GPL (rpaphp_add_slot)
 EXPORT_SYMBOL_GPL (rpaphp_slot_head)
 EXPORT_SYMBOL_GPL (rpaphp_get_drc_props)


bool rpaphp_debug
struct hotplug_slot_ops rpaphp_hotplug_slot_ops

Macro Definition Documentation

#define DRIVER_AUTHOR   "Linda Xie <[email protected]>"

Definition at line 44 of file rpaphp_core.c.

#define DRIVER_DESC   "RPA HOT Plug PCI Controller Driver"

Definition at line 45 of file rpaphp_core.c.

#define DRIVER_VERSION   "0.1"

Definition at line 43 of file rpaphp_core.c.

#define MAX_LOC_CODE   128

Definition at line 47 of file rpaphp_core.c.

Function Documentation

EXPORT_SYMBOL_GPL ( rpaphp_add_slot  )
EXPORT_SYMBOL_GPL ( rpaphp_slot_head  )
EXPORT_SYMBOL_GPL ( rpaphp_get_drc_props  )
LIST_HEAD ( rpaphp_slot_head  )
module_exit ( rpaphp_exit  )
module_init ( rpaphp_init  )
module_param_named ( debug  ,
rpaphp_debug  ,
bool  ,
int rpaphp_add_slot ( struct device_node dn)

rpaphp_add_slot – declare a hotplug slot to the hotplug subsystem. : device node of slot

This subroutine will register a hotplugable slot with the PCI hotplug infrastructure. This routine is typically called during boot time, if the hotplug slots are present at boot time, or is called later, by the dlpar add code, if the slot is being dynamically added during runtime.

If the device node points at an embedded (built-in) slot, this routine will just return without doing anything, since embedded slots cannot be hotplugged.

To remove a slot, it suffices to call rpaphp_deregister_slot().

Definition at line 304 of file rpaphp_core.c.

int rpaphp_get_drc_props ( struct device_node dn,
int drc_index,
char **  drc_name,
char **  drc_type,
int drc_power_domain 

Definition at line 202 of file rpaphp_core.c.

Variable Documentation

bool rpaphp_debug

Definition at line 40 of file rpaphp_core.c.

struct hotplug_slot_ops rpaphp_hotplug_slot_ops
Initial value:
= {
.enable_slot = enable_slot,
.disable_slot = disable_slot,
.set_attention_status = set_attention_status,
.get_power_status = get_power_status,
.get_attention_status = get_attention_status,
.get_adapter_status = get_adapter_status,

Definition at line 428 of file rpaphp_core.c.