| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
The ptr makes for ugly code:
i.e. *(ctx->yield) all over the place.
Change it to copy as it is just 4 pointers.
Tested: ipmitool mc info still works
Change-Id: I30c5bc395849875cd58925fac99bb23c1804cd5b
Signed-off-by: James Feist <james.feist@linux.intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the original ipmi execution queue, handlers were passed a larger
buffer. The current code was only passing in the configured channel
size, or 64 if no size was configured. This is too small and leads
to buffer overflows for responses greater than 64 bytes.
This brings the buffer sizes up to a point that matches the legacy
code and to a size that is larger than any of IPMI standard transport
sizes.
Tested: used a bogus handler to create a large response and found that
the entire response was returned.
Change-Id: I91b359812247ae5fdef105c7b7a9dfe003548494
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Legacy OEM commands didn't handle the IANA numbers themselves as part
of their handler body, and expect the request buffer to not contain
them. We can't pass the raw buffer without removing the already
extracted prefixes.
This should make legacy OEM commands work again.
Also reworks group handling to become consistent with OEM handling. This
happens to fix cases where groupIds were not being returned with error
codes.
Change-Id: I10efe8004f2c2b262f48980852b46317035ca367
Signed-off-by: William A. Kennington III <wak@google.com>
|
|
|
|
|
|
|
|
|
|
|
| |
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 <wak@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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 <wak@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
After some feedback from users of the new IPMI API, they wanted to see
two things:
1) don't require ipmid/api.hpp and ipmid/registration.hpp to be able to
write new handlers
2) only require including ipmid/api.hpp (instead of ipmid/api.h)
So now, by simply including ipmid/api.hpp instead of ipmid/api.h
(deprecated), handlers incorporating the new IPMI API can be written.
Change-Id: I446dcce70cff03d4ecc28c658292d052485f77fc
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
|
|
|
|
|
|
|
|
|
| |
This part was originally omitted, but needed by some external provider
libraries. This will more closely mimic the behavior of ipmid prior to
the architecture update.
Change-Id: I5db35222e268a117480285c700d88206d6505d92
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Until the response goes back out onto D-Bus, the completion code is held
in a separate part of the Response object. The D-Bus response has a
separate field for the completion code as well, reserving a byte array
for response data only.
This fixes the ipmitool error message 'Bad response length, len=1' when
it attempts to query the PICMG capabilities.
Change-Id: Iff0c3cb2e46a20e52229265eebb0995878a41714
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
|
|
|
|
|
|
|
|
|
|
| |
Add full support for the IPMI OEM NetFn and the Group OEM support as
defined in the IPMI 2.0 specification.
For now the legacy OEM router mechanism is still supported.
Change-Id: I8cc999489000c6e0daf5aad3579838e6f499ba47
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
|
|
handler.hpp has the templated wrapping bits for ipmi command handler
callbacks implemented.
message.hpp has the serialization/deserialization of the ipmi data
stream into packed tuples for functions.
message/pack.hpp and message/unpack.hpp contain the actual serialization
and deserialization of types.
Change-Id: If997f8768c8488ab6ac022526a5ef9a1bce57fcb
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
|