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
Kirill Smelkov
linux
Commits
fff42598
Commit
fff42598
authored
Jun 16, 2004
by
Jeff Garzik
Browse files
Options
Browse Files
Download
Plain Diff
Merge pobox.com:/spare/repo/linux-2.6.7
into pobox.com:/spare/repo/libata-2.6
parents
adf791bd
2b13abe5
Changes
10
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
165 additions
and
284 deletions
+165
-284
drivers/scsi/ata_piix.c
drivers/scsi/ata_piix.c
+2
-2
drivers/scsi/libata-core.c
drivers/scsi/libata-core.c
+106
-253
drivers/scsi/sata_promise.c
drivers/scsi/sata_promise.c
+4
-4
drivers/scsi/sata_sil.c
drivers/scsi/sata_sil.c
+1
-1
drivers/scsi/sata_sis.c
drivers/scsi/sata_sis.c
+1
-1
drivers/scsi/sata_svw.c
drivers/scsi/sata_svw.c
+1
-1
drivers/scsi/sata_sx4.c
drivers/scsi/sata_sx4.c
+6
-3
drivers/scsi/sata_via.c
drivers/scsi/sata_via.c
+1
-1
drivers/scsi/sata_vsc.c
drivers/scsi/sata_vsc.c
+1
-1
include/linux/libata.h
include/linux/libata.h
+42
-17
No files found.
drivers/scsi/ata_piix.c
View file @
fff42598
...
...
@@ -138,7 +138,7 @@ static struct ata_port_operations piix_pata_ops = {
.
bmdma_setup
=
ata_bmdma_setup_pio
,
.
bmdma_start
=
ata_bmdma_start_pio
,
.
fill_sg
=
ata_fill_sg
,
.
qc_prep
=
ata_qc_prep
,
.
eng_timeout
=
ata_eng_timeout
,
.
irq_handler
=
ata_interrupt
,
...
...
@@ -161,7 +161,7 @@ static struct ata_port_operations piix_sata_ops = {
.
bmdma_setup
=
ata_bmdma_setup_pio
,
.
bmdma_start
=
ata_bmdma_start_pio
,
.
fill_sg
=
ata_fill_sg
,
.
qc_prep
=
ata_qc_prep
,
.
eng_timeout
=
ata_eng_timeout
,
.
irq_handler
=
ata_interrupt
,
...
...
drivers/scsi/libata-core.c
View file @
fff42598
This diff is collapsed.
Click to expand it.
drivers/scsi/sata_promise.c
View file @
fff42598
...
...
@@ -81,7 +81,7 @@ static void pdc_eng_timeout(struct ata_port *ap);
static
int
pdc_port_start
(
struct
ata_port
*
ap
);
static
void
pdc_port_stop
(
struct
ata_port
*
ap
);
static
void
pdc_phy_reset
(
struct
ata_port
*
ap
);
static
void
pdc_
fill_sg
(
struct
ata_queued_cmd
*
qc
);
static
void
pdc_
qc_prep
(
struct
ata_queued_cmd
*
qc
);
static
void
pdc_tf_load_mmio
(
struct
ata_port
*
ap
,
struct
ata_taskfile
*
tf
);
static
void
pdc_exec_command_mmio
(
struct
ata_port
*
ap
,
struct
ata_taskfile
*
tf
);
static
inline
void
pdc_dma_complete
(
struct
ata_port
*
ap
,
...
...
@@ -114,7 +114,7 @@ static struct ata_port_operations pdc_sata_ops = {
.
phy_reset
=
pdc_phy_reset
,
.
bmdma_setup
=
pdc_dma_setup
,
.
bmdma_start
=
pdc_dma_start
,
.
fill_sg
=
pdc_fill_sg
,
.
qc_prep
=
pdc_qc_prep
,
.
eng_timeout
=
pdc_eng_timeout
,
.
irq_handler
=
pdc_interrupt
,
.
scr_read
=
pdc_sata_scr_read
,
...
...
@@ -261,14 +261,14 @@ static void pdc_sata_scr_write (struct ata_port *ap, unsigned int sc_reg,
writel
(
val
,
(
void
*
)
ap
->
ioaddr
.
scr_addr
+
(
sc_reg
*
4
));
}
static
void
pdc_
fill_sg
(
struct
ata_queued_cmd
*
qc
)
static
void
pdc_
qc_prep
(
struct
ata_queued_cmd
*
qc
)
{
struct
pdc_port_priv
*
pp
=
qc
->
ap
->
private_data
;
unsigned
int
i
;
VPRINTK
(
"ENTER
\n
"
);
ata_
fill_sg
(
qc
);
ata_
qc_prep
(
qc
);
i
=
pdc_pkt_header
(
&
qc
->
tf
,
qc
->
ap
->
prd_dma
,
qc
->
dev
->
devno
,
pp
->
pkt
);
...
...
drivers/scsi/sata_sil.c
View file @
fff42598
...
...
@@ -131,7 +131,7 @@ static struct ata_port_operations sil_ops = {
.
post_set_mode
=
sil_post_set_mode
,
.
bmdma_setup
=
ata_bmdma_setup_mmio
,
.
bmdma_start
=
ata_bmdma_start_mmio
,
.
fill_sg
=
ata_fill_sg
,
.
qc_prep
=
ata_qc_prep
,
.
eng_timeout
=
ata_eng_timeout
,
.
irq_handler
=
ata_interrupt
,
.
scr_read
=
sil_scr_read
,
...
...
drivers/scsi/sata_sis.c
View file @
fff42598
...
...
@@ -100,7 +100,7 @@ static struct ata_port_operations sis_ops = {
.
phy_reset
=
sata_phy_reset
,
.
bmdma_setup
=
ata_bmdma_setup_pio
,
.
bmdma_start
=
ata_bmdma_start_pio
,
.
fill_sg
=
ata_fill_sg
,
.
qc_prep
=
ata_qc_prep
,
.
eng_timeout
=
ata_eng_timeout
,
.
irq_handler
=
ata_interrupt
,
.
scr_read
=
sis_scr_read
,
...
...
drivers/scsi/sata_svw.c
View file @
fff42598
...
...
@@ -233,7 +233,7 @@ static struct ata_port_operations k2_sata_ops = {
.
phy_reset
=
sata_phy_reset
,
.
bmdma_setup
=
ata_bmdma_setup_mmio
,
.
bmdma_start
=
ata_bmdma_start_mmio
,
.
fill_sg
=
ata_fill_sg
,
.
qc_prep
=
ata_qc_prep
,
.
eng_timeout
=
ata_eng_timeout
,
.
irq_handler
=
ata_interrupt
,
.
scr_read
=
k2_sata_scr_read
,
...
...
drivers/scsi/sata_sx4.c
View file @
fff42598
...
...
@@ -153,7 +153,7 @@ static void pdc_eng_timeout(struct ata_port *ap);
static
void
pdc_20621_phy_reset
(
struct
ata_port
*
ap
);
static
int
pdc_port_start
(
struct
ata_port
*
ap
);
static
void
pdc_port_stop
(
struct
ata_port
*
ap
);
static
void
pdc20621_
fill_sg
(
struct
ata_queued_cmd
*
qc
);
static
void
pdc20621_
qc_prep
(
struct
ata_queued_cmd
*
qc
);
static
void
pdc_tf_load_mmio
(
struct
ata_port
*
ap
,
struct
ata_taskfile
*
tf
);
static
void
pdc_exec_command_mmio
(
struct
ata_port
*
ap
,
struct
ata_taskfile
*
tf
);
static
void
pdc20621_host_stop
(
struct
ata_host_set
*
host_set
);
...
...
@@ -200,7 +200,7 @@ static struct ata_port_operations pdc_20621_ops = {
.
phy_reset
=
pdc_20621_phy_reset
,
.
bmdma_setup
=
pdc20621_dma_setup
,
.
bmdma_start
=
pdc20621_dma_start
,
.
fill_sg
=
pdc20621_fill_sg
,
.
qc_prep
=
pdc20621_qc_prep
,
.
eng_timeout
=
pdc_eng_timeout
,
.
irq_handler
=
pdc20621_interrupt
,
.
port_start
=
pdc_port_start
,
...
...
@@ -434,7 +434,7 @@ static inline void pdc20621_host_pkt(struct ata_taskfile *tf, u8 *buf,
buf32
[
dw
+
3
]);
}
static
void
pdc20621_
fill_sg
(
struct
ata_queued_cmd
*
qc
)
static
void
pdc20621_
qc_prep
(
struct
ata_queued_cmd
*
qc
)
{
struct
scatterlist
*
sg
=
qc
->
sg
;
struct
ata_port
*
ap
=
qc
->
ap
;
...
...
@@ -446,6 +446,9 @@ static void pdc20621_fill_sg(struct ata_queued_cmd *qc)
unsigned
int
i
,
last
,
idx
,
total_len
=
0
,
sgt_len
;
u32
*
buf
=
(
u32
*
)
&
pp
->
dimm_buf
[
PDC_DIMM_HEADER_SZ
];
if
(
!
(
qc
->
flags
&
ATA_QCFLAG_SG
))
return
;
VPRINTK
(
"ata%u: ENTER
\n
"
,
ap
->
id
);
/* hard-code chip #0 */
...
...
drivers/scsi/sata_via.c
View file @
fff42598
...
...
@@ -108,7 +108,7 @@ static struct ata_port_operations svia_sata_ops = {
.
bmdma_setup
=
ata_bmdma_setup_pio
,
.
bmdma_start
=
ata_bmdma_start_pio
,
.
fill_sg
=
ata_fill_sg
,
.
qc_prep
=
ata_qc_prep
,
.
eng_timeout
=
ata_eng_timeout
,
.
irq_handler
=
ata_interrupt
,
...
...
drivers/scsi/sata_vsc.c
View file @
fff42598
...
...
@@ -215,7 +215,7 @@ static struct ata_port_operations vsc_sata_ops = {
.
phy_reset
=
sata_phy_reset
,
.
bmdma_setup
=
ata_bmdma_setup_mmio
,
.
bmdma_start
=
ata_bmdma_start_mmio
,
.
fill_sg
=
ata_fill_sg
,
.
qc_prep
=
ata_qc_prep
,
.
eng_timeout
=
ata_eng_timeout
,
.
irq_handler
=
vsc_sata_interrupt
,
.
scr_read
=
vsc_sata_scr_read
,
...
...
include/linux/libata.h
View file @
fff42598
...
...
@@ -133,15 +133,6 @@ enum {
BUS_IDENTIFY
=
8
,
BUS_PACKET
=
9
,
/* thread states */
THR_UNKNOWN
=
0
,
THR_PORT_RESET
=
(
THR_UNKNOWN
+
1
),
THR_AWAIT_DEATH
=
(
THR_PORT_RESET
+
1
),
THR_PROBE_FAILED
=
(
THR_AWAIT_DEATH
+
1
),
THR_IDLE
=
(
THR_PROBE_FAILED
+
1
),
THR_PROBE_SUCCESS
=
(
THR_IDLE
+
1
),
THR_PROBE_START
=
(
THR_PROBE_SUCCESS
+
1
),
/* SATA port states */
PORT_UNKNOWN
=
0
,
PORT_ENABLED
=
1
,
...
...
@@ -294,18 +285,12 @@ struct ata_port {
struct
ata_host_stats
stats
;
struct
ata_host_set
*
host_set
;
struct
semaphore
probe_sem
;
unsigned
int
thr_state
;
struct
work_struct
packet_task
;
struct
work_struct
pio_task
;
unsigned
int
pio_task_state
;
unsigned
long
pio_task_timeout
;
struct
work_struct
probe_task
;
void
*
private_data
;
};
...
...
@@ -330,7 +315,7 @@ struct ata_port_operations {
void
(
*
bmdma_setup
)
(
struct
ata_queued_cmd
*
qc
);
void
(
*
bmdma_start
)
(
struct
ata_queued_cmd
*
qc
);
void
(
*
fill_sg
)
(
struct
ata_queued_cmd
*
qc
);
void
(
*
qc_prep
)
(
struct
ata_queued_cmd
*
qc
);
void
(
*
eng_timeout
)
(
struct
ata_port
*
ap
);
irqreturn_t
(
*
irq_handler
)(
int
,
void
*
,
struct
pt_regs
*
);
...
...
@@ -390,7 +375,7 @@ extern void ata_exec_command_mmio(struct ata_port *ap, struct ata_taskfile *tf);
extern
int
ata_port_start
(
struct
ata_port
*
ap
);
extern
void
ata_port_stop
(
struct
ata_port
*
ap
);
extern
irqreturn_t
ata_interrupt
(
int
irq
,
void
*
dev_instance
,
struct
pt_regs
*
regs
);
extern
void
ata_
fill_sg
(
struct
ata_queued_cmd
*
qc
);
extern
void
ata_
qc_prep
(
struct
ata_queued_cmd
*
qc
);
extern
void
ata_dev_id_string
(
struct
ata_device
*
dev
,
unsigned
char
*
s
,
unsigned
int
ofs
,
unsigned
int
len
);
extern
void
ata_bmdma_setup_mmio
(
struct
ata_queued_cmd
*
qc
);
...
...
@@ -556,4 +541,44 @@ static inline unsigned int sata_dev_present(struct ata_port *ap)
return
((
scr_read
(
ap
,
SCR_STATUS
)
&
0xf
)
==
0x3
)
?
1
:
0
;
}
static
inline
void
ata_bmdma_stop
(
struct
ata_port
*
ap
)
{
if
(
ap
->
flags
&
ATA_FLAG_MMIO
)
{
void
*
mmio
=
(
void
*
)
ap
->
ioaddr
.
bmdma_addr
;
/* clear start/stop bit */
writeb
(
readb
(
mmio
+
ATA_DMA_CMD
)
&
~
ATA_DMA_START
,
mmio
+
ATA_DMA_CMD
);
}
else
{
/* clear start/stop bit */
outb
(
inb
(
ap
->
ioaddr
.
bmdma_addr
+
ATA_DMA_CMD
)
&
~
ATA_DMA_START
,
ap
->
ioaddr
.
bmdma_addr
+
ATA_DMA_CMD
);
}
/* one-PIO-cycle guaranteed wait, per spec, for HDMA1:0 transition */
ata_altstatus
(
ap
);
/* dummy read */
}
static
inline
void
ata_bmdma_ack_irq
(
struct
ata_port
*
ap
)
{
if
(
ap
->
flags
&
ATA_FLAG_MMIO
)
{
void
*
mmio
=
((
void
*
)
ap
->
ioaddr
.
bmdma_addr
)
+
ATA_DMA_STATUS
;
writeb
(
readb
(
mmio
),
mmio
);
}
else
{
unsigned
long
addr
=
ap
->
ioaddr
.
bmdma_addr
+
ATA_DMA_STATUS
;
outb
(
inb
(
addr
),
addr
);
}
}
static
inline
u8
ata_bmdma_status
(
struct
ata_port
*
ap
)
{
u8
host_stat
;
if
(
ap
->
flags
&
ATA_FLAG_MMIO
)
{
void
*
mmio
=
(
void
*
)
ap
->
ioaddr
.
bmdma_addr
;
host_stat
=
readb
(
mmio
+
ATA_DMA_STATUS
);
}
else
host_stat
=
inb
(
ap
->
ioaddr
.
bmdma_addr
+
ATA_DMA_STATUS
);
return
host_stat
;
}
#endif
/* __LINUX_LIBATA_H__ */
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