From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.11]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5E07D1B4223; Fri, 7 Feb 2025 22:50:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.175.65.11 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738968625; cv=none; b=JgpXwdtaoMji0MbJjOkaGG9z4J6qbOcU1U3Dmq9SQN0UbutZlRKrpd/egYFxlG9G4qHkcMZJNSDoe/wI5s2cTjffQ8trDMTxEtByhBbNXrHhOnQTXDipWZmNeW8i6IZ+D/AJKmMQyw0HZPHArv0zbckBwngb/aORdIqNegU0+mA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738968625; c=relaxed/simple; bh=ldBbJi0AlQrM1jIjgApQDpoSApjnEgPIW1bNGoPQCSM=; h=Date:From:To:Cc:Subject:Message-ID:MIME-Version:Content-Type: Content-Disposition; b=KmcwKIeO82CuoknWdq+oHjhUr9e6mtUdUPwZsq4jcObWA9zGxwjzctvej7JwaFum5BITiqxwfjJlAP62wyhiVm3vlJjPBSLzmV1kY6Yk4CaTGjsLgJdWKP88EwOoiXEMW9D61HxixKHTiZ/Zq4eqwfFq1HwpGgjUbKhyE4S6HUE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com; spf=pass smtp.mailfrom=intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=XGlKIEPU; arc=none smtp.client-ip=198.175.65.11 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="XGlKIEPU" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1738968624; x=1770504624; h=date:from:to:cc:subject:message-id:mime-version; bh=ldBbJi0AlQrM1jIjgApQDpoSApjnEgPIW1bNGoPQCSM=; b=XGlKIEPUSYvxT04uk1WkRjyrrnEXFKsKMGh2NpjsnU0F5Gtxxwc+KmVi wAVcrC1gA7z/+ISVAxArKtkOnRw/By/qc48J4/M6/ROqI77rdn/rRxZGD BMeO/MaymcSQw6Y+LyHXVktnXPqm09yQJy1P8RE+2gdZZ9afnsUJxXEW9 tFhTv8sroQf0KmLOoMu5McLSjFKaOUUFaNLrG6EoUUVJiMW5w1mjl3ZmM xNleJpiCiiMg4Ovtkm76A8DyZd6qDCReKZIUkpxLX0Xbpd7jwE42CORPR PsxUuldb3S0lDmWqYK8UCf1OVkT3EXGPDvxo2ADMBfU6ARzt84cFrE3fe w==; X-CSE-ConnectionGUID: 1F3YmATaQZmgsRDvOemKGg== X-CSE-MsgGUID: GWxs3yziQRGOanwqo/HzYg== X-IronPort-AV: E=McAfee;i="6700,10204,11338"; a="49862105" X-IronPort-AV: E=Sophos;i="6.13,268,1732608000"; d="scan'208";a="49862105" Received: from fmviesa005.fm.intel.com ([10.60.135.145]) by orvoesa103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 07 Feb 2025 14:50:20 -0800 X-CSE-ConnectionGUID: 1EO8gpagR3C+zry6DJIZag== X-CSE-MsgGUID: Ef7pUHAFSWWFB/MXBC89vA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.12,224,1728975600"; d="scan'208";a="116251476" Received: from lkp-server01.sh.intel.com (HELO d63d4d77d921) ([10.239.97.150]) by fmviesa005.fm.intel.com with ESMTP; 07 Feb 2025 14:50:18 -0800 Received: from kbuild by d63d4d77d921 with local (Exim 4.96) (envelope-from ) id 1tgXAu-000z95-2f; Fri, 07 Feb 2025 22:50:16 +0000 Date: Sat, 8 Feb 2025 06:49:52 +0800 From: kernel test robot To: Andrea Gelmini Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev Subject: [koverstreet-bcachefs:pr/739 1/1] fs/bcachefs/acl.c:139:8: error: use of undeclared identifier 'PF_MEMALLOC_NORECLAIM' Message-ID: <202502080640.Ckh5y7qa-lkp@intel.com> Precedence: bulk X-Mailing-List: llvm@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline tree: https://github.com/koverstreet/bcachefs pr/739 head: 8fd3bb46913c536490fe0c180ce57dc1c0d630ba commit: 8fd3bb46913c536490fe0c180ce57dc1c0d630ba [1/1] Fix typos config: s390-allmodconfig (https://download.01.org/0day-ci/archive/20250208/202502080640.Ckh5y7qa-lkp@intel.com/config) compiler: clang version 19.1.3 (https://github.com/llvm/llvm-project ab51eccf88f5321e7c60591c5546b254b6afab99) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250208/202502080640.Ckh5y7qa-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 | Closes: https://lore.kernel.org/oe-kbuild-all/202502080640.Ckh5y7qa-lkp@intel.com/ All errors (new ones prefixed by >>): In file included from fs/bcachefs/acl.c:3: In file included from fs/bcachefs/bcachefs.h:188: In file included from include/linux/bio.h:10: In file included from include/linux/blk_types.h:10: In file included from include/linux/bvec.h:10: In file included from include/linux/highmem.h:10: In file included from include/linux/mm.h:2224: include/linux/vmstat.h:504:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion] 504 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS + | ~~~~~~~~~~~~~~~~~~~~~ ^ 505 | item]; | ~~~~ include/linux/vmstat.h:511:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion] 511 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS + | ~~~~~~~~~~~~~~~~~~~~~ ^ 512 | NR_VM_NUMA_EVENT_ITEMS + | ~~~~~~~~~~~~~~~~~~~~~~ include/linux/vmstat.h:524:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion] 524 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS + | ~~~~~~~~~~~~~~~~~~~~~ ^ 525 | NR_VM_NUMA_EVENT_ITEMS + | ~~~~~~~~~~~~~~~~~~~~~~ >> fs/bcachefs/acl.c:139:8: error: use of undeclared identifier 'PF_MEMALLOC_NORECLAIM' 139 | acl = allocate_dropping_locks(trans, ret, | ^ fs/bcachefs/btree_iter.h:900:37: note: expanded from macro 'allocate_dropping_locks' 900 | typeof(_do) _p = memalloc_flags_do(PF_MEMALLOC_NORECLAIM|PF_MEMALLOC_NOWARN, _do);\ | ^ >> fs/bcachefs/acl.c:139:8: error: use of undeclared identifier 'PF_MEMALLOC_NOWARN' fs/bcachefs/btree_iter.h:900:59: note: expanded from macro 'allocate_dropping_locks' 900 | typeof(_do) _p = memalloc_flags_do(PF_MEMALLOC_NORECLAIM|PF_MEMALLOC_NOWARN, _do);\ | ^ fs/bcachefs/acl.c:425:8: error: use of undeclared identifier 'PF_MEMALLOC_NORECLAIM' 425 | ret = allocate_dropping_locks_errcode(trans, | ^ fs/bcachefs/btree_iter.h:890:31: note: expanded from macro 'allocate_dropping_locks_errcode' 890 | int _ret = memalloc_flags_do(PF_MEMALLOC_NORECLAIM|PF_MEMALLOC_NOWARN, _do);\ | ^ fs/bcachefs/acl.c:425:8: error: use of undeclared identifier 'PF_MEMALLOC_NOWARN' fs/bcachefs/btree_iter.h:890:53: note: expanded from macro 'allocate_dropping_locks_errcode' 890 | int _ret = memalloc_flags_do(PF_MEMALLOC_NORECLAIM|PF_MEMALLOC_NOWARN, _do);\ | ^ 3 warnings and 4 errors generated. vim +/PF_MEMALLOC_NORECLAIM +139 fs/bcachefs/acl.c 1c6fdbd8f2465d Kent Overstreet 2017-03-16 87 1c6fdbd8f2465d Kent Overstreet 2017-03-16 88 /* 1c6fdbd8f2465d Kent Overstreet 2017-03-16 89 * Convert from filesystem to in-memory representation. 1c6fdbd8f2465d Kent Overstreet 2017-03-16 90 */ 5ff10c0a04c421 Kent Overstreet 2023-05-28 91 static struct posix_acl *bch2_acl_from_disk(struct btree_trans *trans, 5ff10c0a04c421 Kent Overstreet 2023-05-28 92 const void *value, size_t size) 1c6fdbd8f2465d Kent Overstreet 2017-03-16 93 { 1c6fdbd8f2465d Kent Overstreet 2017-03-16 94 const void *p, *end = value + size; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 95 struct posix_acl *acl; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 96 struct posix_acl_entry *out; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 97 unsigned count = 0; 5ff10c0a04c421 Kent Overstreet 2023-05-28 98 int ret; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 99 1c6fdbd8f2465d Kent Overstreet 2017-03-16 100 if (!value) 1c6fdbd8f2465d Kent Overstreet 2017-03-16 101 return NULL; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 102 if (size < sizeof(bch_acl_header)) 1c6fdbd8f2465d Kent Overstreet 2017-03-16 103 goto invalid; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 104 if (((bch_acl_header *)value)->a_version != 1c6fdbd8f2465d Kent Overstreet 2017-03-16 105 cpu_to_le32(BCH_ACL_VERSION)) 1c6fdbd8f2465d Kent Overstreet 2017-03-16 106 goto invalid; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 107 1c6fdbd8f2465d Kent Overstreet 2017-03-16 108 p = value + sizeof(bch_acl_header); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 109 while (p < end) { 1c6fdbd8f2465d Kent Overstreet 2017-03-16 110 const bch_acl_entry *entry = p; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 111 1c6fdbd8f2465d Kent Overstreet 2017-03-16 112 if (p + sizeof(bch_acl_entry_short) > end) 1c6fdbd8f2465d Kent Overstreet 2017-03-16 113 goto invalid; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 114 1c6fdbd8f2465d Kent Overstreet 2017-03-16 115 switch (le16_to_cpu(entry->e_tag)) { 1c6fdbd8f2465d Kent Overstreet 2017-03-16 116 case ACL_USER_OBJ: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 117 case ACL_GROUP_OBJ: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 118 case ACL_MASK: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 119 case ACL_OTHER: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 120 p += sizeof(bch_acl_entry_short); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 121 break; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 122 case ACL_USER: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 123 case ACL_GROUP: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 124 p += sizeof(bch_acl_entry); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 125 break; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 126 default: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 127 goto invalid; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 128 } 1c6fdbd8f2465d Kent Overstreet 2017-03-16 129 1c6fdbd8f2465d Kent Overstreet 2017-03-16 130 count++; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 131 } 1c6fdbd8f2465d Kent Overstreet 2017-03-16 132 1c6fdbd8f2465d Kent Overstreet 2017-03-16 133 if (p > end) 1c6fdbd8f2465d Kent Overstreet 2017-03-16 134 goto invalid; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 135 1c6fdbd8f2465d Kent Overstreet 2017-03-16 136 if (!count) 1c6fdbd8f2465d Kent Overstreet 2017-03-16 137 return NULL; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 138 5ff10c0a04c421 Kent Overstreet 2023-05-28 @139 acl = allocate_dropping_locks(trans, ret, 8fd3bb46913c53 Andrea Gelmini 2024-12-22 140 posix_acl_alloc(count, GFP_KERNEL)); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 141 if (!acl) 1c6fdbd8f2465d Kent Overstreet 2017-03-16 142 return ERR_PTR(-ENOMEM); 5ff10c0a04c421 Kent Overstreet 2023-05-28 143 if (ret) { 5ff10c0a04c421 Kent Overstreet 2023-05-28 144 kfree(acl); 5ff10c0a04c421 Kent Overstreet 2023-05-28 145 return ERR_PTR(ret); 5ff10c0a04c421 Kent Overstreet 2023-05-28 146 } 1c6fdbd8f2465d Kent Overstreet 2017-03-16 147 1c6fdbd8f2465d Kent Overstreet 2017-03-16 148 out = acl->a_entries; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 149 1c6fdbd8f2465d Kent Overstreet 2017-03-16 150 p = value + sizeof(bch_acl_header); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 151 while (p < end) { 1c6fdbd8f2465d Kent Overstreet 2017-03-16 152 const bch_acl_entry *in = p; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 153 1c6fdbd8f2465d Kent Overstreet 2017-03-16 154 out->e_tag = le16_to_cpu(in->e_tag); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 155 out->e_perm = le16_to_cpu(in->e_perm); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 156 1c6fdbd8f2465d Kent Overstreet 2017-03-16 157 switch (out->e_tag) { 1c6fdbd8f2465d Kent Overstreet 2017-03-16 158 case ACL_USER_OBJ: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 159 case ACL_GROUP_OBJ: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 160 case ACL_MASK: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 161 case ACL_OTHER: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 162 p += sizeof(bch_acl_entry_short); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 163 break; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 164 case ACL_USER: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 165 out->e_uid = make_kuid(&init_user_ns, 1c6fdbd8f2465d Kent Overstreet 2017-03-16 166 le32_to_cpu(in->e_id)); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 167 p += sizeof(bch_acl_entry); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 168 break; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 169 case ACL_GROUP: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 170 out->e_gid = make_kgid(&init_user_ns, 1c6fdbd8f2465d Kent Overstreet 2017-03-16 171 le32_to_cpu(in->e_id)); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 172 p += sizeof(bch_acl_entry); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 173 break; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 174 } 1c6fdbd8f2465d Kent Overstreet 2017-03-16 175 1c6fdbd8f2465d Kent Overstreet 2017-03-16 176 out++; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 177 } 1c6fdbd8f2465d Kent Overstreet 2017-03-16 178 1c6fdbd8f2465d Kent Overstreet 2017-03-16 179 BUG_ON(out != acl->a_entries + acl->a_count); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 180 1c6fdbd8f2465d Kent Overstreet 2017-03-16 181 return acl; 1c6fdbd8f2465d Kent Overstreet 2017-03-16 182 invalid: 1c6fdbd8f2465d Kent Overstreet 2017-03-16 183 pr_err("invalid acl entry"); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 184 return ERR_PTR(-EINVAL); 1c6fdbd8f2465d Kent Overstreet 2017-03-16 185 } 1c6fdbd8f2465d Kent Overstreet 2017-03-16 186 :::::: The code at line 139 was first introduced by commit :::::: 5ff10c0a04c4217b24997d9b127c50602d717ab3 bcachefs: Convert acl.c to allocate_dropping_locks() :::::: TO: Kent Overstreet :::::: CC: Kent Overstreet -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki