Re: [PATCH v3 3/4] KVM: s390: refactor and split some gmap helpers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Claudio,

kernel test robot noticed the following build warnings:

[auto build test WARNING on kvms390/next]
[also build test WARNING on s390/features kvm/queue kvm/next mst-vhost/linux-next linus/master v6.15-rc7 next-20250522]
[cannot apply to kvm/linux-next]
[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/Claudio-Imbrenda/s390-remove-unneeded-includes/20250522-212623
base:   https://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux.git next
patch link:    https://lore.kernel.org/r/20250522132259.167708-4-imbrenda%40linux.ibm.com
patch subject: [PATCH v3 3/4] KVM: s390: refactor and split some gmap helpers
config: s390-randconfig-001-20250523 (https://download.01.org/0day-ci/archive/20250523/202505230839.LAF8wtzO-lkp@xxxxxxxxx/config)
compiler: s390-linux-gcc (GCC) 8.5.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250523/202505230839.LAF8wtzO-lkp@xxxxxxxxx/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@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202505230839.LAF8wtzO-lkp@xxxxxxxxx/

All warnings (new ones prefixed by >>):

   arch/s390/mm/gmap_helpers.c: In function 'ptep_zap_swap_entry':
   arch/s390/mm/gmap_helpers.c:26:7: error: implicit declaration of function 'non_swap_entry'; did you mean 'init_wait_entry'? [-Werror=implicit-function-declaration]
     if (!non_swap_entry(entry))
          ^~~~~~~~~~~~~~
          init_wait_entry
   arch/s390/mm/gmap_helpers.c:28:11: error: implicit declaration of function 'is_migration_entry'; did you mean 'list_first_entry'? [-Werror=implicit-function-declaration]
     else if (is_migration_entry(entry))
              ^~~~~~~~~~~~~~~~~~
              list_first_entry
   arch/s390/mm/gmap_helpers.c:29:33: error: implicit declaration of function 'pfn_swap_entry_folio'; did you mean 'filemap_dirty_folio'? [-Werror=implicit-function-declaration]
      dec_mm_counter(mm, mm_counter(pfn_swap_entry_folio(entry)));
                                    ^~~~~~~~~~~~~~~~~~~~
                                    filemap_dirty_folio
>> arch/s390/mm/gmap_helpers.c:29:33: warning: passing argument 1 of 'mm_counter' makes pointer from integer without a cast [-Wint-conversion]
      dec_mm_counter(mm, mm_counter(pfn_swap_entry_folio(entry)));
                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   In file included from arch/s390/mm/gmap_helpers.c:9:
   include/linux/mm.h:2725:44: note: expected 'struct folio *' but argument is of type 'int'
    static inline int mm_counter(struct folio *folio)
                                 ~~~~~~~~~~~~~~^~~~~
   arch/s390/mm/gmap_helpers.c:30:2: error: implicit declaration of function 'free_swap_and_cache'; did you mean 'free_pgd_range'? [-Werror=implicit-function-declaration]
     free_swap_and_cache(entry);
     ^~~~~~~~~~~~~~~~~~~
     free_pgd_range
   arch/s390/mm/gmap_helpers.c: In function 'gmap_helper_zap_one_page':
   arch/s390/mm/gmap_helpers.c:60:27: error: implicit declaration of function 'pte_to_swp_entry'; did you mean 'ptep_zap_swap_entry'? [-Werror=implicit-function-declaration]
      ptep_zap_swap_entry(mm, pte_to_swp_entry(*ptep));
                              ^~~~~~~~~~~~~~~~
                              ptep_zap_swap_entry
   arch/s390/mm/gmap_helpers.c:60:27: error: incompatible type for argument 2 of 'ptep_zap_swap_entry'
      ptep_zap_swap_entry(mm, pte_to_swp_entry(*ptep));
                              ^~~~~~~~~~~~~~~~~~~~~~~
   arch/s390/mm/gmap_helpers.c:24:67: note: expected 'swp_entry_t' {aka 'struct <anonymous>'} but argument is of type 'int'
    static void ptep_zap_swap_entry(struct mm_struct *mm, swp_entry_t entry)
                                                          ~~~~~~~~~~~~^~~~~
   cc1: some warnings being treated as errors
--
>> arch/s390/mm/gmap.c:2251:33: warning: 'find_zeropage_ops' defined but not used [-Wunused-const-variable=]
    static const struct mm_walk_ops find_zeropage_ops = {
                                    ^~~~~~~~~~~~~~~~~


vim +/mm_counter +29 arch/s390/mm/gmap_helpers.c

    14	
    15	/**
    16	 * ptep_zap_swap_entry() - discard a swap entry.
    17	 * @mm: the mm
    18	 * @entry: the swap entry that needs to be zapped
    19	 *
    20	 * Discards the given swap entry. If the swap entry was an actual swap
    21	 * entry (and not a migration entry, for example), the actual swapped
    22	 * page is also discarded from swap.
    23	 */
    24	static void ptep_zap_swap_entry(struct mm_struct *mm, swp_entry_t entry)
    25	{
    26		if (!non_swap_entry(entry))
    27			dec_mm_counter(mm, MM_SWAPENTS);
    28		else if (is_migration_entry(entry))
  > 29			dec_mm_counter(mm, mm_counter(pfn_swap_entry_folio(entry)));
    30		free_swap_and_cache(entry);
    31	}
    32	

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




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux