Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 349675
b: refs/heads/master
c: 4cc7c1c
h: refs/heads/master
i:
  349673: 4b14d12
  349671: f0a32fc
v: v3
  • Loading branch information
Ian Campbell authored and David S. Miller committed Feb 8, 2013
1 parent e01e14c commit cf55858
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7d5145d8eb2b9791533ffe4dc003b129b9696c48
refs/heads/master: 4cc7c1cb7b11b6f3515bd9075527576a1eecc4aa
13 changes: 12 additions & 1 deletion trunk/drivers/net/xen-netback/netback.c
Original file line number Diff line number Diff line change
Expand Up @@ -978,7 +978,7 @@ static struct gnttab_copy *xen_netbk_get_requests(struct xen_netbk *netbk,
pending_idx = netbk->pending_ring[index];
page = xen_netbk_alloc_page(netbk, skb, pending_idx);
if (!page)
return NULL;
goto err;

gop->source.u.ref = txp->gref;
gop->source.domid = vif->domid;
Expand All @@ -1000,6 +1000,17 @@ static struct gnttab_copy *xen_netbk_get_requests(struct xen_netbk *netbk,
}

return gop;
err:
/* Unwind, freeing all pages and sending error responses. */
while (i-- > start) {
xen_netbk_idx_release(netbk, frag_get_pending_idx(&frags[i]),
XEN_NETIF_RSP_ERROR);
}
/* The head too, if necessary. */
if (start)
xen_netbk_idx_release(netbk, pending_idx, XEN_NETIF_RSP_ERROR);

return NULL;
}

static int xen_netbk_tx_check_gop(struct xen_netbk *netbk,
Expand Down

0 comments on commit cf55858

Please sign in to comment.