summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorVisa Hankala <visa@cvs.openbsd.org>2017-02-16 14:09:01 +0000
committerVisa Hankala <visa@cvs.openbsd.org>2017-02-16 14:09:01 +0000
commit7c7ad3d382116e710cba4992b4db44348785d2fb (patch)
treeb1794904adea07e524825a83bec85da65536525e /sys
parentd706d93d7e1905b435d896d89f06a97a58e6e08d (diff)
Remove an unnecessary NULL pointer check.
OK stsp@
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/usb/dwc2/dwc2.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/sys/dev/usb/dwc2/dwc2.c b/sys/dev/usb/dwc2/dwc2.c
index def32a27fee..bb3a2cbd3eb 100644
--- a/sys/dev/usb/dwc2/dwc2.c
+++ b/sys/dev/usb/dwc2/dwc2.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dwc2.c,v 1.40 2017/02/12 17:41:17 visa Exp $ */
+/* $OpenBSD: dwc2.c,v 1.41 2017/02/16 14:09:00 visa Exp $ */
/* $NetBSD: dwc2.c,v 1.32 2014/09/02 23:26:20 macallan Exp $ */
/*-
@@ -1436,16 +1436,13 @@ dwc2_worker(struct task *wk, void *priv)
}
}
-int dwc2_intr(void *p)
+int
+dwc2_intr(void *p)
{
struct dwc2_softc *sc = p;
- struct dwc2_hsotg *hsotg;
+ struct dwc2_hsotg *hsotg = sc->sc_hsotg;
int ret = 0;
- if (sc == NULL)
- return 0;
-
- hsotg = sc->sc_hsotg;
mtx_enter(&hsotg->lock);
if (sc->sc_dying)