* Re: drivers/scsi/ncr53c8xx.c:5306:9: sparse: sparse: cast truncates bits from constant value (58f becomes 8f) [not found] <202005160227.h6Ieqnmz%lkp@intel.com> @ 2020-05-15 19:00 ` Matthew Wilcox 2020-05-18 0:34 ` [kbuild-all] " Philip Li 0 siblings, 1 reply; 2+ messages in thread From: Matthew Wilcox @ 2020-05-15 19:00 UTC (permalink / raw) To: kbuild test robot Cc: Michal Simek, kbuild-all, linux-kernel, Andrew Morton, Linux Memory Management List, Stefan Asserhall, linux-scsi, linux-parisc On Sat, May 16, 2020 at 02:20:38AM +0800, kbuild test robot wrote: > tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master > head: 051e6b7e34b9bd24f46725f74994a4d3a653966e > commit: 06e85c7e9a1c1356038936566fc23f7c0d363b96 asm-generic: fix unistd_32.h generation format > date: 5 weeks ago I don't see how that commit in any way reflects this error message. > reproduce: > # apt-get install sparse > # sparse version: v0.6.1-193-gb8fad4bc-dirty > git checkout 06e85c7e9a1c1356038936566fc23f7c0d363b96 > make ARCH=x86_64 allmodconfig I can't even see a way to build the ncr53c8xx module with this config. Unless somebody reenabled EISA on x86, the only way I can see to still build this driver is on PA-RISC with the ZALON code. > make C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' > > If you fix the issue, kindly add following tag as appropriate > Reported-by: kbuild test robot <lkp@intel.com> > > > sparse warnings: (new ones prefixed by >>) > > >> drivers/scsi/ncr53c8xx.c:5306:9: sparse: sparse: cast truncates bits from constant value (58f becomes 8f) > > ^1da177e4c3f41 Linus Torvalds 2005-04-16 @5306 OUTW (nc_sien , STO|HTH|MA|SGE|UDC|RST|PAR); This seems entirely intentional. Something like this should do the job (whitespace damaged): +++ b/drivers/scsi/ncr53c8xx.h @@ -407,7 +407,7 @@ #ifdef CONFIG_SCSI_NCR53C8XX_NO_WORD_TRANSFERS /* Only 8 or 32 bit transfers allowed */ -#define OUTW_OFF(o, val) do { writeb((char)((val) >> 8), (char __iomem *)np->reg + ncr_offw(o)); writeb((char)(val), (char __iomem *)np->reg + ncr_offw(o) + 1); } while (0) +#define OUTW_OFF(o, val) do { writeb((char)((val) >> 8), (char __iomem *)np->reg + ncr_offw(o)); writeb((char)((val) & 0xff), (char __iomem *)np->reg + ncr_offw(o) + 1); } while (0) #else #define OUTW_OFF(o, val) writew_raw((val), (char __iomem *)np->reg + ncr_offw(o)) #endif ^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [kbuild-all] Re: drivers/scsi/ncr53c8xx.c:5306:9: sparse: sparse: cast truncates bits from constant value (58f becomes 8f) 2020-05-15 19:00 ` drivers/scsi/ncr53c8xx.c:5306:9: sparse: sparse: cast truncates bits from constant value (58f becomes 8f) Matthew Wilcox @ 2020-05-18 0:34 ` Philip Li 0 siblings, 0 replies; 2+ messages in thread From: Philip Li @ 2020-05-18 0:34 UTC (permalink / raw) To: Matthew Wilcox Cc: kbuild test robot, Michal Simek, kbuild-all, linux-kernel, Andrew Morton, Linux Memory Management List, Stefan Asserhall, linux-scsi, linux-parisc On Fri, May 15, 2020 at 12:00:26PM -0700, Matthew Wilcox wrote: > On Sat, May 16, 2020 at 02:20:38AM +0800, kbuild test robot wrote: > > tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master > > head: 051e6b7e34b9bd24f46725f74994a4d3a653966e > > commit: 06e85c7e9a1c1356038936566fc23f7c0d363b96 asm-generic: fix unistd_32.h generation format > > date: 5 weeks ago > > I don't see how that commit in any way reflects this error message. > > > reproduce: > > # apt-get install sparse > > # sparse version: v0.6.1-193-gb8fad4bc-dirty > > git checkout 06e85c7e9a1c1356038936566fc23f7c0d363b96 > > make ARCH=x86_64 allmodconfig > > I can't even see a way to build the ncr53c8xx module with this config. > Unless somebody reenabled EISA on x86, the only way I can see to > still build this driver is on PA-RISC with the ZALON code. sorry, the reproduce steps here is wrong, it is not for x86_64. We will fix this. > > > make C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' > > > > If you fix the issue, kindly add following tag as appropriate > > Reported-by: kbuild test robot <lkp@intel.com> > > > > > > sparse warnings: (new ones prefixed by >>) > > > > >> drivers/scsi/ncr53c8xx.c:5306:9: sparse: sparse: cast truncates bits from constant value (58f becomes 8f) > > > > ^1da177e4c3f41 Linus Torvalds 2005-04-16 @5306 OUTW (nc_sien , STO|HTH|MA|SGE|UDC|RST|PAR); > > This seems entirely intentional. > > Something like this should do the job (whitespace damaged): > > +++ b/drivers/scsi/ncr53c8xx.h > @@ -407,7 +407,7 @@ > > #ifdef CONFIG_SCSI_NCR53C8XX_NO_WORD_TRANSFERS > /* Only 8 or 32 bit transfers allowed */ > -#define OUTW_OFF(o, val) do { writeb((char)((val) >> 8), (char __iomem *)np->reg + ncr_offw(o)); writeb((char)(val), (char __iomem *)np->reg + ncr_offw(o) + 1); } while (0) > +#define OUTW_OFF(o, val) do { writeb((char)((val) >> 8), (char __iomem *)np->reg + ncr_offw(o)); writeb((char)((val) & 0xff), (char __iomem *)np->reg + ncr_offw(o) + 1); } while (0) > #else > #define OUTW_OFF(o, val) writew_raw((val), (char __iomem *)np->reg + ncr_offw(o)) > #endif > > _______________________________________________ > kbuild-all mailing list -- kbuild-all@lists.01.org > To unsubscribe send an email to kbuild-all-leave@lists.01.org ^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-05-18 0:35 UTC | newest] Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <202005160227.h6Ieqnmz%lkp@intel.com> 2020-05-15 19:00 ` drivers/scsi/ncr53c8xx.c:5306:9: sparse: sparse: cast truncates bits from constant value (58f becomes 8f) Matthew Wilcox 2020-05-18 0:34 ` [kbuild-all] " Philip Li
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).