* [PATCH] KEYS: include header for EINVAL definition
@ 2024-01-07 13:28 clayc
2024-01-08 14:24 ` Jarkko Sakkinen
2024-01-26 8:59 ` Herbert Xu
0 siblings, 2 replies; 7+ messages in thread
From: clayc @ 2024-01-07 13:28 UTC (permalink / raw)
To: keyrings, linux-crypto, linux-kernel; +Cc: dhowells, herbert, davem, Clay Chang
From: Clay Chang <clayc@hpe.com>
This patch includes linux/errno.h to address the issue of 'EINVAL' being
undeclared.
Signed-off-by: Clay Chang <clayc@hpe.com>
---
include/crypto/public_key.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/crypto/public_key.h b/include/crypto/public_key.h
index 462f8a34cdf8..b7f308977c84 100644
--- a/include/crypto/public_key.h
+++ b/include/crypto/public_key.h
@@ -10,6 +10,7 @@
#ifndef _LINUX_PUBLIC_KEY_H
#define _LINUX_PUBLIC_KEY_H
+#include <linux/errno.h>
#include <linux/keyctl.h>
#include <linux/oid_registry.h>
--
2.34.1
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] KEYS: include header for EINVAL definition
2024-01-07 13:28 [PATCH] KEYS: include header for EINVAL definition clayc
@ 2024-01-08 14:24 ` Jarkko Sakkinen
2024-01-09 2:10 ` Clay Chang
2024-01-26 8:59 ` Herbert Xu
1 sibling, 1 reply; 7+ messages in thread
From: Jarkko Sakkinen @ 2024-01-08 14:24 UTC (permalink / raw)
To: clayc, keyrings, linux-crypto, linux-kernel; +Cc: dhowells, herbert, davem
On Sun Jan 7, 2024 at 3:28 PM EET, wrote:
> From: Clay Chang <clayc@hpe.com>
>
> This patch includes linux/errno.h to address the issue of 'EINVAL' being
> undeclared.
>
> Signed-off-by: Clay Chang <clayc@hpe.com>
> ---
> include/crypto/public_key.h | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/include/crypto/public_key.h b/include/crypto/public_key.h
> index 462f8a34cdf8..b7f308977c84 100644
> --- a/include/crypto/public_key.h
> +++ b/include/crypto/public_key.h
> @@ -10,6 +10,7 @@
> #ifndef _LINUX_PUBLIC_KEY_H
> #define _LINUX_PUBLIC_KEY_H
>
> +#include <linux/errno.h>
> #include <linux/keyctl.h>
> #include <linux/oid_registry.h>
>
Please provide evidence that issue exist (applies for any possible kernel issue).
BR, Jarkko
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] KEYS: include header for EINVAL definition
2024-01-08 14:24 ` Jarkko Sakkinen
@ 2024-01-09 2:10 ` Clay Chang
2024-01-10 19:54 ` Jarkko Sakkinen
0 siblings, 1 reply; 7+ messages in thread
From: Clay Chang @ 2024-01-09 2:10 UTC (permalink / raw)
To: Jarkko Sakkinen, keyrings, linux-crypto, linux-kernel
Cc: dhowells, herbert, davem
Hi Jarkko,
The issue was found when crypto/public_key.h was included, but CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE was not enabled. If CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE was not enabled, the public_key_verify_signature simply returned -EINVAL, which was not declared without linux/errno.h being included.
Thanks,
Clay
On 2024/1/8 10:24 PM, Jarkko Sakkinen wrote:
> On Sun Jan 7, 2024 at 3:28 PM EET, wrote:
>> From: Clay Chang <clayc@hpe.com>
>>
>> This patch includes linux/errno.h to address the issue of 'EINVAL' being
>> undeclared.
>>
>> Signed-off-by: Clay Chang <clayc@hpe.com>
>> ---
>> include/crypto/public_key.h | 1 +
>> 1 file changed, 1 insertion(+)
>>
>> diff --git a/include/crypto/public_key.h b/include/crypto/public_key.h
>> index 462f8a34cdf8..b7f308977c84 100644
>> --- a/include/crypto/public_key.h
>> +++ b/include/crypto/public_key.h
>> @@ -10,6 +10,7 @@
>> #ifndef _LINUX_PUBLIC_KEY_H
>> #define _LINUX_PUBLIC_KEY_H
>>
>> +#include <linux/errno.h>
>> #include <linux/keyctl.h>
>> #include <linux/oid_registry.h>
>>
>
> Please provide evidence that issue exist (applies for any possible kernel issue).
>
> BR, Jarkko
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] KEYS: include header for EINVAL definition
2024-01-09 2:10 ` Clay Chang
@ 2024-01-10 19:54 ` Jarkko Sakkinen
2024-01-12 5:59 ` Clay Chang
0 siblings, 1 reply; 7+ messages in thread
From: Jarkko Sakkinen @ 2024-01-10 19:54 UTC (permalink / raw)
To: Clay Chang, keyrings, linux-crypto, linux-kernel; +Cc: dhowells, herbert, davem
On Tue Jan 9, 2024 at 4:10 AM EET, Clay Chang wrote:
> Hi Jarkko,
>
> The issue was found when crypto/public_key.h was included, but
> CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE was not enabled. If
> CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE was not enabled, the
> public_key_verify_signature simply returned -EINVAL, which was not
> declared without linux/errno.h being included.
>
> Thanks,
> Clay
Do you have .config to verify this?
BR, Jarkko
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] KEYS: include header for EINVAL definition
2024-01-10 19:54 ` Jarkko Sakkinen
@ 2024-01-12 5:59 ` Clay Chang
2024-01-13 20:46 ` Jarkko Sakkinen
0 siblings, 1 reply; 7+ messages in thread
From: Clay Chang @ 2024-01-12 5:59 UTC (permalink / raw)
To: Jarkko Sakkinen, keyrings, linux-crypto, linux-kernel
Cc: dhowells, herbert, davem
Hi Jarkko,
Yes, I have. I am working on an OpenBMC project and the kernel .config was generated by merging several config fragments. In one experiment where the CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE was not presented, I got a EINVAL undeclared compilation error.
Do you want me to show the full .config here?
Thanks,
Clay
On 2024/1/11 3:54 AM, Jarkko Sakkinen wrote:
> On Tue Jan 9, 2024 at 4:10 AM EET, Clay Chang wrote:
>> Hi Jarkko,
>>
>> The issue was found when crypto/public_key.h was included, but
>> CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE was not enabled. If
>> CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE was not enabled, the
>> public_key_verify_signature simply returned -EINVAL, which was not
>> declared without linux/errno.h being included.
>>
>> Thanks,
>> Clay
>
> Do you have .config to verify this?
>
> BR, Jarkko
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] KEYS: include header for EINVAL definition
2024-01-12 5:59 ` Clay Chang
@ 2024-01-13 20:46 ` Jarkko Sakkinen
0 siblings, 0 replies; 7+ messages in thread
From: Jarkko Sakkinen @ 2024-01-13 20:46 UTC (permalink / raw)
To: Clay Chang, keyrings, linux-crypto, linux-kernel; +Cc: dhowells, herbert, davem
On Fri Jan 12, 2024 at 7:59 AM EET, Clay Chang wrote:
> Hi Jarkko,
>
> Yes, I have. I am working on an OpenBMC project and the kernel .config was generated by merging several config fragments. In one experiment where the CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE was not presented, I got a EINVAL undeclared compilation error.
>
> Do you want me to show the full .config here?
Well the problem with the patch is that it does not *prove*
that there is issue.
So you evidence in the commit message that there is bug in
the first place and which config options cause it. And it
it must be testable with latest mainline (not by downstream
project).
BR, Jarkko
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] KEYS: include header for EINVAL definition
2024-01-07 13:28 [PATCH] KEYS: include header for EINVAL definition clayc
2024-01-08 14:24 ` Jarkko Sakkinen
@ 2024-01-26 8:59 ` Herbert Xu
1 sibling, 0 replies; 7+ messages in thread
From: Herbert Xu @ 2024-01-26 8:59 UTC (permalink / raw)
To: clayc; +Cc: keyrings, linux-crypto, linux-kernel, dhowells, davem
On Sun, Jan 07, 2024 at 09:28:42PM +0800, clayc@hpe.com wrote:
> From: Clay Chang <clayc@hpe.com>
>
> This patch includes linux/errno.h to address the issue of 'EINVAL' being
> undeclared.
>
> Signed-off-by: Clay Chang <clayc@hpe.com>
> ---
> include/crypto/public_key.h | 1 +
> 1 file changed, 1 insertion(+)
Patch applied. Thanks.
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2024-01-26 8:59 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-07 13:28 [PATCH] KEYS: include header for EINVAL definition clayc
2024-01-08 14:24 ` Jarkko Sakkinen
2024-01-09 2:10 ` Clay Chang
2024-01-10 19:54 ` Jarkko Sakkinen
2024-01-12 5:59 ` Clay Chang
2024-01-13 20:46 ` Jarkko Sakkinen
2024-01-26 8:59 ` Herbert Xu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).