<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/crypto/ahash.c, branch linux-4.11.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.11.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.11.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2017-04-10T11:09:18Z</updated>
<entry>
<title>crypto: ahash - Fix EINPROGRESS notification callback</title>
<updated>2017-04-10T11:09:18Z</updated>
<author>
<name>Herbert Xu</name>
</author>
<published>2017-04-10T09:27:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=ef0579b64e93188710d48667cb5e014926af9f1b'/>
<id>urn:sha1:ef0579b64e93188710d48667cb5e014926af9f1b</id>
<content type='text'>
The ahash API modifies the request's callback function in order
to clean up after itself in some corner cases (unaligned final
and missing finup).

When the request is complete ahash will restore the original
callback and everything is fine.  However, when the request gets
an EBUSY on a full queue, an EINPROGRESS callback is made while
the request is still ongoing.

In this case the ahash API will incorrectly call its own callback.

This patch fixes the problem by creating a temporary request
object on the stack which is used to relay EINPROGRESS back to
the original completion function.

This patch also adds code to preserve the original flags value.

Fixes: ab6bf4e5e5e4 ("crypto: hash - Fix the pointer voodoo in...")
Cc: &lt;stable@vger.kernel.org&gt;
Reported-by: Sabrina Dubroca &lt;sd@queasysnail.net&gt;
Tested-by: Sabrina Dubroca &lt;sd@queasysnail.net&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: Replaced gcc specific attributes with macros from compiler.h</title>
<updated>2017-01-12T16:24:39Z</updated>
<author>
<name>Gideon Israel Dsouza</name>
</author>
<published>2016-12-31T15:56:23Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d8c34b949d8c9f61e099e00f22770e400adf2b76'/>
<id>urn:sha1:d8c34b949d8c9f61e099e00f22770e400adf2b76</id>
<content type='text'>
Continuing from this commit: 52f5684c8e1e
("kernel: use macros from compiler.h instead of __attribute__((...))")

I submitted 4 total patches. They are part of task I've taken up to
increase compiler portability in the kernel. I've cleaned up the
subsystems under /kernel /mm /block and /security, this patch targets
/crypto.

There is &lt;linux/compiler.h&gt; which provides macros for various gcc specific
constructs. Eg: __weak for __attribute__((weak)). I've cleaned all
instances of gcc specific attributes with the right macros for the crypto
subsystem.

