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
e74cba9e
Commit
e74cba9e
authored
Sep 12, 2002
by
David S. Miller
Browse files
Options
Browse Files
Download
Plain Diff
Merge nuts.ninka.net:/home/davem/src/BK/network-2.5
into nuts.ninka.net:/home/davem/src/BK/net-2.5
parents
c39f7320
ec7ccb4c
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
861 additions
and
157 deletions
+861
-157
drivers/net/tg3.c
drivers/net/tg3.c
+801
-137
drivers/net/tg3.h
drivers/net/tg3.h
+23
-10
net/8021q/vlan.c
net/8021q/vlan.c
+1
-1
net/core/dev.c
net/core/dev.c
+6
-4
net/ipv4/tcp_input.c
net/ipv4/tcp_input.c
+30
-5
No files found.
drivers/net/tg3.c
View file @
e74cba9e
This diff is collapsed.
Click to expand it.
drivers/net/tg3.h
View file @
e74cba9e
...
...
@@ -1248,14 +1248,19 @@
#define NIC_SRAM_DATA_SIG_MAGIC 0x4b657654
/* ascii for 'KevT' */
#define NIC_SRAM_DATA_CFG 0x00000b58
#define NIC_SRAM_DATA_CFG_PHY_TYPE_MASK 0x0000000c
#define NIC_SRAM_DATA_CFG_PHY_TYPE_UNKNOWN 0x00000000
#define NIC_SRAM_DATA_CFG_PHY_TYPE_COPPER 0x00000004
#define NIC_SRAM_DATA_CFG_PHY_TYPE_FIBER 0x00000008
#define NIC_SRAM_DATA_CFG_LED_MODE_MASK 0x00000030
#define NIC_SRAM_DATA_CFG_LED_MODE_MASK 0x0000000c
#define NIC_SRAM_DATA_CFG_LED_MODE_UNKNOWN 0x00000000
#define NIC_SRAM_DATA_CFG_LED_TRIPLE_SPD 0x00000010
#define NIC_SRAM_DATA_CFG_LED_LINK_SPD 0x00000020
#define NIC_SRAM_DATA_CFG_LED_TRIPLE_SPD 0x00000004
#define NIC_SRAM_DATA_CFG_LED_OPEN_DRAIN 0x00000004
#define NIC_SRAM_DATA_CFG_LED_LINK_SPD 0x00000008
#define NIC_SRAM_DATA_CFG_LED_OUTPUT 0x00000008
#define NIC_SRAM_DATA_CFG_PHY_TYPE_MASK 0x00000030
#define NIC_SRAM_DATA_CFG_PHY_TYPE_UNKNOWN 0x00000000
#define NIC_SRAM_DATA_CFG_PHY_TYPE_COPPER 0x00000010
#define NIC_SRAM_DATA_CFG_PHY_TYPE_FIBER 0x00000020
#define NIC_SRAM_DATA_CFG_WOL_ENABLE 0x00000040
#define NIC_SRAM_DATA_CFG_ASF_ENABLE 0x00000080
#define NIC_SRAM_DATA_CFG_EEPROM_WP 0x00000100
#define NIC_SRAM_DATA_PHY_ID 0x00000b74
#define NIC_SRAM_DATA_PHY_ID1_MASK 0xffff0000
...
...
@@ -1410,6 +1415,7 @@ struct tg3_tx_buffer_desc {
u32
vlan_tag
;
#define TXD_VLAN_TAG_SHIFT 0
#define TXD_MSS_SHIFT 16
};
#define TXD_ADDR 0x00UL
/* 64-bit */
...
...
@@ -1660,6 +1666,12 @@ struct ring_info {
DECLARE_PCI_UNMAP_ADDR
(
mapping
)
};
struct
tx_ring_info
{
struct
sk_buff
*
skb
;
DECLARE_PCI_UNMAP_ADDR
(
mapping
)
u32
prev_vlan_tag
;
};
struct
tg3_config_info
{
u32
flags
;
};
...
...
@@ -1738,10 +1750,11 @@ struct tg3 {
#define TG3_FLAG_USE_LINKCHG_REG 0x00000008
#define TG3_FLAG_USE_MI_INTERRUPT 0x00000010
#define TG3_FLAG_POLL_SERDES 0x00000080
#define TG3_FLAG_
PHY_RESET_ON_INIT
0x00000100
#define TG3_FLAG_
MBOX_WRITE_REORDER
0x00000100
#define TG3_FLAG_PCIX_TARGET_HWBUG 0x00000200
#define TG3_FLAG_WOL_SPEED_100MB 0x00000400
#define TG3_FLAG_WOL_ENABLE 0x00001000
#define TG3_FLAG_WOL_ENABLE 0x00000800
#define TG3_FLAG_EEPROM_WRITE_PROT 0x00001000
#define TG3_FLAG_NVRAM 0x00002000
#define TG3_FLAG_NVRAM_BUFFERED 0x00004000
#define TG3_FLAG_RX_PAUSE 0x00008000
...
...
@@ -1853,7 +1866,7 @@ struct tg3 {
/* TX descs are only used if TG3_FLAG_HOST_TXDS is set. */
struct
tg3_tx_buffer_desc
*
tx_ring
;
struct
ring_info
*
tx_buffers
;
struct
tx_
ring_info
*
tx_buffers
;
dma_addr_t
tx_desc_mapping
;
struct
tg3_hw_status
*
hw_status
;
...
...
net/8021q/vlan.c
View file @
e74cba9e
...
...
@@ -626,7 +626,7 @@ static int vlan_device_event(struct notifier_block *unused, unsigned long event,
ret
=
unregister_vlan_dev
(
dev
,
VLAN_DEV_INFO
(
vlandev
)
->
vlan_id
);
unregister_netdev
(
vlandev
);
unregister_netdev
ice
(
vlandev
);
/* Group was destroyed? */
if
(
ret
==
1
)
...
...
net/core/dev.c
View file @
e74cba9e
...
...
@@ -694,10 +694,14 @@ int dev_open(struct net_device *dev)
* Call device private open method
*/
if
(
try_inc_mod_count
(
dev
->
owner
))
{
set_bit
(
__LINK_STATE_START
,
&
dev
->
state
);
if
(
dev
->
open
)
{
ret
=
dev
->
open
(
dev
);
if
(
ret
&&
dev
->
owner
)
__MOD_DEC_USE_COUNT
(
dev
->
owner
);
if
(
ret
)
{
clear_bit
(
__LINK_STATE_START
,
&
dev
->
state
);
if
(
dev
->
owner
)
__MOD_DEC_USE_COUNT
(
dev
->
owner
);
}
}
}
else
{
ret
=
-
ENODEV
;
...
...
@@ -713,8 +717,6 @@ int dev_open(struct net_device *dev)
*/
dev
->
flags
|=
IFF_UP
;
set_bit
(
__LINK_STATE_START
,
&
dev
->
state
);
/*
* Initialize multicasting status
*/
...
...
net/ipv4/tcp_input.c
View file @
e74cba9e
...
...
@@ -3289,17 +3289,24 @@ int tcp_rcv_established(struct sock *sk, struct sk_buff *skb,
if
((
s32
)(
tp
->
rcv_tsval
-
tp
->
ts_recent
)
<
0
)
goto
slow_path
;
/* Predicted packet is in window by definition.
* seq == rcv_nxt and rcv_wup <= rcv_nxt.
* Hence, check seq<=rcv_wup reduces to:
/* DO NOT update ts_recent here, if checksum fails
* and timestamp was corrupted part, it will result
* in a hung connection since we will drop all
* future packets due to the PAWS test.
*/
if
(
tp
->
rcv_nxt
==
tp
->
rcv_wup
)
tcp_store_ts_recent
(
tp
);
}
if
(
len
<=
tcp_header_len
)
{
/* Bulk data transfer: sender */
if
(
len
==
tcp_header_len
)
{
/* Predicted packet is in window by definition.
* seq == rcv_nxt and rcv_wup <= rcv_nxt.
* Hence, check seq<=rcv_wup reduces to:
*/
if
(
tcp_header_len
==
(
sizeof
(
struct
tcphdr
)
+
TCPOLEN_TSTAMP_ALIGNED
)
&&
tp
->
rcv_nxt
==
tp
->
rcv_wup
)
tcp_store_ts_recent
(
tp
);
/* We know that such packets are checksummed
* on entry.
*/
...
...
@@ -3325,12 +3332,30 @@ int tcp_rcv_established(struct sock *sk, struct sk_buff *skb,
tp
->
rcv_nxt
=
TCP_SKB_CB
(
skb
)
->
end_seq
;
NET_INC_STATS_BH
(
TCPHPHitsToUser
);
eaten
=
1
;
/* Predicted packet is in window by definition.
* seq == rcv_nxt and rcv_wup <= rcv_nxt.
* Hence, check seq<=rcv_wup reduces to:
*/
if
(
tcp_header_len
==
(
sizeof
(
struct
tcphdr
)
+
TCPOLEN_TSTAMP_ALIGNED
)
&&
tp
->
rcv_nxt
==
tp
->
rcv_wup
)
tcp_store_ts_recent
(
tp
);
}
}
if
(
!
eaten
)
{
if
(
tcp_checksum_complete_user
(
sk
,
skb
))
goto
csum_error
;
/* Predicted packet is in window by definition.
* seq == rcv_nxt and rcv_wup <= rcv_nxt.
* Hence, check seq<=rcv_wup reduces to:
*/
if
(
tcp_header_len
==
(
sizeof
(
struct
tcphdr
)
+
TCPOLEN_TSTAMP_ALIGNED
)
&&
tp
->
rcv_nxt
==
tp
->
rcv_wup
)
tcp_store_ts_recent
(
tp
);
if
((
int
)
skb
->
truesize
>
sk
->
forward_alloc
)
goto
step5
;
...
...
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