Module Name:src
Committed By: martin
Date: Wed Aug 8 10:36:08 UTC 2018
Modified Files:
src/sys/external/bsd/dwc2/dist [netbsd-8]: dwc2_core.h dwc2_hcd.c
dwc2_hcd.h dwc2_hcdintr.c dwc2_hcdqueue.c
Log Message:
Pull up following revision(s) (requested by simonb in ticket #966):
sys/external/bsd/dwc2/dist/dwc2_core.h: revision 1.9
sys/external/bsd/dwc2/dist/dwc2_hcdqueue.c: revision 1.15
sys/external/bsd/dwc2/dist/dwc2_hcd.h: revision 1.15
sys/external/bsd/dwc2/dist/dwc2_hcdintr.c: revision 1.14
sys/external/bsd/dwc2/dist/dwc2_hcd.c: revision 1.21
Merge
https://github.com/torvalds/linux/commit/38d2b5fb75c15923fb89c32134516a623515bce4
to mitigate USB NAK interrupt storms, with an extra change from
skrll@ to also mitigate interrupt storms on the non-split case with
older DWC2 cores.
Fixes woeful USB disk performance on an ERLITE.
Much thanks to skrll@ for pointer to the above patch, handling the
non-split case and testing.
To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.8.10.1 src/sys/external/bsd/dwc2/dist/dwc2_core.h
cvs rdiff -u -r1.19 -r1.19.10.1 src/sys/external/bsd/dwc2/dist/dwc2_hcd.c
cvs rdiff -u -r1.14 -r1.14.10.1 src/sys/external/bsd/dwc2/dist/dwc2_hcd.h \
src/sys/external/bsd/dwc2/dist/dwc2_hcdqueue.c
cvs rdiff -u -r1.13 -r1.13.10.1 src/sys/external/bsd/dwc2/dist/dwc2_hcdintr.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/external/bsd/dwc2/dist/dwc2_core.h
diff -u src/sys/external/bsd/dwc2/dist/dwc2_core.h:1.8 src/sys/external/bsd/dwc2/dist/dwc2_core.h:1.8.10.1
--- src/sys/external/bsd/dwc2/dist/dwc2_core.h:1.8 Wed Feb 24 22:17:54 2016
+++ src/sys/external/bsd/dwc2/dist/dwc2_core.h Wed Aug 8 10:36:08 2018
@@ -1,4 +1,4 @@
-/* $NetBSD: dwc2_core.h,v 1.8 2016/02/24 22:17:54 skrll Exp $ */
+/* $NetBSD: dwc2_core.h,v 1.8.10.1 2018/08/08 10:36:08 martin Exp $ */
/*
* core.h - DesignWare HS OTG Controller common declarations
@@ -756,6 +756,7 @@ struct dwc2_hsotg {
} flags;
struct list_head non_periodic_sched_inactive;
+ struct list_head non_periodic_sched_waiting;
struct list_head non_periodic_sched_active;
struct list_head *non_periodic_qh_ptr;
struct list_head periodic_sched_inactive;
Index: src/sys/external/bsd/dwc2/dist/dwc2_hcd.c
diff -u src/sys/external/bsd/dwc2/dist/dwc2_hcd.c:1.19 src/sys/external/bsd/dwc2/dist/dwc2_hcd.c:1.19.10.1
--- src/sys/external/bsd/dwc2/dist/dwc2_hcd.c:1.19 Wed Feb 24 22:17:54 2016
+++ src/sys/external/bsd/dwc2/dist/dwc2_hcd.c Wed Aug 8 10:36:08 2018
@@ -1,4 +1,4 @@
-/* $NetBSD: dwc2_hcd.c,v 1.19 2016/02/24 22:17:54 skrll Exp $ */
+/* $NetBSD: dwc2_hcd.c,v 1.19.10.1 2018/08/08 10:36:08 martin Exp $ */
/*
* hcd.c - DesignWare HS OTG Controller host-mode routines
@@ -42,7 +42,7 @@
*/
#include
-__KERNEL_RCSID(0, "$NetBSD: dwc2_hcd.c,v 1.19 2016/02/24 22:17:54 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dwc2_hcd.c,v 1.19.10.1 2018/08/08 10:36:08 martin Exp $");
#include
#include
@@ -117,6 +117,10 @@ static void dwc2_dump_channel_info(struc
list_for_each_entry(qh, >non_periodic_sched_inactive,
qh_list_entry)
dev_dbg(hsotg->dev, "%p\n", qh);
+ dev_dbg(hsotg->dev, " NP waiting sched:\n");
+ list_for_each_entry(qh, >non_periodic_sched_waiting,
+ qh_list_entry)
+ dev_dbg(hsotg->dev, "%p\n", qh);
dev_dbg(hsotg->dev, " NP active sched:\n");
list_for_each_entry(qh, >non_periodic_sched_active,
qh_list_entry)
@@ -194,6 +198,7 @@ static void dwc2_qh_list_free(struct dwc
static void dwc2_kill_all_urbs(struct dwc2_hsotg *hsotg)
{
dwc2_kill_urbs_in_qh_list(hsotg, >non_periodic_sched_inactive);
+ dwc2_kill_urbs_in_qh_list(hsotg, >non_periodic_sched_waiting);
dwc2_kill_urbs_in_qh_list(hsotg, >non_periodic_sched_active);
dwc2_kill_urbs_in_qh_list(hsotg, >periodic_sched_inactive);
dwc2_kill_urbs_in_qh_list(hsotg, >periodic_sched_ready);
@@ -2215,6 +2220,7 @@ static void dwc2_hcd_free(struct dwc2_hs
/* Free memory for QH/QTD lists */
dwc2_qh_list_free(hsotg, >non_periodic_sched_inactive);
+ dwc2_qh_list_free(hsotg, >non_periodic_sched_waiting);
dwc2_qh_list_free(hsotg, >non_periodic_sched_active);
dwc2_qh_list_free(hsotg, >periodic_sched_inactive);
dwc2_qh_list_free(hsotg, >periodic_sched_ready);
@@ -2337,6 +2343,7 @@ int dwc2_hcd_init(struct dwc2_hsotg *hso
/* Initialize the non-periodic schedule */
INIT_LIST_HEAD(>non_periodic_sched_inactive);
+ INIT_LIST_HEAD(>non_periodic_sched_waiting);
INIT_LIST_HEAD(>non_periodic_sched_active);
/* Initialize the periodic schedule */
Index: src/sys/external/bsd/dwc2/dist/dwc2_hcd.h
diff -u src/sys/external/bsd/dwc2/dist/dwc2_hcd.h:1.14 src/sys/external/bsd/dwc2/dist/dwc2_hcd.h:1.14.10.1
--- src/sys/external/bsd/dwc2/dist/dwc2_hcd.h:1.14 Sat Apr 23 10:15:30 2016
+++ src/sys/external/bsd/dwc2/dist/dwc2_hcd.h Wed Aug 8 10:36:08 2018
@@ -1,4 +1,4 @@
-/*