From: Naresh Kamboju <naresh.kamboju@linaro.org>
To: "open list:KERNEL SELFTEST FRAMEWORK"
<linux-kselftest@vger.kernel.org>,
open list <linux-kernel@vger.kernel.org>,
linux-mm <linux-mm@kvack.org>,
lkft-triage@lists.linaro.org
Cc: Andrew Morton <akpm@linux-foundation.org>,
Shuah Khan <shuah@kernel.org>,
Anders Roxell <anders.roxell@linaro.org>,
Arnd Bergmann <arnd@arndb.de>,
Dan Carpenter <dan.carpenter@linaro.org>
Subject: selftests: mm: seal_elf.c:140:45: warning: format '%s' expects argument of type 'char *', but argument 5 has type 'char (*)[5]' [-Wformat=]
Date: Thu, 18 Apr 2024 15:07:23 +0530 [thread overview]
Message-ID: <CA+G9fYvacWNZsmizotfcwD35xBq0999_EAV0wZgwjdi46yivgg@mail.gmail.com> (raw)
The Linux next building selftests with gcc-13 found these build warnings
and errors.
Reported-by: Linux Kernel Functional Testing <lkft@linaro.org>
Build log:
---------
PATH:
selftests/mm/seal_elf
seal_elf.c: In function 'test_seal_elf':
seal_elf.c:140:45: warning: format '%s' expects argument of type 'char
*', but argument 5 has type 'char (*)[5]' [-Wformat=]
140 | if (sscanf(line, "%lx-%lx %4s %*x %*x:%*x %*u
%255[^\n]",
| ~~^
| |
| char *
141 | &addr_start, &addr_end, &prot,
&filename) == 4) {
| ~~~~~
| |
| char (*)[5]
seal_elf.c:140:69: warning: format '%[^
' expects argument of type 'char *', but argument 6 has type 'char
(*)[256]' [-Wformat=]
140 | if (sscanf(line, "%lx-%lx %4s %*x %*x:%*x %*u
%255[^\n]",
| ~~~~~~^~
| |
|
char *
141 | &addr_start, &addr_end, &prot,
&filename) == 4) {
| ~~~~~~~~~
| |
| char (*)[256]
seal_elf.c:110:13: warning: unused variable 'size' [-Wunused-variable]
110 | int size = 0;
| ^~~~
/usr/lib/gcc-cross/aarch64-linux-gnu/13/../../../../aarch64-linux-gnu/bin/ld:
/tmp/cczODkiZ.o: in function `test_seal_elf':
seal_elf.c:(.text+0x738): undefined reference to `sys_mprotect'
/usr/lib/gcc-cross/aarch64-linux-gnu/13/../../../../aarch64-linux-gnu/bin/ld:
seal_elf.c:(.text+0x794): undefined reference to `sys_mprotect'
/usr/lib/gcc-cross/aarch64-linux-gnu/13/../../../../aarch64-linux-gnu/bin/ld:
seal_elf.c:(.text+0x944): undefined reference to `sys_mprotect'
collect2: error: ld returned 1 exit status
Steps to reproduce:
---
tuxmake --runtime podman --target-arch arm64 --toolchain gcc-13 \
--kconfig https://storage.tuxsuite.com/public/linaro/lkft/builds/2fDW3wG8BqWxf0afUI5f4wkArPi/config
\
debugkernel dtbs dtbs-legacy headers kernel kselftest modules
Links:
- https://storage.tuxsuite.com/public/linaro/lkft/builds/2fDW3wG8BqWxf0afUI5f4wkArPi/
--
Linaro LKFT
https://lkft.linaro.org
reply other threads:[~2024-04-18 9:37 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CA+G9fYvacWNZsmizotfcwD35xBq0999_EAV0wZgwjdi46yivgg@mail.gmail.com \
--to=naresh.kamboju@linaro.org \
--cc=akpm@linux-foundation.org \
--cc=anders.roxell@linaro.org \
--cc=arnd@arndb.de \
--cc=dan.carpenter@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=lkft-triage@lists.linaro.org \
--cc=shuah@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox