Building the Linux kernel with Clang and LLVM
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Richard Kuo <rkuo@quicinc.com>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
	Brian Cain <bcain@kernel.org>
Subject: [bcain:bcain/hmx 26/66] arch/hexagon/kernel/devtree.c:107:16: warning: variable 'dt_root' set but not used
Date: Wed, 29 Apr 2026 00:03:29 +0800	[thread overview]
Message-ID: <202604282333.UkZL41Tj-lkp@intel.com> (raw)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/bcain/linux.git bcain/hmx
head:   1d0fb0b4cf1764f00775cff1c17c2b3494b6b94e
commit: 4f3ac18400ea643ada1af624c617c61f2b32aa5e [26/66] hexagon: add memory management enhancements
config: hexagon-allnoconfig (https://download.01.org/0day-ci/archive/20260428/202604282333.UkZL41Tj-lkp@intel.com/config)
compiler: clang version 23.0.0git (https://github.com/llvm/llvm-project 5bac06718f502014fade905512f1d26d578a18f3)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260428/202604282333.UkZL41Tj-lkp@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 <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202604282333.UkZL41Tj-lkp@intel.com/

All warnings (new ones prefixed by >>):

   arch/hexagon/kernel/devtree.c:50:44: error: incompatible pointer types passing 'unsigned long *' to parameter of type 'int *' [-Wincompatible-pointer-types]
      50 |         p = of_get_flat_dt_prop(node, "bootargs", &l);
         |                                                   ^~
   include/linux/of_fdt.h:57:17: note: passing argument to parameter 'size' here
      57 |                                        int *size);
         |                                             ^
   arch/hexagon/kernel/devtree.c:50:4: error: assigning to 'char *' from 'const void *' discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
      50 |         p = of_get_flat_dt_prop(node, "bootargs", &l);
         |           ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> arch/hexagon/kernel/devtree.c:107:16: warning: variable 'dt_root' set but not used [-Wunused-but-set-variable]
     107 |         unsigned long dt_root;
         |                       ^
   1 warning and 2 errors generated.


vim +/dt_root +107 arch/hexagon/kernel/devtree.c

51ba881ada7104 Brian Cain  2026-01-24   89  
efcb3f02069d74 Richard Kuo 2025-08-18   90  /*
efcb3f02069d74 Richard Kuo 2025-08-18   91   * setup_machine_fdt - set up machine based on dtb passed to kernel
efcb3f02069d74 Richard Kuo 2025-08-18   92   * @dt_phys: physical address of dtb
efcb3f02069d74 Richard Kuo 2025-08-18   93   *
efcb3f02069d74 Richard Kuo 2025-08-18   94   * Sets up some of the earliest stuff -- setting the machine type,
efcb3f02069d74 Richard Kuo 2025-08-18   95   * pulling the command line options, and finding the memory.
efcb3f02069d74 Richard Kuo 2025-08-18   96   *
efcb3f02069d74 Richard Kuo 2025-08-18   97   * Since we're calling this from setup_arch, this is going to happen
efcb3f02069d74 Richard Kuo 2025-08-18   98   * very, very early.  Prior to even the bootmem being set up in the
efcb3f02069d74 Richard Kuo 2025-08-18   99   * old scheme I think.
efcb3f02069d74 Richard Kuo 2025-08-18  100   *
efcb3f02069d74 Richard Kuo 2025-08-18  101   * Also since we're always being fired up by the hypervisor, then
efcb3f02069d74 Richard Kuo 2025-08-18  102   * we are already running with the MMU on with an init segtable.
efcb3f02069d74 Richard Kuo 2025-08-18  103   */
51ba881ada7104 Brian Cain  2026-01-24  104  const struct machine_desc * __init setup_machine_fdt(void *dt_phys)
efcb3f02069d74 Richard Kuo 2025-08-18  105  {
51ba881ada7104 Brian Cain  2026-01-24  106  	const struct machine_desc *mdesc_best = NULL;
efcb3f02069d74 Richard Kuo 2025-08-18 @107  	unsigned long dt_root;
efcb3f02069d74 Richard Kuo 2025-08-18  108  

:::::: The code at line 107 was first introduced by commit
:::::: efcb3f02069d744d73c43ded9cc7d7b20454e203 hexagon: add device tree support

:::::: TO: Richard Kuo <rkuo@quicinc.com>
:::::: CC: Brian Cain <brian.cain@oss.qualcomm.com>

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

                 reply	other threads:[~2026-04-28 16:04 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=202604282333.UkZL41Tj-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=bcain@kernel.org \
    --cc=llvm@lists.linux.dev \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=rkuo@quicinc.com \
    /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