<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/crypto/inside-secure, branch v4.15</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v4.15</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v4.15'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2017-12-22T08:48:01Z</updated>
<entry>
<title>crypto: inside-secure - do not use areq-&gt;result for partial results</title>
<updated>2017-12-22T08:48:01Z</updated>
<author>
<name>Antoine Ténart</name>
<email>antoine.tenart@free-electrons.com</email>
</author>
<published>2017-12-11T11:10:58Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=2973633e9f09311e849f975d969737af81a521ff'/>
<id>urn:sha1:2973633e9f09311e849f975d969737af81a521ff</id>
<content type='text'>
This patches update the SafeXcel driver to stop using the crypto
ahash_request result field for partial results (i.e. on updates).
Instead the driver local safexcel_ahash_req state field is used, and
only on final operations the ahash_request result buffer is updated.

Fixes: 1b44c5a60c13 ("crypto: inside-secure - add SafeXcel EIP197 crypto engine driver")
Signed-off-by: Antoine Tenart &lt;antoine.tenart@free-electrons.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: inside-secure - fix request allocations in invalidation path</title>
<updated>2017-12-22T08:48:00Z</updated>
<author>
<name>Antoine Ténart</name>
<email>antoine.tenart@free-electrons.com</email>
</author>
<published>2017-12-11T11:10:57Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=7cad2fabd5691dbb17762877d4e7f236fe4bc181'/>
<id>urn:sha1:7cad2fabd5691dbb17762877d4e7f236fe4bc181</id>
<content type='text'>
This patch makes use of the SKCIPHER_REQUEST_ON_STACK and
AHASH_REQUEST_ON_STACK helpers to allocate enough memory to contain both
the crypto request structures and their embedded context (__ctx).

Fixes: 1b44c5a60c13 ("crypto: inside-secure - add SafeXcel EIP197 crypto engine driver")
Suggested-by: Ofer Heifetz &lt;oferh@marvell.com&gt;
Signed-off-by: Antoine Tenart &lt;antoine.tenart@free-electrons.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: inside-secure - free requests even if their handling failed</title>
<updated>2017-12-22T08:48:00Z</updated>
<author>
<name>Antoine Ténart</name>
<email>antoine.tenart@free-electrons.com</email>
</author>
<published>2017-12-11T11:10:56Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0a02dcca126280595950f3ea809f77c9cb0a235c'/>
<id>urn:sha1:0a02dcca126280595950f3ea809f77c9cb0a235c</id>
<content type='text'>
This patch frees the request private data even if its handling failed,
as it would never be freed otherwise.

Fixes: 1b44c5a60c13 ("crypto: inside-secure - add SafeXcel EIP197 crypto engine driver")
Suggested-by: Ofer Heifetz &lt;oferh@marvell.com&gt;
Signed-off-by: Antoine Tenart &lt;antoine.tenart@free-electrons.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: inside-secure - per request invalidation</title>
<updated>2017-12-22T08:47:59Z</updated>
<author>
<name>Ofer Heifetz</name>
<email>oferh@marvell.com</email>
</author>
<published>2017-12-11T11:10:55Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=1eb7b40386c97f6c4d1c62931bf306f4535a4bd6'/>
<id>urn:sha1:1eb7b40386c97f6c4d1c62931bf306f4535a4bd6</id>
<content type='text'>
When an invalidation request is needed we currently override the context
.send and .handle_result helpers. This is wrong as under high load other
requests can already be queued and overriding the context helpers will
make them execute the wrong .send and .handle_result functions.

This commit fixes this by adding a needs_inv flag in the request to
choose the action to perform when sending requests or handling their
results. This flag will be set when needed (i.e. when the context flag
will be set).

Fixes: 1b44c5a60c13 ("crypto: inside-secure - add SafeXcel EIP197 crypto engine driver")
Signed-off-by: Ofer Heifetz &lt;oferh@marvell.com&gt;
[Antoine: commit message, and removed non related changes from the
original commit]
Signed-off-by: Antoine Tenart &lt;antoine.tenart@free-electrons.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: inside-secure - remove null check before kfree</title>
<updated>2017-09-22T09:43:25Z</updated>
<author>
<name>Himanshu Jha</name>
<email>himanshujha199640@gmail.com</email>
</author>
<published>2017-08-26T21:15:30Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=18fddf5fd2111dd670156b3dfb2dfed16d7889b4'/>
<id>urn:sha1:18fddf5fd2111dd670156b3dfb2dfed16d7889b4</id>
<content type='text'>
Kfree on NULL pointer is a no-op and therefore checking is redundant.