I had to make one additional change into compiler-gcc.h for the case when
one wants to use this: __attribute__((aligned) and not specify an alignment
factor. From the gcc docs, this will result in the largest alignment for
that data type on the target machine so I've named the macro
__aligned_largest. Please advise if another name is more appropriate.

Signed-off-by: Gideon Israel Dsouza &lt;gidisrael@gmail.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: ahash - Add padding in crypto_ahash_extsize</title>
<updated>2016-07-01T15:45:03Z</updated>
<author>
<name>Herbert Xu</name>
</author>
<published>2016-06-29T10:03:47Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2495cf25f60e085b35beb9b215235dfe1ca4f200'/>
<id>urn:sha1:2495cf25f60e085b35beb9b215235dfe1ca4f200</id>
<content type='text'>
The function crypto_ahash_extsize did not include padding when
computing the tfm context size.  This patch fixes this by using
the generic crypto_alg_extsize helper.

Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: hash - Fix page length clamping in hash walk</title>
<updated>2016-05-05T06:27:04Z</updated>
<author>
<name>Herbert Xu</name>
</author>
<published>2016-05-04T09:52:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=13f4bb78cf6a312bbdec367ba3da044b09bf0e29'/>
<id>urn:sha1:13f4bb78cf6a312bbdec367ba3da044b09bf0e29</id>
<content type='text'>
The crypto hash walk code is broken when supplied with an offset
greater than or equal to PAGE_SIZE.  This patch fixes it by adjusting
walk-&gt;pg and walk-&gt;offset when this happens.

Cc: &lt;stable@vger.kernel.org&gt;
Reported-by: Steffen Klassert &lt;steffen.klassert@secunet.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: hash - Remove crypto_hash interface</title>
<updated>2016-02-06T07:33:20Z</updated>
<author>
<name>Herbert Xu</name>
</author>
<published>2016-02-01T13:36:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=896545098777564212b9e91af4c973f094649aa7'/>
<id>urn:sha1:896545098777564212b9e91af4c973f094649aa7</id>
<content type='text'>
This patch removes all traces of the crypto_hash interface, now
that everyone has switched over to shash or ahash.

Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: hash - Add crypto_has_ahash helper</title>
<updated>2016-01-25T14:42:13Z</updated>
<author>
<name>Herbert Xu</name>
</author>
<published>2016-01-23T05:52:40Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8d18e34c1fe22418ae0b5475ab0d1956d69ad195'/>
<id>urn:sha1:8d18e34c1fe22418ae0b5475ab0d1956d69ad195</id>
<content type='text'>
This patch adds the helper crypto_has_ahash which should replace
crypto_has_hash.

Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: hash - Add crypto_ahash_has_setkey</title>
<updated>2016-01-18T10:16:11Z</updated>
<author>
<name>Herbert Xu</name>
</author>
<published>2016-01-08T13:28:26Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a5596d6332787fd383b3b5427b41f94254430827'/>
<id>urn:sha1:a5596d6332787fd383b3b5427b41f94254430827</id>
<content type='text'>
This patch adds a way for ahash users to determine whether a key
is required by a crypto_ahash transform.

Cc: stable@vger.kernel.org
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: ahash - ensure statesize is non-zero</title>
<updated>2015-10-13T14:28:10Z</updated>
<author>
<name>Russell King</name>
</author>
<published>2015-10-09T19:43:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8996eafdcbad149ac0f772fb1649fbb75c482a6a'/>
<id>urn:sha1:8996eafdcbad149ac0f772fb1649fbb75c482a6a</id>
<content type='text'>
Unlike shash algorithms, ahash drivers must implement export
and import as their descriptors may contain hardware state and
cannot be exported as is.  Unfortunately some ahash drivers did
not provide them and end up causing crashes with algif_hash.

This patch adds a check to prevent these drivers from registering
ahash algorithms until they are fixed.

Cc: stable@vger.kernel.org
Signed-off-by: Russell King &lt;rmk+kernel@arm.linux.org.uk&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: replace scatterwalk_sg_next with sg_next</title>
<updated>2015-01-26T00:34:22Z</updated>
<author>
<name>Cristian Stoica</name>
</author>
<published>2015-01-20T08:06:16Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5be4d4c94b1f98b839344fda7a8752a4a09d0ef5'/>
<id>urn:sha1:5be4d4c94b1f98b839344fda7a8752a4a09d0ef5</id>
<content type='text'>
Modify crypto drivers to use the generic SG helper since
both of them are equivalent and the one from crypto is redundant.

See also:
  468577abe37ff7b453a9ac613e0ea155349203ae   reverted in
  b2ab4a57b018aafbba35bff088218f5cc3d2142e

Signed-off-by: Cristian Stoica &lt;cristian.stoica@freescale.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
<entry>
<title>crypto: ahash - fixed style error in ahash.c</title>
<updated>2014-12-22T12:02:36Z</updated>
<author>
<name>Joshua I. James</name>
</author>
<published>2014-12-05T05:44:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b516d514020f17c83267f76366691e4cc9b7bddf'/>
<id>urn:sha1:b516d514020f17c83267f76366691e4cc9b7bddf</id>
<content type='text'>
Fixed style error identified by checkpatch.

WARNING: Missing a blank line after declarations
+               unsigned int unaligned = alignmask + 1 - (offset &amp; alignmask);
+               if (nbytes &gt; unaligned)

Signed-off-by: Joshua I. James &lt;joshua@cybercrimetech.com&gt;
Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
</content>
</entry>
</feed>
