lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202407190525.rqkFKslD-lkp@intel.com>
Date: Fri, 19 Jul 2024 05:19:40 +0800
From: kernel test robot <lkp@...el.com>
To: Oscar Salvador <osalvador@...e.de>,
	Andrew Morton <akpm@...ux-foundation.org>
Cc: oe-kbuild-all@...ts.linux.dev,
	Linux Memory Management List <linux-mm@...ck.org>,
	linux-kernel@...r.kernel.org, Peter Xu <peterx@...hat.com>,
	Muchun Song <muchun.song@...ux.dev>, Michal Hocko <mhocko@...e.com>,
	Donet Tom <donettom@...ux.ibm.com>,
	"Kirill A . Shutemov" <kirill.shutemov@...ux.intel.com>,
	Matthew Wilcox <willy@...radead.org>,
	Vlastimil Babka <vbabka@...e.cz>,
	Oscar Salvador <osalvador@...e.de>
Subject: Re: [PATCH 4/9] arch/sparc: Teach arch_get_unmapped_area{_topdown}
 to handle hugetlb mappings

Hi Oscar,

kernel test robot noticed the following build errors:

[auto build test ERROR on s390/features]
[also build test ERROR on akpm-mm/mm-everything powerpc/next powerpc/fixes deller-parisc/for-next arnd-asm-generic/master linus/master v6.10 next-20240718]
[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/Oscar-Salvador/mm-mmap-Teach-generic_get_unmapped_area-_topdown-to-handle-hugetlb-mappings/20240718-191208
base:   https://git.kernel.org/pub/scm/linux/kernel/git/s390/linux.git features
patch link:    https://lore.kernel.org/r/20240718105903.19617-5-osalvador%40suse.de
patch subject: [PATCH 4/9] arch/sparc: Teach arch_get_unmapped_area{_topdown} to handle hugetlb mappings
config: sparc-allnoconfig (https://download.01.org/0day-ci/archive/20240719/202407190525.rqkFKslD-lkp@intel.com/config)
compiler: sparc-linux-gcc (GCC) 14.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240719/202407190525.rqkFKslD-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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202407190525.rqkFKslD-lkp@intel.com/

All errors (new ones prefixed by >>):

   arch/sparc/kernel/sys_sparc_32.c: In function 'arch_get_unmapped_area':
>> arch/sparc/kernel/sys_sparc_32.c:47:21: error: implicit declaration of function 'is_file_hugepages' [-Wimplicit-function-declaration]
      47 |         if (filp && is_file_hugepages(filp))
         |                     ^~~~~~~~~~~~~~~~~
>> arch/sparc/kernel/sys_sparc_32.c:74:35: error: implicit declaration of function 'huge_page_mask_align' [-Wimplicit-function-declaration]
      74 |                 info.align_mask = huge_page_mask_align(filp);
         |                                   ^~~~~~~~~~~~~~~~~~~~


vim +/is_file_hugepages +47 arch/sparc/kernel/sys_sparc_32.c

    41	
    42	unsigned long arch_get_unmapped_area(struct file *filp, unsigned long addr, unsigned long len, unsigned long pgoff, unsigned long flags)
    43	{
    44		struct vm_unmapped_area_info info = {};
    45		bool file_hugepage = false;
    46	
  > 47		if (filp && is_file_hugepages(filp))
    48			file_hugepage = true;
    49	
    50		if (flags & MAP_FIXED) {
    51			/* We do not accept a shared mapping if it would violate
    52			 * cache aliasing constraints.
    53			 */
    54			if (!file_hugepage && (flags & MAP_SHARED) &&
    55			    ((addr - (pgoff << PAGE_SHIFT)) & (SHMLBA - 1)))
    56				return -EINVAL;
    57			return addr;
    58		}
    59	
    60		/* See asm-sparc/uaccess.h */
    61		if (len > TASK_SIZE - PAGE_SIZE)
    62			return -ENOMEM;
    63		if (!addr)
    64			addr = TASK_UNMAPPED_BASE;
    65	
    66		info.length = len;
    67		info.low_limit = addr;
    68		info.high_limit = TASK_SIZE;
    69		if (!file_hugepage) {
    70			info.align_mask = (flags & MAP_SHARED) ?
    71				(PAGE_MASK & (SHMLBA - 1)) : 0;
    72			info.align_offset = pgoff << PAGE_SHIFT;
    73		} else {
  > 74			info.align_mask = huge_page_mask_align(filp);
    75		}
    76		return vm_unmapped_area(&info);
    77	}
    78	

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