* [md:devel 41/50] drivers/md/md.c:1663:33: sparse: restricted __le32 degrades to integer
@ 2015-08-19 6:51 kbuild test robot
0 siblings, 0 replies; only message in thread
From: kbuild test robot @ 2015-08-19 6:51 UTC (permalink / raw)
To: Song Liu; +Cc: kbuild-all, NeilBrown, Shaohua Li, linux-raid
tree: git://neil.brown.name/md devel
head: da63d1b483fa5a9604d65974eb442a110ee41e89
commit: 1a8a1e097abc6d2787ef6f2e915d5f18d42a1e6c [41/50] MD: add a new disk role to present write journal device
reproduce:
# apt-get install sparse
git checkout 1a8a1e097abc6d2787ef6f2e915d5f18d42a1e6c
make ARCH=x86_64 allmodconfig
make C=1 CF=-D__CHECK_ENDIAN__
sparse warnings: (new ones prefixed by >>)
drivers/md/md.c:1501:34: sparse: cast to restricted __le64
>> drivers/md/md.c:1663:33: sparse: restricted __le32 degrades to integer
drivers/md/md.c:1794:40: sparse: incorrect type in assignment (different base types)
drivers/md/md.c:1794:40: expected unsigned long long [unsigned] [long] [long long] [usertype] <noident>
drivers/md/md.c:1794:40: got restricted __le64 [usertype] <noident>
drivers/md/md.c:1872:26: sparse: incorrect type in assignment (different base types)
drivers/md/md.c:1872:26: expected restricted __le64 [usertype] super_offset
drivers/md/md.c:1872:26: got unsigned long [unsigned] [usertype] sb_start
drivers/md/md.c:8980:39: sparse: restricted __le64 degrades to integer
vim +1663 drivers/md/md.c
1647 }
1648 if (mddev->level != LEVEL_MULTIPATH) {
1649 int role;
1650 if (rdev->desc_nr < 0 ||
1651 rdev->desc_nr >= le32_to_cpu(sb->max_dev)) {
1652 role = MD_DISK_ROLE_SPARE;
1653 rdev->desc_nr = -1;
1654 } else
1655 role = le16_to_cpu(sb->dev_roles[rdev->desc_nr]);
1656 switch(role) {
1657 case MD_DISK_ROLE_SPARE: /* spare */
1658 break;
1659 case MD_DISK_ROLE_FAULTY: /* faulty */
1660 set_bit(Faulty, &rdev->flags);
1661 break;
1662 case MD_DISK_ROLE_JOURNAL: /* journal device */
> 1663 if (!(sb->feature_map & MD_FEATURE_JOURNAL)) {
1664 /* journal device without journal feature */
1665 printk(KERN_WARNING
1666 "md: journal device provided without "
1667 "journal feature, ignoring the device\n");
1668 return -EINVAL;
1669 }
1670 set_bit(Journal, &rdev->flags);
1671 break;
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2015-08-19 6:51 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-08-19 6:51 [md:devel 41/50] drivers/md/md.c:1663:33: sparse: restricted __le32 degrades to integer kbuild 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).