Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linux
linux-davinci
Commits
4099e012
Commit
4099e012
authored
Mar 29, 2009
by
David S. Miller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
niu: Add GRO support.
Signed-off-by:
David S. Miller
<
davem@davemloft.net
>
parent
129dd967
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
drivers/net/niu.c
drivers/net/niu.c
+7
-5
No files found.
drivers/net/niu.c
View file @
4099e012
...
...
@@ -3441,7 +3441,8 @@ static int niu_rx_pkt_ignore(struct niu *np, struct rx_ring_info *rp)
return
num_rcr
;
}
static
int
niu_process_rx_pkt
(
struct
niu
*
np
,
struct
rx_ring_info
*
rp
)
static
int
niu_process_rx_pkt
(
struct
napi_struct
*
napi
,
struct
niu
*
np
,
struct
rx_ring_info
*
rp
)
{
unsigned
int
index
=
rp
->
rcr_index
;
struct
sk_buff
*
skb
;
...
...
@@ -3518,7 +3519,7 @@ static int niu_process_rx_pkt(struct niu *np, struct rx_ring_info *rp)
skb
->
protocol
=
eth_type_trans
(
skb
,
np
->
dev
);
skb_record_rx_queue
(
skb
,
rp
->
rx_channel
);
n
etif_receive_skb
(
skb
);
n
api_gro_receive
(
napi
,
skb
);
return
num_rcr
;
}
...
...
@@ -3706,7 +3707,8 @@ static inline void niu_sync_rx_discard_stats(struct niu *np,
}
}
static
int
niu_rx_work
(
struct
niu
*
np
,
struct
rx_ring_info
*
rp
,
int
budget
)
static
int
niu_rx_work
(
struct
napi_struct
*
napi
,
struct
niu
*
np
,
struct
rx_ring_info
*
rp
,
int
budget
)
{
int
qlen
,
rcr_done
=
0
,
work_done
=
0
;
struct
rxdma_mailbox
*
mbox
=
rp
->
mbox
;
...
...
@@ -3728,7 +3730,7 @@ static int niu_rx_work(struct niu *np, struct rx_ring_info *rp, int budget)
rcr_done
=
work_done
=
0
;
qlen
=
min
(
qlen
,
budget
);
while
(
work_done
<
qlen
)
{
rcr_done
+=
niu_process_rx_pkt
(
np
,
rp
);
rcr_done
+=
niu_process_rx_pkt
(
n
api
,
n
p
,
rp
);
work_done
++
;
}
...
...
@@ -3776,7 +3778,7 @@ static int niu_poll_core(struct niu *np, struct niu_ldg *lp, int budget)
if
(
rx_vec
&
(
1
<<
rp
->
rx_channel
))
{
int
this_work_done
;
this_work_done
=
niu_rx_work
(
np
,
rp
,
this_work_done
=
niu_rx_work
(
&
lp
->
napi
,
np
,
rp
,
budget
);
budget
-=
this_work_done
;
...
...
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