653-0022-rtl8xxxu-Setup-interrupts-for-8188eu.patch 1.3 KB

12345678910111213141516171819202122232425262728293031
  1. From 4c85a1704e555aa04d72e31a4a90b9c4bf01d83b Mon Sep 17 00:00:00 2001
  2. From: Jes Sorensen <Jes.Sorensen@redhat.com>
  3. Date: Wed, 20 Jul 2016 16:59:18 -0400
  4. Subject: [PATCH] rtl8xxxu: Setup interrupts for 8188eu
  5. This sets up interrupts for 8188eu, but per vendor driver, it's not
  6. obvious this is really needed for USB devices.
  7. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com>
  8. ---
  9. drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 9 +++++++++
  10. 1 file changed, 9 insertions(+)
  11. --- a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c
  12. +++ b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c
  13. @@ -4041,6 +4041,15 @@ static int rtl8xxxu_init_device(struct i
  14. if (priv->rtl_chip == RTL8192E) {
  15. rtl8xxxu_write32(priv, REG_HIMR0, 0x00);
  16. rtl8xxxu_write32(priv, REG_HIMR1, 0x00);
  17. + } else if (priv->rtl_chip == RTL8188E) {
  18. + rtl8xxxu_write32(priv, REG_HISR0, 0xffffffff);
  19. + val32 = IMR0_PSTIMEOUT | IMR0_TBDER | IMR0_CPWM | IMR0_CPWM2;
  20. + rtl8xxxu_write32(priv, REG_HIMR0, val32);
  21. + val32 = IMR1_TXERR | IMR1_RXERR | IMR1_TXFOVW | IMR1_RXFOVW;
  22. + rtl8xxxu_write32(priv, REG_HIMR1, val32);
  23. + val8 = rtl8xxxu_read8(priv, REG_USB_SPECIAL_OPTION);
  24. + val8 |= USB_SPEC_INT_BULK_SELECT;
  25. + rtl8xxxu_write8(priv, REG_USB_SPECIAL_OPTION, val8);
  26. } else {
  27. /*
  28. * Enable all interrupts - not obvious USB needs to do this