All of lore.kernel.org
 help / color / mirror / Atom feed
* [kas:lam 6/8] arch/x86/kernel/process_64.c:745:5: warning: no previous prototype for 'prctl_enable_tagged_addr'
@ 2022-06-10 11:55 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2022-06-10 11:55 UTC (permalink / raw)
  To: Kirill A. Shutemov; +Cc: kbuild-all, linux-kernel

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/kas/linux.git lam
head:   83ba389477b29461f0c926b69deca5eb6f3f5b6a
commit: 91934401d053c31ea7851a9e88fa83b9fa5a7bc4 [6/8] x86/mm: Provide ARCH_GET_UNTAG_MASK and ARCH_ENABLE_TAGGED_ADDR
config: x86_64-defconfig (https://download.01.org/0day-ci/archive/20220610/202206101916.IklgUdbQ-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce (this is a W=1 build):
        # https://git.kernel.org/pub/scm/linux/kernel/git/kas/linux.git/commit/?id=91934401d053c31ea7851a9e88fa83b9fa5a7bc4
        git remote add kas https://git.kernel.org/pub/scm/linux/kernel/git/kas/linux.git
        git fetch --no-tags kas lam
        git checkout 91934401d053c31ea7851a9e88fa83b9fa5a7bc4
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        make W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash arch/x86/kernel/

If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

>> arch/x86/kernel/process_64.c:745:5: warning: no previous prototype for 'prctl_enable_tagged_addr' [-Wmissing-prototypes]
     745 | int prctl_enable_tagged_addr(unsigned long nr_bits)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~


vim +/prctl_enable_tagged_addr +745 arch/x86/kernel/process_64.c

   744	
 > 745	int prctl_enable_tagged_addr(unsigned long nr_bits)
   746	{
   747		struct mm_struct *mm = current->mm;
   748	
   749		/* Already enabled? */
   750		if (mm->context.lam_cr3_mask)
   751			return -EBUSY;
   752	
   753		/* LAM has to be enabled before spawning threads */
   754		if (get_nr_threads(current) > 1)
   755			return -EBUSY;
   756	
   757		if (!nr_bits) {
   758			return -EINVAL;
   759		} else if (nr_bits <= 6) {
   760			mm->context.lam_cr3_mask = X86_CR3_LAM_U57;
   761			mm->context.untag_mask =  ~GENMASK(62, 57);
   762		} else {
   763			return -EINVAL;
   764		}
   765	
   766		/* Update CR3 to get LAM active */
   767		switch_mm(current->mm, current->mm, current);
   768		return 0;
   769	}
   770	

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-06-10 11:55 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-10 11:55 [kas:lam 6/8] arch/x86/kernel/process_64.c:745:5: warning: no previous prototype for 'prctl_enable_tagged_addr' kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.