<feed xmlns='http://www.w3.org/2005/Atom'>
<title>phosphor-host-ipmid/test/message, branch master</title>
<subtitle>OpenBMC Phosphor local IPMI daemon sources</subtitle>
<id>https://git.raptorcs.com/git/phosphor-host-ipmid/atom?h=master</id>
<link rel='self' href='https://git.raptorcs.com/git/phosphor-host-ipmid/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/phosphor-host-ipmid/'/>
<updated>2019-09-16T20:12:11+00:00</updated>
<entry>
<title>fix logic error for unpack vector of tuple</title>
<updated>2019-09-16T20:12:11+00:00</updated>
<author>
<name>Vernon Mauery</name>
<email>vernon.mauery@linux.intel.com</email>
</author>
<published>2019-07-23T23:49:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/phosphor-host-ipmid/commit/?id=caabc36b6a7596c6a6deb774770f4271f50942e9'/>
<id>urn:sha1:caabc36b6a7596c6a6deb774770f4271f50942e9</id>
<content type='text'>
Unpacking a vector of tuples is failing if the correct number of bytes
does not match an integral number of bytes needed to fully unpack all
the tuples.

Unpacking a tuple should return an error if it does not fully unpack all
the items. This will signal the vector unpack to bail and return however
many items it has unpacked to that point.

A vector unpack should always return success because no matter how many
items it has unpacked, it is fine, because a vector can have any number
of items.

Tested: Unit tests updated to check for proper unpacking of vectors and
        tuples (and optionals) as well as new unit tests added for more
        targetted testing.

Change-Id: I4b45198f8bc4a49913beb923d10079983179402a
Signed-off-by: Vernon Mauery &lt;vernon.mauery@linux.intel.com&gt;
</content>
</entry>
<entry>
<title>message: Support prepending payloads</title>
<updated>2019-04-29T19:06:35+00:00</updated>
<author>
<name>William A. Kennington III</name>
<email>wak@google.com</email>
</author>
<published>2019-04-25T08:32:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/phosphor-host-ipmid/commit/?id=92476a84180ad4e60c698d21b6f14c368511ce6f'/>
<id>urn:sha1:92476a84180ad4e60c698d21b6f14c368511ce6f</id>
<content type='text'>
Needed solely so that we can support adding the necessary
bits for oem and group commands. We shouldn't be using this anywhere
else, which is why it is not generalized to non-payload types.

Change-Id: I6573f981fbe68cebb89abcdfb3de5de5d139e1e0
Signed-off-by: William A. Kennington III &lt;wak@google.com&gt;
</content>
</entry>
<entry>
<title>message/pack: Allow packing payloads</title>
<updated>2019-04-29T19:06:35+00:00</updated>
<author>
<name>William A. Kennington III</name>
<email>wak@google.com</email>
</author>
<published>2019-04-24T21:45:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/phosphor-host-ipmid/commit/?id=e15e53eb5b3e8b279504710b5759fdfdd32bb128'/>
<id>urn:sha1:e15e53eb5b3e8b279504710b5759fdfdd32bb128</id>
<content type='text'>
Some IPMI handlers need the ability to support variable return types.
The easiest way to do that is to be able to return payloads and pack
them into the final payload.

Change-Id: I5098a1ab0998ada712096929eae40a3c88a6dea0
Signed-off-by: William A. Kennington III &lt;wak@google.com&gt;
</content>
</entry>
<entry>
<title>message/pack: Support packing string_views</title>
<updated>2019-04-29T19:06:35+00:00</updated>
<author>
<name>William A. Kennington III</name>
<email>wak@google.com</email>
</author>
<published>2019-04-24T21:44:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/phosphor-host-ipmid/commit/?id=e2aec26caacdc65711a96ce3b6dbaa5ea526fc1f'/>
<id>urn:sha1:e2aec26caacdc65711a96ce3b6dbaa5ea526fc1f</id>
<content type='text'>
Now we don't need to make an intermediate copy of our data into an array
before packing it into a payload.

Change-Id: Iac79a79e0ae95835cb67d617a966a92ce8dcd5f8
Signed-off-by: William A. Kennington III &lt;wak@google.com&gt;
</content>
</entry>
<entry>
<title>message/pack: Check for outstanding bits</title>
<updated>2019-04-29T19:06:35+00:00</updated>
<author>
<name>William A. Kennington III</name>
<email>wak@google.com</email>
</author>
<published>2019-04-24T21:44:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/phosphor-host-ipmid/commit/?id=906e0f802b56d26e7e0c65eba797fa8a596dee91'/>
<id>urn:sha1:906e0f802b56d26e7e0c65eba797fa8a596dee91</id>
<content type='text'>
Currently, if you pack a non-byte aligned member into a message and then
pack an array, it will do the wrong thing and treat the unaligned data
as being appended to the end of the message. Allowing for this behavior
is convoluted and probably not useful, so just return an error.

