[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202012291348.t5DtLHhO-lkp@intel.com>
Date: Tue, 29 Dec 2020 13:12:39 +0800
From: kernel test robot <lkp@...el.com>
To: Konstantin Komarov <almaz.alexandrovich@...agon-software.com>,
linux-fsdevel@...r.kernel.org
Cc: kbuild-all@...ts.01.org, clang-built-linux@...glegroups.com,
viro@...iv.linux.org.uk, linux-kernel@...r.kernel.org,
pali@...nel.org, dsterba@...e.cz, aaptel@...e.com,
willy@...radead.org, rdunlap@...radead.org, joe@...ches.com,
mark@...mstone.com
Subject: Re: [PATCH v16 09/10] fs/ntfs3: Add NTFS3 in fs/Kconfig and
fs/Makefile
Hi Konstantin,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on linus/master]
[also build test WARNING on v5.11-rc1 next-20201223]
[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]
url: https://github.com/0day-ci/linux/commits/Konstantin-Komarov/NTFS-read-write-driver-GPL-implementation-by-Paragon-Software/20201225-215909
base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 71c5f03154ac1cb27423b984743ccc2f5d11d14d
config: powerpc64-randconfig-r021-20201229 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project cee1e7d14f4628d6174b33640d502bff3b54ae45)
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
# install powerpc64 cross compiling tool for clang build
# apt-get install binutils-powerpc64-linux-gnu
# https://github.com/0day-ci/linux/commit/fafee24e48a76d7a2f856437aa0480ecfe72bec6
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Konstantin-Komarov/NTFS-read-write-driver-GPL-implementation-by-Paragon-Software/20201225-215909
git checkout fafee24e48a76d7a2f856437aa0480ecfe72bec6
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
All warnings (new ones prefixed by >>):
>> fs/ntfs3/attrib.c:1543:7: warning: variable 'hint' is used uninitialized whenever '&&' condition is false [-Wsometimes-uninitialized]
if (vcn + clst_data &&
^~~~~~~~~~~~~~~
fs/ntfs3/attrib.c:1550:11: note: uninitialized use occurs here
hint + 1, len - clst_data, NULL, 0,
^~~~
fs/ntfs3/attrib.c:1543:7: note: remove the '&&' if its condition is always true
if (vcn + clst_data &&
^~~~~~~~~~~~~~~~~~
fs/ntfs3/attrib.c:1541:18: note: initialize the variable 'hint' to silence this warning
CLST alen, hint;
^
= 0
>> fs/ntfs3/attrib.c:1962:31: warning: variable 'attr' is uninitialized when used here [-Wuninitialized]
u32 data_size = le32_to_cpu(attr->res.data_size);
^~~~
include/linux/byteorder/generic.h:89:21: note: expanded from macro 'le32_to_cpu'
#define le32_to_cpu __le32_to_cpu
^
include/uapi/linux/byteorder/big_endian.h:34:59: note: expanded from macro '__le32_to_cpu'
#define __le32_to_cpu(x) __swab32((__force __u32)(__le32)(x))
^
include/uapi/linux/swab.h:118:32: note: expanded from macro '__swab32'
(__builtin_constant_p((__u32)(x)) ? \
^
fs/ntfs3/attrib.c:1947:21: note: initialize the variable 'attr' to silence this warning
struct ATTRIB *attr, *attr_b;
^
= NULL
fs/ntfs3/attrib.c:70:20: warning: unused function 'attr_must_be_resident' [-Wunused-function]
static inline bool attr_must_be_resident(struct ntfs_sb_info *sbi,
^
3 warnings generated.
vim +1543 fs/ntfs3/attrib.c
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1458
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1459 /*
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1460 * attr_allocate_frame
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1461 *
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1462 * allocate/free clusters for 'frame'
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1463 * assumed: down_write(&ni->file.run_lock);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1464 */
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1465 int attr_allocate_frame(struct ntfs_inode *ni, CLST frame, size_t compr_size,
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1466 u64 new_valid)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1467 {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1468 int err = 0;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1469 struct runs_tree *run = &ni->file.run;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1470 struct ntfs_sb_info *sbi = ni->mi.sbi;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1471 struct ATTRIB *attr, *attr_b;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1472 struct ATTR_LIST_ENTRY *le, *le_b;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1473 struct mft_inode *mi, *mi_b;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1474 CLST svcn, evcn1, next_svcn, lcn, len;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1475 CLST vcn, end, clst_data;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1476 u64 total_size, valid_size, data_size;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1477
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1478 le_b = NULL;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1479 attr_b = ni_find_attr(ni, NULL, &le_b, ATTR_DATA, NULL, 0, NULL, &mi_b);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1480 if (!attr_b)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1481 return -ENOENT;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1482
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1483 if (!is_attr_ext(attr_b))
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1484 return -EINVAL;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1485
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1486 vcn = frame << NTFS_LZNT_CUNIT;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1487 total_size = le64_to_cpu(attr_b->nres.total_size);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1488
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1489 svcn = le64_to_cpu(attr_b->nres.svcn);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1490 evcn1 = le64_to_cpu(attr_b->nres.evcn) + 1;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1491 data_size = le64_to_cpu(attr_b->nres.data_size);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1492
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1493 if (svcn <= vcn && vcn < evcn1) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1494 attr = attr_b;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1495 le = le_b;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1496 mi = mi_b;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1497 } else if (!le_b) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1498 err = -EINVAL;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1499 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1500 } else {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1501 le = le_b;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1502 attr = ni_find_attr(ni, attr_b, &le, ATTR_DATA, NULL, 0, &vcn,
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1503 &mi);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1504 if (!attr) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1505 err = -EINVAL;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1506 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1507 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1508 svcn = le64_to_cpu(attr->nres.svcn);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1509 evcn1 = le64_to_cpu(attr->nres.evcn) + 1;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1510 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1511
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1512 err = attr_load_runs(attr, ni, run, NULL);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1513 if (err)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1514 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1515
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1516 err = attr_is_frame_compressed(ni, attr_b, frame, &clst_data);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1517 if (err)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1518 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1519
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1520 total_size -= (u64)clst_data << sbi->cluster_bits;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1521
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1522 len = bytes_to_cluster(sbi, compr_size);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1523
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1524 if (len == clst_data)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1525 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1526
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1527 if (len < clst_data) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1528 err = run_deallocate_ex(sbi, run, vcn + len, clst_data - len,
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1529 NULL, true);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1530 if (err)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1531 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1532
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1533 if (!run_add_entry(run, vcn + len, SPARSE_LCN, clst_data - len,
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1534 false)) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1535 err = -ENOMEM;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1536 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1537 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1538 end = vcn + clst_data;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1539 /* run contains updated range [vcn + len : end) */
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1540 } else {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1541 CLST alen, hint;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1542 /* Get the last lcn to allocate from */
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 @1543 if (vcn + clst_data &&
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1544 !run_lookup_entry(run, vcn + clst_data - 1, &hint, NULL,
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1545 NULL)) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1546 hint = -1;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1547 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1548
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1549 err = attr_allocate_clusters(sbi, run, vcn + clst_data,
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1550 hint + 1, len - clst_data, NULL, 0,
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1551 &alen, 0, &lcn);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1552 if (err)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1553 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1554
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1555 end = vcn + len;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1556 /* run contains updated range [vcn + clst_data : end) */
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1557 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1558
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1559 total_size += (u64)len << sbi->cluster_bits;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1560
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1561 repack:
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1562 err = mi_pack_runs(mi, attr, run, max(end, evcn1) - svcn);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1563 if (err)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1564 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1565
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1566 attr_b->nres.total_size = cpu_to_le64(total_size);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1567 inode_set_bytes(&ni->vfs_inode, total_size);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1568
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1569 mi_b->dirty = true;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1570 mark_inode_dirty(&ni->vfs_inode);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1571
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1572 /* stored [vcn : next_svcn) from [vcn : end) */
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1573 next_svcn = le64_to_cpu(attr->nres.evcn) + 1;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1574
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1575 if (end <= evcn1) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1576 if (next_svcn == evcn1) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1577 /* Normal way. update attribute and exit */
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1578 goto ok;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1579 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1580 /* add new segment [next_svcn : evcn1 - next_svcn )*/
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1581 if (!ni->attr_list.size) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1582 err = ni_create_attr_list(ni);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1583 if (err)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1584 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1585 /* layout of records is changed */
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1586 le_b = NULL;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1587 attr_b = ni_find_attr(ni, NULL, &le_b, ATTR_DATA, NULL,
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1588 0, NULL, &mi_b);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1589 if (!attr_b) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1590 err = -ENOENT;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1591 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1592 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1593
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1594 attr = attr_b;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1595 le = le_b;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1596 mi = mi_b;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1597 goto repack;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1598 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1599 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1600
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1601 svcn = evcn1;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1602
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1603 /* Estimate next attribute */
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1604 attr = ni_find_attr(ni, attr, &le, ATTR_DATA, NULL, 0, &svcn, &mi);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1605
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1606 if (attr) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1607 CLST alloc = bytes_to_cluster(
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1608 sbi, le64_to_cpu(attr_b->nres.alloc_size));
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1609 CLST evcn = le64_to_cpu(attr->nres.evcn);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1610
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1611 if (end < next_svcn)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1612 end = next_svcn;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1613 while (end > evcn) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1614 /* remove segment [svcn : evcn)*/
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1615 mi_remove_attr(mi, attr);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1616
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1617 if (!al_remove_le(ni, le)) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1618 err = -EINVAL;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1619 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1620 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1621
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1622 if (evcn + 1 >= alloc) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1623 /* last attribute segment */
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1624 evcn1 = evcn + 1;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1625 goto ins_ext;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1626 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1627
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1628 if (ni_load_mi(ni, le, &mi)) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1629 attr = NULL;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1630 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1631 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1632
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1633 attr = mi_find_attr(mi, NULL, ATTR_DATA, NULL, 0,
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1634 &le->id);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1635 if (!attr) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1636 err = -EINVAL;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1637 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1638 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1639 svcn = le64_to_cpu(attr->nres.svcn);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1640 evcn = le64_to_cpu(attr->nres.evcn);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1641 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1642
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1643 if (end < svcn)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1644 end = svcn;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1645
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1646 err = attr_load_runs(attr, ni, run, &end);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1647 if (err)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1648 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1649
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1650 evcn1 = evcn + 1;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1651 attr->nres.svcn = cpu_to_le64(next_svcn);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1652 err = mi_pack_runs(mi, attr, run, evcn1 - next_svcn);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1653 if (err)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1654 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1655
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1656 le->vcn = cpu_to_le64(next_svcn);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1657 ni->attr_list.dirty = true;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1658 mi->dirty = true;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1659
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1660 next_svcn = le64_to_cpu(attr->nres.evcn) + 1;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1661 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1662 ins_ext:
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1663 if (evcn1 > next_svcn) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1664 err = ni_insert_nonresident(ni, ATTR_DATA, NULL, 0, run,
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1665 next_svcn, evcn1 - next_svcn,
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1666 attr_b->flags, &attr, &mi);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1667 if (err)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1668 goto out;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1669 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1670 ok:
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1671 run_truncate_around(run, vcn);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1672 out:
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1673 if (new_valid > data_size)
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1674 new_valid = data_size;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1675
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1676 valid_size = le64_to_cpu(attr_b->nres.valid_size);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1677 if (new_valid != valid_size) {
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1678 attr_b->nres.valid_size = cpu_to_le64(valid_size);
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1679 mi_b->dirty = true;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1680 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1681
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1682 return err;
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1683 }
ebfca8733bf2f6f Konstantin Komarov 2020-12-25 1684
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
Download attachment ".config.gz" of type "application/gzip" (41295 bytes)
Powered by blists - more mailing lists