ata.h (249115) | ata.h (249895) |
---|---|
1/*- 2 * Copyright (c) 2000 - 2008 S��ren Schmidt <sos@FreeBSD.org> 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 9 unchanged lines hidden (view full) --- 18 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 19 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 20 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25 * | 1/*- 2 * Copyright (c) 2000 - 2008 S��ren Schmidt <sos@FreeBSD.org> 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 9 unchanged lines hidden (view full) --- 18 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 19 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 20 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25 * |
26 * $FreeBSD: head/sys/sys/ata.h 249115 2013-04-04 23:19:51Z smh $ | 26 * $FreeBSD: head/sys/sys/ata.h 249895 2013-04-25 14:11:38Z smh $ |
27 */ 28 29#ifndef _SYS_ATA_H_ 30#define _SYS_ATA_H_ 31 32#include <sys/ioccom.h> 33 34/* ATA/ATAPI device parameters */ --- 243 unchanged lines hidden (view full) --- 278 * bit 4 1 = Slave Drive, 0 = Master Drive 279 * bit 3-0 In LBA mode, 27-24 of address. In CHS mode, head number 280*/ 281 282#define ATA_DEV_MASTER 0x00 283#define ATA_DEV_SLAVE 0x10 284#define ATA_DEV_LBA 0x40 285 | 27 */ 28 29#ifndef _SYS_ATA_H_ 30#define _SYS_ATA_H_ 31 32#include <sys/ioccom.h> 33 34/* ATA/ATAPI device parameters */ --- 243 unchanged lines hidden (view full) --- 278 * bit 4 1 = Slave Drive, 0 = Master Drive 279 * bit 3-0 In LBA mode, 27-24 of address. In CHS mode, head number 280*/ 281 282#define ATA_DEV_MASTER 0x00 283#define ATA_DEV_SLAVE 0x10 284#define ATA_DEV_LBA 0x40 285 |
286/* ATA limits */ 287#define ATA_MAX_28BIT_LBA 268435455UL |
|
286 | 288 |
289/* ATA Status Register */ 290#define ATA_STATUS_ERROR 0x01 291#define ATA_STATUS_DEVICE_FAULT 0x20 292 293/* ATA Error Register */ 294#define ATA_ERROR_ABORT 0x04 295#define ATA_ERROR_ID_NOT_FOUND 0x10 296 297/* ATA HPA Features */ 298#define ATA_HPA_FEAT_MAX_ADDR 0x00 299#define ATA_HPA_FEAT_SET_PWD 0x01 300#define ATA_HPA_FEAT_LOCK 0x02 301#define ATA_HPA_FEAT_UNLOCK 0x03 302#define ATA_HPA_FEAT_FREEZE 0x04 303 |
|
287/* ATA transfer modes */ 288#define ATA_MODE_MASK 0x0f 289#define ATA_DMA_MASK 0xf0 290#define ATA_PIO 0x00 291#define ATA_PIO0 0x08 292#define ATA_PIO1 0x09 293#define ATA_PIO2 0x0a 294#define ATA_PIO3 0x0b --- 309 unchanged lines hidden --- | 304/* ATA transfer modes */ 305#define ATA_MODE_MASK 0x0f 306#define ATA_DMA_MASK 0xf0 307#define ATA_PIO 0x00 308#define ATA_PIO0 0x08 309#define ATA_PIO1 0x09 310#define ATA_PIO2 0x0a 311#define ATA_PIO3 0x0b --- 309 unchanged lines hidden --- |