Details
-
Bug
-
Resolution: Fixed
-
Minor
-
None
-
3
-
16635
Description
665 kiblnd_map_tx(lnet_ni_t *ni, kib_tx_t *tx, ...... 677 tx->tx_nfrags = nfrags; 678 679 rd->rd_nfrags = 680 kiblnd_dma_map_sg(hdev->ibh_ibdev, 681 tx->tx_frags, tx->tx_nfrags, tx->tx_dmadir);
As dma_map_sg() can return fewer entries in the mapped SG list, it may happen that "rd->rd_nfrags < tx->tx_nfrags". But the code seemed to assume "rd->rd_nfrags == tx->tx_nfrags":
642 kiblnd_unmap_tx(lnet_ni_t *ni, kib_tx_t *tx) 658 kiblnd_dma_unmap_sg(tx->tx_pool->tpo_hdev->ibh_ibdev, 659 tx->tx_frags, tx->tx_nfrags, tx->tx_dmadir); 1474 kiblnd_send (lnet_ni_t *ni, void *private, lnet_msg_t *lntmsg) 1550 nob = offsetof(kib_get_msg_t, ibgm_rd.rd_frags[tx->tx_nfrags]); 1707 kiblnd_recv (lnet_ni_t *ni, void *private, lnet_msg_t *lntmsg, int delayed, 1788 nob = offsetof(kib_putack_msg_t, ibpam_rd.rd_frags[tx->tx_nfrags]);
It seemed that the # original SG entries is not needed anywhere in the code, so it can be fixed by assigning the # mapped SG entries to kib_tx_t::tx_nfrags.
Attachments
Issue Links
- mentioned in
-
Page Loading...