* Re: [RFCv5 2/5] iomap: Refactor iop_set_range_uptodate() function
[not found] <203a9e25873f6c94c9de89823439aa1f6a7dc714.1683485700.git.ritesh.list@gmail.com>
@ 2023-05-07 21:54 ` kernel test robot
2023-05-08 2:42 ` kernel test robot
1 sibling, 0 replies; 2+ messages in thread
From: kernel test robot @ 2023-05-07 21:54 UTC (permalink / raw)
To: Ritesh Harjani (IBM); +Cc: oe-kbuild-all
Hi Ritesh,
[This is a private test report for your RFC patch.]
kernel test robot noticed the following build warnings:
[auto build test WARNING on xfs-linux/for-next]
[also build test WARNING on gfs2/for-next linus/master v6.3 next-20230505]
[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/Ritesh-Harjani-IBM/iomap-Rename-iomap_page_create-release-to-iop_alloc-free/20230508-032903
base: https://git.kernel.org/pub/scm/fs/xfs/xfs-linux.git for-next
patch link: https://lore.kernel.org/r/203a9e25873f6c94c9de89823439aa1f6a7dc714.1683485700.git.ritesh.list%40gmail.com
patch subject: [RFCv5 2/5] iomap: Refactor iop_set_range_uptodate() function
config: m68k-allyesconfig (https://download.01.org/0day-ci/archive/20230508/202305080558.vdZsLPmE-lkp@intel.com/config)
compiler: m68k-linux-gcc (GCC) 12.1.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/intel-lab-lkp/linux/commit/9f4d2751ba6c4b9022e0361ce14274eb156cf39b
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Ritesh-Harjani-IBM/iomap-Rename-iomap_page_create-release-to-iop_alloc-free/20230508-032903
git checkout 9f4d2751ba6c4b9022e0361ce14274eb156cf39b
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=m68k olddefconfig
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=m68k SHELL=/bin/bash fs/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@intel.com>
| Link: https://lore.kernel.org/oe-kbuild-all/202305080558.vdZsLPmE-lkp@intel.com/
All warnings (new ones prefixed by >>):
fs/iomap/buffered-io.c: In function 'iomap_read_inline_data':
>> fs/iomap/buffered-io.c:215:28: warning: variable 'iop' set but not used [-Wunused-but-set-variable]
215 | struct iomap_page *iop;
| ^~~
vim +/iop +215 fs/iomap/buffered-io.c
afc51aaa22f26c Darrick J. Wong 2019-07-15 202
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 203 /**
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 204 * iomap_read_inline_data - copy inline data into the page cache
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 205 * @iter: iteration structure
874628a2c59003 Matthew Wilcox (Oracle 2021-07-23 206) * @folio: folio to copy to
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 207 *
874628a2c59003 Matthew Wilcox (Oracle 2021-07-23 208) * Copy the inline data in @iter into @folio and zero out the rest of the folio.
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 209 * Only a single IOMAP_INLINE extent is allowed at the end of each file.
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 210 * Returns zero for success to complete the read, or the usual negative errno.
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 211 */
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 212 static int iomap_read_inline_data(const struct iomap_iter *iter,
874628a2c59003 Matthew Wilcox (Oracle 2021-07-23 213) struct folio *folio)
afc51aaa22f26c Darrick J. Wong 2019-07-15 214 {
cd1e5afe5503ed Matthew Wilcox (Oracle 2021-04-28 @215) struct iomap_page *iop;
fad0a1ab34f777 Christoph Hellwig 2021-08-10 216 const struct iomap *iomap = iomap_iter_srcmap(iter);
1b5c1e36dc0e0f Christoph Hellwig 2021-08-10 217 size_t size = i_size_read(iter->inode) - iomap->offset;
b405435b419cb6 Matthew Wilcox (Oracle 2021-08-02 218) size_t poff = offset_in_page(iomap->offset);
431c0566bb6078 Matthew Wilcox (Oracle 2021-04-28 219) size_t offset = offset_in_folio(folio, iomap->offset);
afc51aaa22f26c Darrick J. Wong 2019-07-15 220 void *addr;
afc51aaa22f26c Darrick J. Wong 2019-07-15 221
874628a2c59003 Matthew Wilcox (Oracle 2021-07-23 222) if (folio_test_uptodate(folio))
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 223 return 0;
afc51aaa22f26c Darrick J. Wong 2019-07-15 224
ae44f9c286da3f Matthew Wilcox (Oracle 2021-08-04 225) if (WARN_ON_ONCE(size > PAGE_SIZE - poff))
ae44f9c286da3f Matthew Wilcox (Oracle 2021-08-04 226) return -EIO;
69f4a26c1e0c7c Gao Xiang 2021-08-03 227 if (WARN_ON_ONCE(size > PAGE_SIZE -
69f4a26c1e0c7c Gao Xiang 2021-08-03 228 offset_in_page(iomap->inline_data)))
69f4a26c1e0c7c Gao Xiang 2021-08-03 229 return -EIO;
69f4a26c1e0c7c Gao Xiang 2021-08-03 230 if (WARN_ON_ONCE(size > iomap->length))
69f4a26c1e0c7c Gao Xiang 2021-08-03 231 return -EIO;
431c0566bb6078 Matthew Wilcox (Oracle 2021-04-28 232) if (offset > 0)
bd964cc84262c6 Ritesh Harjani (IBM 2023-05-08 233) iop = iop_alloc(iter->inode, folio, iter->flags);
cd1e5afe5503ed Matthew Wilcox (Oracle 2021-04-28 234) else
cd1e5afe5503ed Matthew Wilcox (Oracle 2021-04-28 235) iop = to_iomap_page(folio);
afc51aaa22f26c Darrick J. Wong 2019-07-15 236
874628a2c59003 Matthew Wilcox (Oracle 2021-07-23 237) addr = kmap_local_folio(folio, offset);
afc51aaa22f26c Darrick J. Wong 2019-07-15 238 memcpy(addr, iomap->inline_data, size);
b405435b419cb6 Matthew Wilcox (Oracle 2021-08-02 239) memset(addr + size, 0, PAGE_SIZE - poff - size);
ab069d5fdcd145 Matthew Wilcox (Oracle 2021-08-04 240) kunmap_local(addr);
9f4d2751ba6c4b Ritesh Harjani (IBM 2023-05-08 241) iop_set_range_uptodate(iter->inode, folio, offset, PAGE_SIZE - poff);
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 242 return 0;
afc51aaa22f26c Darrick J. Wong 2019-07-15 243 }
afc51aaa22f26c Darrick J. Wong 2019-07-15 244
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [RFCv5 2/5] iomap: Refactor iop_set_range_uptodate() function
[not found] <203a9e25873f6c94c9de89823439aa1f6a7dc714.1683485700.git.ritesh.list@gmail.com>
2023-05-07 21:54 ` [RFCv5 2/5] iomap: Refactor iop_set_range_uptodate() function kernel test robot
@ 2023-05-08 2:42 ` kernel test robot
1 sibling, 0 replies; 2+ messages in thread
From: kernel test robot @ 2023-05-08 2:42 UTC (permalink / raw)
To: Ritesh Harjani (IBM); +Cc: llvm, oe-kbuild-all
Hi Ritesh,
[This is a private test report for your RFC patch.]
kernel test robot noticed the following build warnings:
[auto build test WARNING on xfs-linux/for-next]
[also build test WARNING on gfs2/for-next linus/master v6.4-rc1 next-20230505]
[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/Ritesh-Harjani-IBM/iomap-Rename-iomap_page_create-release-to-iop_alloc-free/20230508-032903
base: https://git.kernel.org/pub/scm/fs/xfs/xfs-linux.git for-next
patch link: https://lore.kernel.org/r/203a9e25873f6c94c9de89823439aa1f6a7dc714.1683485700.git.ritesh.list%40gmail.com
patch subject: [RFCv5 2/5] iomap: Refactor iop_set_range_uptodate() function
config: i386-randconfig-a001-20230508 (https://download.01.org/0day-ci/archive/20230508/202305080949.grIeocG0-lkp@intel.com/config)
compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project f28c006a5895fc0e329fe15fead81e37457cb1d1)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/intel-lab-lkp/linux/commit/9f4d2751ba6c4b9022e0361ce14274eb156cf39b
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Ritesh-Harjani-IBM/iomap-Rename-iomap_page_create-release-to-iop_alloc-free/20230508-032903
git checkout 9f4d2751ba6c4b9022e0361ce14274eb156cf39b
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 olddefconfig
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 SHELL=/bin/bash fs/iomap/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@intel.com>
| Link: https://lore.kernel.org/oe-kbuild-all/202305080949.grIeocG0-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> fs/iomap/buffered-io.c:215:21: warning: variable 'iop' set but not used [-Wunused-but-set-variable]
struct iomap_page *iop;
^
1 warning generated.
vim +/iop +215 fs/iomap/buffered-io.c
afc51aaa22f26c Darrick J. Wong 2019-07-15 202
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 203 /**
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 204 * iomap_read_inline_data - copy inline data into the page cache
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 205 * @iter: iteration structure
874628a2c59003 Matthew Wilcox (Oracle 2021-07-23 206) * @folio: folio to copy to
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 207 *
874628a2c59003 Matthew Wilcox (Oracle 2021-07-23 208) * Copy the inline data in @iter into @folio and zero out the rest of the folio.
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 209 * Only a single IOMAP_INLINE extent is allowed at the end of each file.
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 210 * Returns zero for success to complete the read, or the usual negative errno.
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 211 */
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 212 static int iomap_read_inline_data(const struct iomap_iter *iter,
874628a2c59003 Matthew Wilcox (Oracle 2021-07-23 213) struct folio *folio)
afc51aaa22f26c Darrick J. Wong 2019-07-15 214 {
cd1e5afe5503ed Matthew Wilcox (Oracle 2021-04-28 @215) struct iomap_page *iop;
fad0a1ab34f777 Christoph Hellwig 2021-08-10 216 const struct iomap *iomap = iomap_iter_srcmap(iter);
1b5c1e36dc0e0f Christoph Hellwig 2021-08-10 217 size_t size = i_size_read(iter->inode) - iomap->offset;
b405435b419cb6 Matthew Wilcox (Oracle 2021-08-02 218) size_t poff = offset_in_page(iomap->offset);
431c0566bb6078 Matthew Wilcox (Oracle 2021-04-28 219) size_t offset = offset_in_folio(folio, iomap->offset);
afc51aaa22f26c Darrick J. Wong 2019-07-15 220 void *addr;
afc51aaa22f26c Darrick J. Wong 2019-07-15 221
874628a2c59003 Matthew Wilcox (Oracle 2021-07-23 222) if (folio_test_uptodate(folio))
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 223 return 0;
afc51aaa22f26c Darrick J. Wong 2019-07-15 224
ae44f9c286da3f Matthew Wilcox (Oracle 2021-08-04 225) if (WARN_ON_ONCE(size > PAGE_SIZE - poff))
ae44f9c286da3f Matthew Wilcox (Oracle 2021-08-04 226) return -EIO;
69f4a26c1e0c7c Gao Xiang 2021-08-03 227 if (WARN_ON_ONCE(size > PAGE_SIZE -
69f4a26c1e0c7c Gao Xiang 2021-08-03 228 offset_in_page(iomap->inline_data)))
69f4a26c1e0c7c Gao Xiang 2021-08-03 229 return -EIO;
69f4a26c1e0c7c Gao Xiang 2021-08-03 230 if (WARN_ON_ONCE(size > iomap->length))
69f4a26c1e0c7c Gao Xiang 2021-08-03 231 return -EIO;
431c0566bb6078 Matthew Wilcox (Oracle 2021-04-28 232) if (offset > 0)
bd964cc84262c6 Ritesh Harjani (IBM 2023-05-08 233) iop = iop_alloc(iter->inode, folio, iter->flags);
cd1e5afe5503ed Matthew Wilcox (Oracle 2021-04-28 234) else
cd1e5afe5503ed Matthew Wilcox (Oracle 2021-04-28 235) iop = to_iomap_page(folio);
afc51aaa22f26c Darrick J. Wong 2019-07-15 236
874628a2c59003 Matthew Wilcox (Oracle 2021-07-23 237) addr = kmap_local_folio(folio, offset);
afc51aaa22f26c Darrick J. Wong 2019-07-15 238 memcpy(addr, iomap->inline_data, size);
b405435b419cb6 Matthew Wilcox (Oracle 2021-08-02 239) memset(addr + size, 0, PAGE_SIZE - poff - size);
ab069d5fdcd145 Matthew Wilcox (Oracle 2021-08-04 240) kunmap_local(addr);
9f4d2751ba6c4b Ritesh Harjani (IBM 2023-05-08 241) iop_set_range_uptodate(iter->inode, folio, offset, PAGE_SIZE - poff);
5ad448ce2976f8 Andreas Gruenbacher 2021-11-24 242 return 0;
afc51aaa22f26c Darrick J. Wong 2019-07-15 243 }
afc51aaa22f26c Darrick J. Wong 2019-07-15 244
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-05-08 2:43 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <203a9e25873f6c94c9de89823439aa1f6a7dc714.1683485700.git.ritesh.list@gmail.com>
2023-05-07 21:54 ` [RFCv5 2/5] iomap: Refactor iop_set_range_uptodate() function kernel test robot
2023-05-08 2:42 ` kernel test robot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).