From nobody Thu Jan 06 11:38:19 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 74E46193BAEA; Thu, 6 Jan 2022 11:38:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JV49S0jQ4z3vWr; Thu, 6 Jan 2022 11:38:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id ECCB01EDF5; Thu, 6 Jan 2022 11:38:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 206BcJ34051789; Thu, 6 Jan 2022 11:38:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 206BcJTA051788; Thu, 6 Jan 2022 11:38:19 GMT (envelope-from git) Date: Thu, 6 Jan 2022 11:38:19 GMT Message-Id: <202201061138.206BcJTA051788@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Toomas Soome Subject: git: 1d15c6b3e516 - stable/13 - bhyve smbios type 3 structure is incorrect List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tsoome X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 1d15c6b3e51637471ace760006e377d59e34a6dc Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1641469100; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=pyAGlvImOh4oL79xo4l6SWbzImhb5Dx1LTiCFMktTr8=; b=p2NciogdEuGIPB8zmbQbqO3x8quEXKeW8Jp8grhuLeImbPWnyPYRBLD1jBeAPHPte1cjWU Sa9sGkDuyp1l9Rk9QfDxGFE+rydh5k+trRpf+kZ5CK2ugSQ59cLQAS2i/cbmEz71OL9xxR oxd75+U1YiX/4MFQv5YYr4kyMyY/OKFHY8H47Tmuohuy636QzoQvpW8CyTNkR6gNQAVb+6 3axAj71y2Bkk2+FFODcVeZko6MoWWF4lFhC3wOsy5VJIf1v+qvUfkg18qMU7OSgCQz1oCn gFCREU0rNo8CrjzPUYN44/u51u7ChAq0mshwlsJ1ftWMTbmGeQaAUhKr25aYMg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1641469100; a=rsa-sha256; cv=none; b=IQ3kE8TVRMm+8s+c/FXwuKpHQeV6mqqY3bYZNZW4gJzMrAsec2BD0Pd4DHj72ABgVNasOR lx2ztfSXGuzZMinhXjDeaaz+SFBlanQMt627fMfbbLFsKzQJn3bmTm0fewn0qcKV0nfyjF 1Bw1w1zH7puRZ3FKIysf3n5C2xf4jBXuC9BdiBmKcZTWeDSS0+Xu5I3mU9IWJMQgd1UG0I HB7jJ92mrCwgk8Abl8woItozEftXL6jZ8KUS9AICU3IsIcXVnTW4NCrVGQ+IXlGBKp18Fj WlPhv9oV+3Ns1LU4LuK9hGa+j/llUXEbNdEMyT0Y5KF8TMK+Njg3317Er7QfaQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by tsoome: URL: https://cgit.FreeBSD.org/src/commit/?id=1d15c6b3e51637471ace760006e377d59e34a6dc commit 1d15c6b3e51637471ace760006e377d59e34a6dc Author: Toomas Soome AuthorDate: 2021-12-26 09:01:16 +0000 Commit: Toomas Soome CommitDate: 2022-01-06 11:37:09 +0000 bhyve smbios type 3 structure is incorrect If you look at the SMBIOS specification, we'll find something is missing. In particular at offset 0Dh is supposed to be the OEM-defined field. This should go between security and height. It is not legal to actually skip this and will lead to other folks not properly interpreting later parts of the table. https://www.illumos.org/issues/14312 Reviewed by: jhb Submitted by: Robert Mustacchi Obtained from: ilumos Differential Revision: https://reviews.freebsd.org/D33682 (cherry picked from 04f55b5b0e8f561aac100083f07df3f570880d69) --- usr.sbin/bhyve/smbiostbl.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/usr.sbin/bhyve/smbiostbl.c b/usr.sbin/bhyve/smbiostbl.c index ca68f8d95363..2b12c0b272b0 100644 --- a/usr.sbin/bhyve/smbiostbl.c +++ b/usr.sbin/bhyve/smbiostbl.c @@ -199,6 +199,7 @@ struct smbios_table_type3 { uint8_t psstate; /* power supply state */ uint8_t tstate; /* thermal state */ uint8_t security; /* security status */ + uint32_t oemdata; /* OEM-specific data */ uint8_t uheight; /* height in 'u's */ uint8_t cords; /* number of power cords */ uint8_t elems; /* number of element records */ @@ -417,6 +418,7 @@ struct smbios_table_type3 smbios_type3_template = { SMBIOS_CHST_SAFE, SMBIOS_CHST_SAFE, SMBIOS_CHSC_NONE, + 0, /* OEM specific data, we have none */ 0, /* height in 'u's (0=enclosure height unspecified) */ 0, /* number of power cords (0=number unspecified) */ 0, /* number of contained element records */