forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
-Wuninitialized in arch/mips/include/asm/syscall.h #604
Labels
-Wuninitialized
[ARCH] mips
This bug impacts ARCH=mips
[BUG] linux
A bug that should be fixed in the mainline kernel.
[FIXED][LINUX] 5.4
This bug was fixed in Linux 5.4
Comments
nathanchance
added
[BUG] linux
A bug that should be fixed in the mainline kernel.
[PATCH] Exists
There is a patch that fixes this issue
-Wuninitialized
[ARCH] mips
This bug impacts ARCH=mips
labels
Jul 17, 2019
nathanchance
added a commit
that referenced
this issue
Jul 18, 2019
clang warns: In file included from arch/mips/kernel/ptrace.c:45: arch/mips/include/asm/syscall.h:130:3: warning: variable 'ret' is uninitialized when used here [-Wuninitialized] ret |= mips_get_syscall_arg(args++, task, regs, i++); ^~~ arch/mips/include/asm/syscall.h:123:9: note: initialize the variable 'ret' to silence this warning int ret; ^ = 0 1 warning generated. It's not wrong; however, it's not an issue in practice because ret is only assigned to, not read from. ret could just be initialized to zero but looking into it further, ret has been unused since it was first added in 2012 so just get rid of it and update mips_get_syscall_arg's return type since none of the return values are ever checked. If it is ever needed again, this commit can be reverted and ret can be properly initialized. Fixes: c0ff3c5 ("MIPS: Enable HAVE_ARCH_TRACEHOOK.") Link: #604 Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
nathanchance
added a commit
that referenced
this issue
Jul 19, 2019
clang warns: In file included from arch/mips/kernel/ptrace.c:45: arch/mips/include/asm/syscall.h:130:3: warning: variable 'ret' is uninitialized when used here [-Wuninitialized] ret |= mips_get_syscall_arg(args++, task, regs, i++); ^~~ arch/mips/include/asm/syscall.h:123:9: note: initialize the variable 'ret' to silence this warning int ret; ^ = 0 1 warning generated. It's not wrong; however, it's not an issue in practice because ret is only assigned to, not read from. ret could just be initialized to zero but looking into it further, ret has been unused since it was first added in 2012 so just get rid of it and update mips_get_syscall_arg's return type since none of the return values are ever checked. If it is ever needed again, this commit can be reverted and ret can be properly initialized. Fixes: c0ff3c5 ("MIPS: Enable HAVE_ARCH_TRACEHOOK.") Link: #604 Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
nathanchance
added a commit
that referenced
this issue
Jul 25, 2019
clang warns: In file included from arch/mips/kernel/ptrace.c:45: arch/mips/include/asm/syscall.h:130:3: warning: variable 'ret' is uninitialized when used here [-Wuninitialized] ret |= mips_get_syscall_arg(args++, task, regs, i++); ^~~ arch/mips/include/asm/syscall.h:123:9: note: initialize the variable 'ret' to silence this warning int ret; ^ = 0 1 warning generated. It's not wrong; however, it's not an issue in practice because ret is only assigned to, not read from. ret could just be initialized to zero but looking into it further, ret has been unused since it was first added in 2012 so just get rid of it and update mips_get_syscall_arg's return type since none of the return values are ever checked. If it is ever needed again, this commit can be reverted and ret can be properly initialized. Fixes: c0ff3c5 ("MIPS: Enable HAVE_ARCH_TRACEHOOK.") Link: #604 Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
nathanchance
added a commit
that referenced
this issue
Jul 27, 2019
clang warns: In file included from arch/mips/kernel/ptrace.c:45: arch/mips/include/asm/syscall.h:130:3: warning: variable 'ret' is uninitialized when used here [-Wuninitialized] ret |= mips_get_syscall_arg(args++, task, regs, i++); ^~~ arch/mips/include/asm/syscall.h:123:9: note: initialize the variable 'ret' to silence this warning int ret; ^ = 0 1 warning generated. It's not wrong; however, it's not an issue in practice because ret is only assigned to, not read from. ret could just be initialized to zero but looking into it further, ret has been unused since it was first added in 2012 so just get rid of it and update mips_get_syscall_arg's return type since none of the return values are ever checked. If it is ever needed again, this commit can be reverted and ret can be properly initialized. Fixes: c0ff3c5 ("MIPS: Enable HAVE_ARCH_TRACEHOOK.") Link: #604 Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
nathanchance
added a commit
that referenced
this issue
Aug 3, 2019
clang warns: In file included from arch/mips/kernel/ptrace.c:45: arch/mips/include/asm/syscall.h:130:3: warning: variable 'ret' is uninitialized when used here [-Wuninitialized] ret |= mips_get_syscall_arg(args++, task, regs, i++); ^~~ arch/mips/include/asm/syscall.h:123:9: note: initialize the variable 'ret' to silence this warning int ret; ^ = 0 1 warning generated. It's not wrong; however, it's not an issue in practice because ret is only assigned to, not read from. ret could just be initialized to zero but looking into it further, ret has been unused since it was first added in 2012 so just get rid of it and update mips_get_syscall_arg's return type since none of the return values are ever checked. If it is ever needed again, this commit can be reverted and ret can be properly initialized. Fixes: c0ff3c5 ("MIPS: Enable HAVE_ARCH_TRACEHOOK.") Link: #604 Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
nathanchance
added
[PATCH] Submitted
A patch has been submitted for review
and removed
[PATCH] Exists
There is a patch that fixes this issue
labels
Aug 12, 2019
nathanchance
added a commit
that referenced
this issue
Aug 12, 2019
clang warns: arch/mips/include/asm/syscall.h:136:3: error: variable 'ret' is uninitialized when used here [-Werror,-Wuninitialized] ret |= mips_get_syscall_arg(args++, task, regs, i++); ^~~ arch/mips/include/asm/syscall.h:129:9: note: initialize the variable 'ret' to silence this warning int ret; ^ = 0 1 error generated. It's not wrong; however, it's not an issue in practice because ret is only assigned to, not read from. ret could just be initialized to zero but looking into it further, ret has been unused since it was first added in 2012 so just get rid of it and update mips_get_syscall_arg's return type since none of the return values are ever checked. If it is ever needed again, this commit can be reverted and ret can be properly initialized. Fixes: c0ff3c5 ("MIPS: Enable HAVE_ARCH_TRACEHOOK.") Link: #604 Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
nathanchance
added
[PATCH] Accepted
A submitted patch has been accepted upstream
and removed
[PATCH] Submitted
A patch has been submitted for review
labels
Aug 12, 2019
nathanchance
added a commit
that referenced
this issue
Aug 12, 2019
clang warns: arch/mips/include/asm/syscall.h:136:3: error: variable 'ret' is uninitialized when used here [-Werror,-Wuninitialized] ret |= mips_get_syscall_arg(args++, task, regs, i++); ^~~ arch/mips/include/asm/syscall.h:129:9: note: initialize the variable 'ret' to silence this warning int ret; ^ = 0 1 error generated. It's not wrong; however, it's not an issue in practice because ret is only assigned to, not read from. ret could just be initialized to zero but looking into it further, ret has been unused since it was first added in 2012 so just get rid of it and update mips_get_syscall_arg's return type since none of the return values are ever checked. If it is ever needed again, this commit can be reverted and ret can be properly initialized. Fixes: c0ff3c5 ("MIPS: Enable HAVE_ARCH_TRACEHOOK.") Link: #604 Signed-off-by: Nathan Chancellor <natechancellor@gmail.com> Signed-off-by: Paul Burton <paul.burton@mips.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: James Hogan <jhogan@kernel.org> Cc: Nick Desaulniers <ndesaulniers@google.com> Cc: linux-mips@vger.kernel.org Cc: linux-kernel@vger.kernel.org Cc: clang-built-linux@googlegroups.com
Merged into mainline: https://git.kernel.org/linus/077ff3be06e8de2657075dd2738b9a21f8ebd890 |
nathanchance
added
[FIXED][LINUX] 5.4
This bug was fixed in Linux 5.4
and removed
[PATCH] Accepted
A submitted patch has been accepted upstream
labels
Sep 23, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
-Wuninitialized
[ARCH] mips
This bug impacts ARCH=mips
[BUG] linux
A bug that should be fixed in the mainline kernel.
[FIXED][LINUX] 5.4
This bug was fixed in Linux 5.4
Tentative patch (going to send as a series):
The text was updated successfully, but these errors were encountered: