Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
0baab86b
Commit
0baab86b
authored
Jun 02, 2005
by
Edward Falk
Committed by
Jeff Garzik
Jun 02, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
libata: update inline source docs
parent
92bab26b
Changes
2
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
334 additions
and
7 deletions
+334
-7
drivers/scsi/libata-core.c
drivers/scsi/libata-core.c
+276
-7
include/linux/libata.h
include/linux/libata.h
+58
-0
No files found.
drivers/scsi/libata-core.c
View file @
0baab86b
This diff is collapsed.
Click to expand it.
include/linux/libata.h
View file @
0baab86b
...
...
@@ -466,12 +466,34 @@ static inline u8 ata_chk_status(struct ata_port *ap)
return
ap
->
ops
->
check_status
(
ap
);
}
/**
* ata_pause - Flush writes and pause 400 nanoseconds.
* @ap: Port to wait for.
*
* LOCKING:
* Inherited from caller.
*/
static
inline
void
ata_pause
(
struct
ata_port
*
ap
)
{
ata_altstatus
(
ap
);
ndelay
(
400
);
}
/**
* ata_busy_wait - Wait for a port status register
* @ap: Port to wait for.
*
* Waits up to max*10 microseconds for the selected bits in the port's
* status register to be cleared.
* Returns final value of status register.
*
* LOCKING:
* Inherited from caller.
*/
static
inline
u8
ata_busy_wait
(
struct
ata_port
*
ap
,
unsigned
int
bits
,
unsigned
int
max
)
{
...
...
@@ -486,6 +508,18 @@ static inline u8 ata_busy_wait(struct ata_port *ap, unsigned int bits,
return
status
;
}
/**
* ata_wait_idle - Wait for a port to be idle.
* @ap: Port to wait for.
*
* Waits up to 10ms for port's BUSY and DRQ signals to clear.
* Returns final value of status register.
*
* LOCKING:
* Inherited from caller.
*/
static
inline
u8
ata_wait_idle
(
struct
ata_port
*
ap
)
{
u8
status
=
ata_busy_wait
(
ap
,
ATA_BUSY
|
ATA_DRQ
,
1000
);
...
...
@@ -524,6 +558,18 @@ static inline void ata_tf_init(struct ata_port *ap, struct ata_taskfile *tf, uns
tf
->
device
=
ATA_DEVICE_OBS
|
ATA_DEV1
;
}
/**
* ata_irq_on - Enable interrupts on a port.
* @ap: Port on which interrupts are enabled.
*
* Enable interrupts on a legacy IDE device using MMIO or PIO,
* wait for idle, clear any pending interrupts.
*
* LOCKING:
* Inherited from caller.
*/
static
inline
u8
ata_irq_on
(
struct
ata_port
*
ap
)
{
struct
ata_ioports
*
ioaddr
=
&
ap
->
ioaddr
;
...
...
@@ -543,6 +589,18 @@ static inline u8 ata_irq_on(struct ata_port *ap)
return
tmp
;
}
/**
* ata_irq_ack - Acknowledge a device interrupt.
* @ap: Port on which interrupts are enabled.
*
* Wait up to 10 ms for legacy IDE device to become idle (BUSY
* or BUSY+DRQ clear). Obtain dma status and port status from
* device. Clear the interrupt. Return port status.
*
* LOCKING:
*/
static
inline
u8
ata_irq_ack
(
struct
ata_port
*
ap
,
unsigned
int
chk_drq
)
{
unsigned
int
bits
=
chk_drq
?
ATA_BUSY
|
ATA_DRQ
:
ATA_BUSY
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment