diff --git a/daemon/face/lp-reliability.hpp b/daemon/face/lp-reliability.hpp
index 17b2e44..415a06d 100644
--- a/daemon/face/lp-reliability.hpp
+++ b/daemon/face/lp-reliability.hpp
@@ -39,7 +39,7 @@
 class GenericLinkService;
 
 /**
- * \brief Provides for reliable sending and receiving of link-layer packets
+ * \brief Provides for reliable sending and receiving of link-layer packets.
  * \sa https://redmine.named-data.net/projects/nfd/wiki/NDNLPv2
  */
 class LpReliability : noncopyable
@@ -52,31 +52,31 @@
 
   struct Options
   {
-    /** \brief enables link-layer reliability
+    /** \brief Enables link-layer reliability.
      */
     bool isEnabled = false;
 
-    /** \brief maximum number of retransmissions for an LpPacket
+    /** \brief Maximum number of retransmissions for an LpPacket.
      */
     size_t maxRetx = 3;
 
-    /** \brief period between sending pending Acks in an IDLE packet
+    /** \brief Period between sending pending Acks in an IDLE packet.
      */
     time::nanoseconds idleAckTimerPeriod = 5_ms;
 
-    /** \brief a fragment is considered lost if this number of fragments with greater sequence
-     *         numbers are acknowledged
+    /** \brief A fragment is considered lost if this number of fragments with greater sequence
+     *         numbers are acknowledged.
      */
     size_t seqNumLossThreshold = 3;
   };
 
   LpReliability(const Options& options, GenericLinkService* linkService);
 
-  /** \brief signals on Interest dropped by reliability system for exceeding allowed number of retx
+  /** \brief Signals on Interest dropped by reliability system for exceeding allowed number of retx.
    */
   signal::Signal<LpReliability, Interest> onDroppedInterest;
 
-  /** \brief set options for reliability
+  /** \brief Set options for reliability.
    */
   void
   setOptions(const Options& options);
@@ -88,7 +88,7 @@
   const GenericLinkService*
   getLinkService() const;
 
-  /** \brief observe outgoing fragment(s) of a network packet and store for potential retransmission
+  /** \brief Observe outgoing fragment(s) of a network packet and store for potential retransmission.
    *  \param frags fragments of network packet
    *  \param pkt encapsulated network packet
    *  \param isInterest whether the network packet is an Interest
@@ -96,16 +96,16 @@
   void
   handleOutgoing(std::vector<lp::Packet>& frags, lp::Packet&& pkt, bool isInterest);
 
-  /** \brief extract and parse all Acks and add Ack for contained Fragment (if any) to AckQueue
+  /** \brief Extract and parse all Acks and add Ack for contained Fragment (if any) to AckQueue.
    *  \param pkt incoming LpPacket
    *  \return whether incoming LpPacket is new and not a duplicate
    */
   bool
   processIncomingPacket(const lp::Packet& pkt);
 
-  /** \brief called by GenericLinkService to attach Acks onto an outgoing LpPacket
+  /** \brief Called by GenericLinkService to attach Acks onto an outgoing LpPacket.
    *  \param pkt outgoing LpPacket to attach Acks to
-   *  \param mtu MTU of the Transport
+   *  \param mtu MTU of the transport
    */
   void
   piggyback(lp::Packet& pkt, ssize_t mtu);
@@ -115,7 +115,7 @@
   class NetPkt;
   using UnackedFrags = std::map<lp::Sequence, UnackedFrag>;
 
