| Message ID | 20251222152356.301762-5-amorenoz@redhat.com |
|---|---|
| State | New |
| Headers | show
Return-Path: <ovs-dev-bounces@openvswitch.org> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=J2SXkcbQ; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=140.211.166.138; helo=smtp1.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=patchwork.ozlabs.org) Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4dZhkw6Mnlz1y4J for <incoming@patchwork.ozlabs.org>; Tue, 23 Dec 2025 02:24:24 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 39534822E9; Mon, 22 Dec 2025 15:24:23 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id OZKro7tHqU5Z; Mon, 22 Dec 2025 15:24:21 +0000 (UTC) X-Comment: SPF check N/A for local connections - client-ip=2605:bc80:3010:104::8cd3:938; helo=lists.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=<UNKNOWN> DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 1CA8482283 Authentication-Results: smtp1.osuosl.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=J2SXkcbQ Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [IPv6:2605:bc80:3010:104::8cd3:938]) by smtp1.osuosl.org (Postfix) with ESMTPS id 1CA8482283; Mon, 22 Dec 2025 15:24:19 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 7CF28C0642; Mon, 22 Dec 2025 15:24:18 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by lists.linuxfoundation.org (Postfix) with ESMTP id 13A64C0641 for <dev@openvswitch.org>; Mon, 22 Dec 2025 15:24:18 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 052EF404F0 for <dev@openvswitch.org>; Mon, 22 Dec 2025 15:24:18 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id iQ6yf25c1Yyo for <dev@openvswitch.org>; Mon, 22 Dec 2025 15:24:17 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=170.10.129.124; helo=us-smtp-delivery-124.mimecast.com; envelope-from=amorenoz@redhat.com; receiver=<UNKNOWN> DMARC-Filter: OpenDMARC Filter v1.4.2 smtp2.osuosl.org CFA7F40542 Authentication-Results: smtp2.osuosl.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org CFA7F40542 Authentication-Results: smtp2.osuosl.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=J2SXkcbQ Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by smtp2.osuosl.org (Postfix) with ESMTPS id CFA7F40542 for <dev@openvswitch.org>; Mon, 22 Dec 2025 15:24:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1766417055; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=zKPxgBH+n/pbS7NCUp2WKnMMhuiHFsWNzqy4PDOmp/c=; b=J2SXkcbQJumSpw7ciwjDYjN9C2RR09uqlU3R0CGCbtgERpD/pDFPivLLsTsXJw4Sg6+dmg zaKd3M/cg6Ohq1KRfLFYNBaRDMUot/CMxkBgjEUFZIg5NrLp4y6FqDsh0WU7Uov6xPYXPv krtHN0pIQUfkCcX98IlF4VkWntlWUnY= Received: from mx-prod-mc-05.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-515-ZnSUUqi9P7K2CZKdmhVnMg-1; Mon, 22 Dec 2025 10:24:14 -0500 X-MC-Unique: ZnSUUqi9P7K2CZKdmhVnMg-1 X-Mimecast-MFC-AGG-ID: ZnSUUqi9P7K2CZKdmhVnMg_1766417053 Received: from mx-prod-int-08.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-08.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.111]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-05.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 9BCA5195609D for <dev@openvswitch.org>; Mon, 22 Dec 2025 15:24:13 +0000 (UTC) Received: from antares.redhat.com (unknown [10.45.224.150]) by mx-prod-int-08.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 28F75180045B; Mon, 22 Dec 2025 15:24:11 +0000 (UTC) To: dev@openvswitch.org Date: Mon, 22 Dec 2025 16:23:40 +0100 Message-ID: <20251222152356.301762-5-amorenoz@redhat.com> In-Reply-To: <20251222152356.301762-1-amorenoz@redhat.com> References: <20251222152356.301762-1-amorenoz@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.111 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: vmDUERhx-XwQcttv5AAZULStfJRFQcn9PETGXPJ1UN4_1766417053 X-Mimecast-Originator: redhat.com Subject: [ovs-dev] [PATCH v1 4/9] netlink-notifier: Drain socket on overflow. X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: <ovs-dev.openvswitch.org> List-Unsubscribe: <https://mail.openvswitch.org/mailman/options/ovs-dev>, <mailto:ovs-dev-request@openvswitch.org?subject=unsubscribe> List-Archive: <http://mail.openvswitch.org/pipermail/ovs-dev/> List-Post: <mailto:ovs-dev@openvswitch.org> List-Help: <mailto:ovs-dev-request@openvswitch.org?subject=help> List-Subscribe: <https://mail.openvswitch.org/mailman/listinfo/ovs-dev>, <mailto:ovs-dev-request@openvswitch.org?subject=subscribe> From: Adrian Moreno via dev <ovs-dev@openvswitch.org> Reply-To: Adrian Moreno <amorenoz@redhat.com> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" <ovs-dev-bounces@openvswitch.org> |
| Series |
netdev-linux: Use event-driven netlink notifications.
|
expand
|
| Context | Check | Description |
|---|---|---|
| ovsrobot/apply-robot | success | apply and check: success |
| ovsrobot/github-robot-_Build_and_Test | success | github build: passed |
diff --git a/lib/netlink-notifier.c b/lib/netlink-notifier.c index 7ea5a4181..ea4742a90 100644 --- a/lib/netlink-notifier.c +++ b/lib/netlink-notifier.c @@ -200,6 +200,7 @@ nln_run(struct nln *nln) return; } else { if (error == ENOBUFS) { + nl_sock_drain(nln->notify_sock); /* The socket buffer might be full, there could be too many * notifications, so it makes sense to call nln_report() */ nln_report(nln, NULL, 0);
If the netlink socket overflows, we report an empty change to let all notifiers know some events are lost and therefore they can no longer trust their known state. This acts as a kind of reset. Draining the socket makes sense here so that partial events are not sent afterwards. Signed-off-by: Adrian Moreno <amorenoz@redhat.com> --- lib/netlink-notifier.c | 1 + 1 file changed, 1 insertion(+)