| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
The old code deletes session from the session map before doing a lookup
of the path. Fix the order and add a unit test to catch the error case.
(The unit test would fail without this fix).
Signed-off-by: Kun Yi <kunyi731@gmail.com>
Change-Id: If043d6aad7bbaafa19ae3b63a6d9cc7a836d25b5
|
|
|
|
|
|
|
|
| |
Add simple tests to ensure the session expire method is called when
the timeout is set to zero.
Signed-off-by: Kun Yi <kunyi731@gmail.com>
Change-Id: Ic6e973ede760a6a6f15726d5b6c93a892d858c8b
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Because this structure is not anything special, simply use the cpp
idiomatic way of referencing the object.
Consistently, structures that are packed still have "struct" used in
declarations. However, this distinction is only clear through its usage
and nothing in the language. Perhaps a better approach would be
notational naming struct PackedXYZ {};. However, that can get out of
control quickly.
Signed-off-by: Patrick Venture <venture@google.com>
Change-Id: I3b7e48e4b6687ef2e15e9d07c0eeba96eb5d2552
|
|
|
|
|
| |
Signed-off-by: Patrick Venture <venture@google.com>
Change-Id: Ic5aa3e38b4df33a2cfa29c575f17097e38d06605
|
|
|
|
|
|
|
|
|
| |
Split the object into two pieces so we can pass part of it to the
unit-tests.
Tested: Verified the coverage output processed the files.
Change-Id: Idf1bdf9d21eb1324395eb9a2c09ff8f1b4ecad6b
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
| |
The code coverage macros from the archive changed in a backward
incompatible way. This adds a workaround to autodetect either version
and do the right thing.
Change-Id: I09b88e6b4792c99140a73a4ceb11d2896ee13562
Signed-off-by: William A. Kennington III <wak@google.com>
|
|
|
|
|
|
|
|
|
|
| |
Drop all code that is now handled by the ipmiblob library provided by
the new ipmi-blob-tool. This is a library that can be included on the
BMC if necessary, but relies on nothing that is strictly meant for the
BMC.
Change-Id: I2b02ae0d432e84c08e598d27eef85b57c06a70fc
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
| |
Use filesystem now that it should be available instead of
experimental::filesystem.
Change-Id: Ia9b17f33ced70fe2f1f12f11d8708d15ff422bfa
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
| |
Enable valgrind tests.
Change-Id: Ib5ec22a19c043ef45f5274e4716e2abbae9c19da
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
| |
Enable code coverage for the project. Valgrind not enabled in this
step.
Change-Id: I439d58b23d2bc29d6f602600319074c8fd8c04d6
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
| |
Rework gtest checks to be modeled after openbmc/gpioplus.
Change-Id: I263bf12c0323ebee5d95b569ce28da2042bd3c1d
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The host-client cannot try to read back more than this number of bytes
without hitting a memory overflow in phosphor-host-ipmid. The method we
can call to dynamically receive that number isn't currently linking out
of the userlayer library.
Note: Once the configure_ac can find and provide the userlayer library
from phosphor-host-ipmid, we can remove the hard-coded 64 and 0xe.
Change-Id: I08f6bb59ce44279f76a494dccaa477ae75d532c4
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
| |
Stop installing the manager header as it is no longer meant to be
exported, but rather used only internally within this repository.
Change-Id: I2ab21a31fd745e1b3e36fc39ffea5e26d373ff51
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
| |
The read command, if returning 0 bytes of data, does return the CRC.
Tested: Verified via a client implementation that it now behaves as
expected on returning 0 bytes from a read (returns only the CRC).
Change-Id: I84200c0fbe8400cc9234b55991fee750cb84faa2
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
| |
Add interface defining the methods for dynamic linking to enable
testing.
Change-Id: If4d090d3cedc019b426435a1f651191803bfc1a9
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
|
| |
Skip the 0'd CRC bytes on reply computation, mirroring the skipping
during request validation.
Tested: Verified via client the CRC for the reply now matches
expectations.
Change-Id: I18da28604a388fb4210c55f3e54410a067b9f10a
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
|
|
| |
The IPMI packet validation code must return specific IPMI errors
corresponding to what error has occurred instead of the invalid command
error.
Update all IPMI handler pieces to return more specific errors.
Change-Id: I8d21e92015d84cc0880e3b83991aed7288e19eab
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
| |
Implement new command BmcBlobWriteMeta.
Change-Id: I2e148f4bde4ef5d24db7e30bb02bdde024d9166a
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
| |
IPMI Blob handlers will need to include these mocks when building
unit-tests. Therefore, they must be installed.
Change-Id: I4c8ed0fa1a4a8912853c024206ef5e61f87707d8
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
| |
The blobs and manager header will be used by handlers once we've
transitioned to dynamic loading.
Change-Id: Ieae8fcfe383007731cb4f8b2619612c3bfa47f50
Signed-off-by: Patrick Venture <venture@google.com>
|
|
This implements a majority of the OEM IPMI BLOBS protocol. The only
piece missing from this is the timed expiration of sessions.
Change-Id: I82c9d17b625c94fc3340edcfabbbf1ffeb5ad7ac
Signed-off-by: Patrick Venture <venture@google.com>
|