msm8953-mainline / linux

Linux mainline kernel with WIP patches for msm8953 devices
Other
113 stars 59 forks source link

Use kernel BAM for ipa2_lite #194

Closed spasswolf closed 5 months ago

spasswolf commented 5 months ago

This uses the BAM dmaengine driver for the ipa2_lite driver. It gives working mobile data in simple cases (accessing wikipedia works), but crashes when accessing youtube.

The crash when using youtube is caused by a NULL pointer in ipa_poll_tx, using netconsole I could observe BUG_ON(!skb) being triggered.


    while (done < budget) {
        struct ipa_trans *trans;
        done++;
        trans = bam_channel_poll_one_new(ep);
        if (!trans)
            break;

        skb = trans->skb;
        BUG_ON(!skb);

        bytes += skb->len;
        packets++;

        dma_unmap_single(dev, trans->addr, skb->len, DMA_TO_DEVICE);
        dev_consume_skb_any(skb);

        ipa_trans_free(trans);
    }

Another issue is that I had to remove the iommus from the ipa and ipa_bam nodes to make BAM dma work.

spasswolf commented 5 months ago

Close by popular demand :)