Hi Fidal, kernel test robot noticed the following build warnings:
[auto build test WARNING on trace/for-next] [also build test WARNING on linus/master v6.17-rc4 next-20250905] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Fidal-Palamparambil/Fixed-the-build-warning-in-init_trace_printk_function_export/20250907-221041 base: https://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace for-next patch link: https://lore.kernel.org/r/20250907140755.529-1-rootuserhere%40gmail.com patch subject: [PATCH] Fixed the build warning in init_trace_printk_function_export(): config: x86_64-buildonly-randconfig-001-20250907 (https://download.01.org/0day-ci/archive/20250908/202509080040.8geyq9ef-...@intel.com/config) compiler: gcc-13 (Debian 13.3.0-16) 13.3.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250908/202509080040.8geyq9ef-...@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <l...@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202509080040.8geyq9ef-...@intel.com/ All warnings (new ones prefixed by >>): kernel/trace/trace_printk.c: In function 'ftrace_formats_open': >> kernel/trace/trace_printk.c:369:25: warning: passing argument 1 of >> 'seq_open' discards 'const' qualifier from pointer target type >> [-Wdiscarded-qualifiers] 369 | return seq_open(file, &show_format_seq_ops); | ^~~~ In file included from kernel/trace/trace_printk.c:8: include/linux/seq_file.h:108:14: note: expected 'struct file *' but argument is of type 'const struct file *' 108 | int seq_open(struct file *, const struct seq_operations *); | ^~~~~~~~~~~~~ kernel/trace/trace_printk.c: At top level: kernel/trace/trace_printk.c:373:17: error: initialization of 'int (*)(struct inode *, struct file *)' from incompatible pointer type 'int (*)(struct inode *, const struct file *)' [-Werror=incompatible-pointer-types] 373 | .open = ftrace_formats_open, | ^~~~~~~~~~~~~~~~~~~ kernel/trace/trace_printk.c:373:17: note: (near initialization for 'ftrace_formats_fops.open') cc1: some warnings being treated as errors vim +369 kernel/trace/trace_printk.c 7975a2be16dd42 Steven Rostedt 2009-03-12 359 7975a2be16dd42 Steven Rostedt 2009-03-12 360 static int 66670b02cb828c Fidal palamparambil 2025-09-07 361 ftrace_formats_open(struct inode *inode, const struct file *file) 7975a2be16dd42 Steven Rostedt 2009-03-12 362 { 17911ff38aa58d Steven Rostedt (VMware 2019-10-11 363) int ret; 17911ff38aa58d Steven Rostedt (VMware 2019-10-11 364) 17911ff38aa58d Steven Rostedt (VMware 2019-10-11 365) ret = security_locked_down(LOCKDOWN_TRACEFS); 17911ff38aa58d Steven Rostedt (VMware 2019-10-11 366) if (ret) 17911ff38aa58d Steven Rostedt (VMware 2019-10-11 367) return ret; 17911ff38aa58d Steven Rostedt (VMware 2019-10-11 368) c8961ec6da22ea Li Zefan 2009-06-24 @369 return seq_open(file, &show_format_seq_ops); 7975a2be16dd42 Steven Rostedt 2009-03-12 370 } 7975a2be16dd42 Steven Rostedt 2009-03-12 371 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki