svn commit: r342569 - stable/11/sys/dev/ichwd
Andriy Gapon
avg at FreeBSD.org
Fri Dec 28 08:53:27 UTC 2018
Author: avg
Date: Fri Dec 28 08:53:26 2018
New Revision: 342569
URL: https://svnweb.freebsd.org/changeset/base/342569
Log:
MFC r342193: ichwd: add a few assertions about tco_version
Modified:
stable/11/sys/dev/ichwd/ichwd.c
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/sys/dev/ichwd/ichwd.c
==============================================================================
--- stable/11/sys/dev/ichwd/ichwd.c Fri Dec 28 08:52:50 2018 (r342568)
+++ stable/11/sys/dev/ichwd/ichwd.c Fri Dec 28 08:53:26 2018 (r342569)
@@ -633,6 +633,13 @@ ichwd_identify(driver_t *driver, device_t parent)
return;
}
+ KASSERT(id_p->tco_version >= 1,
+ ("unexpected TCO version %d", id_p->tco_version));
+ KASSERT(id_p->tco_version != 4 || smb != NULL,
+ ("could not find PCI SMBus device for TCOv4"));
+ KASSERT(id_p->tco_version >= 4 || ich != NULL,
+ ("could not find PCI LPC bridge device for TCOv1-3"));
+
/* good, add child to bus */
if ((dev = device_find_child(parent, driver->name, 0)) == NULL)
dev = BUS_ADD_CHILD(parent, 0, driver->name, 0);
More information about the svn-src-stable-11
mailing list