* [PATCH -next] x86/sgx: Make symbol 'sgx_vepc_vm_ops' static
@ 2021-04-12 16:00 Wei Yongjun
2021-04-12 17:46 ` Borislav Petkov
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Wei Yongjun @ 2021-04-12 16:00 UTC (permalink / raw)
To: weiyongjun1, Jarkko Sakkinen, Thomas Gleixner, Ingo Molnar,
Borislav Petkov, Sean Christopherson, x86
Cc: linux-sgx, kernel-janitors, Hulk Robot
The sparse tool complains as follows:
arch/x86/kernel/cpu/sgx/virt.c:95:35: warning:
symbol 'sgx_vepc_vm_ops' was not declared. Should it be static?
This symbol is not used outside of virt.c, so this
commit marks it static.
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
arch/x86/kernel/cpu/sgx/virt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/x86/kernel/cpu/sgx/virt.c b/arch/x86/kernel/cpu/sgx/virt.c
index 7d221eac716a..6ad165a5c0cc 100644
--- a/arch/x86/kernel/cpu/sgx/virt.c
+++ b/arch/x86/kernel/cpu/sgx/virt.c
@@ -92,7 +92,7 @@ static vm_fault_t sgx_vepc_fault(struct vm_fault *vmf)
return VM_FAULT_SIGBUS;
}
-const struct vm_operations_struct sgx_vepc_vm_ops = {
+static const struct vm_operations_struct sgx_vepc_vm_ops = {
.fault = sgx_vepc_fault,
};
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH -next] x86/sgx: Make symbol 'sgx_vepc_vm_ops' static
2021-04-12 16:00 [PATCH -next] x86/sgx: Make symbol 'sgx_vepc_vm_ops' static Wei Yongjun
@ 2021-04-12 17:46 ` Borislav Petkov
2021-04-13 7:19 ` 答复: " weiyongjun (A)
2021-04-12 18:00 ` [tip: x86/sgx] x86/sgx: Mark sgx_vepc_vm_ops static tip-bot2 for Wei Yongjun
2021-04-14 11:11 ` [PATCH -next] x86/sgx: Make symbol 'sgx_vepc_vm_ops' static Jarkko Sakkinen
2 siblings, 1 reply; 5+ messages in thread
From: Borislav Petkov @ 2021-04-12 17:46 UTC (permalink / raw)
To: Wei Yongjun
Cc: Jarkko Sakkinen, Thomas Gleixner, Ingo Molnar,
Sean Christopherson, x86, linux-sgx, kernel-janitors, Hulk Robot
On Mon, Apr 12, 2021 at 04:00:23PM +0000, Wei Yongjun wrote:
> The sparse tool complains as follows:
>
> arch/x86/kernel/cpu/sgx/virt.c:95:35: warning:
> symbol 'sgx_vepc_vm_ops' was not declared. Should it be static?
>
> This symbol is not used outside of virt.c, so this
> commit marks it static.
For the future:
Avoid having "This patch" or "This commit" in the commit message. It is
tautologically useless.
Also, do
$ git grep 'This patch' Documentation/process
for more details.
Thx.
--
Regards/Gruss,
Boris.
https://people.kernel.org/tglx/notes-about-netiquette
^ permalink raw reply [flat|nested] 5+ messages in thread
* [tip: x86/sgx] x86/sgx: Mark sgx_vepc_vm_ops static
2021-04-12 16:00 [PATCH -next] x86/sgx: Make symbol 'sgx_vepc_vm_ops' static Wei Yongjun
2021-04-12 17:46 ` Borislav Petkov
@ 2021-04-12 18:00 ` tip-bot2 for Wei Yongjun
2021-04-14 11:11 ` [PATCH -next] x86/sgx: Make symbol 'sgx_vepc_vm_ops' static Jarkko Sakkinen
2 siblings, 0 replies; 5+ messages in thread
From: tip-bot2 for Wei Yongjun @ 2021-04-12 18:00 UTC (permalink / raw)
To: linux-tip-commits
Cc: Hulk Robot, Wei Yongjun, Borislav Petkov, x86, linux-kernel
The following commit has been merged into the x86/sgx branch of tip:
Commit-ID: 523caed9efbb049339706b124185c9358c1b6477
Gitweb: https://git.kernel.org/tip/523caed9efbb049339706b124185c9358c1b6477
Author: Wei Yongjun <weiyongjun1@huawei.com>
AuthorDate: Mon, 12 Apr 2021 16:00:23
Committer: Borislav Petkov <bp@suse.de>
CommitterDate: Mon, 12 Apr 2021 19:48:32 +02:00
x86/sgx: Mark sgx_vepc_vm_ops static
Fix the following sparse warning:
arch/x86/kernel/cpu/sgx/virt.c:95:35: warning:
symbol 'sgx_vepc_vm_ops' was not declared. Should it be static?
This symbol is not used outside of virt.c so mark it static.
[ bp: Massage commit message. ]
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Link: https://lkml.kernel.org/r/20210412160023.193850-1-weiyongjun1@huawei.com
---
arch/x86/kernel/cpu/sgx/virt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/x86/kernel/cpu/sgx/virt.c b/arch/x86/kernel/cpu/sgx/virt.c
index 7d221ea..6ad165a 100644
--- a/arch/x86/kernel/cpu/sgx/virt.c
+++ b/arch/x86/kernel/cpu/sgx/virt.c
@@ -92,7 +92,7 @@ static vm_fault_t sgx_vepc_fault(struct vm_fault *vmf)
return VM_FAULT_SIGBUS;
}
-const struct vm_operations_struct sgx_vepc_vm_ops = {
+static const struct vm_operations_struct sgx_vepc_vm_ops = {
.fault = sgx_vepc_fault,
};
^ permalink raw reply related [flat|nested] 5+ messages in thread
* 答复: [PATCH -next] x86/sgx: Make symbol 'sgx_vepc_vm_ops' static
2021-04-12 17:46 ` Borislav Petkov
@ 2021-04-13 7:19 ` weiyongjun (A)
0 siblings, 0 replies; 5+ messages in thread
From: weiyongjun (A) @ 2021-04-13 7:19 UTC (permalink / raw)
To: Borislav Petkov
Cc: Jarkko Sakkinen, Thomas Gleixner, Ingo Molnar,
Sean Christopherson, x86, linux-sgx, kernel-janitors,
pmail_hulkci
>
> On Mon, Apr 12, 2021 at 04:00:23PM +0000, Wei Yongjun wrote:
> > The sparse tool complains as follows:
> >
> > arch/x86/kernel/cpu/sgx/virt.c:95:35: warning:
> > symbol 'sgx_vepc_vm_ops' was not declared. Should it be static?
> >
> > This symbol is not used outside of virt.c, so this commit marks it
> > static.
>
> For the future:
>
> Avoid having "This patch" or "This commit" in the commit message. It is tautologically useless.
>
> Also, do
>
> $ git grep 'This patch' Documentation/process
>
> for more details.
>
> Thx.
Got it, thanks.
Regards,
Wei Yongjun
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH -next] x86/sgx: Make symbol 'sgx_vepc_vm_ops' static
2021-04-12 16:00 [PATCH -next] x86/sgx: Make symbol 'sgx_vepc_vm_ops' static Wei Yongjun
2021-04-12 17:46 ` Borislav Petkov
2021-04-12 18:00 ` [tip: x86/sgx] x86/sgx: Mark sgx_vepc_vm_ops static tip-bot2 for Wei Yongjun
@ 2021-04-14 11:11 ` Jarkko Sakkinen
2 siblings, 0 replies; 5+ messages in thread
From: Jarkko Sakkinen @ 2021-04-14 11:11 UTC (permalink / raw)
To: Wei Yongjun
Cc: Thomas Gleixner, Ingo Molnar, Borislav Petkov,
Sean Christopherson, x86, linux-sgx, kernel-janitors, Hulk Robot
On Mon, Apr 12, 2021 at 04:00:23PM +0000, Wei Yongjun wrote:
> The sparse tool complains as follows:
>
> arch/x86/kernel/cpu/sgx/virt.c:95:35: warning:
> symbol 'sgx_vepc_vm_ops' was not declared. Should it be static?
>
> This symbol is not used outside of virt.c, so this
> commit marks it static.
>
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
The only reason I cannot ack this is that instead telling what the
commit does, the long description asks should this be done or not.
/Jarkko
> arch/x86/kernel/cpu/sgx/virt.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/x86/kernel/cpu/sgx/virt.c b/arch/x86/kernel/cpu/sgx/virt.c
> index 7d221eac716a..6ad165a5c0cc 100644
> --- a/arch/x86/kernel/cpu/sgx/virt.c
> +++ b/arch/x86/kernel/cpu/sgx/virt.c
> @@ -92,7 +92,7 @@ static vm_fault_t sgx_vepc_fault(struct vm_fault *vmf)
> return VM_FAULT_SIGBUS;
> }
>
> -const struct vm_operations_struct sgx_vepc_vm_ops = {
> +static const struct vm_operations_struct sgx_vepc_vm_ops = {
> .fault = sgx_vepc_fault,
> };
>
>
>
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2021-04-14 11:11 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-12 16:00 [PATCH -next] x86/sgx: Make symbol 'sgx_vepc_vm_ops' static Wei Yongjun
2021-04-12 17:46 ` Borislav Petkov
2021-04-13 7:19 ` 答复: " weiyongjun (A)
2021-04-12 18:00 ` [tip: x86/sgx] x86/sgx: Mark sgx_vepc_vm_ops static tip-bot2 for Wei Yongjun
2021-04-14 11:11 ` [PATCH -next] x86/sgx: Make symbol 'sgx_vepc_vm_ops' static Jarkko Sakkinen
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.