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
7813856a
Commit
7813856a
authored
Aug 25, 2003
by
Christoph Hellwig
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] don't export proc_scsi
proc_mkdir can also take absolute pathes, so we can avoid the export.
parent
a32b9f49
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
13 deletions
+5
-13
drivers/scsi/scsi_proc.c
drivers/scsi/scsi_proc.c
+1
-3
drivers/scsi/sg.c
drivers/scsi/sg.c
+4
-10
No files found.
drivers/scsi/scsi_proc.c
View file @
7813856a
...
...
@@ -37,9 +37,7 @@
/* 4K page size, but our output routines, use some slack for overruns */
#define PROC_BLOCK_SIZE (3*1024)
/* XXX: this shouldn't really be exposed to drivers. */
struct
proc_dir_entry
*
proc_scsi
;
EXPORT_SYMBOL
(
proc_scsi
);
static
struct
proc_dir_entry
*
proc_scsi
;
/* Protect sht->present and sht->proc_dir */
static
DECLARE_MUTEX
(
global_host_template_sem
);
...
...
drivers/scsi/sg.c
View file @
7813856a
...
...
@@ -2583,7 +2583,7 @@ sg_get_dev(int dev)
static
struct
proc_dir_entry
*
sg_proc_sgp
=
NULL
;
static
char
sg_proc_sg_dirname
[]
=
"sg"
;
static
char
sg_proc_sg_dirname
[]
=
"s
csi/s
g"
;
static
int
sg_proc_adio_read
(
char
*
buffer
,
char
**
start
,
off_t
offset
,
int
size
,
int
*
eof
,
void
*
data
);
...
...
@@ -2657,10 +2657,6 @@ static struct sg_proc_leaf sg_proc_leaf_arr[] = {
size : begin + len - offset; \
} while(0)
/* this should _really_ be private to the scsi midlayer. But
/proc/scsi/sg is an established name, so.. */
extern
struct
proc_dir_entry
*
proc_scsi
;
static
int
sg_proc_init
(
void
)
{
...
...
@@ -2670,10 +2666,8 @@ sg_proc_init(void)
struct
proc_dir_entry
*
pdep
;
struct
sg_proc_leaf
*
leaf
;
if
(
!
proc_scsi
)
return
1
;
sg_proc_sgp
=
create_proc_entry
(
sg_proc_sg_dirname
,
S_IFDIR
|
S_IRUGO
|
S_IXUGO
,
proc_scsi
);
S_IFDIR
|
S_IRUGO
|
S_IXUGO
,
NULL
);
if
(
!
sg_proc_sgp
)
return
1
;
for
(
k
=
0
;
k
<
num_leaves
;
++
k
)
{
...
...
@@ -2696,11 +2690,11 @@ sg_proc_cleanup(void)
int
num_leaves
=
sizeof
(
sg_proc_leaf_arr
)
/
sizeof
(
sg_proc_leaf_arr
[
0
]);
if
(
(
!
proc_scsi
)
||
(
!
sg_proc_sgp
)
)
if
(
!
sg_proc_sgp
)
return
;
for
(
k
=
0
;
k
<
num_leaves
;
++
k
)
remove_proc_entry
(
sg_proc_leaf_arr
[
k
].
name
,
sg_proc_sgp
);
remove_proc_entry
(
sg_proc_sg_dirname
,
proc_scsi
);
remove_proc_entry
(
sg_proc_sg_dirname
,
NULL
);
}
static
int
...
...
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