653-0009-rtl8xxxu-8188e-add-REG_TXDMA_OFFSET_CHK-quirk.patch 1.2 KB

12345678910111213141516171819202122232425262728293031323334
  1. From 3ab047939db70fcae2a7c5993a8feaf3ac413e35 Mon Sep 17 00:00:00 2001
  2. From: Jes Sorensen <Jes.Sorensen@redhat.com>
  3. Date: Wed, 29 Jun 2016 11:53:31 -0400
  4. Subject: [PATCH] rtl8xxxu: 8188e add REG_TXDMA_OFFSET_CHK quirk
  5. Enable quirk allowing TX DMA to drop redundant data of packet. This is
  6. the same quirk enabled on gen2 parts.
  7. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com>
  8. ---
  9. drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8188e.c | 5 +++++
  10. 1 file changed, 5 insertions(+)
  11. --- a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8188e.c
  12. +++ b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8188e.c
  13. @@ -203,6 +203,7 @@ exit:
  14. static void rtl8188e_usb_quirks(struct rtl8xxxu_priv *priv)
  15. {
  16. u16 val16;
  17. + u32 val32;
  18. /*
  19. * Technically this is not a USB quirk, but a chip quirk.
  20. @@ -212,6 +213,10 @@ static void rtl8188e_usb_quirks(struct r
  21. val16 = rtl8xxxu_read16(priv, REG_CR);
  22. val16 |= (CR_MAC_TX_ENABLE | CR_MAC_RX_ENABLE);
  23. rtl8xxxu_write16(priv, REG_CR, val16);
  24. +
  25. + val32 = rtl8xxxu_read32(priv, REG_TXDMA_OFFSET_CHK);
  26. + val32 |= TXDMA_OFFSET_DROP_DATA_EN;
  27. + rtl8xxxu_write32(priv, REG_TXDMA_OFFSET_CHK, val32);
  28. }
  29. struct rtl8xxxu_fileops rtl8188eu_fops = {