* [linux-stable-rc:linux-5.15.y 3230/8464] drivers/gpu/drm/i915/gt/intel_gt.c:966:2: error: format string is not a string literal (potentially insecure)
@ 2022-07-18 8:24 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2022-07-18 8:24 UTC (permalink / raw)
To: Tvrtko Ursulin
Cc: llvm, kbuild-all, linux-kernel, Greg Kroah-Hartman, Daniel Vetter
Hi Tvrtko,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.15.y
head: baefa2315cb1371486f6661a628e96fa3336f573
commit: 8a17a077e7e9ecce25c95dbdb27843d2d6c2f0f7 [3230/8464] drm/i915: Flush TLBs before releasing backing store
config: i386-randconfig-a002-20220718 (https://download.01.org/0day-ci/archive/20220718/202207181627.mc5qRroQ-lkp@intel.com/config)
compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project d74b88c69dc2644bd0dc5d64e2d7413a0d4040e5)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git/commit/?id=8a17a077e7e9ecce25c95dbdb27843d2d6c2f0f7
git remote add linux-stable-rc https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git
git fetch --no-tags linux-stable-rc linux-5.15.y
git checkout 8a17a077e7e9ecce25c95dbdb27843d2d6c2f0f7
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 SHELL=/bin/bash
If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
>> drivers/gpu/drm/i915/gt/intel_gt.c:966:2: error: format string is not a string literal (potentially insecure) [-Werror,-Wformat-security]
GEM_TRACE("\n");
^~~~~~~~~~~~~~~
drivers/gpu/drm/i915/i915_gem.h:76:24: note: expanded from macro 'GEM_TRACE'
#define GEM_TRACE(...) trace_printk(__VA_ARGS__)
^~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/kernel.h:366:3: note: expanded from macro 'trace_printk'
do_trace_printk(fmt, ##__VA_ARGS__); \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/kernel.h:380:30: note: expanded from macro 'do_trace_printk'
__trace_bprintk(_THIS_IP_, trace_printk_fmt, ##args); \
^~~~~~~~~~~~~~~~
drivers/gpu/drm/i915/gt/intel_gt.c:966:2: note: treat the string as an argument to avoid this
drivers/gpu/drm/i915/i915_gem.h:76:24: note: expanded from macro 'GEM_TRACE'
#define GEM_TRACE(...) trace_printk(__VA_ARGS__)
^
include/linux/kernel.h:366:3: note: expanded from macro 'trace_printk'
do_trace_printk(fmt, ##__VA_ARGS__); \
^
include/linux/kernel.h:380:30: note: expanded from macro 'do_trace_printk'
__trace_bprintk(_THIS_IP_, trace_printk_fmt, ##args); \
^
1 error generated.
vim +966 drivers/gpu/drm/i915/gt/intel_gt.c
927
928 void intel_gt_invalidate_tlbs(struct intel_gt *gt)
929 {
930 static const i915_reg_t gen8_regs[] = {
931 [RENDER_CLASS] = GEN8_RTCR,
932 [VIDEO_DECODE_CLASS] = GEN8_M1TCR, /* , GEN8_M2TCR */
933 [VIDEO_ENHANCEMENT_CLASS] = GEN8_VTCR,
934 [COPY_ENGINE_CLASS] = GEN8_BTCR,
935 };
936 static const i915_reg_t gen12_regs[] = {
937 [RENDER_CLASS] = GEN12_GFX_TLB_INV_CR,
938 [VIDEO_DECODE_CLASS] = GEN12_VD_TLB_INV_CR,
939 [VIDEO_ENHANCEMENT_CLASS] = GEN12_VE_TLB_INV_CR,
940 [COPY_ENGINE_CLASS] = GEN12_BLT_TLB_INV_CR,
941 };
942 struct drm_i915_private *i915 = gt->i915;
943 struct intel_uncore *uncore = gt->uncore;
944 struct intel_engine_cs *engine;
945 enum intel_engine_id id;
946 const i915_reg_t *regs;
947 unsigned int num = 0;
948
949 if (I915_SELFTEST_ONLY(gt->awake == -ENODEV))
950 return;
951
952 if (GRAPHICS_VER(i915) == 12) {
953 regs = gen12_regs;
954 num = ARRAY_SIZE(gen12_regs);
955 } else if (GRAPHICS_VER(i915) >= 8 && GRAPHICS_VER(i915) <= 11) {
956 regs = gen8_regs;
957 num = ARRAY_SIZE(gen8_regs);
958 } else if (GRAPHICS_VER(i915) < 8) {
959 return;
960 }
961
962 if (drm_WARN_ONCE(&i915->drm, !num,
963 "Platform does not implement TLB invalidation!"))
964 return;
965
> 966 GEM_TRACE("\n");
--
0-DAY CI Kernel Test Service
https://01.org/lkp
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-07-18 8:24 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-18 8:24 [linux-stable-rc:linux-5.15.y 3230/8464] drivers/gpu/drm/i915/gt/intel_gt.c:966:2: error: format string is not a string literal (potentially insecure) kernel test robot
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.