From: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
To: Narayana Prasad Athreya <pathreya@caviumnetworks.com>
Cc: Seth Jennings <sjenning@redhat.com>,
Mahipal Challa <mahipalreddy2006@gmail.com>,
herbert@gondor.apana.org.au, davem@davemloft.net,
linux-crypto@vger.kernel.org, LKML <linux-kernel@vger.kernel.org>,
Linux-MM <linux-mm@kvack.org>,
pathreya@cavium.com, vnair@cavium.com,
Mahipal Challa <Mahipal.Challa@cavium.com>,
Vishnu Nair <Vishnu.Nair@cavium.com>
Subject: Re: [RFC PATCH v1 1/1] mm: zswap - Add crypto acomp/scomp framework support
Date: Wed, 15 Feb 2017 22:12:08 +0000 [thread overview]
Message-ID: <20170215221208.GA820@silv-gc1.ir.intel.com> (raw)
In-Reply-To: <58A45E4A.8080508@caviumnetworks.com>
On Wed, Feb 15, 2017 at 07:27:30PM +0530, Narayana Prasad Athreya wrote:
> > I assume all of these crypto_acomp_[compress|decompress] calls are
> > actually synchronous,
> > not asynchronous as the name suggests. Otherwise, this would blow up
> > quite spectacularly
> > since all the resources we use in the call get derefed/unmapped below.
> >
> > Could an async algorithm be implement/used that would break this assumption?
>
> The callback is set to NULL using acomp_request_set_callback(). This implies
> synchronous mode of operation. So the underlying implementation must
> complete the operation synchronously.
This assumption is not correct. An asynchronous implementation, when
it finishes processing a request, will call acomp_request_complete() which
in turn calls the callback.
If the callback is set to NULL, this function will dereference a NULL
pointer.
Regards,
--
Giovanni
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2017-02-15 22:12 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-14 15:40 [RFC PATCH v1 0/1] mm: zswap - crypto acomp/scomp support Mahipal Challa
2017-02-14 15:40 ` [RFC PATCH v1 1/1] mm: zswap - Add crypto acomp/scomp framework support Mahipal Challa
2017-02-14 16:20 ` Seth Jennings
2017-02-15 13:57 ` Narayana Prasad Athreya
2017-02-15 22:12 ` Giovanni Cabiddu [this message]
2017-02-20 9:52 ` Nair, Vishnu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170215221208.GA820@silv-gc1.ir.intel.com \
--to=giovanni.cabiddu@intel.com \
--cc=Mahipal.Challa@cavium.com \
--cc=Vishnu.Nair@cavium.com \
--cc=davem@davemloft.net \
--cc=herbert@gondor.apana.org.au \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mahipalreddy2006@gmail.com \
--cc=pathreya@cavium.com \
--cc=pathreya@caviumnetworks.com \
--cc=sjenning@redhat.com \
--cc=vnair@cavium.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox