summaryrefslogtreecommitdiff
path: root/lib/mpi/mpi-inline.c
diff options
context:
space:
mode:
authorKees Cook <kees@kernel.org>2025-04-15 19:15:19 +0300
committerLuiz Augusto von Dentz <luiz.von.dentz@intel.com>2025-04-16 23:50:47 +0300
commit875db86e1ec75fe633f1e85ed2f92c731cdbf760 (patch)
treee5c2b8054cf2ab9accdcba8d3a71662fa30e5646 /lib/mpi/mpi-inline.c
parente2e49e214145a8f6ece6ecd52fec63ebc2b27ce9 (diff)
downloadlinux-875db86e1ec75fe633f1e85ed2f92c731cdbf760.tar.xz
Bluetooth: vhci: Avoid needless snprintf() calls
Avoid double-copying of string literals. Use a "const char *" for each string instead of copying from .rodata into stack and then into the skb. We can go directly from .rodata to the skb. This also works around a Clang bug (that has since been fixed[1]). Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202401250927.1poZERd6-lkp@intel.com/ Fixes: ab4e4380d4e1 ("Bluetooth: Add vhci devcoredump support") Link: https://github.com/llvm/llvm-project/commit/ea2e66aa8b6e363b89df66dc44275a0d7ecd70ce [1] Cc: stable@vger.kernel.org Signed-off-by: Kees Cook <kees@kernel.org> Reviewed-by: Nathan Chancellor <nathan@kernel.org> Reviewed-by: Josh Poimboeuf <jpoimboe@kernel.org> Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Diffstat (limited to 'lib/mpi/mpi-inline.c')
0 files changed, 0 insertions, 0 deletions