Hi Ashish,

kernel test robot noticed the following build warnings:

[auto build test WARNING on efi/next]
[also build test WARNING on linus/master v6.9-rc2 next-20240405]
[cannot apply to tip/x86/core tip/master tip/x86/mm tip/auto-latest]
[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/Ashish-Kalra/efi-x86-skip-efi_arch_mem_reserve-in-case-of-kexec/20240405-071346
base:   https://git.kernel.org/pub/scm/linux/kernel/git/efi/efi.git next
patch link:    
https://lore.kernel.org/r/41db1ebbe58fb082dbe848f1c666ed23e83f1752.1712270976.git.ashish.kalra%40amd.com
patch subject: [PATCH v3 4/4] x86/snp: Convert shared memory back to private on 
kexec
config: x86_64-rhel-8.3-rust 
(https://download.01.org/0day-ci/archive/20240405/[email protected]/config)
compiler: clang version 17.0.6 (https://github.com/llvm/llvm-project 
6009708b4367171ccdbf4b5905cb6a803753fe18)
reproduce (this is a W=1 build): 
(https://download.01.org/0day-ci/archive/20240405/[email protected]/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 <[email protected]>
| Closes: 
https://lore.kernel.org/oe-kbuild-all/[email protected]/

All warnings (new ones prefixed by >>):

   arch/x86/kernel/sev.c:1006:14: error: call to undeclared function 
'pte_decrypted'; ISO C99 and later do not support implicit function 
declarations [-Wimplicit-function-declaration]
    1006 |                 if (pte && pte_decrypted(*pte) && !pte_none(*pte)) {
         |                            ^
   arch/x86/kernel/sev.c:1035:16: error: call to undeclared function 
'pte_decrypted'; ISO C99 and later do not support implicit function 
declarations [-Wimplicit-function-declaration]
    1035 |                 if (!pte || !pte_decrypted(*pte) || pte_none(*pte))
         |                              ^
>> arch/x86/kernel/sev.c:1025:16: warning: variable 'size' set but not used 
>> [-Wunused-but-set-variable]
    1025 |         unsigned long size;
         |                       ^
   arch/x86/kernel/sev.c:1056:7: error: call to undeclared function 
'stop_memory_enc_conversion'; ISO C99 and later do not support implicit 
function declarations [-Wimplicit-function-declaration]
    1056 |         if (!stop_memory_enc_conversion(wait_for_lock))
         |              ^
   1 warning and 3 errors generated.


vim +/size +1025 arch/x86/kernel/sev.c

  1021  
  1022  static void unshare_all_bss_decrypted_memory(void)
  1023  {
  1024          unsigned long vaddr, vaddr_end;
> 1025          unsigned long size;
  1026          unsigned int level;
  1027          unsigned int npages;
  1028          pte_t *pte;
  1029  
  1030          vaddr = (unsigned long)__start_bss_decrypted;
  1031          vaddr_end = (unsigned long)__start_bss_decrypted_unused;
  1032          npages = (vaddr_end - vaddr) >> PAGE_SHIFT;
  1033          for (; vaddr < vaddr_end; vaddr += PAGE_SIZE) {
  1034                  pte = lookup_address(vaddr, &level);
  1035                  if (!pte || !pte_decrypted(*pte) || pte_none(*pte))
  1036                          continue;
  1037  
  1038                  size = page_level_size(level);
  1039                  set_pte_enc(pte, level, (void *)vaddr);
  1040          }
  1041          vaddr = (unsigned long)__start_bss_decrypted;
  1042          snp_set_memory_private(vaddr, npages);
  1043  }
  1044  

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

_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec

Reply via email to