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
3e7b7c35
Commit
3e7b7c35
authored
Nov 18, 2002
by
Russell King
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[ARM] Acorn SCSI build fixes
Oops, I broke them. This cset fixes the errors.
parent
457a8bb0
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
50 additions
and
70 deletions
+50
-70
drivers/acorn/scsi/arxescsi.c
drivers/acorn/scsi/arxescsi.c
+1
-1
drivers/acorn/scsi/cumana_1.c
drivers/acorn/scsi/cumana_1.c
+5
-5
drivers/acorn/scsi/ecoscsi.c
drivers/acorn/scsi/ecoscsi.c
+40
-60
drivers/acorn/scsi/oak.c
drivers/acorn/scsi/oak.c
+4
-4
No files found.
drivers/acorn/scsi/arxescsi.c
View file @
3e7b7c35
...
...
@@ -411,7 +411,7 @@ arxescsi_probe(struct expansion_card *ec, const struct ecard_id *id)
return
ret
;
}
static
void
__devexit
arxescsi_re
leas
e
(
struct
expansion_card
*
ec
)
static
void
__devexit
arxescsi_re
mov
e
(
struct
expansion_card
*
ec
)
{
struct
Scsi_Host
*
host
=
ecard_get_drvdata
(
ec
);
...
...
drivers/acorn/scsi/cumana_1.c
View file @
3e7b7c35
...
...
@@ -260,12 +260,12 @@ static Scsi_Host_Template cumanascsi_template = {
};
static
int
__devinit
cumanascsi1_probe
(
struct
expansion_card
*
ec
,
struct
ecard_ids
*
id
)
cumanascsi1_probe
(
struct
expansion_card
*
ec
,
const
struct
ecard_id
*
id
)
{
struct
Scsi_Host
*
host
;
int
ret
=
-
ENOMEM
;
host
=
scsi_register
(
tpnt
,
sizeof
(
struct
NCR5380_hostdata
));
host
=
scsi_register
(
&
cumanascsi_template
,
sizeof
(
struct
NCR5380_hostdata
));
if
(
!
host
)
goto
out
;
...
...
@@ -294,7 +294,7 @@ cumanascsi1_probe(struct expansion_card *ec, struct ecard_ids *id)
printk
(
"scsi%d: at port 0x%08lx irq %d"
,
host
->
host_no
,
host
->
io_port
,
host
->
irq
);
printk
(
" options CAN_QUEUE=%d CMD_PER_LUN=%d release=%d"
,
tpnt
->
can_queue
,
tpn
t
->
cmd_per_lun
,
CUMANASCSI_PUBLIC_RELEASE
);
host
->
can_queue
,
hos
t
->
cmd_per_lun
,
CUMANASCSI_PUBLIC_RELEASE
);
printk
(
"
\n
scsi%d:"
,
host
->
host_no
);
NCR5380_print_options
(
host
);
printk
(
"
\n
"
);
...
...
@@ -321,10 +321,10 @@ static void __devexit cumanascsi1_remove(struct expansion_card *ec)
scsi_remove_host
(
host
);
free_irq
(
host
->
irq
,
host
);
release_region
(
host
->
io_port
,
host
->
n_io_port
);
scsi_
remove
(
host
);
scsi_
unregister
(
host
);
}
static
const
struct
ecard_id
s
cumanascsi1_cids
[]
=
{
static
const
struct
ecard_id
cumanascsi1_cids
[]
=
{
{
MANU_CUMANA
,
PROD_CUMANA_SCSI_1
},
{
0xffff
,
0xffff
}
};
...
...
drivers/acorn/scsi/ecoscsi.c
View file @
3e7b7c35
...
...
@@ -54,6 +54,18 @@
#include "../../scsi/scsi.h"
#include "../../scsi/hosts.h"
#define NCR5380_implementation_fields int port, ctrl
#define NCR5380_local_declare() struct Scsi_Host *_instance
#define NCR5380_setup(instance) _instance = instance
#define NCR5380_read(reg) ecoscsi_read(_instance, reg)
#define NCR5380_write(reg, value) ecoscsi_write(_instance, reg, value)
#define NCR5380_intr ecoscsi_intr
#define NCR5380_queue_command ecoscsi_queue_command
#define NCR5380_proc_info ecoscsi_proc_info
#include "../../scsi/NCR5380.h"
#define ECOSCSI_PUBLIC_RELEASE 1
...
...
@@ -99,62 +111,45 @@ void ecoscsi_setup(char *str, int *ints) {
int
ecoscsi_detect
(
Scsi_Host_Template
*
tpnt
)
{
struct
Scsi_Host
*
instance
;
struct
Scsi_Host
*
host
;
tpnt
->
proc_name
=
"ecoscsi"
;
instance
=
scsi_register
(
tpnt
,
sizeof
(
struct
NCR5380_hostdata
));
if
(
!
instance
)
host
=
scsi_register
(
tpnt
,
sizeof
(
struct
NCR5380_hostdata
));
if
(
!
host
)
return
0
;
instance
->
io_port
=
0x80ce8000
;
instance
->
n_io_port
=
144
;
instance
->
irq
=
IRQ_NONE
;
host
->
io_port
=
0x80ce8000
;
host
->
n_io_port
=
144
;
host
->
irq
=
IRQ_NONE
;
if
(
!
(
request_region
(
instance
->
io_port
,
instance
->
n_io_port
,
"ecoscsi"
))
)
if
(
!
(
request_region
(
host
->
io_port
,
host
->
n_io_port
,
"ecoscsi"
))
)
goto
unregister_scsi
;
ecoscsi_write
(
instance
,
MODE_REG
,
0x20
);
/* Is it really SCSI? */
if
(
ecoscsi_read
(
instance
,
MODE_REG
)
!=
0x20
)
/* Write to a reg. */
ecoscsi_write
(
host
,
MODE_REG
,
0x20
);
/* Is it really SCSI? */
if
(
ecoscsi_read
(
host
,
MODE_REG
)
!=
0x20
)
/* Write to a reg. */
goto
release_reg
;
ecoscsi_write
(
instance
,
MODE_REG
,
0x00
);
/* it back. */
if
(
ecoscsi_read
(
instance
,
MODE_REG
)
!=
0x00
)
ecoscsi_write
(
host
,
MODE_REG
,
0x00
);
/* it back. */
if
(
ecoscsi_read
(
host
,
MODE_REG
)
!=
0x00
)
goto
release_reg
;
NCR5380_init
(
instance
,
0
);
if
(
instance
->
irq
!=
IRQ_NONE
)
{
if
(
request_irq
(
instance
->
irq
,
do_ecoscsi_intr
,
SA_INTERRUPT
,
"ecoscsi"
,
NULL
))
{
printk
(
"scsi%d: IRQ%d not free, interrupts disabled
\n
"
,
instance
->
host_no
,
instance
->
irq
);
instance
->
irq
=
IRQ_NONE
;
}
}
NCR5380_init
(
host
,
0
);
if
(
instance
->
irq
!=
IRQ_NONE
)
{
printk
(
"scsi%d: eek! Interrupts enabled, but I don't think
\n
"
,
instance
->
host_no
);
printk
(
"scsi%d: that the board had an interrupt!
\n
"
,
instance
->
host_no
);
}
printk
(
"scsi%d: at port %X irq"
,
instance
->
host_no
,
instance
->
io_port
);
if
(
instance
->
irq
==
IRQ_NONE
)
printk
(
"s disabled"
);
else
printk
(
" %d"
,
instance
->
irq
);
printk
(
"scsi%d: at port 0x%08lx irqs disabled"
,
host
->
host_no
,
host
->
io_port
);
printk
(
" options CAN_QUEUE=%d CMD_PER_LUN=%d release=%d"
,
CAN_QUEUE
,
CMD_PER_LUN
,
ECOSCSI_PUBLIC_RELEASE
);
printk
(
"
\n
scsi%d:"
,
instance
->
host_no
);
NCR5380_print_options
(
instance
);
host
->
can_queue
,
host
->
cmd_per_lun
,
ECOSCSI_PUBLIC_RELEASE
);
printk
(
"
\n
scsi%d:"
,
host
->
host_no
);
NCR5380_print_options
(
host
);
printk
(
"
\n
"
);
return
1
;
release_reg:
release_region
(
instance
->
io_port
,
instance
->
n_io_port
);
release_region
(
host
->
io_port
,
host
->
n_io_port
);
unregister_scsi:
scsi_unregister
(
instance
);
return
0
scsi_unregister
(
host
);
return
0
;
}
int
ecoscsi_release
(
struct
Scsi_Host
*
shpnt
)
...
...
@@ -166,17 +161,18 @@ int ecoscsi_release (struct Scsi_Host *shpnt)
return
0
;
}
const
char
*
ecoscsi_info
(
struct
Scsi_Host
*
spnt
)
{
const
char
*
ecoscsi_info
(
struct
Scsi_Host
*
spnt
)
{
return
""
;
}
#if 0
#define STAT(p) inw(p + 144)
static inline int NCR5380_pwrite(struct Scsi_Host *
instance
, unsigned char *addr,
static inline int NCR5380_pwrite(struct Scsi_Host *
host
, unsigned char *addr,
int len)
{
int iobase =
instance
->io_port;
int iobase =
host
->io_port;
printk("writing %p len %d\n",addr, len);
if(!len) return -1;
...
...
@@ -187,11 +183,11 @@ printk("writing %p len %d\n",addr, len);
}
}
static inline int NCR5380_pread(struct Scsi_Host *
instance
, unsigned char *addr,
static inline int NCR5380_pread(struct Scsi_Host *
host
, unsigned char *addr,
int len)
{
int iobase =
instance
->io_port;
int iobase2=
instance
->io_port + 0x100;
int iobase =
host
->io_port;
int iobase2=
host
->io_port + 0x100;
unsigned char *start = addr;
int s;
printk("reading %p len %d\n",addr, len);
...
...
@@ -237,22 +233,6 @@ printk("reading %p len %d\n",addr, len);
#endif
#undef STAT
#define NCR5380_implementation_fields \
int port, ctrl
#define NCR5380_local_declare() \
struct Scsi_Host *_instance
#define NCR5380_setup(instance) \
_instance = instance
#define NCR5380_read(reg) ecoscsi_read(_instance, reg)
#define NCR5380_write(reg, value) ecoscsi_write(_instance, reg, value)
#define NCR5380_intr ecoscsi_intr
#define NCR5380_queue_command ecoscsi_queue_command
#define NCR5380_proc_info ecoscsi_proc_info
int
NCR5380_proc_info
(
char
*
buffer
,
char
**
start
,
off_t
offset
,
int
length
,
int
hostno
,
int
inout
);
...
...
drivers/acorn/scsi/oak.c
View file @
3e7b7c35
...
...
@@ -138,11 +138,11 @@ oakscsi_probe(struct expansion_card *ec, const struct ecard_id *id)
struct
Scsi_Host
*
host
;
int
ret
=
-
ENOMEM
;
host
=
scsi_register
(
tpnt
,
sizeof
(
struct
NCR5380_hostdata
));
host
=
scsi_register
(
&
oakscsi_template
,
sizeof
(
struct
NCR5380_hostdata
));
if
(
!
host
)
goto
out
;
host
->
io_port
=
ecard_address
(
ec
,
ECARD_MEMC
,
0
)
host
->
io_port
=
ecard_address
(
ec
,
ECARD_MEMC
,
0
);
host
->
irq
=
IRQ_NONE
;
host
->
n_io_port
=
255
;
...
...
@@ -155,7 +155,7 @@ oakscsi_probe(struct expansion_card *ec, const struct ecard_id *id)
printk
(
"scsi%d: at port 0x%08lx irqs disabled"
,
host
->
host_no
,
host
->
io_port
);
printk
(
" options CAN_QUEUE=%d CMD_PER_LUN=%d release=%d"
,
tpnt
->
can_queue
,
tpn
t
->
cmd_per_lun
,
OAKSCSI_PUBLIC_RELEASE
);
host
->
can_queue
,
hos
t
->
cmd_per_lun
,
OAKSCSI_PUBLIC_RELEASE
);
printk
(
"
\n
scsi%d:"
,
host
->
host_no
);
NCR5380_print_options
(
host
);
printk
(
"
\n
"
);
...
...
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