lkml.org 
[lkml]   [2020]   [Aug]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v5 06/17] sched/debug: Output SD flag names rather than their values
On Wed, Aug 12, 2020 at 07:51:08PM +0100, Valentin Schneider wrote:
> On 12/08/20 17:35, kernel test robot wrote:
>
> > config: i386-randconfig-s001-20200811 (attached as .config)
> > reproduce:
> > # sparse version: v0.6.2-168-g9554805c-dirty
> > make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=i386
> >
> >>> kernel/sched/debug.c:279:17: sparse: sparse: non size-preserving pointer to integer cast
> >>> kernel/sched/debug.c:279:17: sparse: sparse: non size-preserving integer to pointer cast
> >
> > > 279 tmp += *ppos;
>
> I pretty much copied kernel/sysctl.c::_proc_do_string() and I think that's
> exactly the same types here: char* buffer incremented by loff_t offset. It
> does look fine to me, but I can't really parse that warning.

The warnings mean that there is a cast from a pointer to an integer with
a size other than the size of a pointer and the other way around.

I's indeed the case here, on i386, where pointers are 32-bit and loff_t
is 64-bit. But yes, I agree:
1) these messages are far from clear
2) these casts are internal and are probably not appropriate here.

I'll look later what can be done at sparse level.

Regards,
-- Luc

\
 
 \ /
  Last update: 2020-08-13 14:04    [W:0.078 / U:0.020 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site