Date: Fri, 28 Dec 2018 08:52:50 +0000 (UTC) From: Andriy Gapon <avg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org Subject: svn commit: r342568 - stable/12/sys/dev/ichwd Message-ID: <201812280852.wBS8qoal011944@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: avg Date: Fri Dec 28 08:52:50 2018 New Revision: 342568 URL: https://svnweb.freebsd.org/changeset/base/342568 Log: MFC r342193: ichwd: add a few assertions about tco_version Modified: stable/12/sys/dev/ichwd/ichwd.c Directory Properties: stable/12/ (props changed) Modified: stable/12/sys/dev/ichwd/ichwd.c ============================================================================== --- stable/12/sys/dev/ichwd/ichwd.c Fri Dec 28 08:50:27 2018 (r342567) +++ stable/12/sys/dev/ichwd/ichwd.c Fri Dec 28 08:52:50 2018 (r342568) @@ -635,6 +635,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);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201812280852.wBS8qoal011944>