From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id A0C66A32A4 for ; Fri, 25 Oct 2019 21:02:11 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 7B3701E558; Fri, 25 Oct 2019 21:02:11 +0200 (CEST) Received: from mail-pf1-f194.google.com (mail-pf1-f194.google.com [209.85.210.194]) by dpdk.org (Postfix) with ESMTP id D223D1E550 for ; Fri, 25 Oct 2019 21:02:09 +0200 (CEST) Received: by mail-pf1-f194.google.com with SMTP id v19so2196177pfm.3 for ; Fri, 25 Oct 2019 12:02:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=UmaNYGOl+2jpmlRUPnGWIQbqMIvHSboyv7XMLwAh29Y=; b=pA7Sv8Zrp3j8NfKT7rPJCaNtVJqJzTG2YrrdzoB6c3zyR6b9w3UkeR/oo8G6LG1hps yYGfcvOM8DIwEx+2KYt+2NhdRrevDfDS4CBYdTgISwZIrzmWninceFLdrv0TJo9h/3Tg kI4TnxukEjYpPhRy8bCMX9kM9uw+/OWMYGdwAjCGoM0LC11yenzbc9ERfhpr9OwOnU1E cgFzWkMC01DygycGAST2xcacVuOW8IBYLZFSgql+XUIEH0SgnSnvSsJsiMygU4cMNwqY OurPocAdHHhPyCmEjiHZl1NlOxv8+D4L/5oi2PflMKBOM0me9FKmLALHrHQhh9vU94c6 XSRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=UmaNYGOl+2jpmlRUPnGWIQbqMIvHSboyv7XMLwAh29Y=; b=dMS2FdhmP0+If4EGgSY39joBb/8ertkeX9LGoZrpN3jOKwZYynngXg0xdo7HtEIPAd Ris/EAtQUxSIidJNtz/aMDEJHPQ04SB+94FxgduW2AbS/YI0MtWjKywo8RqVjp5TFidj 3eUT35JjGqv1+Llv1+cBxhCVjqur7rB/WdCRXObhcPzJ3sXWXW6m+xhe/UnkoD8xwJ/Z GbacYlfR8u8E6nR0KQCoHL3xLUbVut1HwYq4c8NQ7hALdzOeEMeDriz2nxCB/UV3EGM2 JEDxlemBM60y48t2IhTI010gdIYP/ATpuKvAzhxW8X1TideiC1oPYFo+FHrc+ZCTH11l n0VA== X-Gm-Message-State: APjAAAUAPvWVNUku4orm/swjKw/znb0CpZ4+hp6rjna1NHJRQZniU1pN tTp5mTeGACUK9Xfgh0+0js1obQ== X-Google-Smtp-Source: APXvYqykl76LuIm7UUDx1GruAeOPKnk4GmZ/DtPwXgBq9klLyJZ35BY35FKnlVfYzs+4b2AWLWDP+Q== X-Received: by 2002:a62:2b55:: with SMTP id r82mr6042217pfr.56.1572030129096; Fri, 25 Oct 2019 12:02:09 -0700 (PDT) Received: from hermes.lan (204-195-22-127.wavecable.com. [204.195.22.127]) by smtp.gmail.com with ESMTPSA id ev14sm2829878pjb.32.2019.10.25.12.02.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Oct 2019 12:02:08 -0700 (PDT) Date: Fri, 25 Oct 2019 12:02:05 -0700 From: Stephen Hemminger To: Pavel Belous Cc: "dev@dpdk.org" , Ferruh Yigit , Akhil Goyal , John McNamara , Declan Doherty , Konstantin Ananyev , Thomas Monjalon , Igor Russkikh , Fenilkumar Patel , Hitesh K Maisheri Message-ID: <20191025120205.5114b782@hermes.lan> In-Reply-To: <357ff7d38cb313efe4278dc7cf175bb60bab398b.1571928488.git.Pavel.Belous@aquantia.com> References: <357ff7d38cb313efe4278dc7cf175bb60bab398b.1571928488.git.Pavel.Belous@aquantia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [RFC v2 6/7] app/testpmd: macsec on/off commands using rte_security interface X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Fri, 25 Oct 2019 17:54:08 +0000 Pavel Belous wrote: > +int set_macsec_on_off(portid_t port_id, int on, int en, int rp) > +{ > + struct rte_security_session_conf macsec_conf; > + struct rte_security_ctx *ctx; > + struct rte_mempool *mp; > + int err = 0; > + > + ctx = rte_eth_dev_get_sec_ctx(port_id); > + > + if (!ctx) { blank line between assignment and the if() statement is not necessary.