lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240103122734.16b29e09@canb.auug.org.au>
Date: Wed, 3 Jan 2024 12:27:34 +1100
From: Stephen Rothwell <sfr@...b.auug.org.au>
To: Dave Airlie <airlied@...hat.com>
Cc: DRI <dri-devel@...ts.freedesktop.org>, Andrzej Hajda
 <andrzej.hajda@...el.com>, Linux Kernel Mailing List
 <linux-kernel@...r.kernel.org>, Linux Next Mailing List
 <linux-next@...r.kernel.org>
Subject: Re: linux-next: build warning after merge of the drm tree

Hi all,

On Wed, 3 Jan 2024 12:19:11 +1100 Stephen Rothwell <sfr@...b.auug.org.au> wrote:
>
> On Tue, 2 Jan 2024 11:12:22 +1100 Stephen Rothwell <sfr@...b.auug.org.au> wrote:
> >
> > After merging the drm tree, today's linux-next build (x86_64 allmodconfig)
> > produced this warning:
> > 
> > In file included from include/drm/drm_mm.h:51,
> >                  from drivers/gpu/drm/xe/xe_bo_types.h:11,
> >                  from drivers/gpu/drm/xe/xe_bo.h:11,
> >                  from drivers/gpu/drm/xe/compat-i915-headers/gem/i915_gem_object.h:11,
> >                  from drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h:15,
> >                  from drivers/gpu/drm/i915/display/intel_display_power.c:8:
> > drivers/gpu/drm/i915/display/intel_display_power.c: In function 'print_async_put_domains_state':
> > drivers/gpu/drm/i915/display/intel_display_power.c:408:29: warning: format '%lu' expects argument of type 'long unsigned int', but argument 5 has type 'int' [-Wformat=]
> >   408 |         drm_dbg(&i915->drm, "async_put_wakeref %lu\n",
> >       |                             ^~~~~~~~~~~~~~~~~~~~~~~~~
> >   409 |                 power_domains->async_put_wakeref);
> >       |                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> >       |                              |
> >       |                              int
> > 
>
> In file included from include/drm/ttm/ttm_resource.h:34,
>                  from include/drm/ttm/ttm_device.h:30,
>                  from drivers/gpu/drm/i915/i915_drv.h:37,
>                  from drivers/gpu/drm/i915/display/intel_display_power.c:8:  
> drivers/gpu/drm/i915/display/intel_display_power.c: In function 'print_async_put_domains_state':
> drivers/gpu/drm/i915/display/intel_display_power.c:408:29: error: format '%u' expects argument of type 'unsigned int', but argument 5 has type 'intel_wakeref_t' {aka 'long unsigned int'} [-Werror=format=]
>   408 |         drm_dbg(&i915->drm, "async_put_wakeref %u\n",
>       |                             ^~~~~~~~~~~~~~~~~~~~~~~~
>   409 |                 power_domains->async_put_wakeref);
>       |                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>       |                              |
>       |                              intel_wakeref_t {aka long unsigned int}
> 
> I don't understand how the above patch can change the compilation like
> that.  I must be missing something obvious.  Maybe my compiler is
> strangely broken?

OK, the only thing I can find is that there are 2 intel_wakeref.h files
that have different definitions for intel_wakeref_t:

./drivers/gpu/drm/i915/intel_wakeref.h:typedef unsigned long intel_wakeref_t;
./drivers/gpu/drm/xe/compat-i915-headers/intel_wakeref.h:typedef bool intel_wakeref_t;

and the two compilations above seem to use different include paths, but
how the single character change causes that is beyond me.
-- 
Cheers,
Stephen Rothwell

Content of type "application/pgp-signature" skipped

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