From patchwork Wed Sep 9 10:09:41 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Numan Siddique X-Patchwork-Id: 1360532 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=140.211.166.136; helo=silver.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=ovn.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4Bmd6q3tk3z9sTN for ; Wed, 9 Sep 2020 20:09:55 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id E9BED2E17D; Wed, 9 Sep 2020 10:09:53 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Cs9WKG1eBgSx; Wed, 9 Sep 2020 10:09:52 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by silver.osuosl.org (Postfix) with ESMTP id 74A9422E96; Wed, 9 Sep 2020 10:09:52 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 51FDEC0891; Wed, 9 Sep 2020 10:09:52 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by lists.linuxfoundation.org (Postfix) with ESMTP id AEA7CC0051 for ; Wed, 9 Sep 2020 10:09:50 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 8FEB322E96 for ; Wed, 9 Sep 2020 10:09:50 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id hwl3VkQIw5mh for ; Wed, 9 Sep 2020 10:09:49 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from relay7-d.mail.gandi.net (relay7-d.mail.gandi.net [217.70.183.200]) by silver.osuosl.org (Postfix) with ESMTPS id 8218E203F0 for ; Wed, 9 Sep 2020 10:09:49 +0000 (UTC) X-Originating-IP: 27.7.129.187 Received: from nusiddiq.home.org.com (unknown [27.7.129.187]) (Authenticated sender: numans@ovn.org) by relay7-d.mail.gandi.net (Postfix) with ESMTPSA id B56DB20002; Wed, 9 Sep 2020 10:09:45 +0000 (UTC) From: numans@ovn.org To: dev@openvswitch.org Date: Wed, 9 Sep 2020 15:39:41 +0530 Message-Id: <20200909100941.649009-1-numans@ovn.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200909100903.648778-1-numans@ovn.org> References: <20200909100903.648778-1-numans@ovn.org> MIME-Version: 1.0 Subject: [ovs-dev] [PATCH ovn v2 1/4] I-P engine: Provide the option to store client data in engine ctx. X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" From: Numan Siddique There can be some client specific data which could change from one engine run to another. Adding a 'void *' data in 'struct engine_ctx' will be useful. One such usecase is to provide a config option in ovn-controller to turn on or off logical flow expr caching. And this config knob can be stored in the engine_ctx. An upcoming patch will make use of this. Signed-off-by: Numan Siddique --- lib/inc-proc-eng.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/inc-proc-eng.h b/lib/inc-proc-eng.h index e25bcb29c6..80de75029e 100644 --- a/lib/inc-proc-eng.h +++ b/lib/inc-proc-eng.h @@ -66,6 +66,7 @@ struct engine_context { struct ovsdb_idl_txn *ovs_idl_txn; struct ovsdb_idl_txn *ovnsb_idl_txn; + void *client_ctx; }; /* Arguments to be passed to the engine at engine_init(). */