summaryrefslogtreecommitdiff
path: root/sys/arch
diff options
context:
space:
mode:
authorVisa Hankala <visa@cvs.openbsd.org>2022-07-10 08:33:01 +0000
committerVisa Hankala <visa@cvs.openbsd.org>2022-07-10 08:33:01 +0000
commit40a602772d154f7b5a7c7c080260913d29276983 (patch)
treeed06a9a84701d7e32c77e00dd00d0e86a5992854 /sys/arch
parente582073d51d3250a948bd6721df5e80ff6d50711 (diff)
Add missing device_unref() calls.
OK kettenis@
Diffstat (limited to 'sys/arch')
-rw-r--r--sys/arch/sparc64/dev/vldcp.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/arch/sparc64/dev/vldcp.c b/sys/arch/sparc64/dev/vldcp.c
index 6d686388f8e..ca48a469b59 100644
--- a/sys/arch/sparc64/dev/vldcp.c
+++ b/sys/arch/sparc64/dev/vldcp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vldcp.c,v 1.23 2022/07/02 08:50:41 visa Exp $ */
+/* $OpenBSD: vldcp.c,v 1.24 2022/07/10 08:33:00 visa Exp $ */
/*
* Copyright (c) 2009, 2012 Mark Kettenis
*
@@ -683,6 +683,7 @@ vldcpkqfilter(dev_t dev, struct knote *kn)
break;
default:
+ device_unref(&sc->sc_dv);
return (EINVAL);
}
@@ -692,5 +693,6 @@ vldcpkqfilter(dev_t dev, struct knote *kn)
klist_insert_locked(klist, kn);
splx(s);
+ device_unref(&sc->sc_dv);
return (0);
}