Linux Kernel
3.7.1
|
#include <linux/stddef.h>
#include <linux/kernel.h>
#include <linux/sched.h>
#include <linux/timer.h>
#include <linux/delay.h>
#include <linux/fd.h>
#include <linux/ioctl.h>
#include <linux/blkdev.h>
#include <linux/interrupt.h>
#include <linux/mutex.h>
#include <linux/module.h>
#include <linux/spinlock.h>
#include <asm/io.h>
#include <asm/dbdma.h>
#include <asm/prom.h>
#include <asm/uaccess.h>
#include <asm/mediabay.h>
#include <asm/machdep.h>
#include <asm/pmac_feature.h>
Go to the source code of this file.
Data Structures | |
struct | swim3 |
struct | floppy_state |
Macros | |
#define | MAX_FLOPPIES 2 |
#define | REG(x) unsigned char x; char x ## _pad[15]; |
#define | control_bic control |
#define | control_bis status |
#define | CA_MASK 7 |
#define | LSTRB 8 |
#define | DO_SEEK 0x80 |
#define | FORMAT 0x40 |
#define | SELECT 0x20 |
#define | WRITE_SECTORS 0x10 |
#define | DO_ACTION 0x08 |
#define | DRIVE2_ENABLE 0x04 |
#define | DRIVE_ENABLE 0x02 |
#define | INTR_ENABLE 0x01 |
#define | FIFO_1BYTE 0x80 |
#define | FIFO_2BYTE 0x40 |
#define | ERROR 0x20 |
#define | DATA 0x08 |
#define | RDDATA 0x04 |
#define | INTR_PENDING 0x02 |
#define | MARK_BYTE 0x01 |
#define | ERROR_INTR 0x20 |
#define | DATA_CHANGED 0x10 |
#define | TRANSFER_DONE 0x08 |
#define | SEEN_SECTOR 0x04 |
#define | SEEK_DONE 0x02 |
#define | TIMER_DONE 0x01 |
#define | ERR_DATA_CRC 0x80 |
#define | ERR_ADDR_CRC 0x40 |
#define | ERR_OVERRUN 0x04 |
#define | ERR_UNDERRUN 0x01 |
#define | S_SW_RESET 0x80 |
#define | S_GCR_WRITE 0x40 |
#define | S_IBM_DRIVE 0x20 |
#define | S_TEST_MODE 0x10 |
#define | S_FCLK_DIV2 0x08 |
#define | S_GCR 0x04 |
#define | S_COPY_PROT 0x02 |
#define | S_INV_WDATA 0x01 |
#define | SEEK_POSITIVE 0 |
#define | SEEK_NEGATIVE 4 |
#define | STEP 1 |
#define | MOTOR_ON 2 |
#define | MOTOR_OFF 6 |
#define | INDEX 3 |
#define | EJECT 7 |
#define | SETMFM 9 |
#define | SETGCR 13 |
#define | STEP_DIR 0 |
#define | STEPPING 1 |
#define | MOTOR_ON 2 |
#define | RELAX 3 /* also eject in progress */ |
#define | READ_DATA_0 4 |
#define | TWOMEG_DRIVE 5 |
#define | SINGLE_SIDED 6 /* drive or diskette is 4MB type? */ |
#define | DRIVE_PRESENT 7 |
#define | DISK_IN 8 |
#define | WRITE_PROT 9 |
#define | TRACK_ZERO 10 |
#define | TACHO 11 |
#define | READ_DATA_1 12 |
#define | MFM_MODE 13 |
#define | SEEK_COMPLETE 14 |
#define | ONEMEG_MEDIA 15 |
#define | DATA_ESCAPE 0x99 |
#define | GCR_SYNC_EXC 0x3f |
#define | GCR_SYNC_CONV 0x80 |
#define | GCR_FIRST_MARK 0xd5 |
#define | GCR_SECOND_MARK 0xaa |
#define | GCR_ADDR_MARK "\xd5\xaa\x00" |
#define | GCR_DATA_MARK "\xd5\xaa\x0b" |
#define | GCR_SLIP_BYTE "\x27\xaa" |
#define | GCR_SELF_SYNC "\x3f\xbf\x1e\x34\x3c\x3f" |
#define | DATA_99 "\x99\x99" |
#define | MFM_ADDR_MARK "\x99\xa1\x99\xa1\x99\xa1\x99\xfe" |
#define | MFM_INDEX_MARK "\x99\xc2\x99\xc2\x99\xc2\x99\xfc" |
#define | MFM_GAP_LEN 12 |
#define | swim3_err(fmt, arg...) dev_err(&fs->mdev->ofdev.dev, "[fd%d] " fmt, fs->index, arg) |
#define | swim3_warn(fmt, arg...) dev_warn(&fs->mdev->ofdev.dev, "[fd%d] " fmt, fs->index, arg) |
#define | swim3_info(fmt, arg...) dev_info(&fs->mdev->ofdev.dev, "[fd%d] " fmt, fs->index, arg) |
#define | swim3_dbg(fmt, arg...) do { } while(0) |
Enumerations | |
enum | swim_state { idle, locating, seeking, settling, do_transfer, jogging, available, revalidating, ejecting } |
Functions | |
int | swim3_init (void) |
enum swim_state |