Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp5426998ybi; Tue, 4 Jun 2019 06:33:56 -0700 (PDT) X-Google-Smtp-Source: APXvYqxxZYk0NJHzXzGF0Yqvzie9CJdJv/MKL2/r7pkIWfDmHoV/uO67uIs7E69Kj1fqY3ANDM37 X-Received: by 2002:a63:144e:: with SMTP id 14mr35136067pgu.304.1559655236045; Tue, 04 Jun 2019 06:33:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559655236; cv=none; d=google.com; s=arc-20160816; b=K6oJW02TGblfh+/bSGO8v/T12X5dgQbgnBlH5ZiOpsrQhtwvFvr4/ImlHdW25+MLF3 Dd0Ti9zToZl42FPVERjGMlCOJLRkrmu34LB2c9YHkfGISAGb9AjhqL9Ga1vbdMzs4bFP 12E4Vezw9grBfL+XdRqwILs8CZ1ECbHEIfUe4hD96UMDmCmDuu3GmlPT8uJEBxwH38rn jfqAPfULrK6wCB11bdjzV18h69HFJD8G9AgW1LqlbvRiEugE5PjCeJhl4FmA9kkaL867 qDqgOaybj+gaZ+utrBglJ+ODVTtjUok01FOfovQTxc94T3HE4qx6e7AeHODL9StUYOil ct2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:dlp-filter:cms-type :content-transfer-encoding:date:message-id:in-reply-to:cc:to:from :reply-to:subject:mime-version:dkim-signature:dkim-filter; bh=1aLsXVY/wr2CuW5Tk9MkhyWV/LeW13egcTyA8RW2iMM=; b=J6jRi7tHROiPcNNYxV1gi/Au3K+Vwt3Xvgzt2vSt12WLlsk+TtrI2Y1BjyYsAFpnBI FkQRBCHwCqdsvhc2RwAb/nymq82jS6NVQnJz2TKCpa5dOqXctvVsg3WwCw9v8oD3jLCi WlmkBgRkIPO1+INFjBqf4i/ysEWBuKo4mqu4k/0KMmh7ImU7Bu85edNDP2oiwq5Oe18s IW+c2Bfg4VMdWcVlui71ZjosK+HEqtUTnobXw+hz0//6m4vChQ7hrb6jfMGJUySZfyAp aT6nbS0CdNIAXqqg/Bpczl/xQ5rRad2r3GB1IcRIKtwYEqc4n3fqZiKE9Mc2KT8OYo1Q 2lGQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=q+llcIgm; spf=pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y1si17375791plk.374.2019.06.04.06.33.30; Tue, 04 Jun 2019 06:33:56 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=q+llcIgm; spf=pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727212AbfFDNdV (ORCPT + 99 others); Tue, 4 Jun 2019 09:33:21 -0400 Received: from mailout4.samsung.com ([203.254.224.34]:14395 "EHLO mailout4.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727229AbfFDNdV (ORCPT ); Tue, 4 Jun 2019 09:33:21 -0400 Received: from epcas5p4.samsung.com (unknown [182.195.41.42]) by mailout4.samsung.com (KnoxPortal) with ESMTP id 20190604133318epoutp04a83719748429dd02fd9db9d31b415d53~lAiO-ihlq0515305153epoutp044 for ; Tue, 4 Jun 2019 13:33:18 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout4.samsung.com 20190604133318epoutp04a83719748429dd02fd9db9d31b415d53~lAiO-ihlq0515305153epoutp044 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1559655198; bh=1aLsXVY/wr2CuW5Tk9MkhyWV/LeW13egcTyA8RW2iMM=; h=Subject:Reply-To:From:To:CC:In-Reply-To:Date:References:From; b=q+llcIgmIE+nKyEDth0vGJXSKXjwIqcmCCtAk3njiGlG1Zcjo+KbhmDs46qiWA1Ip VFw9TC0LpBOkTs1G52XMVguAPaPl4nJmo4zCxHitr5uK/SJ9H6HhAydGQGAJQyO8xh ltM9eRTLDnk/uBBAFpTwycgde84/r1BGFStb8chY= Received: from epsmges5p1new.samsung.com (unknown [182.195.40.193]) by epcas5p3.samsung.com (KnoxPortal) with ESMTP id 20190604133316epcas5p3b088c59033d7fd46263f8507907a9ba2~lAiM63HyX2076420764epcas5p3r; Tue, 4 Jun 2019 13:33:16 +0000 (GMT) X-AuditID: b6c32a49-5b7ff70000000fe7-3f-5cf6731c2aaf Received: from epcas5p3.samsung.com ( [182.195.41.41]) by epsmges5p1new.samsung.com (Symantec Messaging Gateway) with SMTP id AF.03.04071.C1376FC5; Tue, 4 Jun 2019 22:33:16 +0900 (KST) Mime-Version: 1.0 Subject: RE:(2) [PATCH 1/4] zstd: pass pointer rathen than structure to functions Reply-To: v.narang@samsung.com From: Vaneet Narang To: Andrew Morton , Maninder Singh CC: "herbert@gondor.apana.org.au" , "davem@davemloft.net" , "keescook@chromium.org" , "gustavo@embeddedor.com" , "joe@perches.com" , "linux-crypto@vger.kernel.org" , "linux-kernel@vger.kernel.org" , AMIT SAHRAWAT , PANKAJ MISHRA , Vaneet Narang X-Priority: 3 X-Content-Kind-Code: NORMAL In-Reply-To: <20190603144132.7611b8fe3cf6928d8391a24a@linux-foundation.org> X-Drm-Type: N,general X-Msg-Generator: Mail X-Msg-Type: PERSONAL X-Reply-Demand: N Message-ID: <20190604131935epcms5p1c4a375fca57e4df5d233fd2769a3c2be@epcms5p1> Date: Tue, 04 Jun 2019 18:49:35 +0530 X-CMS-MailID: 20190604131935epcms5p1c4a375fca57e4df5d233fd2769a3c2be Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" X-Sendblock-Type: REQ_APPROVE CMS-TYPE: 105P X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFtrBJsWRmVeSWpSXmKPExsWy7bCmpq5M8bcYg/u/eS0u7k61mLN+DZvF nPMtLBZb96hadL+SsZh9/zGLxZnuXIv7934yWVzeNYfN4vD8NhaLe2+2MlkcOjmX0YHHY3bD RRaPLStvMnmsO6jqse2AqseJGb9ZPL6susbs0bdlFaPH501yARxROTYZqYkpqUUKqXnJ+SmZ eem2St7B8c7xpmYGhrqGlhbmSgp5ibmptkouPgG6bpk5QIcqKZQl5pQChQISi4uV9O1sivJL S1IVMvKLS2yVUgtScgoMjQr0ihNzi0vz0vWS83OtDA0MjEyBKhNyMq73XmYpaGet6Pq2ia2B 8RNLFyMnh4SAiUTnhtesXYxcHEICuxkllh9eC+RwcPAKCEr83SEMYgoLBEvM/5MBUi4kICdx /MZuRhBbWEBH4sS8NYwgJWwCWhIfW8JBTBGBSIlbq9RBBjILfGaWaD/ziRFiE6/EjPanUFul JbYv3woW5xTwlri5bi87RFxU4ubqt3D2+2PzoXpFJFrvnWWGsAUlHvzcDbZWQkBGYtdbcZBd EgLdjBITzi1nhXBmMEqc6n0D1WAucf7kfDCbV8BXYtGaq0wgNouAqsSLx+fZIQa5SPx+Vg4S ZhbQlli28DUzSJhZQFNi/S59iCmyElNPrWOCKOGT6P39hAnmrR3zYGwliXMHd7JB2BISTzpn Ql3gIfFobRs0kHuYJI5MPc08gVFhFiKcZyHZPAth8wJG5lWMkqkFxbnpqcWmBYZ5qeXIsbuJ EZxqtTx3MM4653OIUYCDUYmHd0b8txgh1sSy4srcQ4wSHMxKIryJt7/ECPGmJFZWpRblxxeV 5qQWH2I0BQbBRGYp0eR8YB7IK4k3NDUyMzOwNDA1tjAzVBLnncR6NUZIID2xJDU7NbUgtQim j4mDU6qBMXaV5hbHVOMPv5IOpYrc6VrwflfeDQ1btS8C1Wde/uK6qSF/56lU9cHVV158Kn1s c36hcEQ/h0XvFZl5r86svsQjvO6hktDe2yeln4rFF27vNF0YVMap8POD7MWAzZZB2w8YTMvb dLZxsZOWecOU+xPXPSnYY65gzJMRE2S0JPq+yukN+36vF1ViKc5INNRiLipOBACEjAf6ywMA AA== DLP-Filter: Pass X-CFilter-Loop: Reflected X-CMS-RootMailID: 20190603090232epcas5p1630d0584e8a1aa9495edc819605664fc References: <20190603144132.7611b8fe3cf6928d8391a24a@linux-foundation.org> <1559552526-4317-1-git-send-email-maninder1.s@samsung.com> <1559552526-4317-2-git-send-email-maninder1.s@samsung.com> Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org Hi Andrew, =C2=A0=0D=0A>But=C2=A0struct=C2=A0ZSTD_CCtx_s.params=C2=A0is=C2=A0still=C2= =A0a=C2=A0copied=C2=A0structure.=C2=A0=C2=A0Could=C2=A0we=0D=0A>make=C2=A0i= t=C2=A0=60const=C2=A0ZSTD_parameters=C2=A0*params'?=C2=A0=C2=A0Probably=C2= =A0not,=C2=A0due=C2=A0to=C2=A0lifetime=0D=0A>issues?=0D=0A=0D=0AZSTD=20main= tains=20its=20own=20ctxt.=20Yes=20we=20can=20avoid=20storing=20pointers=20o= f=20other=20modules=0D=0Abecause=20of=20lifetime=20issues.=20We=20should=20= keep=20ZSTD_CCtx_s.params=20as=20structure=20instead=20of=20pointer.=0D=0A= =0D=0A=0D=0AThanks=20&=20Regards,=0D=0AVaneet=20Narang=20=0D=0A=0D=0A=C2=A0= =0D=0A=C2=A0