summaryrefslogtreecommitdiff
path: root/sys/dev/pci/alipm.c
diff options
context:
space:
mode:
authorChristiano F. Haesbaert <haesbaert@cvs.openbsd.org>2012-10-05 10:51:29 +0000
committerChristiano F. Haesbaert <haesbaert@cvs.openbsd.org>2012-10-05 10:51:29 +0000
commitac70364f9c3148c8006cd01b7e152df220bb5ba6 (patch)
treee82a0491370ea7e85f58cd4fec401883891b098a /sys/dev/pci/alipm.c
parent9c3f569a5c4f292478d96d01b01ae81aa26b5a27 (diff)
Avoid uninitiliazed use of ctl and corresponding warnings.
Part of the work to remove -Wno-uninitialized. ok kettenis@
Diffstat (limited to 'sys/dev/pci/alipm.c')
-rw-r--r--sys/dev/pci/alipm.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/dev/pci/alipm.c b/sys/dev/pci/alipm.c
index 8c71bd497e5..da1c657dedf 100644
--- a/sys/dev/pci/alipm.c
+++ b/sys/dev/pci/alipm.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: alipm.c,v 1.15 2010/04/08 00:23:53 tedu Exp $ */
+/* $OpenBSD: alipm.c,v 1.16 2012/10/05 10:51:28 haesbaert Exp $ */
/*
* Copyright (c) 2005 Mark Kettenis
@@ -327,6 +327,8 @@ alipm_smb_exec(void *cookie, i2c_op_t op, i2c_addr_t addr,
ctl = ALIPM_SMB_HC_CMD_BDATA;
else if (len == 2)
ctl = ALIPM_SMB_HC_CMD_WDATA;
+ else
+ panic("%s: unexpected len %zd", __func__, len);
bus_space_write_1(sc->sc_iot, sc->sc_ioh, ALIPM_SMB_HC, ctl);
/* Start transaction */