LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH][I/OAT]: Remove duplicate assignation in dma_skb_copy_datagram_iovec
@ 2008-02-13 21:05 Brice Goglin
2008-02-14 1:02 ` Dan Williams
2008-02-14 2:29 ` Nelson, Shannon
0 siblings, 2 replies; 3+ messages in thread
From: Brice Goglin @ 2008-02-13 21:05 UTC (permalink / raw)
To: shannon.nelson, dan.j.williams; +Cc: Chris Leech, LKML
[I/OAT]: Remove duplicate assignation in dma_skb_copy_datagram_iovec
No need to compute copy twice in the frags loop in
dma_skb_copy_datagram_iovec().
Signed-off-by: Brice Goglin <Brice.Goglin@inria.fr>
---
user_dma.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/core/user_dma.c b/net/core/user_dma.c
index 0ad1cd5..c77aff9 100644
--- a/net/core/user_dma.c
+++ b/net/core/user_dma.c
@@ -75,7 +75,7 @@ int dma_skb_copy_datagram_iovec(struct dma_chan *chan,
end = start + skb_shinfo(skb)->frags[i].size;
copy = end - offset;
- if ((copy = end - offset) > 0) {
+ if (copy > 0) {
skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
struct page *page = frag->page;
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH][I/OAT]: Remove duplicate assignation in dma_skb_copy_datagram_iovec
2008-02-13 21:05 [PATCH][I/OAT]: Remove duplicate assignation in dma_skb_copy_datagram_iovec Brice Goglin
@ 2008-02-14 1:02 ` Dan Williams
2008-02-14 2:29 ` Nelson, Shannon
1 sibling, 0 replies; 3+ messages in thread
From: Dan Williams @ 2008-02-14 1:02 UTC (permalink / raw)
To: Brice Goglin; +Cc: shannon.nelson, Chris Leech, LKML
On Feb 13, 2008 2:05 PM, Brice Goglin <Brice.Goglin@inria.fr> wrote:
> [I/OAT]: Remove duplicate assignation in dma_skb_copy_datagram_iovec
>
> No need to compute copy twice in the frags loop in
> dma_skb_copy_datagram_iovec().
>
> Signed-off-by: Brice Goglin <Brice.Goglin@inria.fr>
Thanks, I'll push this along.
--
Dan
^ permalink raw reply [flat|nested] 3+ messages in thread
* RE: [PATCH][I/OAT]: Remove duplicate assignation in dma_skb_copy_datagram_iovec
2008-02-13 21:05 [PATCH][I/OAT]: Remove duplicate assignation in dma_skb_copy_datagram_iovec Brice Goglin
2008-02-14 1:02 ` Dan Williams
@ 2008-02-14 2:29 ` Nelson, Shannon
1 sibling, 0 replies; 3+ messages in thread
From: Nelson, Shannon @ 2008-02-14 2:29 UTC (permalink / raw)
To: Brice Goglin, Williams, Dan J; +Cc: Leech, Christopher, LKML
>-----Original Message-----
>From: Brice Goglin [mailto:Brice.Goglin@inria.fr]
>Sent: Wednesday, February 13, 2008 1:05 PM
>To: Nelson, Shannon; Williams, Dan J
>Cc: Leech, Christopher; LKML
>Subject: [PATCH][I/OAT]: Remove duplicate assignation in
>dma_skb_copy_datagram_iovec
>
>[I/OAT]: Remove duplicate assignation in dma_skb_copy_datagram_iovec
>
>No need to compute copy twice in the frags loop in
>dma_skb_copy_datagram_iovec().
>
>Signed-off-by: Brice Goglin <Brice.Goglin@inria.fr>
>---
> user_dma.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
>diff --git a/net/core/user_dma.c b/net/core/user_dma.c
>index 0ad1cd5..c77aff9 100644
>--- a/net/core/user_dma.c
>+++ b/net/core/user_dma.c
>@@ -75,7 +75,7 @@ int dma_skb_copy_datagram_iovec(struct
>dma_chan *chan,
>
> end = start + skb_shinfo(skb)->frags[i].size;
> copy = end - offset;
>- if ((copy = end - offset) > 0) {
>+ if (copy > 0) {
> skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
> struct page *page = frag->page;
>
Acked-by: Shannon Nelson <shannon.nelson@intel.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2008-02-14 2:38 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-02-13 21:05 [PATCH][I/OAT]: Remove duplicate assignation in dma_skb_copy_datagram_iovec Brice Goglin
2008-02-14 1:02 ` Dan Williams
2008-02-14 2:29 ` Nelson, Shannon
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).