Change-Id: I6f200dbea96c41f49a110ba7536ccfd37115d277
Signed-off-by: William A. Kennington III &lt;wak@google.com&gt;
</content>
</entry>
<entry>
<title>message/payload: Ignore unchecked unpack warning during unwind</title>
<updated>2019-04-29T19:06:35+00:00</updated>
<author>
<name>William A. Kennington III</name>
<email>wak@google.com</email>
</author>
<published>2019-04-24T08:53:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/phosphor-host-ipmid/commit/?id=f2fd17a41bf7e3afd4d69adf5f8ea5642bdfffcf'/>
<id>urn:sha1:f2fd17a41bf7e3afd4d69adf5f8ea5642bdfffcf</id>
<content type='text'>
If we are caught in an exception unwind we don't care that the
payload is not be fully checked. Otherwise, this encourages the pattern
of wrapping all handler code in try catch blocks that set trailingOk as
it is not required to read the entire payload when throwing an
exception.

Change-Id: I35149eedd33bd9fd41968e89d5a8614df7436872
Signed-off-by: William A. Kennington III &lt;wak@google.com&gt;
</content>
</entry>
<entry>
<title>message/payload: Clean up check / trailing state</title>
<updated>2019-04-29T19:06:35+00:00</updated>
<author>
<name>William A. Kennington III</name>
<email>wak@google.com</email>
</author>
<published>2019-04-24T08:44:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/phosphor-host-ipmid/commit/?id=51694c22130d4f6160f63167a547d0a40763ef31'/>
<id>urn:sha1:51694c22130d4f6160f63167a547d0a40763ef31</id>
<content type='text'>
We want to be able to trivially re-use payloads for marshalling data
from a buffer into other formats. This change tries to make the meaning
of trailingOk and unpackCheck consistent, since the meanings didn't seem
clear in the previous code. Now, unpackCheck is only used to determine
if unpacking was checked, and trailingOk determines if unpackCheck is
required.

This also fixes lots of spurious warnings being printed for commands
which were checking their output correctly, or were legacy and unable to
check output.

Change-Id: Id7aa9266693b4e3f896027acf6b3e5d757fdf981
Signed-off-by: William A. Kennington III &lt;wak@google.com&gt;
</content>
</entry>
<entry>
<title>Add a tuple type for packing</title>
<updated>2019-04-09T17:42:38+00:00</updated>
<author>
<name>Vernon Mauery</name>
<email>vernon.mauery@linux.intel.com</email>
</author>
<published>2019-04-08T17:01:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/phosphor-host-ipmid/commit/?id=508c457688e4be878f75f7951ac2e5e95e7de3a8'/>
<id>urn:sha1:508c457688e4be878f75f7951ac2e5e95e7de3a8</id>
<content type='text'>
At the top level, payload had the ability to pack a tuple, but it did it
by splitting it into its parts and packing those individually. But if
one of those parts was a tuple, it would fail. This moves the tuple
packing code into the packing templates so that it is possible to pack a
nested tuple of tuples.

Tested-by: newly written tuple unit tests pass

Change-Id: Icd80926314072df78b0083a823dcfb46e944e365
Signed-off-by: Vernon Mauery &lt;vernon.mauery@linux.intel.com&gt;
</content>
</entry>
<entry>
<title>Add support for returning optional values</title>
<updated>2019-04-05T09:31:35+00:00</updated>
<author>
<name>Vernon Mauery</name>
<email>vernon.mauery@linux.intel.com</email>
</author>
<published>2019-04-03T19:11:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/phosphor-host-ipmid/commit/?id=bae91350cc4bad07b841037f078c0df282beffbf'/>
<id>urn:sha1:bae91350cc4bad07b841037f078c0df282beffbf</id>
<content type='text'>
Some commands have optional return values. This allows the handlers to
be defined as returning an optional&lt;T&gt; value and then in the body of the
handler set the value in the optional or not.

Tested-by: unit test runs successfully

Change-Id: Ib38a4589609fb1eb192106e511c9ee3a507ac42f
Signed-off-by: Vernon Mauery &lt;vernon.mauery@linux.intel.com&gt;
</content>
</entry>
<entry>
<title>message: pack: add variant support</title>
<updated>2019-04-04T22:55:56+00:00</updated>
<author>
<name>James Feist</name>
<email>james.feist@linux.intel.com</email>
</author>
<published>2019-04-03T18:54:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/phosphor-host-ipmid/commit/?id=f299807f1bcca4e2582427d4dcd2a4473871d125'/>
<id>urn:sha1:f299807f1bcca4e2582427d4dcd2a4473871d125</id>
<content type='text'>
Add variant support to allow return of mutliple specific
types. Also change types to const as this is required by
the visitor and these could have been const all along.

Tested: Added unit test and used in oem provider

Change-Id: I5cb056c15d4813b9eee58eecb707664477d019d9
Signed-off-by: James Feist &lt;james.feist@linux.intel.com&gt;
</content>
</entry>
</feed>
