Lines Matching refs:ptask

1334 static int ether1394_send_packet(struct packet_task *ptask, unsigned int tx_len)  in ether1394_send_packet()  argument
1336 struct eth1394_priv *priv = ptask->priv; in ether1394_send_packet()
1343 if (ptask->tx_type == ETH1394_GASP) { in ether1394_send_packet()
1346 ether1394_prep_gasp_packet(packet, priv, ptask->skb, length); in ether1394_send_packet()
1348 ptask->dest_node, in ether1394_send_packet()
1349 ptask->addr, ptask->skb->data, in ether1394_send_packet()
1355 ptask->packet = packet; in ether1394_send_packet()
1356 hpsb_set_packet_complete_task(ptask->packet, ether1394_complete_cb, in ether1394_send_packet()
1357 ptask); in ether1394_send_packet()
1369 static inline void ether1394_dg_complete(struct packet_task *ptask, int fail) in ether1394_dg_complete() argument
1371 struct sk_buff *skb = ptask->skb; in ether1394_dg_complete()
1388 kmem_cache_free(packet_task_cache, ptask); in ether1394_dg_complete()
1396 struct packet_task *ptask = (struct packet_task *)__ptask; in ether1394_complete_cb() local
1397 struct hpsb_packet *packet = ptask->packet; in ether1394_complete_cb()
1405 ptask->outstanding_pkts--; in ether1394_complete_cb()
1406 if (ptask->outstanding_pkts > 0 && !fail) in ether1394_complete_cb()
1411 tx_len = ether1394_encapsulate(ptask->skb, ptask->max_payload, in ether1394_complete_cb()
1412 &ptask->hdr); in ether1394_complete_cb()
1413 if (ether1394_send_packet(ptask, tx_len)) in ether1394_complete_cb()
1414 ether1394_dg_complete(ptask, 1); in ether1394_complete_cb()
1416 ether1394_dg_complete(ptask, fail); in ether1394_complete_cb()
1437 struct packet_task *ptask; in ether1394_tx() local
1440 ptask = kmem_cache_alloc(packet_task_cache, kmflags); in ether1394_tx()
1441 if (ptask == NULL) { in ether1394_tx()
1514 ptask->hdr.words.word1 = 0; in ether1394_tx()
1515 ptask->hdr.words.word2 = 0; in ether1394_tx()
1516 ptask->hdr.words.word3 = 0; in ether1394_tx()
1517 ptask->hdr.words.word4 = 0; in ether1394_tx()
1518 ptask->skb = skb; in ether1394_tx()
1519 ptask->priv = priv; in ether1394_tx()
1520 ptask->tx_type = tx_type; in ether1394_tx()
1538 ptask->addr = addr; in ether1394_tx()
1539 ptask->dest_node = dest_node; in ether1394_tx()
1542 ptask->tx_type = tx_type; in ether1394_tx()
1543 ptask->max_payload = max_payload; in ether1394_tx()
1544 ptask->outstanding_pkts = ether1394_encapsulate_prep(max_payload, proto, in ether1394_tx()
1545 &ptask->hdr, dg_size, in ether1394_tx()
1549 tx_len = ether1394_encapsulate(skb, max_payload, &ptask->hdr); in ether1394_tx()
1551 if (ether1394_send_packet(ptask, tx_len)) in ether1394_tx()
1557 if (ptask) in ether1394_tx()
1558 kmem_cache_free(packet_task_cache, ptask); in ether1394_tx()