Re: [PATCH net-next v20 20/25] ovpn: implement peer add/get/dump/delete via netlink

From: Sabrina Dubroca
Date: Sun Mar 02 2025 - 13:24:44 EST


2025-02-27, 02:21:45 +0100, Antonio Quartulli wrote:
> @@ -1310,9 +1329,12 @@ void ovpn_peer_keepalive_work(struct work_struct *work)
> if (next_run > 0 && ovpn->registered) {
> netdev_dbg(ovpn->dev,
> "scheduling keepalive work: now=%llu next_run=%llu delta=%llu\n",
> - next_run, now, next_run - now);
> + next_run, now, next_run - now ?: 0);

nit: I don't think this "?: 0" does anything

> + /* due to the waiting above, the next_run deadline may have
> + * passed: in this case we reschedule the worker immediately
> + */
> schedule_delayed_work(&ovpn->keepalive_work,
> - (next_run - now) * HZ);
> + (next_run - now) * HZ ?: 0);

nit: same here

--
Sabrina