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
d5787c80
Commit
d5787c80
authored
Sep 09, 2003
by
Joe Perches
Committed by
Linus Torvalds
Sep 09, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] Use SEQ_START_TOKEN in include/net/* [3/3]
parent
18d0a2b7
Changes
34
Hide whitespace changes
Inline
Side-by-side
Showing
34 changed files
with
126 additions
and
140 deletions
+126
-140
net/802/tr.c
net/802/tr.c
+3
-5
net/8021q/vlanproc.c
net/8021q/vlanproc.c
+0
-4
net/appletalk/aarp.c
net/appletalk/aarp.c
+3
-3
net/appletalk/atalk_proc.c
net/appletalk/atalk_proc.c
+9
-9
net/ax25/ax25_route.c
net/ax25/ax25_route.c
+3
-5
net/ax25/ax25_uid.c
net/ax25/ax25_uid.c
+3
-5
net/core/dev.c
net/core/dev.c
+3
-3
net/core/wireless.c
net/core/wireless.c
+1
-1
net/decnet/af_decnet.c
net/decnet/af_decnet.c
+4
-4
net/decnet/dn_dev.c
net/decnet/dn_dev.c
+4
-4
net/decnet/dn_neigh.c
net/decnet/dn_neigh.c
+4
-4
net/ipv4/arp.c
net/ipv4/arp.c
+4
-4
net/ipv4/fib_hash.c
net/ipv4/fib_hash.c
+3
-3
net/ipv4/igmp.c
net/ipv4/igmp.c
+6
-6
net/ipv4/raw.c
net/ipv4/raw.c
+3
-3
net/ipv4/route.c
net/ipv4/route.c
+4
-4
net/ipv4/tcp_ipv4.c
net/ipv4/tcp_ipv4.c
+4
-4
net/ipv4/udp.c
net/ipv4/udp.c
+1
-1
net/ipv6/addrconf.c
net/ipv6/addrconf.c
+3
-3
net/ipv6/ip6_flowlabel.c
net/ipv6/ip6_flowlabel.c
+3
-3
net/ipv6/mcast.c
net/ipv6/mcast.c
+3
-3
net/ipv6/raw.c
net/ipv6/raw.c
+3
-3
net/ipv6/tcp_ipv6.c
net/ipv6/tcp_ipv6.c
+1
-1
net/ipv6/udp.c
net/ipv6/udp.c
+1
-1
net/ipx/ipx_proc.c
net/ipx/ipx_proc.c
+9
-9
net/irda/irlan/irlan_common.c
net/irda/irlan/irlan_common.c
+3
-4
net/llc/llc_proc.c
net/llc/llc_proc.c
+4
-4
net/netrom/af_netrom.c
net/netrom/af_netrom.c
+3
-5
net/netrom/nr_route.c
net/netrom/nr_route.c
+6
-7
net/rose/af_rose.c
net/rose/af_rose.c
+3
-3
net/rose/rose_route.c
net/rose/rose_route.c
+9
-9
net/sunrpc/cache.c
net/sunrpc/cache.c
+3
-3
net/wanrouter/wanproc.c
net/wanrouter/wanproc.c
+4
-4
net/x25/x25_proc.c
net/x25/x25_proc.c
+6
-6
No files found.
net/802/tr.c
View file @
d5787c80
...
@@ -464,8 +464,6 @@ static void rif_check_expire(unsigned long dummy)
...
@@ -464,8 +464,6 @@ static void rif_check_expire(unsigned long dummy)
*/
*/
#ifdef CONFIG_PROC_FS
#ifdef CONFIG_PROC_FS
/* Magic token to indicate first entry (header line) */
#define RIF_PROC_START ((void *)1)
static
struct
rif_cache_s
*
rif_get_idx
(
loff_t
pos
)
static
struct
rif_cache_s
*
rif_get_idx
(
loff_t
pos
)
{
{
...
@@ -487,7 +485,7 @@ static void *rif_seq_start(struct seq_file *seq, loff_t *pos)
...
@@ -487,7 +485,7 @@ static void *rif_seq_start(struct seq_file *seq, loff_t *pos)
{
{
spin_lock_bh
(
&
rif_lock
);
spin_lock_bh
(
&
rif_lock
);
return
*
pos
?
rif_get_idx
(
*
pos
-
1
)
:
RIF_PROC_START
;
return
*
pos
?
rif_get_idx
(
*
pos
-
1
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
rif_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
rif_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -497,7 +495,7 @@ static void *rif_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -497,7 +495,7 @@ static void *rif_seq_next(struct seq_file *seq, void *v, loff_t *pos)
++*
pos
;
++*
pos
;
if
(
v
==
RIF_PROC_START
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
i
=
-
1
;
i
=
-
1
;
goto
scan
;
goto
scan
;
}
}
...
@@ -524,7 +522,7 @@ static int rif_seq_show(struct seq_file *seq, void *v)
...
@@ -524,7 +522,7 @@ static int rif_seq_show(struct seq_file *seq, void *v)
int
j
,
rcf_len
,
segment
,
brdgnmb
;
int
j
,
rcf_len
,
segment
,
brdgnmb
;
struct
rif_cache_s
*
entry
=
v
;
struct
rif_cache_s
*
entry
=
v
;
if
(
v
==
RIF_PROC_START
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
seq_puts
(
seq
,
"if TR address TTL rcf routing segments
\n
"
);
"if TR address TTL rcf routing segments
\n
"
);
else
{
else
{
...
...
net/8021q/vlanproc.c
View file @
d5787c80
...
@@ -46,10 +46,6 @@ static void *vlan_seq_next(struct seq_file *seq, void *v, loff_t *pos);
...
@@ -46,10 +46,6 @@ static void *vlan_seq_next(struct seq_file *seq, void *v, loff_t *pos);
static
void
vlan_seq_stop
(
struct
seq_file
*
seq
,
void
*
);
static
void
vlan_seq_stop
(
struct
seq_file
*
seq
,
void
*
);
static
int
vlandev_seq_show
(
struct
seq_file
*
seq
,
void
*
v
);
static
int
vlandev_seq_show
(
struct
seq_file
*
seq
,
void
*
v
);
/* Miscellaneous */
#define SEQ_START_TOKEN ((void *) 1)
/*
/*
* Global Data
* Global Data
*/
*/
...
...
net/appletalk/aarp.c
View file @
d5787c80
...
@@ -941,7 +941,7 @@ static void *aarp_seq_start(struct seq_file *seq, loff_t *pos)
...
@@ -941,7 +941,7 @@ static void *aarp_seq_start(struct seq_file *seq, loff_t *pos)
iter
->
table
=
resolved
;
iter
->
table
=
resolved
;
iter
->
bucket
=
0
;
iter
->
bucket
=
0
;
return
*
pos
?
iter_next
(
iter
,
pos
)
:
((
void
*
)
1
);
return
*
pos
?
iter_next
(
iter
,
pos
)
:
SEQ_START_TOKEN
);
}
}
static
void
*
aarp_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
aarp_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -952,7 +952,7 @@ static void *aarp_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -952,7 +952,7 @@ static void *aarp_seq_next(struct seq_file *seq, void *v, loff_t *pos)
++*
pos
;
++*
pos
;
/* first line after header */
/* first line after header */
if
(
v
==
((
void
*
)
1
)
)
if
(
v
==
SEQ_START_TOKEN
)
entry
=
iter_next
(
iter
,
NULL
);
entry
=
iter_next
(
iter
,
NULL
);
/* next entry in current bucket */
/* next entry in current bucket */
...
@@ -987,7 +987,7 @@ static int aarp_seq_show(struct seq_file *seq, void *v)
...
@@ -987,7 +987,7 @@ static int aarp_seq_show(struct seq_file *seq, void *v)
struct
aarp_entry
*
entry
=
v
;
struct
aarp_entry
*
entry
=
v
;
unsigned
long
now
=
jiffies
;
unsigned
long
now
=
jiffies
;
if
(
v
==
((
void
*
)
1
)
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
seq_puts
(
seq
,
"Address Interface Hardware Address"
"Address Interface Hardware Address"
" Expires LastSend Retry Status
\n
"
);
" Expires LastSend Retry Status
\n
"
);
...
...
net/appletalk/atalk_proc.c
View file @
d5787c80
...
@@ -33,7 +33,7 @@ static void *atalk_seq_interface_start(struct seq_file *seq, loff_t *pos)
...
@@ -33,7 +33,7 @@ static void *atalk_seq_interface_start(struct seq_file *seq, loff_t *pos)
loff_t
l
=
*
pos
;
loff_t
l
=
*
pos
;
read_lock_bh
(
&
atalk_interfaces_lock
);
read_lock_bh
(
&
atalk_interfaces_lock
);
return
l
?
atalk_get_interface_idx
(
--
l
)
:
(
void
*
)
1
;
return
l
?
atalk_get_interface_idx
(
--
l
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
atalk_seq_interface_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
atalk_seq_interface_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -41,7 +41,7 @@ static void *atalk_seq_interface_next(struct seq_file *seq, void *v, loff_t *pos
...
@@ -41,7 +41,7 @@ static void *atalk_seq_interface_next(struct seq_file *seq, void *v, loff_t *pos
struct
atalk_iface
*
i
;
struct
atalk_iface
*
i
;
++*
pos
;
++*
pos
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
i
=
NULL
;
i
=
NULL
;
if
(
atalk_interfaces
)
if
(
atalk_interfaces
)
i
=
atalk_interfaces
;
i
=
atalk_interfaces
;
...
@@ -62,7 +62,7 @@ static int atalk_seq_interface_show(struct seq_file *seq, void *v)
...
@@ -62,7 +62,7 @@ static int atalk_seq_interface_show(struct seq_file *seq, void *v)
{
{
struct
atalk_iface
*
iface
;
struct
atalk_iface
*
iface
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_puts
(
seq
,
"Interface Address Networks "
seq_puts
(
seq
,
"Interface Address Networks "
"Status
\n
"
);
"Status
\n
"
);
goto
out
;
goto
out
;
...
@@ -92,7 +92,7 @@ static void *atalk_seq_route_start(struct seq_file *seq, loff_t *pos)
...
@@ -92,7 +92,7 @@ static void *atalk_seq_route_start(struct seq_file *seq, loff_t *pos)
loff_t
l
=
*
pos
;
loff_t
l
=
*
pos
;
read_lock_bh
(
&
atalk_routes_lock
);
read_lock_bh
(
&
atalk_routes_lock
);
return
l
?
atalk_get_route_idx
(
--
l
)
:
(
void
*
)
1
;
return
l
?
atalk_get_route_idx
(
--
l
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
atalk_seq_route_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
atalk_seq_route_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -100,7 +100,7 @@ static void *atalk_seq_route_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -100,7 +100,7 @@ static void *atalk_seq_route_next(struct seq_file *seq, void *v, loff_t *pos)
struct
atalk_route
*
r
;
struct
atalk_route
*
r
;
++*
pos
;
++*
pos
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
r
=
NULL
;
r
=
NULL
;
if
(
atalk_routes
)
if
(
atalk_routes
)
r
=
atalk_routes
;
r
=
atalk_routes
;
...
@@ -121,7 +121,7 @@ static int atalk_seq_route_show(struct seq_file *seq, void *v)
...
@@ -121,7 +121,7 @@ static int atalk_seq_route_show(struct seq_file *seq, void *v)
{
{
struct
atalk_route
*
rt
;
struct
atalk_route
*
rt
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_puts
(
seq
,
"Target Router Flags Dev
\n
"
);
seq_puts
(
seq
,
"Target Router Flags Dev
\n
"
);
goto
out
;
goto
out
;
}
}
...
@@ -160,7 +160,7 @@ static void *atalk_seq_socket_start(struct seq_file *seq, loff_t *pos)
...
@@ -160,7 +160,7 @@ static void *atalk_seq_socket_start(struct seq_file *seq, loff_t *pos)
loff_t
l
=
*
pos
;
loff_t
l
=
*
pos
;
read_lock_bh
(
&
atalk_sockets_lock
);
read_lock_bh
(
&
atalk_sockets_lock
);
return
l
?
atalk_get_socket_idx
(
--
l
)
:
(
void
*
)
1
;
return
l
?
atalk_get_socket_idx
(
--
l
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
atalk_seq_socket_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
atalk_seq_socket_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -168,7 +168,7 @@ static void *atalk_seq_socket_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -168,7 +168,7 @@ static void *atalk_seq_socket_next(struct seq_file *seq, void *v, loff_t *pos)
struct
sock
*
i
;
struct
sock
*
i
;
++*
pos
;
++*
pos
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
i
=
sk_head
(
&
atalk_sockets
);
i
=
sk_head
(
&
atalk_sockets
);
goto
out
;
goto
out
;
}
}
...
@@ -187,7 +187,7 @@ static int atalk_seq_socket_show(struct seq_file *seq, void *v)
...
@@ -187,7 +187,7 @@ static int atalk_seq_socket_show(struct seq_file *seq, void *v)
struct
sock
*
s
;
struct
sock
*
s
;
struct
atalk_sock
*
at
;
struct
atalk_sock
*
at
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_printf
(
seq
,
"Type Local_addr Remote_addr Tx_queue "
seq_printf
(
seq
,
"Type Local_addr Remote_addr Tx_queue "
"Rx_queue St UID
\n
"
);
"Rx_queue St UID
\n
"
);
goto
out
;
goto
out
;
...
...
net/ax25/ax25_route.c
View file @
d5787c80
...
@@ -281,8 +281,6 @@ int ax25_rt_ioctl(unsigned int cmd, void *arg)
...
@@ -281,8 +281,6 @@ int ax25_rt_ioctl(unsigned int cmd, void *arg)
#ifdef CONFIG_PROC_FS
#ifdef CONFIG_PROC_FS
#define AX25_PROC_START ((void *)1)
static
void
*
ax25_rt_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
ax25_rt_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
struct
ax25_route
*
ax25_rt
;
struct
ax25_route
*
ax25_rt
;
...
@@ -290,7 +288,7 @@ static void *ax25_rt_seq_start(struct seq_file *seq, loff_t *pos)
...
@@ -290,7 +288,7 @@ static void *ax25_rt_seq_start(struct seq_file *seq, loff_t *pos)
read_lock
(
&
ax25_route_lock
);
read_lock
(
&
ax25_route_lock
);
if
(
*
pos
==
0
)
if
(
*
pos
==
0
)
return
AX25_PROC_START
;
return
SEQ_START_TOKEN
;
for
(
ax25_rt
=
ax25_route_list
;
ax25_rt
!=
NULL
;
ax25_rt
=
ax25_rt
->
next
)
{
for
(
ax25_rt
=
ax25_route_list
;
ax25_rt
!=
NULL
;
ax25_rt
=
ax25_rt
->
next
)
{
if
(
i
==
*
pos
)
if
(
i
==
*
pos
)
...
@@ -304,7 +302,7 @@ static void *ax25_rt_seq_start(struct seq_file *seq, loff_t *pos)
...
@@ -304,7 +302,7 @@ static void *ax25_rt_seq_start(struct seq_file *seq, loff_t *pos)
static
void
*
ax25_rt_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
ax25_rt_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
++*
pos
;
++*
pos
;
return
(
v
==
AX25_PROC_START
)
?
ax25_route_list
:
return
(
v
==
SEQ_START_TOKEN
)
?
ax25_route_list
:
((
struct
ax25_route
*
)
v
)
->
next
;
((
struct
ax25_route
*
)
v
)
->
next
;
}
}
...
@@ -315,7 +313,7 @@ static void ax25_rt_seq_stop(struct seq_file *seq, void *v)
...
@@ -315,7 +313,7 @@ static void ax25_rt_seq_stop(struct seq_file *seq, void *v)
static
int
ax25_rt_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
ax25_rt_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
AX25_PROC_START
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
"callsign dev mode digipeaters
\n
"
);
seq_puts
(
seq
,
"callsign dev mode digipeaters
\n
"
);
else
{
else
{
struct
ax25_route
*
ax25_rt
=
v
;
struct
ax25_route
*
ax25_rt
=
v
;
...
...
net/ax25/ax25_uid.c
View file @
d5787c80
...
@@ -144,8 +144,6 @@ int ax25_uid_ioctl(int cmd, struct sockaddr_ax25 *sax)
...
@@ -144,8 +144,6 @@ int ax25_uid_ioctl(int cmd, struct sockaddr_ax25 *sax)
#ifdef CONFIG_PROC_FS
#ifdef CONFIG_PROC_FS
#define AX25_PROC_START ((void *)1)
static
void
*
ax25_uid_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
ax25_uid_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
struct
ax25_uid_assoc
*
pt
;
struct
ax25_uid_assoc
*
pt
;
...
@@ -153,7 +151,7 @@ static void *ax25_uid_seq_start(struct seq_file *seq, loff_t *pos)
...
@@ -153,7 +151,7 @@ static void *ax25_uid_seq_start(struct seq_file *seq, loff_t *pos)
read_lock
(
&
ax25_uid_lock
);
read_lock
(
&
ax25_uid_lock
);
if
(
*
pos
==
0
)
if
(
*
pos
==
0
)
return
AX25_PROC_START
;
return
SEQ_START_TOKEN
;
for
(
pt
=
ax25_uid_list
;
pt
!=
NULL
;
pt
=
pt
->
next
)
{
for
(
pt
=
ax25_uid_list
;
pt
!=
NULL
;
pt
=
pt
->
next
)
{
if
(
i
==
*
pos
)
if
(
i
==
*
pos
)
...
@@ -166,7 +164,7 @@ static void *ax25_uid_seq_start(struct seq_file *seq, loff_t *pos)
...
@@ -166,7 +164,7 @@ static void *ax25_uid_seq_start(struct seq_file *seq, loff_t *pos)
static
void
*
ax25_uid_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
ax25_uid_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
++*
pos
;
++*
pos
;
return
(
v
==
AX25_PROC_START
)
?
ax25_uid_list
:
return
(
v
==
SEQ_START_TOKEN
)
?
ax25_uid_list
:
((
struct
ax25_uid_assoc
*
)
v
)
->
next
;
((
struct
ax25_uid_assoc
*
)
v
)
->
next
;
}
}
...
@@ -177,7 +175,7 @@ static void ax25_uid_seq_stop(struct seq_file *seq, void *v)
...
@@ -177,7 +175,7 @@ static void ax25_uid_seq_stop(struct seq_file *seq, void *v)
static
int
ax25_uid_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
ax25_uid_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
AX25_PROC_START
)
if
(
v
==
SEQ_START_TOKEN
)
seq_printf
(
seq
,
"Policy: %d
\n
"
,
ax25_uid_policy
);
seq_printf
(
seq
,
"Policy: %d
\n
"
,
ax25_uid_policy
);
else
{
else
{
struct
ax25_uid_assoc
*
pt
=
v
;
struct
ax25_uid_assoc
*
pt
=
v
;
...
...
net/core/dev.c
View file @
d5787c80
...
@@ -1844,13 +1844,13 @@ static __inline__ struct net_device *dev_get_idx(loff_t pos)
...
@@ -1844,13 +1844,13 @@ static __inline__ struct net_device *dev_get_idx(loff_t pos)
void
*
dev_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
void
*
dev_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
read_lock
(
&
dev_base_lock
);
read_lock
(
&
dev_base_lock
);
return
*
pos
?
dev_get_idx
(
*
pos
-
1
)
:
(
void
*
)
1
;
return
*
pos
?
dev_get_idx
(
*
pos
-
1
)
:
SEQ_START_TOKEN
;
}
}
void
*
dev_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
void
*
dev_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
++*
pos
;
++*
pos
;
return
v
==
(
void
*
)
1
?
dev_base
:
((
struct
net_device
*
)
v
)
->
next
;
return
v
==
SEQ_START_TOKEN
?
dev_base
:
((
struct
net_device
*
)
v
)
->
next
;
}
}
void
dev_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
void
dev_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
...
@@ -1890,7 +1890,7 @@ static void dev_seq_printf_stats(struct seq_file *seq, struct net_device *dev)
...
@@ -1890,7 +1890,7 @@ static void dev_seq_printf_stats(struct seq_file *seq, struct net_device *dev)
*/
*/
static
int
dev_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
dev_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
"Inter-| Receive "
seq_puts
(
seq
,
"Inter-| Receive "
" | Transmit
\n
"
" | Transmit
\n
"
" face |bytes packets errs drop fifo frame "
" face |bytes packets errs drop fifo frame "
...
...
net/core/wireless.c
View file @
d5787c80
...
@@ -458,7 +458,7 @@ static __inline__ void wireless_seq_printf_stats(struct seq_file *seq,
...
@@ -458,7 +458,7 @@ static __inline__ void wireless_seq_printf_stats(struct seq_file *seq,
*/
*/
static
int
wireless_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
wireless_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
seq_printf
(
seq
,
"Inter-| sta-| Quality | Discarded "
seq_printf
(
seq
,
"Inter-| sta-| Quality | Discarded "
"packets | Missed | WE
\n
"
"packets | Missed | WE
\n
"
" face | tus | link level noise | nwid "
" face | tus | link level noise | nwid "
...
...
net/decnet/af_decnet.c
View file @
d5787c80
...
@@ -2146,14 +2146,14 @@ static void *dn_socket_get_idx(struct seq_file *seq, loff_t pos)
...
@@ -2146,14 +2146,14 @@ static void *dn_socket_get_idx(struct seq_file *seq, loff_t pos)
static
void
*
dn_socket_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
dn_socket_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
return
*
pos
?
dn_socket_get_idx
(
seq
,
*
pos
-
1
)
:
(
void
*
)
1
;
return
*
pos
?
dn_socket_get_idx
(
seq
,
*
pos
-
1
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
dn_socket_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
dn_socket_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
void
*
rc
;
void
*
rc
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
rc
=
dn_socket_get_idx
(
seq
,
0
);
rc
=
dn_socket_get_idx
(
seq
,
0
);
goto
out
;
goto
out
;
}
}
...
@@ -2169,7 +2169,7 @@ static void *dn_socket_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -2169,7 +2169,7 @@ static void *dn_socket_seq_next(struct seq_file *seq, void *v, loff_t *pos)
static
void
dn_socket_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
static
void
dn_socket_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
&&
v
!=
(
void
*
)
1
)
if
(
v
&&
v
!=
SEQ_START_TOKEN
)
read_unlock_bh
(
&
dn_hash_lock
);
read_unlock_bh
(
&
dn_hash_lock
);
}
}
...
@@ -2269,7 +2269,7 @@ static inline void dn_socket_format_entry(struct seq_file *seq, struct sock *sk)
...
@@ -2269,7 +2269,7 @@ static inline void dn_socket_format_entry(struct seq_file *seq, struct sock *sk)
static
int
dn_socket_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
dn_socket_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_puts
(
seq
,
"Local Remote
\n
"
);
seq_puts
(
seq
,
"Local Remote
\n
"
);
}
else
{
}
else
{
dn_socket_format_entry
(
seq
,
v
);
dn_socket_format_entry
(
seq
,
v
);
...
...
net/decnet/dn_dev.c
View file @
d5787c80
...
@@ -1365,7 +1365,7 @@ static void *dn_dev_seq_start(struct seq_file *seq, loff_t *pos)
...
@@ -1365,7 +1365,7 @@ static void *dn_dev_seq_start(struct seq_file *seq, loff_t *pos)
read_unlock
(
&
dev_base_lock
);
read_unlock
(
&
dev_base_lock
);
return
dev
;
return
dev
;
}
}
return
(
void
*
)
1
;
return
SEQ_START_TOKEN
;
}
}
static
void
*
dn_dev_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
dn_dev_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -1373,7 +1373,7 @@ static void *dn_dev_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -1373,7 +1373,7 @@ static void *dn_dev_seq_next(struct seq_file *seq, void *v, loff_t *pos)
struct
net_device
*
dev
=
v
;
struct
net_device
*
dev
=
v
;
loff_t
one
=
1
;
loff_t
one
=
1
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
dev
=
dn_dev_seq_start
(
seq
,
&
one
);
dev
=
dn_dev_seq_start
(
seq
,
&
one
);
}
else
{
}
else
{
dev
=
dn_dev_get_next
(
seq
,
dev
);
dev
=
dn_dev_get_next
(
seq
,
dev
);
...
@@ -1386,7 +1386,7 @@ static void *dn_dev_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -1386,7 +1386,7 @@ static void *dn_dev_seq_next(struct seq_file *seq, void *v, loff_t *pos)
static
void
dn_dev_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
static
void
dn_dev_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
&&
v
!=
(
void
*
)
1
)
if
(
v
&&
v
!=
SEQ_START_TOKEN
)
read_unlock
(
&
dev_base_lock
);
read_unlock
(
&
dev_base_lock
);
}
}
...
@@ -1406,7 +1406,7 @@ static char *dn_type2asc(char type)
...
@@ -1406,7 +1406,7 @@ static char *dn_type2asc(char type)
static
int
dn_dev_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
dn_dev_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
"Name Flags T1 Timer1 T3 Timer3 BlkSize Pri State DevType Router Peer
\n
"
);
seq_puts
(
seq
,
"Name Flags T1 Timer1 T3 Timer3 BlkSize Pri State DevType Router Peer
\n
"
);
else
{
else
{
struct
net_device
*
dev
=
v
;
struct
net_device
*
dev
=
v
;
...
...
net/decnet/dn_neigh.c
View file @
d5787c80
...
@@ -604,7 +604,7 @@ static void *dn_neigh_get_idx(struct seq_file *seq, loff_t pos)
...
@@ -604,7 +604,7 @@ static void *dn_neigh_get_idx(struct seq_file *seq, loff_t pos)
static
void
*
dn_neigh_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
dn_neigh_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
return
*
pos
?
dn_neigh_get_idx
(
seq
,
*
pos
-
1
)
:
(
void
*
)
1
;
return
*
pos
?
dn_neigh_get_idx
(
seq
,
*
pos
-
1
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
dn_neigh_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
dn_neigh_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -612,7 +612,7 @@ static void *dn_neigh_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -612,7 +612,7 @@ static void *dn_neigh_seq_next(struct seq_file *seq, void *v, loff_t *pos)
void
*
rc
;
void
*
rc
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
rc
=
dn_neigh_get_idx
(
seq
,
0
);
rc
=
dn_neigh_get_idx
(
seq
,
0
);
goto
out
;
goto
out
;
}
}
...
@@ -628,7 +628,7 @@ static void *dn_neigh_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -628,7 +628,7 @@ static void *dn_neigh_seq_next(struct seq_file *seq, void *v, loff_t *pos)
static
void
dn_neigh_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
static
void
dn_neigh_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
&&
v
!=
(
void
*
)
1
)
if
(
v
&&
v
!=
SEQ_START_TOKEN
)
read_unlock_bh
(
&
dn_neigh_table
.
lock
);
read_unlock_bh
(
&
dn_neigh_table
.
lock
);
}
}
...
@@ -653,7 +653,7 @@ static inline void dn_neigh_format_entry(struct seq_file *seq,
...
@@ -653,7 +653,7 @@ static inline void dn_neigh_format_entry(struct seq_file *seq,
static
int
dn_neigh_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
dn_neigh_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_puts
(
seq
,
"Addr Flags State Use Blksize Dev
\n
"
);
seq_puts
(
seq
,
"Addr Flags State Use Blksize Dev
\n
"
);
}
else
{
}
else
{
dn_neigh_format_entry
(
seq
,
v
);
dn_neigh_format_entry
(
seq
,
v
);
...
...
net/ipv4/arp.c
View file @
d5787c80
...
@@ -1275,7 +1275,7 @@ static void *arp_get_idx(struct seq_file *seq, loff_t pos)
...
@@ -1275,7 +1275,7 @@ static void *arp_get_idx(struct seq_file *seq, loff_t pos)
static
void
*
arp_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
arp_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
return
*
pos
?
arp_get_idx
(
seq
,
*
pos
-
1
)
:
(
void
*
)
1
;
return
*
pos
?
arp_get_idx
(
seq
,
*
pos
-
1
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
arp_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
arp_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -1283,7 +1283,7 @@ static void *arp_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -1283,7 +1283,7 @@ static void *arp_seq_next(struct seq_file *seq, void *v, loff_t *pos)
void
*
rc
;
void
*
rc
;
struct
arp_iter_state
*
state
;
struct
arp_iter_state
*
state
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
rc
=
arp_get_idx
(
seq
,
0
);
rc
=
arp_get_idx
(
seq
,
0
);
goto
out
;
goto
out
;
}
}
...
@@ -1306,7 +1306,7 @@ static void arp_seq_stop(struct seq_file *seq, void *v)
...
@@ -1306,7 +1306,7 @@ static void arp_seq_stop(struct seq_file *seq, void *v)
{
{
struct
arp_iter_state
*
state
=
seq
->
private
;
struct
arp_iter_state
*
state
=
seq
->
private
;
if
(
!
state
->
is_pneigh
&&
v
!=
(
void
*
)
1
)
if
(
!
state
->
is_pneigh
&&
v
!=
SEQ_START_TOKEN
)
read_unlock_bh
(
&
arp_tbl
.
lock
);
read_unlock_bh
(
&
arp_tbl
.
lock
);
}
}
...
@@ -1359,7 +1359,7 @@ static __inline__ void arp_format_pneigh_entry(struct seq_file *seq,
...
@@ -1359,7 +1359,7 @@ static __inline__ void arp_format_pneigh_entry(struct seq_file *seq,
static
int
arp_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
arp_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
"IP address HW type Flags "
seq_puts
(
seq
,
"IP address HW type Flags "
"HW address Mask Device
\n
"
);
"HW address Mask Device
\n
"
);
else
{
else
{
...
...
net/ipv4/fib_hash.c
View file @
d5787c80
...
@@ -979,14 +979,14 @@ static void *fib_seq_start(struct seq_file *seq, loff_t *pos)
...
@@ -979,14 +979,14 @@ static void *fib_seq_start(struct seq_file *seq, loff_t *pos)
read_lock
(
&
fib_hash_lock
);
read_lock
(
&
fib_hash_lock
);
if
(
ip_fib_main_table
)
if
(
ip_fib_main_table
)
v
=
*
pos
?
fib_get_next
(
seq
)
:
(
void
*
)
1
;
v
=
*
pos
?
fib_get_next
(
seq
)
:
SEQ_START_TOKEN
;
return
v
;
return
v
;
}
}
static
void
*
fib_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
fib_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
++*
pos
;
++*
pos
;
return
v
==
(
void
*
)
1
?
fib_get_first
(
seq
)
:
fib_get_next
(
seq
);
return
v
==
SEQ_START_TOKEN
?
fib_get_first
(
seq
)
:
fib_get_next
(
seq
);
}
}
static
void
fib_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
static
void
fib_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
...
@@ -1025,7 +1025,7 @@ static int fib_seq_show(struct seq_file *seq, void *v)
...
@@ -1025,7 +1025,7 @@ static int fib_seq_show(struct seq_file *seq, void *v)
struct
fib_node
*
f
;
struct
fib_node
*
f
;
struct
fib_info
*
fi
;
struct
fib_info
*
fi
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_printf
(
seq
,
"%-127s
\n
"
,
"Iface
\t
Destination
\t
Gateway "
seq_printf
(
seq
,
"%-127s
\n
"
,
"Iface
\t
Destination
\t
Gateway "
"
\t
Flags
\t
RefCnt
\t
Use
\t
Metric
\t
Mask
\t\t
MTU"
"
\t
Flags
\t
RefCnt
\t
Use
\t
Metric
\t
Mask
\t\t
MTU"
"
\t
Window
\t
IRTT"
);
"
\t
Window
\t
IRTT"
);
...
...
net/ipv4/igmp.c
View file @
d5787c80
...
@@ -2162,13 +2162,13 @@ static struct ip_mc_list *igmp_mc_get_idx(struct seq_file *seq, loff_t pos)
...
@@ -2162,13 +2162,13 @@ static struct ip_mc_list *igmp_mc_get_idx(struct seq_file *seq, loff_t pos)
static
void
*
igmp_mc_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
igmp_mc_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
read_lock
(
&
dev_base_lock
);
read_lock
(
&
dev_base_lock
);
return
*
pos
?
igmp_mc_get_idx
(
seq
,
*
pos
)
:
(
void
*
)
1
;
return
*
pos
?
igmp_mc_get_idx
(
seq
,
*
pos
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
igmp_mc_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
igmp_mc_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
struct
ip_mc_list
*
im
;
struct
ip_mc_list
*
im
;
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
im
=
igmp_mc_get_first
(
seq
);
im
=
igmp_mc_get_first
(
seq
);
else
else
im
=
igmp_mc_get_next
(
seq
,
v
);
im
=
igmp_mc_get_next
(
seq
,
v
);
...
@@ -2190,7 +2190,7 @@ static void igmp_mc_seq_stop(struct seq_file *seq, void *v)
...
@@ -2190,7 +2190,7 @@ static void igmp_mc_seq_stop(struct seq_file *seq, void *v)
static
int
igmp_mc_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
igmp_mc_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
seq_printf
(
seq
,
seq_printf
(
seq
,
"Idx
\t
Device : Count Querier
\t
Group Users Timer
\t
Reporter
\n
"
);
"Idx
\t
Device : Count Querier
\t
Group Users Timer
\t
Reporter
\n
"
);
else
{
else
{
...
@@ -2337,13 +2337,13 @@ static struct ip_sf_list *igmp_mcf_get_idx(struct seq_file *seq, loff_t pos)
...
@@ -2337,13 +2337,13 @@ static struct ip_sf_list *igmp_mcf_get_idx(struct seq_file *seq, loff_t pos)
static
void
*
igmp_mcf_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
igmp_mcf_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
read_lock
(
&
dev_base_lock
);
read_lock
(
&
dev_base_lock
);
return
*
pos
?
igmp_mcf_get_idx
(
seq
,
*
pos
)
:
(
void
*
)
1
;
return
*
pos
?
igmp_mcf_get_idx
(
seq
,
*
pos
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
igmp_mcf_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
igmp_mcf_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
struct
ip_sf_list
*
psf
;
struct
ip_sf_list
*
psf
;
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
psf
=
igmp_mcf_get_first
(
seq
);
psf
=
igmp_mcf_get_first
(
seq
);
else
else
psf
=
igmp_mcf_get_next
(
seq
,
v
);
psf
=
igmp_mcf_get_next
(
seq
,
v
);
...
@@ -2372,7 +2372,7 @@ static int igmp_mcf_seq_show(struct seq_file *seq, void *v)
...
@@ -2372,7 +2372,7 @@ static int igmp_mcf_seq_show(struct seq_file *seq, void *v)
struct
ip_sf_list
*
psf
=
(
struct
ip_sf_list
*
)
v
;
struct
ip_sf_list
*
psf
=
(
struct
ip_sf_list
*
)
v
;
struct
igmp_mcf_iter_state
*
state
=
igmp_mcf_seq_private
(
seq
);
struct
igmp_mcf_iter_state
*
state
=
igmp_mcf_seq_private
(
seq
);
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_printf
(
seq
,
seq_printf
(
seq
,
"%3s %6s "
"%3s %6s "
"%10s %10s %6s %6s
\n
"
,
"Idx"
,
"%10s %10s %6s %6s
\n
"
,
"Idx"
,
...
...
net/ipv4/raw.c
View file @
d5787c80
...
@@ -736,14 +736,14 @@ static struct sock *raw_get_idx(struct seq_file *seq, loff_t pos)
...
@@ -736,14 +736,14 @@ static struct sock *raw_get_idx(struct seq_file *seq, loff_t pos)
static
void
*
raw_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
raw_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
read_lock
(
&
raw_v4_lock
);
read_lock
(
&
raw_v4_lock
);
return
*
pos
?
raw_get_idx
(
seq
,
*
pos
)
:
(
void
*
)
1
;
return
*
pos
?
raw_get_idx
(
seq
,
*
pos
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
raw_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
raw_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
struct
sock
*
sk
;
struct
sock
*
sk
;
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
sk
=
raw_get_first
(
seq
);
sk
=
raw_get_first
(
seq
);
else
else
sk
=
raw_get_next
(
seq
,
v
);
sk
=
raw_get_next
(
seq
,
v
);
...
@@ -778,7 +778,7 @@ static int raw_seq_show(struct seq_file *seq, void *v)
...
@@ -778,7 +778,7 @@ static int raw_seq_show(struct seq_file *seq, void *v)
{
{
char
tmpbuf
[
129
];
char
tmpbuf
[
129
];
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
seq_printf
(
seq
,
"%-127s
\n
"
,
seq_printf
(
seq
,
"%-127s
\n
"
,
" sl local_address rem_address st tx_queue "
" sl local_address rem_address st tx_queue "
"rx_queue tr tm->when retrnsmt uid timeout "
"rx_queue tr tm->when retrnsmt uid timeout "
...
...
net/ipv4/route.c
View file @
d5787c80
...
@@ -259,14 +259,14 @@ static struct rtable *rt_cache_get_idx(struct seq_file *seq, loff_t pos)
...
@@ -259,14 +259,14 @@ static struct rtable *rt_cache_get_idx(struct seq_file *seq, loff_t pos)
static
void
*
rt_cache_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
rt_cache_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
return
*
pos
?
rt_cache_get_idx
(
seq
,
*
pos
)
:
(
void
*
)
1
;
return
*
pos
?
rt_cache_get_idx
(
seq
,
*
pos
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
rt_cache_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
rt_cache_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
struct
rtable
*
r
=
NULL
;
struct
rtable
*
r
=
NULL
;
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
r
=
rt_cache_get_first
(
seq
);
r
=
rt_cache_get_first
(
seq
);
else
else
r
=
rt_cache_get_next
(
seq
,
v
);
r
=
rt_cache_get_next
(
seq
,
v
);
...
@@ -276,13 +276,13 @@ static void *rt_cache_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -276,13 +276,13 @@ static void *rt_cache_seq_next(struct seq_file *seq, void *v, loff_t *pos)
static
void
rt_cache_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
static
void
rt_cache_seq_stop
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
&&
v
!=
(
void
*
)
1
)
if
(
v
&&
v
!=
SEQ_START_TOKEN
)
rcu_read_unlock
();
rcu_read_unlock
();
}
}
static
int
rt_cache_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
rt_cache_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
seq_printf
(
seq
,
"%-127s
\n
"
,
seq_printf
(
seq
,
"%-127s
\n
"
,
"Iface
\t
Destination
\t
Gateway
\t
Flags
\t\t
RefCnt
\t
Use
\t
"
"Iface
\t
Destination
\t
Gateway
\t
Flags
\t\t
RefCnt
\t
Use
\t
"
"Metric
\t
Source
\t\t
MTU
\t
Window
\t
IRTT
\t
TOS
\t
HHRef
\t
"
"Metric
\t
Source
\t\t
MTU
\t
Window
\t
IRTT
\t
TOS
\t
HHRef
\t
"
...
...
net/ipv4/tcp_ipv4.c
View file @
d5787c80
...
@@ -2351,7 +2351,7 @@ static void *tcp_get_idx(struct seq_file *seq, loff_t pos)
...
@@ -2351,7 +2351,7 @@ static void *tcp_get_idx(struct seq_file *seq, loff_t pos)
static
void
*
tcp_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
tcp_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
return
*
pos
?
tcp_get_idx
(
seq
,
*
pos
-
1
)
:
(
void
*
)
1
;
return
*
pos
?
tcp_get_idx
(
seq
,
*
pos
-
1
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
tcp_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
tcp_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -2359,7 +2359,7 @@ static void *tcp_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -2359,7 +2359,7 @@ static void *tcp_seq_next(struct seq_file *seq, void *v, loff_t *pos)
void
*
rc
=
NULL
;
void
*
rc
=
NULL
;
struct
tcp_iter_state
*
st
;
struct
tcp_iter_state
*
st
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
rc
=
tcp_get_idx
(
seq
,
0
);
rc
=
tcp_get_idx
(
seq
,
0
);
goto
out
;
goto
out
;
}
}
...
@@ -2397,7 +2397,7 @@ static void tcp_seq_stop(struct seq_file *seq, void *v)
...
@@ -2397,7 +2397,7 @@ static void tcp_seq_stop(struct seq_file *seq, void *v)
read_unlock_bh
(
&
tp
->
syn_wait_lock
);
read_unlock_bh
(
&
tp
->
syn_wait_lock
);
}
}
case
TCP_SEQ_STATE_LISTENING
:
case
TCP_SEQ_STATE_LISTENING
:
if
(
v
!=
(
void
*
)
1
)
if
(
v
!=
SEQ_START_TOKEN
)
tcp_listen_unlock
();
tcp_listen_unlock
();
break
;
break
;
case
TCP_SEQ_STATE_TIME_WAIT
:
case
TCP_SEQ_STATE_TIME_WAIT
:
...
@@ -2559,7 +2559,7 @@ static int tcp4_seq_show(struct seq_file *seq, void *v)
...
@@ -2559,7 +2559,7 @@ static int tcp4_seq_show(struct seq_file *seq, void *v)
struct
tcp_iter_state
*
st
;
struct
tcp_iter_state
*
st
;
char
tmpbuf
[
TMPSZ
+
1
];
char
tmpbuf
[
TMPSZ
+
1
];
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_printf
(
seq
,
"%-*s
\n
"
,
TMPSZ
-
1
,
seq_printf
(
seq
,
"%-*s
\n
"
,
TMPSZ
-
1
,
" sl local_address rem_address st tx_queue "
" sl local_address rem_address st tx_queue "
"rx_queue tr tm->when retrnsmt uid timeout "
"rx_queue tr tm->when retrnsmt uid timeout "
...
...
net/ipv4/udp.c
View file @
d5787c80
...
@@ -1497,7 +1497,7 @@ static void udp4_format_sock(struct sock *sp, char *tmpbuf, int bucket)
...
@@ -1497,7 +1497,7 @@ static void udp4_format_sock(struct sock *sp, char *tmpbuf, int bucket)
static
int
udp4_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
udp4_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
seq_printf
(
seq
,
"%-127s
\n
"
,
seq_printf
(
seq
,
"%-127s
\n
"
,
" sl local_address rem_address st tx_queue "
" sl local_address rem_address st tx_queue "
"rx_queue tr tm->when retrnsmt uid timeout "
"rx_queue tr tm->when retrnsmt uid timeout "
...
...
net/ipv6/addrconf.c
View file @
d5787c80
...
@@ -2170,7 +2170,7 @@ static inline struct inet6_ifaddr *if6_get_bucket(struct seq_file *seq, loff_t *
...
@@ -2170,7 +2170,7 @@ static inline struct inet6_ifaddr *if6_get_bucket(struct seq_file *seq, loff_t *
static
void
*
if6_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
if6_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
read_lock_bh
(
&
addrconf_hash_lock
);
read_lock_bh
(
&
addrconf_hash_lock
);
return
*
pos
?
if6_get_bucket
(
seq
,
pos
)
:
(
void
*
)
1
;
return
*
pos
?
if6_get_bucket
(
seq
,
pos
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
if6_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
if6_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -2178,7 +2178,7 @@ static void *if6_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -2178,7 +2178,7 @@ static void *if6_seq_next(struct seq_file *seq, void *v, loff_t *pos)
struct
inet6_ifaddr
*
ifa
;
struct
inet6_ifaddr
*
ifa
;
struct
if6_iter_state
*
state
;
struct
if6_iter_state
*
state
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
ifa
=
if6_get_bucket
(
seq
,
pos
);
ifa
=
if6_get_bucket
(
seq
,
pos
);
goto
out
;
goto
out
;
}
}
...
@@ -2214,7 +2214,7 @@ static inline void if6_iface_seq_show(struct seq_file *seq, struct inet6_ifaddr
...
@@ -2214,7 +2214,7 @@ static inline void if6_iface_seq_show(struct seq_file *seq, struct inet6_ifaddr
static
int
if6_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
if6_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
return
0
;
return
0
;
else
else
if6_iface_seq_show
(
seq
,
v
);
if6_iface_seq_show
(
seq
,
v
);
...
...
net/ipv6/ip6_flowlabel.c
View file @
d5787c80
...
@@ -603,14 +603,14 @@ static struct ip6_flowlabel *ip6fl_get_idx(struct seq_file *seq, loff_t pos)
...
@@ -603,14 +603,14 @@ static struct ip6_flowlabel *ip6fl_get_idx(struct seq_file *seq, loff_t pos)
static
void
*
ip6fl_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
ip6fl_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
read_lock_bh
(
&
ip6_fl_lock
);
read_lock_bh
(
&
ip6_fl_lock
);
return
*
pos
?
ip6fl_get_idx
(
seq
,
*
pos
)
:
(
void
*
)
1
;
return
*
pos
?
ip6fl_get_idx
(
seq
,
*
pos
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
ip6fl_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
ip6fl_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
struct
ip6_flowlabel
*
fl
;
struct
ip6_flowlabel
*
fl
;
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
fl
=
ip6fl_get_first
(
seq
);
fl
=
ip6fl_get_first
(
seq
);
else
else
fl
=
ip6fl_get_next
(
seq
,
v
);
fl
=
ip6fl_get_next
(
seq
,
v
);
...
@@ -644,7 +644,7 @@ static void ip6fl_fl_seq_show(struct seq_file *seq, struct ip6_flowlabel *fl)
...
@@ -644,7 +644,7 @@ static void ip6fl_fl_seq_show(struct seq_file *seq, struct ip6_flowlabel *fl)
static
int
ip6fl_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
ip6fl_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
seq_printf
(
seq
,
"Label S Owner Users Linger Expires "
seq_printf
(
seq
,
"Label S Owner Users Linger Expires "
"Dst Opt
\n
"
);
"Dst Opt
\n
"
);
else
else
...
...
net/ipv6/mcast.c
View file @
d5787c80
...
@@ -2278,13 +2278,13 @@ static struct ip6_sf_list *igmp6_mcf_get_idx(struct seq_file *seq, loff_t pos)
...
@@ -2278,13 +2278,13 @@ static struct ip6_sf_list *igmp6_mcf_get_idx(struct seq_file *seq, loff_t pos)
static
void
*
igmp6_mcf_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
igmp6_mcf_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
read_lock
(
&
dev_base_lock
);
read_lock
(
&
dev_base_lock
);
return
*
pos
?
igmp6_mcf_get_idx
(
seq
,
*
pos
)
:
(
void
*
)
1
;
return
*
pos
?
igmp6_mcf_get_idx
(
seq
,
*
pos
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
igmp6_mcf_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
igmp6_mcf_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
struct
ip6_sf_list
*
psf
;
struct
ip6_sf_list
*
psf
;
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
psf
=
igmp6_mcf_get_first
(
seq
);
psf
=
igmp6_mcf_get_first
(
seq
);
else
else
psf
=
igmp6_mcf_get_next
(
seq
,
v
);
psf
=
igmp6_mcf_get_next
(
seq
,
v
);
...
@@ -2313,7 +2313,7 @@ static int igmp6_mcf_seq_show(struct seq_file *seq, void *v)
...
@@ -2313,7 +2313,7 @@ static int igmp6_mcf_seq_show(struct seq_file *seq, void *v)
struct
ip6_sf_list
*
psf
=
(
struct
ip6_sf_list
*
)
v
;
struct
ip6_sf_list
*
psf
=
(
struct
ip6_sf_list
*
)
v
;
struct
igmp6_mcf_iter_state
*
state
=
igmp6_mcf_seq_private
(
seq
);
struct
igmp6_mcf_iter_state
*
state
=
igmp6_mcf_seq_private
(
seq
);
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_printf
(
seq
,
seq_printf
(
seq
,
"%3s %6s "
"%3s %6s "
"%32s %32s %6s %6s
\n
"
,
"Idx"
,
"%32s %32s %6s %6s
\n
"
,
"Idx"
,
...
...
net/ipv6/raw.c
View file @
d5787c80
...
@@ -961,14 +961,14 @@ static struct sock *raw6_get_idx(struct seq_file *seq, loff_t pos)
...
@@ -961,14 +961,14 @@ static struct sock *raw6_get_idx(struct seq_file *seq, loff_t pos)
static
void
*
raw6_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
raw6_seq_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
read_lock
(
&
raw_v6_lock
);
read_lock
(
&
raw_v6_lock
);
return
*
pos
?
raw6_get_idx
(
seq
,
*
pos
)
:
(
void
*
)
1
;
return
*
pos
?
raw6_get_idx
(
seq
,
*
pos
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
raw6_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
raw6_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
{
{
struct
sock
*
sk
;
struct
sock
*
sk
;
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
sk
=
raw6_get_first
(
seq
);
sk
=
raw6_get_first
(
seq
);
else
else
sk
=
raw6_get_next
(
seq
,
v
);
sk
=
raw6_get_next
(
seq
,
v
);
...
@@ -1010,7 +1010,7 @@ static void raw6_sock_seq_show(struct seq_file *seq, struct sock *sp, int i)
...
@@ -1010,7 +1010,7 @@ static void raw6_sock_seq_show(struct seq_file *seq, struct sock *sp, int i)
static
int
raw6_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
raw6_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
seq_printf
(
seq
,
seq_printf
(
seq
,
" sl "
" sl "
"local_address "
"local_address "
...
...
net/ipv6/tcp_ipv6.c
View file @
d5787c80
...
@@ -2027,7 +2027,7 @@ static int tcp6_seq_show(struct seq_file *seq, void *v)
...
@@ -2027,7 +2027,7 @@ static int tcp6_seq_show(struct seq_file *seq, void *v)
{
{
struct
tcp_iter_state
*
st
;
struct
tcp_iter_state
*
st
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_printf
(
seq
,
seq_printf
(
seq
,
" sl "
" sl "
"local_address "
"local_address "
...
...
net/ipv6/udp.c
View file @
d5787c80
...
@@ -1113,7 +1113,7 @@ static void udp6_sock_seq_show(struct seq_file *seq, struct sock *sp, int bucket
...
@@ -1113,7 +1113,7 @@ static void udp6_sock_seq_show(struct seq_file *seq, struct sock *sp, int bucket
static
int
udp6_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
udp6_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
seq_printf
(
seq
,
seq_printf
(
seq
,
" sl "
" sl "
"local_address "
"local_address "
...
...
net/ipx/ipx_proc.c
View file @
d5787c80
...
@@ -39,7 +39,7 @@ static void *ipx_seq_interface_start(struct seq_file *seq, loff_t *pos)
...
@@ -39,7 +39,7 @@ static void *ipx_seq_interface_start(struct seq_file *seq, loff_t *pos)
loff_t
l
=
*
pos
;
loff_t
l
=
*
pos
;
spin_lock_bh
(
&
ipx_interfaces_lock
);
spin_lock_bh
(
&
ipx_interfaces_lock
);
return
l
?
ipx_get_interface_idx
(
--
l
)
:
(
void
*
)
1
;
return
l
?
ipx_get_interface_idx
(
--
l
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
ipx_seq_interface_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
ipx_seq_interface_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -47,7 +47,7 @@ static void *ipx_seq_interface_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -47,7 +47,7 @@ static void *ipx_seq_interface_next(struct seq_file *seq, void *v, loff_t *pos)
struct
ipx_interface
*
i
;
struct
ipx_interface
*
i
;
++*
pos
;
++*
pos
;
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
i
=
ipx_interfaces_head
();
i
=
ipx_interfaces_head
();
else
else
i
=
ipx_interfaces_next
(
v
);
i
=
ipx_interfaces_next
(
v
);
...
@@ -63,7 +63,7 @@ static int ipx_seq_interface_show(struct seq_file *seq, void *v)
...
@@ -63,7 +63,7 @@ static int ipx_seq_interface_show(struct seq_file *seq, void *v)
{
{
struct
ipx_interface
*
i
;
struct
ipx_interface
*
i
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_puts
(
seq
,
"Network Node_Address Primary Device "
seq_puts
(
seq
,
"Network Node_Address Primary Device "
"Frame_Type"
);
"Frame_Type"
);
#ifdef IPX_REFCNT_DEBUG
#ifdef IPX_REFCNT_DEBUG
...
@@ -123,7 +123,7 @@ static void *ipx_seq_route_start(struct seq_file *seq, loff_t *pos)
...
@@ -123,7 +123,7 @@ static void *ipx_seq_route_start(struct seq_file *seq, loff_t *pos)
{
{
loff_t
l
=
*
pos
;
loff_t
l
=
*
pos
;
read_lock_bh
(
&
ipx_routes_lock
);
read_lock_bh
(
&
ipx_routes_lock
);
return
l
?
ipx_get_route_idx
(
--
l
)
:
(
void
*
)
1
;
return
l
?
ipx_get_route_idx
(
--
l
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
ipx_seq_route_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
ipx_seq_route_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -131,7 +131,7 @@ static void *ipx_seq_route_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -131,7 +131,7 @@ static void *ipx_seq_route_next(struct seq_file *seq, void *v, loff_t *pos)
struct
ipx_route
*
r
;
struct
ipx_route
*
r
;
++*
pos
;
++*
pos
;
if
(
v
==
(
void
*
)
1
)
if
(
v
==
SEQ_START_TOKEN
)
r
=
ipx_routes_head
();
r
=
ipx_routes_head
();
else
else
r
=
ipx_routes_next
(
v
);
r
=
ipx_routes_next
(
v
);
...
@@ -147,7 +147,7 @@ static int ipx_seq_route_show(struct seq_file *seq, void *v)
...
@@ -147,7 +147,7 @@ static int ipx_seq_route_show(struct seq_file *seq, void *v)
{
{
struct
ipx_route
*
rt
;
struct
ipx_route
*
rt
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_puts
(
seq
,
"Network Router_Net Router_Node
\n
"
);
seq_puts
(
seq
,
"Network Router_Net Router_Node
\n
"
);
goto
out
;
goto
out
;
}
}
...
@@ -195,7 +195,7 @@ static void *ipx_seq_socket_start(struct seq_file *seq, loff_t *pos)
...
@@ -195,7 +195,7 @@ static void *ipx_seq_socket_start(struct seq_file *seq, loff_t *pos)
loff_t
l
=
*
pos
;
loff_t
l
=
*
pos
;
spin_lock_bh
(
&
ipx_interfaces_lock
);
spin_lock_bh
(
&
ipx_interfaces_lock
);
return
l
?
ipx_get_socket_idx
(
--
l
)
:
(
void
*
)
1
;
return
l
?
ipx_get_socket_idx
(
--
l
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
ipx_seq_socket_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
ipx_seq_socket_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -205,7 +205,7 @@ static void *ipx_seq_socket_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -205,7 +205,7 @@ static void *ipx_seq_socket_next(struct seq_file *seq, void *v, loff_t *pos)
struct
ipx_opt
*
ipxs
;
struct
ipx_opt
*
ipxs
;
++*
pos
;
++*
pos
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
sk
=
NULL
;
sk
=
NULL
;
i
=
ipx_interfaces_head
();
i
=
ipx_interfaces_head
();
if
(
!
i
)
if
(
!
i
)
...
@@ -245,7 +245,7 @@ static int ipx_seq_socket_show(struct seq_file *seq, void *v)
...
@@ -245,7 +245,7 @@ static int ipx_seq_socket_show(struct seq_file *seq, void *v)
struct
sock
*
s
;
struct
sock
*
s
;
struct
ipx_opt
*
ipxs
;
struct
ipx_opt
*
ipxs
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
#ifdef CONFIG_IPX_INTERN
#ifdef CONFIG_IPX_INTERN
seq_puts
(
seq
,
"Local_Address "
seq_puts
(
seq
,
"Local_Address "
"Remote_Address Tx_Queue "
"Remote_Address Tx_Queue "
...
...
net/irda/irlan/irlan_common.c
View file @
d5787c80
...
@@ -1068,7 +1068,6 @@ int irlan_extract_param(__u8 *buf, char *name, char *value, __u16 *len)
...
@@ -1068,7 +1068,6 @@ int irlan_extract_param(__u8 *buf, char *name, char *value, __u16 *len)
}
}
#ifdef CONFIG_PROC_FS
#ifdef CONFIG_PROC_FS
#define IRLAN_PROC_START_TOKEN ((void *)1)
/*
/*
* Start of reading /proc entries.
* Start of reading /proc entries.
...
@@ -1083,7 +1082,7 @@ static void *irlan_seq_start(struct seq_file *seq, loff_t *pos)
...
@@ -1083,7 +1082,7 @@ static void *irlan_seq_start(struct seq_file *seq, loff_t *pos)
rcu_read_lock
();
rcu_read_lock
();
if
(
*
pos
==
0
)
if
(
*
pos
==
0
)
return
IRLAN_PROC
_START_TOKEN
;
return
SEQ
_START_TOKEN
;
list_for_each_entry
(
self
,
&
irlans
,
dev_list
)
{
list_for_each_entry
(
self
,
&
irlans
,
dev_list
)
{
if
(
*
pos
==
i
)
if
(
*
pos
==
i
)
...
@@ -1099,7 +1098,7 @@ static void *irlan_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -1099,7 +1098,7 @@ static void *irlan_seq_next(struct seq_file *seq, void *v, loff_t *pos)
struct
list_head
*
nxt
;
struct
list_head
*
nxt
;
++*
pos
;
++*
pos
;
if
(
v
==
IRLAN_PROC
_START_TOKEN
)
if
(
v
==
SEQ
_START_TOKEN
)
nxt
=
irlans
.
next
;
nxt
=
irlans
.
next
;
else
else
nxt
=
((
struct
irlan_cb
*
)
v
)
->
dev_list
.
next
;
nxt
=
((
struct
irlan_cb
*
)
v
)
->
dev_list
.
next
;
...
@@ -1120,7 +1119,7 @@ static void irlan_seq_stop(struct seq_file *seq, void *v)
...
@@ -1120,7 +1119,7 @@ static void irlan_seq_stop(struct seq_file *seq, void *v)
*/
*/
static
int
irlan_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
irlan_seq_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
IRLAN_PROC
_START_TOKEN
)
if
(
v
==
SEQ
_START_TOKEN
)
seq_puts
(
seq
,
"IrLAN instances:
\n
"
);
seq_puts
(
seq
,
"IrLAN instances:
\n
"
);
else
{
else
{
struct
irlan_cb
*
self
=
v
;
struct
irlan_cb
*
self
=
v
;
...
...
net/llc/llc_proc.c
View file @
d5787c80
...
@@ -67,7 +67,7 @@ static void *llc_seq_start(struct seq_file *seq, loff_t *pos)
...
@@ -67,7 +67,7 @@ static void *llc_seq_start(struct seq_file *seq, loff_t *pos)
loff_t
l
=
*
pos
;
loff_t
l
=
*
pos
;
read_lock_bh
(
&
llc_main_station
.
sap_list
.
lock
);
read_lock_bh
(
&
llc_main_station
.
sap_list
.
lock
);
return
l
?
llc_get_sk_idx
(
--
l
)
:
(
void
*
)
1
;
return
l
?
llc_get_sk_idx
(
--
l
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
llc_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
llc_seq_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -77,7 +77,7 @@ static void *llc_seq_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -77,7 +77,7 @@ static void *llc_seq_next(struct seq_file *seq, void *v, loff_t *pos)
struct
llc_sap
*
sap
;
struct
llc_sap
*
sap
;
++*
pos
;
++*
pos
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
sk
=
llc_get_sk_idx
(
0
);
sk
=
llc_get_sk_idx
(
0
);
goto
out
;
goto
out
;
}
}
...
@@ -123,7 +123,7 @@ static int llc_seq_socket_show(struct seq_file *seq, void *v)
...
@@ -123,7 +123,7 @@ static int llc_seq_socket_show(struct seq_file *seq, void *v)
struct
sock
*
sk
;
struct
sock
*
sk
;
struct
llc_opt
*
llc
;
struct
llc_opt
*
llc
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_puts
(
seq
,
"SKt Mc local_mac_sap remote_mac_sap "
seq_puts
(
seq
,
"SKt Mc local_mac_sap remote_mac_sap "
" tx_queue rx_queue st uid link
\n
"
);
" tx_queue rx_queue st uid link
\n
"
);
goto
out
;
goto
out
;
...
@@ -172,7 +172,7 @@ static int llc_seq_core_show(struct seq_file *seq, void *v)
...
@@ -172,7 +172,7 @@ static int llc_seq_core_show(struct seq_file *seq, void *v)
struct
sock
*
sk
;
struct
sock
*
sk
;
struct
llc_opt
*
llc
;
struct
llc_opt
*
llc
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_puts
(
seq
,
"Connection list:
\n
"
seq_puts
(
seq
,
"Connection list:
\n
"
"dsap state retr txw rxw pf ff sf df rs cs "
"dsap state retr txw rxw pf ff sf df rs cs "
"tack tpfc trs tbs blog busr
\n
"
);
"tack tpfc trs tbs blog busr
\n
"
);
...
...
net/netrom/af_netrom.c
View file @
d5787c80
...
@@ -1241,8 +1241,6 @@ static int nr_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
...
@@ -1241,8 +1241,6 @@ static int nr_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
#ifdef CONFIG_PROC_FS
#ifdef CONFIG_PROC_FS
/* Marker for header entry */
#define NETROM_PROC_START ((void *)1)
static
void
*
nr_info_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
nr_info_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
struct
sock
*
s
;
struct
sock
*
s
;
...
@@ -1251,7 +1249,7 @@ static void *nr_info_start(struct seq_file *seq, loff_t *pos)
...
@@ -1251,7 +1249,7 @@ static void *nr_info_start(struct seq_file *seq, loff_t *pos)
spin_lock_bh
(
&
nr_list_lock
);
spin_lock_bh
(
&
nr_list_lock
);
if
(
*
pos
==
0
)
if
(
*
pos
==
0
)
return
NETROM_PROC_START
;
return
SEQ_START_TOKEN
;
sk_for_each
(
s
,
node
,
&
nr_list
)
{
sk_for_each
(
s
,
node
,
&
nr_list
)
{
if
(
i
==
*
pos
)
if
(
i
==
*
pos
)
...
@@ -1265,7 +1263,7 @@ static void *nr_info_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -1265,7 +1263,7 @@ static void *nr_info_next(struct seq_file *seq, void *v, loff_t *pos)
{
{
++*
pos
;
++*
pos
;
return
(
v
==
NETROM_PROC_START
)
?
sk_head
(
&
nr_list
)
return
(
v
==
SEQ_START_TOKEN
)
?
sk_head
(
&
nr_list
)
:
sk_next
((
struct
sock
*
)
v
);
:
sk_next
((
struct
sock
*
)
v
);
}
}
...
@@ -1281,7 +1279,7 @@ static int nr_info_show(struct seq_file *seq, void *v)
...
@@ -1281,7 +1279,7 @@ static int nr_info_show(struct seq_file *seq, void *v)
nr_cb
*
nr
;
nr_cb
*
nr
;
const
char
*
devname
;
const
char
*
devname
;
if
(
v
==
NETROM_PROC_START
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
seq_puts
(
seq
,
"user_addr dest_node src_node dev my your st vs vr va t1 t2 t4 idle n2 wnd Snd-Q Rcv-Q inode
\n
"
);
"user_addr dest_node src_node dev my your st vs vr va t1 t2 t4 idle n2 wnd Snd-Q Rcv-Q inode
\n
"
);
...
...
net/netrom/nr_route.c
View file @
d5787c80
...
@@ -841,7 +841,6 @@ int nr_route_frame(struct sk_buff *skb, ax25_cb *ax25)
...
@@ -841,7 +841,6 @@ int nr_route_frame(struct sk_buff *skb, ax25_cb *ax25)
}
}
#ifdef CONFIG_PROC_FS
#ifdef CONFIG_PROC_FS
#define NETROM_PROC_START ((void *) 1)
static
void
*
nr_node_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
static
void
*
nr_node_start
(
struct
seq_file
*
seq
,
loff_t
*
pos
)
{
{
...
@@ -851,7 +850,7 @@ static void *nr_node_start(struct seq_file *seq, loff_t *pos)
...
@@ -851,7 +850,7 @@ static void *nr_node_start(struct seq_file *seq, loff_t *pos)
spin_lock_bh
(
&
nr_node_list_lock
);
spin_lock_bh
(
&
nr_node_list_lock
);
if
(
*
pos
==
0
)
if
(
*
pos
==
0
)
return
NETROM_PROC_START
;
return
SEQ_START_TOKEN
;
nr_node_for_each
(
nr_node
,
node
,
&
nr_node_list
)
{
nr_node_for_each
(
nr_node
,
node
,
&
nr_node_list
)
{
if
(
i
==
*
pos
)
if
(
i
==
*
pos
)
...
@@ -867,7 +866,7 @@ static void *nr_node_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -867,7 +866,7 @@ static void *nr_node_next(struct seq_file *seq, void *v, loff_t *pos)
struct
hlist_node
*
node
;
struct
hlist_node
*
node
;
++*
pos
;
++*
pos
;
node
=
(
v
==
NETROM_PROC_START
)
node
=
(
v
==
SEQ_START_TOKEN
)
?
nr_node_list
.
first
?
nr_node_list
.
first
:
((
struct
nr_node
*
)
v
)
->
node_node
.
next
;
:
((
struct
nr_node
*
)
v
)
->
node_node
.
next
;
...
@@ -883,7 +882,7 @@ static int nr_node_show(struct seq_file *seq, void *v)
...
@@ -883,7 +882,7 @@ static int nr_node_show(struct seq_file *seq, void *v)
{
{
int
i
;
int
i
;
if
(
v
==
NETROM_PROC_START
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
seq_puts
(
seq
,
"callsign mnemonic w n qual obs neigh qual obs neigh qual obs neigh
\n
"
);
"callsign mnemonic w n qual obs neigh qual obs neigh qual obs neigh
\n
"
);
else
{
else
{
...
@@ -936,7 +935,7 @@ static void *nr_neigh_start(struct seq_file *seq, loff_t *pos)
...
@@ -936,7 +935,7 @@ static void *nr_neigh_start(struct seq_file *seq, loff_t *pos)
spin_lock_bh
(
&
nr_neigh_list_lock
);
spin_lock_bh
(
&
nr_neigh_list_lock
);
if
(
*
pos
==
0
)
if
(
*
pos
==
0
)
return
NETROM_PROC_START
;
return
SEQ_START_TOKEN
;
nr_neigh_for_each
(
nr_neigh
,
node
,
&
nr_neigh_list
)
{
nr_neigh_for_each
(
nr_neigh
,
node
,
&
nr_neigh_list
)
{
if
(
i
==
*
pos
)
if
(
i
==
*
pos
)
...
@@ -950,7 +949,7 @@ static void *nr_neigh_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -950,7 +949,7 @@ static void *nr_neigh_next(struct seq_file *seq, void *v, loff_t *pos)
struct
hlist_node
*
node
;
struct
hlist_node
*
node
;
++*
pos
;
++*
pos
;
node
=
(
v
==
NETROM_PROC_START
)
node
=
(
v
==
SEQ_START_TOKEN
)
?
nr_neigh_list
.
first
?
nr_neigh_list
.
first
:
((
struct
nr_neigh
*
)
v
)
->
neigh_node
.
next
;
:
((
struct
nr_neigh
*
)
v
)
->
neigh_node
.
next
;
...
@@ -966,7 +965,7 @@ static int nr_neigh_show(struct seq_file *seq, void *v)
...
@@ -966,7 +965,7 @@ static int nr_neigh_show(struct seq_file *seq, void *v)
{
{
int
i
;
int
i
;
if
(
v
==
NETROM_PROC_START
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
"addr callsign dev qual lock count failed digipeaters
\n
"
);
seq_puts
(
seq
,
"addr callsign dev qual lock count failed digipeaters
\n
"
);
else
{
else
{
struct
nr_neigh
*
nr_neigh
=
v
;
struct
nr_neigh
*
nr_neigh
=
v
;
...
...
net/rose/af_rose.c
View file @
d5787c80
...
@@ -1344,7 +1344,7 @@ static void *rose_info_start(struct seq_file *seq, loff_t *pos)
...
@@ -1344,7 +1344,7 @@ static void *rose_info_start(struct seq_file *seq, loff_t *pos)
spin_lock_bh
(
&
rose_list_lock
);
spin_lock_bh
(
&
rose_list_lock
);
if
(
*
pos
==
0
)
if
(
*
pos
==
0
)
return
ROSE_PROC_START
;
return
SEQ_START_TOKEN
;
i
=
1
;
i
=
1
;
sk_for_each
(
s
,
node
,
&
rose_list
)
{
sk_for_each
(
s
,
node
,
&
rose_list
)
{
...
@@ -1359,7 +1359,7 @@ static void *rose_info_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -1359,7 +1359,7 @@ static void *rose_info_next(struct seq_file *seq, void *v, loff_t *pos)
{
{
++*
pos
;
++*
pos
;
return
(
v
==
ROSE_PROC_START
)
?
sk_head
(
&
rose_list
)
return
(
v
==
SEQ_START_TOKEN
)
?
sk_head
(
&
rose_list
)
:
sk_next
((
struct
sock
*
)
v
);
:
sk_next
((
struct
sock
*
)
v
);
}
}
...
@@ -1370,7 +1370,7 @@ static void rose_info_stop(struct seq_file *seq, void *v)
...
@@ -1370,7 +1370,7 @@ static void rose_info_stop(struct seq_file *seq, void *v)
static
int
rose_info_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
rose_info_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
ROSE_PROC_START
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
seq_puts
(
seq
,
"dest_addr dest_call src_addr src_call dev lci neigh st vs vr va t t1 t2 t3 hb idle Snd-Q Rcv-Q inode
\n
"
);
"dest_addr dest_call src_addr src_call dev lci neigh st vs vr va t t1 t2 t3 hb idle Snd-Q Rcv-Q inode
\n
"
);
...
...
net/rose/rose_route.c
View file @
d5787c80
...
@@ -1076,7 +1076,7 @@ static void *rose_node_start(struct seq_file *seq, loff_t *pos)
...
@@ -1076,7 +1076,7 @@ static void *rose_node_start(struct seq_file *seq, loff_t *pos)
spin_lock_bh
(
&
rose_neigh_list_lock
);
spin_lock_bh
(
&
rose_neigh_list_lock
);
if
(
*
pos
==
0
)
if
(
*
pos
==
0
)
return
ROSE_PROC_START
;
return
SEQ_START_TOKEN
;
for
(
rose_node
=
rose_node_list
;
rose_node
&&
i
<
*
pos
;
for
(
rose_node
=
rose_node_list
;
rose_node
&&
i
<
*
pos
;
rose_node
=
rose_node
->
next
,
++
i
);
rose_node
=
rose_node
->
next
,
++
i
);
...
@@ -1088,7 +1088,7 @@ static void *rose_node_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -1088,7 +1088,7 @@ static void *rose_node_next(struct seq_file *seq, void *v, loff_t *pos)
{
{
++*
pos
;
++*
pos
;
return
(
v
==
ROSE_PROC_START
)
?
rose_node_list
return
(
v
==
SEQ_START_TOKEN
)
?
rose_node_list
:
((
struct
rose_node
*
)
v
)
->
next
;
:
((
struct
rose_node
*
)
v
)
->
next
;
}
}
...
@@ -1101,7 +1101,7 @@ static int rose_node_show(struct seq_file *seq, void *v)
...
@@ -1101,7 +1101,7 @@ static int rose_node_show(struct seq_file *seq, void *v)
{
{
int
i
;
int
i
;
if
(
v
==
ROSE_PROC_START
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
"address mask n neigh neigh neigh
\n
"
);
seq_puts
(
seq
,
"address mask n neigh neigh neigh
\n
"
);
else
{
else
{
const
struct
rose_node
*
rose_node
=
v
;
const
struct
rose_node
*
rose_node
=
v
;
...
@@ -1152,7 +1152,7 @@ static void *rose_neigh_start(struct seq_file *seq, loff_t *pos)
...
@@ -1152,7 +1152,7 @@ static void *rose_neigh_start(struct seq_file *seq, loff_t *pos)
spin_lock_bh
(
&
rose_neigh_list_lock
);
spin_lock_bh
(
&
rose_neigh_list_lock
);
if
(
*
pos
==
0
)
if
(
*
pos
==
0
)
return
ROSE_PROC_START
;
return
SEQ_START_TOKEN
;
for
(
rose_neigh
=
rose_neigh_list
;
rose_neigh
&&
i
<
*
pos
;
for
(
rose_neigh
=
rose_neigh_list
;
rose_neigh
&&
i
<
*
pos
;
rose_neigh
=
rose_neigh
->
next
,
++
i
);
rose_neigh
=
rose_neigh
->
next
,
++
i
);
...
@@ -1164,7 +1164,7 @@ static void *rose_neigh_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -1164,7 +1164,7 @@ static void *rose_neigh_next(struct seq_file *seq, void *v, loff_t *pos)
{
{
++*
pos
;
++*
pos
;
return
(
v
==
ROSE_PROC_START
)
?
rose_neigh_list
return
(
v
==
SEQ_START_TOKEN
)
?
rose_neigh_list
:
((
struct
rose_neigh
*
)
v
)
->
next
;
:
((
struct
rose_neigh
*
)
v
)
->
next
;
}
}
...
@@ -1177,7 +1177,7 @@ static int rose_neigh_show(struct seq_file *seq, void *v)
...
@@ -1177,7 +1177,7 @@ static int rose_neigh_show(struct seq_file *seq, void *v)
{
{
int
i
;
int
i
;
if
(
v
==
ROSE_PROC_START
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
seq_puts
(
seq
,
"addr callsign dev count use mode restart t0 tf digipeaters
\n
"
);
"addr callsign dev count use mode restart t0 tf digipeaters
\n
"
);
else
{
else
{
...
@@ -1234,7 +1234,7 @@ static void *rose_route_start(struct seq_file *seq, loff_t *pos)
...
@@ -1234,7 +1234,7 @@ static void *rose_route_start(struct seq_file *seq, loff_t *pos)
spin_lock_bh
(
&
rose_route_list_lock
);
spin_lock_bh
(
&
rose_route_list_lock
);
if
(
*
pos
==
0
)
if
(
*
pos
==
0
)
return
ROSE_PROC_START
;
return
SEQ_START_TOKEN
;
for
(
rose_route
=
rose_route_list
;
rose_route
&&
i
<
*
pos
;
for
(
rose_route
=
rose_route_list
;
rose_route
&&
i
<
*
pos
;
rose_route
=
rose_route
->
next
,
++
i
);
rose_route
=
rose_route
->
next
,
++
i
);
...
@@ -1246,7 +1246,7 @@ static void *rose_route_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -1246,7 +1246,7 @@ static void *rose_route_next(struct seq_file *seq, void *v, loff_t *pos)
{
{
++*
pos
;
++*
pos
;
return
(
v
==
ROSE_PROC_START
)
?
rose_route_list
return
(
v
==
SEQ_START_TOKEN
)
?
rose_route_list
:
((
struct
rose_route
*
)
v
)
->
next
;
:
((
struct
rose_route
*
)
v
)
->
next
;
}
}
...
@@ -1257,7 +1257,7 @@ static void rose_route_stop(struct seq_file *seq, void *v)
...
@@ -1257,7 +1257,7 @@ static void rose_route_stop(struct seq_file *seq, void *v)
static
int
rose_route_show
(
struct
seq_file
*
seq
,
void
*
v
)
static
int
rose_route_show
(
struct
seq_file
*
seq
,
void
*
v
)
{
{
if
(
v
==
ROSE_PROC_START
)
if
(
v
==
SEQ_START_TOKEN
)
seq_puts
(
seq
,
seq_puts
(
seq
,
"lci address callsign neigh <-> lci address callsign neigh
\n
"
);
"lci address callsign neigh <-> lci address callsign neigh
\n
"
);
else
{
else
{
...
...
net/sunrpc/cache.c
View file @
d5787c80
...
@@ -1035,7 +1035,7 @@ static void *c_start(struct seq_file *m, loff_t *pos)
...
@@ -1035,7 +1035,7 @@ static void *c_start(struct seq_file *m, loff_t *pos)
read_lock
(
&
cd
->
hash_lock
);
read_lock
(
&
cd
->
hash_lock
);
if
(
!
n
--
)
if
(
!
n
--
)
return
(
void
*
)
1
;
return
SEQ_START_TOKEN
;
hash
=
n
>>
32
;
hash
=
n
>>
32
;
entry
=
n
&
((
1LL
<<
32
)
-
1
);
entry
=
n
&
((
1LL
<<
32
)
-
1
);
...
@@ -1060,7 +1060,7 @@ static void *c_next(struct seq_file *m, void *p, loff_t *pos)
...
@@ -1060,7 +1060,7 @@ static void *c_next(struct seq_file *m, void *p, loff_t *pos)
int
hash
=
(
*
pos
>>
32
);
int
hash
=
(
*
pos
>>
32
);
struct
cache_detail
*
cd
=
((
struct
handle
*
)
m
->
private
)
->
cd
;
struct
cache_detail
*
cd
=
((
struct
handle
*
)
m
->
private
)
->
cd
;
if
(
p
==
(
void
*
)
1
)
if
(
p
==
SEQ_START_TOKEN
)
hash
=
0
;
hash
=
0
;
else
if
(
ch
->
next
==
NULL
)
{
else
if
(
ch
->
next
==
NULL
)
{
hash
++
;
hash
++
;
...
@@ -1092,7 +1092,7 @@ static int c_show(struct seq_file *m, void *p)
...
@@ -1092,7 +1092,7 @@ static int c_show(struct seq_file *m, void *p)
struct
cache_head
*
cp
=
p
;
struct
cache_head
*
cp
=
p
;
struct
cache_detail
*
cd
=
((
struct
handle
*
)
m
->
private
)
->
cd
;
struct
cache_detail
*
cd
=
((
struct
handle
*
)
m
->
private
)
->
cd
;
if
(
p
==
(
void
*
)
1
)
if
(
p
==
SEQ_START_TOKEN
)
return
cd
->
cache_show
(
m
,
cd
,
NULL
);
return
cd
->
cache_show
(
m
,
cd
,
NULL
);
ifdebug
(
CACHE
)
ifdebug
(
CACHE
)
...
...
net/wanrouter/wanproc.c
View file @
d5787c80
...
@@ -86,7 +86,7 @@ static void *r_start(struct seq_file *m, loff_t *pos)
...
@@ -86,7 +86,7 @@ static void *r_start(struct seq_file *m, loff_t *pos)
lock_kernel
();
lock_kernel
();
if
(
!
l
--
)
if
(
!
l
--
)
return
(
void
*
)
1
;
return
SEQ_START_TOKEN
;
for
(
wandev
=
wanrouter_router_devlist
;
l
--
&&
wandev
;
for
(
wandev
=
wanrouter_router_devlist
;
l
--
&&
wandev
;
wandev
=
wandev
->
next
)
wandev
=
wandev
->
next
)
;
;
...
@@ -97,7 +97,7 @@ static void *r_next(struct seq_file *m, void *v, loff_t *pos)
...
@@ -97,7 +97,7 @@ static void *r_next(struct seq_file *m, void *v, loff_t *pos)
{
{
struct
wan_device
*
wandev
=
v
;
struct
wan_device
*
wandev
=
v
;
(
*
pos
)
++
;
(
*
pos
)
++
;
return
(
v
==
(
void
*
)
1
)
?
wanrouter_router_devlist
:
wandev
->
next
;
return
(
v
==
SEQ_START_TOKEN
)
?
wanrouter_router_devlist
:
wandev
->
next
;
}
}
static
void
r_stop
(
struct
seq_file
*
m
,
void
*
v
)
static
void
r_stop
(
struct
seq_file
*
m
,
void
*
v
)
...
@@ -108,7 +108,7 @@ static void r_stop(struct seq_file *m, void *v)
...
@@ -108,7 +108,7 @@ static void r_stop(struct seq_file *m, void *v)
static
int
config_show
(
struct
seq_file
*
m
,
void
*
v
)
static
int
config_show
(
struct
seq_file
*
m
,
void
*
v
)
{
{
struct
wan_device
*
p
=
v
;
struct
wan_device
*
p
=
v
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_puts
(
m
,
"Device name | port |IRQ|DMA| mem.addr |"
seq_puts
(
m
,
"Device name | port |IRQ|DMA| mem.addr |"
"mem.size|option1|option2|option3|option4
\n
"
);
"mem.size|option1|option2|option3|option4
\n
"
);
return
0
;
return
0
;
...
@@ -124,7 +124,7 @@ static int config_show(struct seq_file *m, void *v)
...
@@ -124,7 +124,7 @@ static int config_show(struct seq_file *m, void *v)
static
int
status_show
(
struct
seq_file
*
m
,
void
*
v
)
static
int
status_show
(
struct
seq_file
*
m
,
void
*
v
)
{
{
struct
wan_device
*
p
=
v
;
struct
wan_device
*
p
=
v
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_puts
(
m
,
"Device name |protocol|station|interface|"
seq_puts
(
m
,
"Device name |protocol|station|interface|"
"clocking|baud rate| MTU |ndev|link state
\n
"
);
"clocking|baud rate| MTU |ndev|link state
\n
"
);
return
0
;
return
0
;
...
...
net/x25/x25_proc.c
View file @
d5787c80
...
@@ -44,7 +44,7 @@ static void *x25_seq_route_start(struct seq_file *seq, loff_t *pos)
...
@@ -44,7 +44,7 @@ static void *x25_seq_route_start(struct seq_file *seq, loff_t *pos)
loff_t
l
=
*
pos
;
loff_t
l
=
*
pos
;
read_lock_bh
(
&
x25_route_list_lock
);
read_lock_bh
(
&
x25_route_list_lock
);
return
l
?
x25_get_route_idx
(
--
l
)
:
(
void
*
)
1
;
return
l
?
x25_get_route_idx
(
--
l
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
x25_seq_route_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
x25_seq_route_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -52,7 +52,7 @@ static void *x25_seq_route_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -52,7 +52,7 @@ static void *x25_seq_route_next(struct seq_file *seq, void *v, loff_t *pos)
struct
x25_route
*
rt
;
struct
x25_route
*
rt
;
++*
pos
;
++*
pos
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
rt
=
NULL
;
rt
=
NULL
;
if
(
!
list_empty
(
&
x25_route_list
))
if
(
!
list_empty
(
&
x25_route_list
))
rt
=
list_entry
(
x25_route_list
.
next
,
rt
=
list_entry
(
x25_route_list
.
next
,
...
@@ -77,7 +77,7 @@ static int x25_seq_route_show(struct seq_file *seq, void *v)
...
@@ -77,7 +77,7 @@ static int x25_seq_route_show(struct seq_file *seq, void *v)
{
{
struct
x25_route
*
rt
;
struct
x25_route
*
rt
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_puts
(
seq
,
"Address Digits Device
\n
"
);
seq_puts
(
seq
,
"Address Digits Device
\n
"
);
goto
out
;
goto
out
;
}
}
...
@@ -108,7 +108,7 @@ static void *x25_seq_socket_start(struct seq_file *seq, loff_t *pos)
...
@@ -108,7 +108,7 @@ static void *x25_seq_socket_start(struct seq_file *seq, loff_t *pos)
loff_t
l
=
*
pos
;
loff_t
l
=
*
pos
;
read_lock_bh
(
&
x25_list_lock
);
read_lock_bh
(
&
x25_list_lock
);
return
l
?
x25_get_socket_idx
(
--
l
)
:
(
void
*
)
1
;
return
l
?
x25_get_socket_idx
(
--
l
)
:
SEQ_START_TOKEN
;
}
}
static
void
*
x25_seq_socket_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
static
void
*
x25_seq_socket_next
(
struct
seq_file
*
seq
,
void
*
v
,
loff_t
*
pos
)
...
@@ -116,7 +116,7 @@ static void *x25_seq_socket_next(struct seq_file *seq, void *v, loff_t *pos)
...
@@ -116,7 +116,7 @@ static void *x25_seq_socket_next(struct seq_file *seq, void *v, loff_t *pos)
struct
sock
*
s
;
struct
sock
*
s
;
++*
pos
;
++*
pos
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
s
=
sk_head
(
&
x25_list
);
s
=
sk_head
(
&
x25_list
);
goto
out
;
goto
out
;
}
}
...
@@ -137,7 +137,7 @@ static int x25_seq_socket_show(struct seq_file *seq, void *v)
...
@@ -137,7 +137,7 @@ static int x25_seq_socket_show(struct seq_file *seq, void *v)
struct
net_device
*
dev
;
struct
net_device
*
dev
;
const
char
*
devname
;
const
char
*
devname
;
if
(
v
==
(
void
*
)
1
)
{
if
(
v
==
SEQ_START_TOKEN
)
{
seq_printf
(
seq
,
"dest_addr src_addr dev lci st vs vr "
seq_printf
(
seq
,
"dest_addr src_addr dev lci st vs vr "
"va t t2 t21 t22 t23 Snd-Q Rcv-Q inode
\n
"
);
"va t t2 t21 t22 t23 Snd-Q Rcv-Q inode
\n
"
);
goto
out
;
goto
out
;
...
...
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