Signed-off-by: Himanshu Jha &lt;himanshujha199640@gmail.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: inside-secure - fix gcc-4.9 warnings</title>
<updated>2017-09-20T09:42:41Z</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2017-09-12T10:12:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=3e1166b94e661ed51af1fe1fe5f74bd83450b50f'/>
<id>urn:sha1:3e1166b94e661ed51af1fe1fe5f74bd83450b50f</id>
<content type='text'>
All older compiler versions up to gcc-4.9 produce these
harmless warnings:

drivers/crypto/inside-secure/safexcel_cipher.c:389:9: warning: missing braces around initializer [-Wmissing-braces]
drivers/crypto/inside-secure/safexcel_cipher.c:389:9: warning: (near initialization for ‘result.completion’) [-Wmissing-braces]
drivers/crypto/inside-secure/safexcel_hash.c:422:9: warning: missing braces around initializer [-Wmissing-braces]
drivers/crypto/inside-secure/safexcel_hash.c:422:9: warning: (near initialization for ‘result.completion’) [-Wmissing-braces]

This changes the syntax to something that works on all versions
without warnings.

Fixes: 1b44c5a60c13 ("crypto: inside-secure - add SafeXcel EIP197 crypto engine driver")
Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Acked-by: Antoine Tenart &lt;antoine.tenart@free-electrons.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: inside-secure - fix an error handling path in safexcel_probe()</title>
<updated>2017-08-22T06:54:55Z</updated>
<author>
<name>Christophe Jaillet</name>
<email>christophe.jaillet@wanadoo.fr</email>
</author>
<published>2017-08-15T19:33:24Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=b7d65fe18129e2f557c31126fe6623e8c2731528'/>
<id>urn:sha1:b7d65fe18129e2f557c31126fe6623e8c2731528</id>
<content type='text'>
'ret' is known to be 0 at this point.
If 'safexcel_request_ring_irq()' fails, it returns an error code.
Return this value instead of 0 which means success.

Signed-off-by: Christophe JAILLET &lt;christophe.jaillet@wanadoo.fr&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: inside-secure - fix the sha state length in hmac_sha1_setkey</title>
<updated>2017-08-03T05:36:11Z</updated>
<author>
<name>Antoine Ténart</name>
<email>antoine.tenart@free-electrons.com</email>
</author>
<published>2017-07-19T09:02:31Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=60c4081ec4195389f4fa1fce83eaad5e4b948748'/>
<id>urn:sha1:60c4081ec4195389f4fa1fce83eaad5e4b948748</id>
<content type='text'>
A check is performed on the ipad/opad in the safexcel_hmac_sha1_setkey
function, but the index used by the loop doing it is wrong. It is
currently the size of the state array while it should be the size of a
sha1 state. This patch fixes it.

Fixes: 1b44c5a60c13 ("crypto: inside-secure - add SafeXcel EIP197 crypto engine driver")
Reported-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Signed-off-by: Antoine Tenart &lt;antoine.tenart@free-electrons.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: inside-secure - fix invalidation check in hmac_sha1_setkey</title>
<updated>2017-08-03T05:36:10Z</updated>
<author>
<name>Antoine Ténart</name>
<email>antoine.tenart@free-electrons.com</email>
</author>
<published>2017-07-19T09:02:30Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=42ef3bedf30020a3b5298c2b918ccd7b6e1794d3'/>
<id>urn:sha1:42ef3bedf30020a3b5298c2b918ccd7b6e1794d3</id>
<content type='text'>
The safexcel_hmac_sha1_setkey function checks if an invalidation command
should be issued, i.e. when the context ipad/opad change. This checks is
done after filling the ipad/opad which and it can't be true. The patch
fixes this by moving the check before the ipad/opad memcpy operations.

Fixes: 1b44c5a60c13 ("crypto: inside-secure - add SafeXcel EIP197 crypto engine driver")
Signed-off-by: Antoine Tenart &lt;antoine.tenart@free-electrons.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: inside-secure - do not parse the dma mask from dt</title>
<updated>2017-07-18T09:01:01Z</updated>
<author>
<name>Antoine Ténart</name>
<email>antoine.tenart@free-electrons.com</email>
</author>
<published>2017-06-23T14:05:25Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a2069aacbe58a8408a5bb0e0a722e1726456519b'/>
<id>urn:sha1:a2069aacbe58a8408a5bb0e0a722e1726456519b</id>
<content type='text'>
Remove the dma mask parsing from dt as this should not be encoded into
the engine device tree node. Keep the fallback value for now, which
should work for the boards already supported upstream.

Signed-off-by: Antoine Tenart &lt;antoine.tenart@free-electrons.com&gt;
Acked-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
</feed>
