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
65df45c8
Commit
65df45c8
authored
Apr 21, 2002
by
Rusty Russell
Committed by
Linus Torvalds
Apr 21, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] request_region in acornscsi.c
Rusty Russell <rusty@rustcorp.com.au>: 13) request_region check, 11-20:
parent
574faf0f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
5 deletions
+24
-5
drivers/acorn/scsi/acornscsi.c
drivers/acorn/scsi/acornscsi.c
+24
-5
No files found.
drivers/acorn/scsi/acornscsi.c
View file @
65df45c8
...
...
@@ -2915,13 +2915,18 @@ int acornscsi_detect(Scsi_Host_Template * tpnt)
ecs
[
count
]
->
irqaddr
=
(
char
*
)
ioaddr
(
host
->
card
.
io_intr
);
ecs
[
count
]
->
irqmask
=
0x0a
;
request_region
(
instance
->
io_port
+
0x800
,
2
,
"acornscsi(sbic)"
);
request_region
(
host
->
card
.
io_intr
,
1
,
"acornscsi(intr)"
);
request_region
(
host
->
card
.
io_page
,
1
,
"acornscsi(page)"
);
if
(
!
request_region
(
instance
->
io_port
+
0x800
,
2
,
"acornscsi(sbic)"
))
goto
err_1
;
if
(
!
request_region
(
host
->
card
.
io_intr
,
1
,
"acornscsi(intr)"
))
goto
err_2
;
if
(
!
request_region
(
host
->
card
.
io_page
,
1
,
"acornscsi(page)"
))
goto
err_3
;
#ifdef USE_DMAC
request_region
(
host
->
dma
.
io_port
,
256
,
"acornscsi(dmac)"
);
if
(
!
request_region
(
host
->
dma
.
io_port
,
256
,
"acornscsi(dmac)"
))
goto
err_4
;
#endif
request_region
(
instance
->
io_port
,
2048
,
"acornscsi(ram)"
);
if
(
!
request_region
(
instance
->
io_port
,
2048
,
"acornscsi(ram)"
))
goto
err_5
;
if
(
request_irq
(
host
->
scsi
.
irq
,
acornscsi_intr
,
SA_INTERRUPT
,
"acornscsi"
,
host
))
{
printk
(
KERN_CRIT
"scsi%d: IRQ%d not free, interrupts disabled
\n
"
,
...
...
@@ -2934,6 +2939,20 @@ int acornscsi_detect(Scsi_Host_Template * tpnt)
++
count
;
}
return
count
;
err_5:
#ifdef USE_DMAC
release_region
(
host
->
dma
.
io_port
,
256
);
#endif
err_4:
release_region
(
host
->
card
.
io_page
,
1
);
err_3:
release_region
(
host
->
card
.
io_intr
,
1
);
err_2:
release_region
(
instance
->
io_port
+
0x800
,
2
);
err_1:
scsi_unregister
(
instance
);
return
0
;
}
/*
...
...
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