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
b0bbff6c
Commit
b0bbff6c
authored
Oct 21, 2002
by
Jeff Garzik
Browse files
Options
Browse Files
Download
Plain Diff
Merge
http://suncobalt.bkbits.net/net-drivers-2.5
into redhat.com:/home/jgarzik/repo/net-drivers-2.5
parents
5619f4c9
755aedd7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
38 deletions
+26
-38
drivers/net/eepro100.c
drivers/net/eepro100.c
+26
-38
No files found.
drivers/net/eepro100.c
View file @
b0bbff6c
...
...
@@ -122,8 +122,7 @@ static int options[] = {-1, -1, -1, -1, -1, -1, -1, -1};
static
int
debug
=
-
1
;
#define DEBUG_DEFAULT (NETIF_MSG_DRV | \
NETIF_MSG_IFDOWN | \
NETIF_MSG_IFUP | \
NETIF_MSG_HW | \
NETIF_MSG_RX_ERR | \
NETIF_MSG_TX_ERR)
#define DEBUG ((debug >= 0) ? (1<<debug)-1 : DEBUG_DEFAULT)
...
...
@@ -568,10 +567,8 @@ static inline unsigned char wait_for_cmd_done(struct net_device *dev)
r
=
inb
(
cmd_ioaddr
);
}
while
(
r
&&
--
wait
>=
0
);
#ifndef final_version
if
(
wait
<
0
)
printk
(
KERN_ALERT
"%s: wait_for_cmd_done timeout!
\n
"
,
dev
->
name
);
#endif
return
r
;
}
...
...
@@ -1207,7 +1204,7 @@ static void speedo_timer(unsigned long data)
/* We haven't received a packet in a Long Time. We might have been
bitten by the receiver hang bug. This can be cleared by sending
a set multicast list command. */
if
(
netif_msg_
rx_er
r
(
sp
))
if
(
netif_msg_
time
r
(
sp
))
printk
(
KERN_DEBUG
"%s: Sending a multicast list set command"
" from a timer routine,"
" m=%d, j=%ld, l=%ld.
\n
"
,
...
...
@@ -1224,25 +1221,26 @@ static void speedo_show_state(struct net_device *dev)
struct
speedo_private
*
sp
=
(
struct
speedo_private
*
)
dev
->
priv
;
int
i
;
/* Print a few items for debugging. */
printk
(
KERN_DEBUG
"%s: Tx ring dump, Tx queue %u / %u:
\n
"
,
dev
->
name
,
sp
->
cur_tx
,
sp
->
dirty_tx
);
for
(
i
=
0
;
i
<
TX_RING_SIZE
;
i
++
)
printk
(
KERN_DEBUG
"%s: %c%c%2d %8.8x.
\n
"
,
dev
->
name
,
i
==
sp
->
dirty_tx
%
TX_RING_SIZE
?
'*'
:
' '
,
i
==
sp
->
cur_tx
%
TX_RING_SIZE
?
'='
:
' '
,
i
,
sp
->
tx_ring
[
i
].
status
);
printk
(
KERN_DEBUG
"%s: Printing Rx ring"
" (next to receive into %u, dirty index %u).
\n
"
,
dev
->
name
,
sp
->
cur_rx
,
sp
->
dirty_rx
);
for
(
i
=
0
;
i
<
RX_RING_SIZE
;
i
++
)
printk
(
KERN_DEBUG
"%s: %c%c%c%2d %8.8x.
\n
"
,
dev
->
name
,
sp
->
rx_ringp
[
i
]
==
sp
->
last_rxf
?
'l'
:
' '
,
i
==
sp
->
dirty_rx
%
RX_RING_SIZE
?
'*'
:
' '
,
i
==
sp
->
cur_rx
%
RX_RING_SIZE
?
'='
:
' '
,
i
,
(
sp
->
rx_ringp
[
i
]
!=
NULL
)
?
(
unsigned
)
sp
->
rx_ringp
[
i
]
->
status
:
0
);
if
(
netif_msg_pktdata
(
sp
))
{
printk
(
KERN_DEBUG
"%s: Tx ring dump, Tx queue %u / %u:
\n
"
,
dev
->
name
,
sp
->
cur_tx
,
sp
->
dirty_tx
);
for
(
i
=
0
;
i
<
TX_RING_SIZE
;
i
++
)
printk
(
KERN_DEBUG
"%s: %c%c%2d %8.8x.
\n
"
,
dev
->
name
,
i
==
sp
->
dirty_tx
%
TX_RING_SIZE
?
'*'
:
' '
,
i
==
sp
->
cur_tx
%
TX_RING_SIZE
?
'='
:
' '
,
i
,
sp
->
tx_ring
[
i
].
status
);
printk
(
KERN_DEBUG
"%s: Printing Rx ring"
" (next to receive into %u, dirty index %u).
\n
"
,
dev
->
name
,
sp
->
cur_rx
,
sp
->
dirty_rx
);
for
(
i
=
0
;
i
<
RX_RING_SIZE
;
i
++
)
printk
(
KERN_DEBUG
"%s: %c%c%c%2d %8.8x.
\n
"
,
dev
->
name
,
sp
->
rx_ringp
[
i
]
==
sp
->
last_rxf
?
'l'
:
' '
,
i
==
sp
->
dirty_rx
%
RX_RING_SIZE
?
'*'
:
' '
,
i
==
sp
->
cur_rx
%
RX_RING_SIZE
?
'='
:
' '
,
i
,
(
sp
->
rx_ringp
[
i
]
!=
NULL
)
?
(
unsigned
)
sp
->
rx_ringp
[
i
]
->
status
:
0
);
}
#if 0
{
...
...
@@ -1378,8 +1376,8 @@ static void speedo_tx_timeout(struct net_device *dev)
sp
->
dirty_tx
,
sp
->
cur_tx
,
sp
->
tx_ring
[
sp
->
dirty_tx
%
TX_RING_SIZE
].
status
);
speedo_show_state
(
dev
);
}
speedo_show_state
(
dev
);
#if 0
if ((status & 0x00C0) != 0x0080
&& (status & 0x003C) == 0x0010) {
...
...
@@ -1564,13 +1562,6 @@ static void speedo_interrupt(int irq, void *dev_instance, struct pt_regs *regs)
long
ioaddr
,
boguscnt
=
max_interrupt_work
;
unsigned
short
status
;
#ifndef final_version
if
(
dev
==
NULL
)
{
printk
(
KERN_ERR
"speedo_interrupt(): irq %d for unknown device.
\n
"
,
irq
);
return
;
}
#endif
ioaddr
=
dev
->
base_addr
;
sp
=
(
struct
speedo_private
*
)
dev
->
priv
;
...
...
@@ -1717,9 +1708,9 @@ static int speedo_refill_rx_buf(struct net_device *dev, int force)
if
(
netif_msg_rx_err
(
sp
)
||
!
(
sp
->
rx_ring_state
&
RrOOMReported
))
{
printk
(
KERN_WARNING
"%s: can't fill rx buffer (force %d)!
\n
"
,
dev
->
name
,
force
);
speedo_show_state
(
dev
);
sp
->
rx_ring_state
|=
RrOOMReported
;
}
speedo_show_state
(
dev
);
if
(
!
force
)
return
-
1
;
/* Better luck next time! */
/* Borrow an skb from one of next entries. */
...
...
@@ -1792,7 +1783,7 @@ speedo_rx(struct net_device *dev)
break
;
}
if
(
netif_msg_
intr
(
sp
))
if
(
netif_msg_
rx_status
(
sp
))
printk
(
KERN_DEBUG
" speedo_rx() status %8.8x len %d.
\n
"
,
status
,
pkt_len
);
if
((
status
&
(
RxErrTooBig
|
RxOK
|
0x0f90
))
!=
RxOK
)
{
...
...
@@ -1894,10 +1885,7 @@ speedo_close(struct net_device *dev)
udelay
(
10
);
free_irq
(
dev
->
irq
,
dev
);
/* Print a few items for debugging. */
if
(
netif_msg_ifdown
(
sp
))
speedo_show_state
(
dev
);
speedo_show_state
(
dev
);
/* Free all the skbuffs in the Rx and Tx queues. */
for
(
i
=
0
;
i
<
RX_RING_SIZE
;
i
++
)
{
...
...
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