400766f9 | 07-Sep-2023 |
Konstantin Aladyshev <aladyshev22@gmail.com> |
astlpc: Provide KCS device path as a binding argument
Currently astlpc binding expects a '/dev/mctp0' device in the system for the KCS communication. This device is a symbolic link to the real '/dev
astlpc: Provide KCS device path as a binding argument
Currently astlpc binding expects a '/dev/mctp0' device in the system for the KCS communication. This device is a symbolic link to the real '/dev/raw-kcsX' device, created by the udev rules populated by the build system. This approach is not ideal since the build system populates udev rules for the KCS3 and KCS4 channels simultaneously and for these channels only. This means that there are some design limitations for the MCTP communication. It is only possible on KCS3 or KCS4 channel, and if one of these channels is used, the other one must be disabled. To make design more flexible get rid of all the udev rules and provide '/dev/raw-kcsX' device path as an argument to the binding initialization code.
Change-Id: I505e44280636c83b59669b314f60279b371d0403 Signed-off-by: Konstantin Aladyshev <aladyshev22@gmail.com>
show more ...
|
dca82599 | 23-Jun-2023 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-demux-daemon: Change default log level to MCTP_LOG_NOTICE
This allows us to log things that aren't warnings or errors but do need some attention, more so than info-level issues.
Signed-off-by:
mctp-demux-daemon: Change default log level to MCTP_LOG_NOTICE
This allows us to log things that aren't warnings or errors but do need some attention, more so than info-level issues.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I99779ebb4f15672e969337be8e52e247d803deb1
show more ...
|
f2988977 | 08-Nov-2022 |
Rashmica Gupta <rashmica@linux.ibm.com> |
pcap: Use SLL2 linktype for captures
This means we can use wireshark on our pcaps.
Signed-off-by: Rashmica Gupta <rashmica@linux.ibm.com> Change-Id: I215af00e064d352e41d0a8eb87d5a30582998676 |
a721c2d8 | 04-Dec-2022 |
Patrick Williams <patrick@stwcx.xyz> |
format: reformat with clang-format
Reformat everything with clang-format and remove .clang-ignore and custom code formatter.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: I93dfca67
format: reformat with clang-format
Reformat everything with clang-format and remove .clang-ignore and custom code formatter.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: I93dfca67948d3fbcc0f05ece4ae3e4dd9495ab57
show more ...
|
4d0c428c | 29-Sep-2022 |
Andrew Jeffery <andrew@aj.id.au> |
utils: mctp-astlpc-daemon: Format with clang-format
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: Ib7d1238d0a2fe3b36ac9289945ef22d1a6b7c023 |
435670d6 | 29-Sep-2022 |
Andrew Jeffery <andrew@aj.id.au> |
utils: mctp-pipe: Format with clang-format
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I8159d7e16a965a76232d2a6311df851e301487c9 |
2c69ab31 | 29-Sep-2022 |
Andrew Jeffery <andrew@aj.id.au> |
utils: mctp-in: Format with clang-format
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I4d7ed30f50e90fa37c462bd854ba8dfcbf019e18 |
94977187 | 29-Sep-2022 |
Andrew Jeffery <andrew@aj.id.au> |
utils: capture: Format with clang-format
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: Ibc0bb3fa67d1163afe7c523f64b7314b7bc98844 |
8f53d631 | 25-Jul-2022 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-demux-daemon: Exploit binding mctp_*_init_pollfd() APIs
Once bindings are correctly implemented as async the daemon itself will follow.
Finally, now they're unused, drop the mctp_*_get_fd() AP
mctp-demux-daemon: Exploit binding mctp_*_init_pollfd() APIs
Once bindings are correctly implemented as async the daemon itself will follow.
Finally, now they're unused, drop the mctp_*_get_fd() APIs as they're strictly less powerful.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: Ibc2bbc1d75b031e4422429d606e6345d794cb44d
show more ...
|
f39c3857 | 10-Jan-2022 |
Sumanth Bhat <sumanth.bhat@linux.intel.com> |
core: Add TX/RX API that exposes message tag and tag owner
MCTP received packets can carry a message tag and tag owner bit which is set by a remote MCTP endpoint. This can be used by the remote MCTP
core: Add TX/RX API that exposes message tag and tag owner
MCTP received packets can carry a message tag and tag owner bit which is set by a remote MCTP endpoint. This can be used by the remote MCTP endpoint to track the responses. Thus, libmctp should provide a mechanism for the upper layer MCTP applications to respond with the same message tag.
This patchset extends TX and RX API with message tag and tag owner bits.
Signed-off-by: Sumanth Bhat <sumanth.bhat@linux.intel.com> Change-Id: I6d07eafa86c653abdd4313ab7cc77e5a93124477
show more ...
|
5ab78259 | 17-Feb-2022 |
Andrew Jeffery <andrew@aj.id.au> |
libmctp: Introduce compiler.h
Define __unused here and include compiler.h in all the places we can make use of it. Clean up some header ordering and include styles while we're at it.
Signed-off-by:
libmctp: Introduce compiler.h
Define __unused here and include compiler.h in all the places we can make use of it. Clean up some header ordering and include styles while we're at it.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I33ddbdacbddbbf557dc02e42d8dde71a16e1cabe
show more ...
|
f967c709 | 17-Feb-2022 |
Andrew Jeffery <andrew@aj.id.au> |
utils: Resolve warnings of unused write() result
For example:
``` utils/mctp-pipe.c:19:9: error: ignoring return value of ‘write’ declared with attribute ‘warn_unused_result’ [-Werror=unused-result
utils: Resolve warnings of unused write() result
For example:
``` utils/mctp-pipe.c:19:9: error: ignoring return value of ‘write’ declared with attribute ‘warn_unused_result’ [-Werror=unused-result] 19 | write(STDOUT_FILENO, msg, len); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ```
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I57041dc85b551f9bb694638642b677b737be21eb
show more ...
|
95cccaec | 07-Oct-2021 |
Brad Bishop <bradleyb@fuzziesquirrel.com> |
mctp-demux-daemon: sanity check pcap args
Ensure that the apporprate linktype argument is provided whenever --capture-socket or --capture-binding are enabled.
Change-Id: I8f1294848be2e5bbf191295f1b
mctp-demux-daemon: sanity check pcap args
Ensure that the apporprate linktype argument is provided whenever --capture-socket or --capture-binding are enabled.
Change-Id: I8f1294848be2e5bbf191295f1bd23ebe3be0424c Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
show more ...
|
e4d8456f | 30-Nov-2021 |
Brad Bishop <bradleyb@fuzziesquirrel.com> |
utils: fix in/pipe utilities
These examples stopped building with 3b36d17cf.
Fixes: 3b36d17cf18bd9ad13f043256371222e2845e4d9 Change-Id: I14218769afd1e9b8171de33b88028ef4a052ce17 Signed-off-by: Brad
utils: fix in/pipe utilities
These examples stopped building with 3b36d17cf.
Fixes: 3b36d17cf18bd9ad13f043256371222e2845e4d9 Change-Id: I14218769afd1e9b8171de33b88028ef4a052ce17 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
show more ...
|
edebe169 | 25-Aug-2021 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-demux-daemon: Cleanup binding on exit
This is necessary for e.g. the astlpc binding which should notify the host that the interface is no longer active if the daemon is going away.
Signed-off-
mctp-demux-daemon: Cleanup binding on exit
This is necessary for e.g. the astlpc binding which should notify the host that the interface is no longer active if the daemon is going away.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I3f92232017d8faa1f3cd9be7ec27043b900fd4be
show more ...
|
f8954b3f | 25-Aug-2021 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-demux-daemon: Fix cleanup path on socket_init() failure
Now that we have potentially set up packet capture, make sure to clean up the packet capture resources if we get a failure during socket
mctp-demux-daemon: Fix cleanup path on socket_init() failure
Now that we have potentially set up packet capture, make sure to clean up the packet capture resources if we get a failure during socket initialisation.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I138cc24509bc6009ad0f3adda282e045a099984c
show more ...
|
cad47301 | 20-Aug-2021 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-demux-daemon: Add packet capture option
Optionally enable libpcap support in mctp-demux-daemon to capture packets both from the Unix domain socket and binding interfaces. Providing the two capt
mctp-demux-daemon: Add packet capture option
Optionally enable libpcap support in mctp-demux-daemon to capture packets both from the Unix domain socket and binding interfaces. Providing the two capture points allows for tracking down issues with packets being dropped during binding initialisation.
As there's no formal linktype defined for MCTP or higher-level DMTF protocols command-line switches provide the ability to specify one of the private linktype values in the range 147-162.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I593d9e4be80c0198e643758f216e774169668a8c
show more ...
|
490e3873 | 24-Aug-2021 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-demux: Add signalfd support
This allows us to clean up resources when the process is terminated.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: Ia8ba75394490f0577bac7d860dbdb4f92e6
mctp-demux: Add signalfd support
This allows us to clean up resources when the process is terminated.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: Ia8ba75394490f0577bac7d860dbdb4f92e672d2d
show more ...
|
d4103f8f | 16-Jun-2021 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-demux-daemon: Use systemd socket activation
Take advantage of lazy initialisation.
However, this also allows (one) daemon providing services over MCTP (pldmd) an opportunity to start prior to
mctp-demux-daemon: Use systemd socket activation
Take advantage of lazy initialisation.
However, this also allows (one) daemon providing services over MCTP (pldmd) an opportunity to start prior to MCTP interfaces coming up. This is a stunted way to provide capabilities that might be assumed by other components (the host) without implementing some required messages from the MCTP standard.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I4b1c21f4fd42f84e2c85a453570a74330fc70ecf
show more ...
|
06735055 | 27-Jan-2021 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-demux-daemon: Warn about failed messages
It's possible that messages might not be sent if they are routed to a binding before that binding has completed its protocol initialisation.
Signed-off
mctp-demux-daemon: Warn about failed messages
It's possible that messages might not be sent if they are routed to a binding before that binding has completed its protocol initialisation.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I1ddf6817fdef974b61dcb3ce0f166af94b4b0f16
show more ...
|
d98b2b23 | 14-Jun-2020 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-astlpc-demux: Explicitly construct a fileio astlpc instance
mctp-astlpc-demux is run on BMCs in userspace, so fileio is what we require.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-
mctp-astlpc-demux: Explicitly construct a fileio astlpc instance
mctp-astlpc-demux is run on BMCs in userspace, so fileio is what we require.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: Iecd8df8901c14ea5924cdc1671b880b5f4824c6c
show more ...
|
b93b6112 | 04-Jun-2020 |
Andrew Jeffery <andrew@aj.id.au> |
bootstrap: Ratchet up compiler strictness
Replace the specific warning flags with -Wall -Wextra and turn on -Werror.
Covered by -Wall:
* -Wformat * -Warray-bounds * -Wimplicit-function-declaration
bootstrap: Ratchet up compiler strictness
Replace the specific warning flags with -Wall -Wextra and turn on -Werror.
Covered by -Wall:
* -Wformat * -Warray-bounds * -Wimplicit-function-declaration
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: Iab21e67026d2453648aa6ebe4c299e1162fc5ebf
show more ...
|
6896d41e | 10-Mar-2020 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-demux-daemon: Silence warnings on remote close
If applications constantly connect then disconnect from the demux daemon we see a "flood" of messages like:
Mar 05 07:15:47 w57 mctp-demux[17
mctp-demux-daemon: Silence warnings on remote close
If applications constantly connect then disconnect from the demux daemon we see a "flood" of messages like:
Mar 05 07:15:47 w57 mctp-demux[177]: mctp-demux-daemon: can't receive(peek) from client: Connection reset by peer Mar 05 07:15:52 w57 mctp-demux[177]: mctp-demux-daemon: can't receive(peek) from client: Connection reset by peer Mar 05 07:15:52 w57 mctp-demux[177]: mctp-demux-daemon: can't receive(peek) from client: Connection reset by peer Mar 05 07:15:53 w57 mctp-demux[177]: mctp-demux-daemon: can't receive(peek) from client: Connection reset by peer Mar 05 07:15:54 w57 mctp-demux[177]: mctp-demux-daemon: can't receive(peek) from client: Connection reset by peer
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I99eabffd45693e5ab570575c4c8cca2ee55196e0
show more ...
|
13a4041f | 07-Feb-2020 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-demux-daemon: Resolve uninitialised variable warning
Multiple error paths in client_process_recv() failed to set rc before returning it from the out_close label:
utils/mctp-demux-daemon.c:
mctp-demux-daemon: Resolve uninitialised variable warning
Multiple error paths in client_process_recv() failed to set rc before returning it from the out_close label:
utils/mctp-demux-daemon.c: In function ‘main’: utils/mctp-demux-daemon.c:457:7: error: ‘rc’ may be used uninitialized in this function [-Werror=maybe-uninitialized] 457 | if (rc) | ^ utils/mctp-demux-daemon.c:307:6: note: ‘rc’ was declared here 307 | int rc; | ^~ cc1: all warnings being treated as errors
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I4196a2b5f7b242c53921040fead102525c92a286
show more ...
|
04b81fc7 | 04-Feb-2020 |
Andrew Jeffery <andrew@aj.id.au> |
mctp-demux-daemon: Explicitly disable verbose before option parsing
Otherwise we have control flow dependent on uninitialised data.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I0d9e5
mctp-demux-daemon: Explicitly disable verbose before option parsing
Otherwise we have control flow dependent on uninitialised data.
Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Change-Id: I0d9e5512ce198ceddf8fb7a09d15c8de991d0dbd
show more ...
|