summaryrefslogtreecommitdiffstats
path: root/sd_event_loop.hpp
Commit message (Collapse)AuthorAgeFilesLines
* netipmid: Remove unused event referencesVernon Mauery2019-02-251-3/+0
| | | | | | | | | | Now that all the provider libraries are only loaded by the main ipmid queue, there are no callers for the event object, so it can be removed. The same goes for the event loop; all users of the sd_event object have been replaced with boost::asio, so it can be removed. Change-Id: Id271c4960a2c5386d6163cc9baecdc368e5e328f Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* netipmid: move sol timers to asioVernon Mauery2019-02-011-100/+0
| | | | | | | | | The IPMI SOL console was using sd_event-based timers directly (without any abstraction). This moves to a much higher level abstraction that is very easy to use: asio timers. Change-Id: Id5df76a1918cdfae420e01884d664234810b7abd Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* netipmid: move sol console sockets to asioVernon Mauery2019-02-011-12/+0
| | | | | | | | Rewrite the SOL console sockets use boost::asio. This reduces code size and ties better into the main asio io loop. Change-Id: Ia79b9aa3fa3c7ce1ddd9b609b032160a88394f8c Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* netipmid: move raw sockets to boost::asio socketsVernon Mauery2019-02-011-3/+8
| | | | | | | | Replacing the raw socket code with boost::asio sockets once again provides a simple API with fewer lines of code. Change-Id: Ibdd4b5ecbead947128200f17025c351d9b3ec859 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* netipmid: move event loop to boost::asio::io_contextVernon Mauery2018-12-111-3/+10
| | | | | | | | | | Replacing the event loop with asio provides for more flexibility and less code than the sd_event model. Intially, this will require the loop to handle both sd_events with a wrapper, but after all the sd_event sources are replaced with asio event sources the wrapper can be removed. Change-Id: Icf020c6c26a214bb1239641733c89603501c0c49 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* netipmid: apply clang-format rulesVernon Mauery2018-11-021-114/+112
| | | | | | | | Lots of whitespace change. Let clang-format do its job and keep the code looking nice. Change-Id: Idfcad1a99cab8170d55a06163de8ad3f420b68b7 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* Create sd_event outside from EventLoopRatan Gupta2018-03-271-1/+2
| | | | | | | | | | | | | | | Presently timer in the provider library needs the sd_event and sd_event gets created in the startEventLoop. RegisterCallbackHandlers gets called before the startEventLoop hence not getting the event. This commit creates the sd_event outside from the sd_event_loop and pass the sd_event reference to the startEventLoop function. Tested: run the fru print in net-ipmid context. Change-Id: I2b227154ba60e56d7faa6c8000c20a5231c4417c Signed-off-by: Ratan Gupta <ratagupt@in.ibm.com>
* Define the ipmid_get_sd_bus_event_connectionRatan Gupta2018-03-211-2/+3
| | | | | | | | | | | | | | Due to the phosphor-host-ipmid commit (7a7f01) transporthandler.cpp start referring to the ipmid_get_sd_bus_event_connection function and transporthandler.cpp is a provider library for phosphor-net-ipmid. This commit defines the ipmid_get_sd_bus_event_connection function in the context of phosphor-net-ipmid process. Change-Id: I7fbc39f526138615966a90f78884a80b4cf063f4 Signed-off-by: Ratan Gupta <ratagupt@in.ibm.com>
* Add API to add host console socket to the event loop.Tom Joseph2017-04-241-0/+6
| | | | | Change-Id: Iee5eacb0948fa5bed8426f38cdbdc04cdf7afa90 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Interfaces for the sd_event_loop adaptationTom Joseph2017-04-241-0/+147
The sd_event_loop is adapted for handling the udp socket for IPMI network traffic, host console unix socket, character accumulate interval timer & retry interval timer for the SOL payload. Change-Id: I6ccec70821c01ae6db0bf04049a61e7854a798ec Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
OpenPOWER on IntegriCloud