From mboxrd@z Thu Jan 1 00:00:00 1970 From: Subject: RE: [PATCH] net/ncsi: Add NCSI OEM command for FB Tiogapass Date: Wed, 26 Sep 2018 20:39:38 +0000 Message-ID: <5e9c8e3f8fd54845b15cd460efe9090d@AUSX13MPS306.AMER.DELL.COM> References: <20180925000840.4111212-1-vijaykhemka@fb.com> <7cd8a49a057f1032e126b1e104fcf61e4956e06d.camel@mendozajonas.com>, Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Cc: , , , To: , , , Return-path: Received: from esa2.dell-outbound.iphmx.com ([68.232.149.220]:1920 "EHLO esa2.dell-outbound.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726623AbeI0Cy0 (ORCPT ); Wed, 26 Sep 2018 22:54:26 -0400 Received: from pps.filterd (m0144104.ppops.net [127.0.0.1]) by mx0b-00154901.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w8QKcH5R129828 for ; Wed, 26 Sep 2018 16:39:41 -0400 Received: from esa2.dell-outbound2.iphmx.com (esa2.dell-outbound2.iphmx.com [68.232.153.202]) by mx0b-00154901.pphosted.com with ESMTP id 2mrgs506a3-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL) for ; Wed, 26 Sep 2018 16:39:41 -0400 In-Reply-To: Content-Language: en-US Sender: netdev-owner@vger.kernel.org List-ID: > > As I understand Justin's version adds a generic handler, using the NCS= I > > Netlink interface to pass OEM commands and responses to and from > > userspace, which does the actual packet handling. > Thanks for the direction Sam! Justin, if you don't mind, can you share th= e patches you have to add the support? This actually would solve a few othe= r things we are trying to accomplish. Basically, I add a new flag to indicate the request is coming from the Netl= ink interface to allow the command handler and response handler to react. #define NCSI_REQ_FLAG_NETLINK_DRIVEN 2 The work flow is as below.=20 Request: User space application -> Netlink interface (msg) -> new Netlink handler - = ncsi_send_cmd_nl() - ncsi_xmit_cmd() Response: Response received - ncsi_rcv_rsp() -> internal response handler - ncsi_rsp_= handler_xxx() -> ncsi_send_netlink_rsp () -> Netlink interface (msg) -> use= r space application Command timeout - ncsi_request_timeout() -> ncsi_send_netlink_timeout () ->= Netlink interface (msg with zero data length) -> user space application Error: Detected error -> ncsi_send_netlink_err () -> Netlink interface (err msg) -= > user space application I will clean up some code and send out the patch.=20 Thanks, Justin