Linux Kernel
3.7.1
|
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/init.h>
#include <linux/blkdev.h>
#include <scsi/scsi_host.h>
#include <linux/ata.h>
#include <linux/libata.h>
#include <linux/platform_device.h>
#include <linux/ata_platform.h>
Go to the source code of this file.
Macros | |
#define | DRV_NAME "pata_platform" |
#define | DRV_VERSION "1.2" |
Functions | |
int __devinit | __pata_platform_probe (struct device *dev, struct resource *io_res, struct resource *ctl_res, struct resource *irq_res, unsigned int ioport_shift, int __pio_mask) |
EXPORT_SYMBOL_GPL (__pata_platform_probe) | |
int | __pata_platform_remove (struct device *dev) |
EXPORT_SYMBOL_GPL (__pata_platform_remove) | |
module_platform_driver (pata_platform_driver) | |
module_param (pio_mask, int, 0) | |
MODULE_AUTHOR ("Paul Mundt") | |
MODULE_DESCRIPTION ("low-level driver for platform device ATA") | |
MODULE_LICENSE ("GPL") | |
MODULE_VERSION (DRV_VERSION) | |
MODULE_ALIAS ("platform:"DRV_NAME) | |
#define DRV_NAME "pata_platform" |
Definition at line 24 of file pata_platform.c.
#define DRV_VERSION "1.2" |
Definition at line 25 of file pata_platform.c.
int __devinit __pata_platform_probe | ( | struct device * | dev, |
struct resource * | io_res, | ||
struct resource * | ctl_res, | ||
struct resource * | irq_res, | ||
unsigned int | ioport_shift, | ||
int | __pio_mask | ||
) |
__pata_platform_probe - attach a platform interface : device : Resource representing I/O base : Resource representing CTL base : Resource representing IRQ and its flags : I/O port shift : PIO mask
Register a platform bus IDE interface. Such interfaces are PIO and we assume do not support IRQ sharing.
Platform devices are expected to contain at least 2 resources per port:
- I/O Base (IORESOURCE_IO or IORESOURCE_MEM) - CTL Base (IORESOURCE_IO or IORESOURCE_MEM)
and optionally:
- IRQ (IORESOURCE_IRQ)
If the base resources are both mem types, the ioremap() is handled here. For IORESOURCE_IO, it's assumed that there's no remapping necessary.
If no IRQ resource is present, PIO polling mode is used instead.
Definition at line 101 of file pata_platform.c.
__pata_platform_remove - unplug a platform interface : device
A platform bus ATA device has been unplugged. Perform the needed cleanup. Also called on module unload for any active devices.
Definition at line 188 of file pata_platform.c.
EXPORT_SYMBOL_GPL | ( | __pata_platform_probe | ) |
EXPORT_SYMBOL_GPL | ( | __pata_platform_remove | ) |
MODULE_ALIAS | ( | "platform:" | DRV_NAME | ) |
MODULE_AUTHOR | ( | "Paul Mundt" | ) |
MODULE_LICENSE | ( | "GPL" | ) |
module_param | ( | pio_mask | , |
int | , | ||
0 | |||
) |
module_platform_driver | ( | pata_platform_driver | ) |
MODULE_VERSION | ( | DRV_VERSION | ) |