-  /** \brief assign TxSequence number to a fragment
+  /** \brief Assign TxSequence number to a fragment.
    *  \param frag fragment to assign TxSequence to
    *  \return assigned TxSequence number
    *  \throw std::length_error assigned TxSequence is equal to the start of the existing window
@@ -123,7 +123,7 @@
   lp::Sequence
   assignTxSequence(lp::Packet& frag);
 
-  /** \brief start the idle Ack timer
+  /** \brief Start the idle Ack timer.
    *
    * This timer requests an IDLE packet to acknowledge pending fragments not already piggybacked.
    * It is called regularly on a period configured in Options::idleAckTimerPeriod. This allows Acks
@@ -132,22 +132,22 @@
   void
   startIdleAckTimer();
 
-  /** \brief find and mark as lost fragments where a configurable number of Acks
-   *         (\p m_options.seqNumLossThreshold) have been received for greater TxSequence numbers
+  /** \brief Find and mark as lost fragments where a configurable number of Acks
+   *         (Options::seqNumLossThreshold) have been received for greater TxSequence numbers.
    *  \param ackIt iterator pointing to acknowledged fragment
    *  \return vector containing TxSequences of fragments marked lost by this mechanism
    */
   std::vector<lp::Sequence>
   findLostLpPackets(UnackedFrags::iterator ackIt);
 
-  /** \brief resend (or give up on) a lost fragment
+  /** \brief Resend (or give up on) a lost fragment.
    *  \return vector of the TxSequences of fragments removed due to a network packet being removed
    */
   std::vector<lp::Sequence>
   onLpPacketLost(lp::Sequence txSeq, bool isTimeout);
 
-  /** \brief remove the fragment with the given sequence number from the map of unacknowledged
-   *         fragments, as well as its associated network packet (if any)
+  /** \brief Remove the fragment with the given sequence number from the map of unacknowledged
+   *         fragments, as well as its associated network packet (if any).
    *  \param fragIt iterator to acknowledged fragment
    *
    *  If the given TxSequence marks the beginning of the send window, the window will be incremented.
@@ -156,7 +156,7 @@
   void
   onLpPacketAcknowledged(UnackedFrags::iterator fragIt);
 
-  /** \brief delete a fragment from UnackedFrags and advance acknowledge window if necessary
+  /** \brief Delete a fragment from UnackedFrags and advance acknowledge window if necessary.
    *  \param fragIt iterator to an UnackedFrag, must be dereferencable
    *  \post fragIt is not in m_unackedFrags
    *  \post if was equal to m_firstUnackedFrag,
@@ -168,7 +168,7 @@
 
 NFD_PUBLIC_WITH_TESTS_ELSE_PRIVATE:
   /**
-   * \brief Contains a sent fragment that has not been acknowledged and associated data
+   * \brief Contains a sent fragment that has not been acknowledged and associated data.
    */
   class UnackedFrag
   {
@@ -179,14 +179,14 @@
   public:
     lp::Packet pkt;
     scheduler::ScopedEventId rtoTimer;
-    time::steady_clock::TimePoint sendTime;
+    time::steady_clock::time_point sendTime;
     size_t retxCount;
     size_t nGreaterSeqAcks; //!< number of Acks received for sequences greater than this fragment
     shared_ptr<NetPkt> netPkt;
   };
 
   /**
-   * \brief Contains a network-layer packet with unacknowledged fragments
+   * \brief Contains a network-layer packet with unacknowledged fragments.
    */
   class NetPkt
   {
@@ -203,14 +203,13 @@
   Options m_options;
   GenericLinkService* m_linkService;
   UnackedFrags m_unackedFrags;
-  /** An iterator that points to the first unacknowledged fragment in the current window. The window
-   *  can wrap around so that the beginning of the window is at a TxSequence greater than other
-   *  fragments in the window. When the window is moved past the last item in the iterator, the
-   *  first fragment in the map will become the start of the window.
-   */
+  // An iterator that points to the first unacknowledged fragment in the current window. The window
+  // can wrap around so that the beginning of the window is at a TxSequence greater than other
+  // fragments in the window. When the window is moved past the last item in the iterator, the
+  // first fragment in the map will become the start of the window.
   UnackedFrags::iterator m_firstUnackedFrag;
   std::queue<lp::Sequence> m_ackQueue;
-  std::map<lp::Sequence, time::steady_clock::TimePoint> m_recentRecvSeqs;
+  std::map<lp::Sequence, time::steady_clock::time_point> m_recentRecvSeqs;
   std::queue<lp::Sequence> m_recentRecvSeqsQueue;
   lp::Sequence m_lastTxSeqNo;
   scheduler::ScopedEventId m_idleAckTimer;
