linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/3] dm9601: enable EP3 interrupt
@ 2016-03-10 11:23 Joseph CHANG
  2016-03-10 21:55 ` Peter Korsgaard
  0 siblings, 1 reply; 3+ messages in thread
From: Joseph CHANG @ 2016-03-10 11:23 UTC (permalink / raw)
  To: Peter Korsgaard, netdev, linux-usb, linux-kernel, Joseph CHANG
  Cc: Joseph Chang

Enable chip's EP3 interrupt to get the link-up notify soon
immediately.

Signed-off-by: Joseph CHANG <josright123@gmail.com>
---
 drivers/net/usb/dm9601.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/net/usb/dm9601.c b/drivers/net/usb/dm9601.c
index 0b4bdd3..520de4f 100644
--- a/drivers/net/usb/dm9601.c
+++ b/drivers/net/usb/dm9601.c
@@ -46,6 +46,9 @@
 #define DM_GPR_DATA	0x1f
 #define DM_CHIP_ID	0x2c
 #define DM_MODE_CTRL	0x91	/* only on dm9620 */
+#define	DM_USB_CTRL	0xf4
+
+#define	USB_CTRL_EP3ACK	0x20
 
 /* chip id values */
 #define ID_DM9601	0
@@ -414,6 +417,9 @@ static int dm9601_bind(struct usbnet *dev, struct usb_interface *intf)
 			goto out;
 		}
 		dm_write_reg(dev, DM_MODE_CTRL, mode & 0x7f);
+
+		/* Always return 8-bytes data to host per interrupt-interval */
+		dm_write_reg(dev, DM_USB_CTRL, USB_CTRL_EP3ACK);
 	}
 
 	/* power up phy */
-- 
2.1.4

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-03-11 10:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-10 11:23 [PATCH 1/3] dm9601: enable EP3 interrupt Joseph CHANG
2016-03-10 21:55 ` Peter Korsgaard
2016-03-11 10:47   ` Joseph Chang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).