caif: Don't resend if dev_queue_xmit fails.

If CAIF Link Layer returns an error, we no longer try to re-build the
CAIF packet and resend it. Instead, we simply return any transmission
errors to the socket client.

Signed-off-by: Sjur Brændeland <sjur.brandeland@stericsson.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Sjur Brændeland
2011-04-11 10:43:51 +00:00
committed by David S. Miller
parent 73d6ac633c
commit 4dd820c088
9 changed files with 13 additions and 87 deletions
+1 -6
View File
@@ -184,7 +184,6 @@ static int cfmuxl_receive(struct cflayer *layr, struct cfpkt *pkt)
static int cfmuxl_transmit(struct cflayer *layr, struct cfpkt *pkt)
{
int ret;
struct cfmuxl *muxl = container_obj(layr);
u8 linkid;
struct cflayer *dn;
@@ -198,11 +197,7 @@ static int cfmuxl_transmit(struct cflayer *layr, struct cfpkt *pkt)
info->hdr_len += 1;
linkid = info->channel_id;
cfpkt_add_head(pkt, &linkid, 1);
ret = dn->transmit(dn, pkt);
/* Remove MUX protocol header upon error. */
if (ret < 0)
cfpkt_extr_head(pkt, &linkid, 1);
return ret;
return dn->transmit(dn, pkt);
}
static void cfmuxl_ctrlcmd(struct cflayer *layr, enum caif_ctrlcmd ctrl,