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] [day] [month] [year] [list]
Message-ID: <CAAA5faF+VVzvgBaxYinRC0YdCqsbDa==dGKhcDhzUQRJK6eHWQ@mail.gmail.com>
Date:	Tue, 7 Jun 2016 18:52:11 -0600
From:	Reinoud Koornstra <reinoudkoornstra@...il.com>
To:	Joe Perches <joe@...ches.com>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: small patch to avoid warning in gcc 6

On Tue, Jun 7, 2016 at 6:47 PM, Joe Perches <joe@...ches.com> wrote:
> On Tue, 2016-06-07 at 18:41 -0600, Reinoud Koornstra wrote:
>> Hello Everybody,
>>
>> A small patch that doesn't really do anything other than getting rid
>> of a warning in gcc 6.1.0.
>>
>> drivers/gpu/drm/i915/i915_debugfs.c: In function ‘i915_dump_lrc’:
>> drivers/gpu/drm/i915/i915_debugfs.c:2060:6: warning: suggest explicit
>> braces to avoid ambiguous ‘else’ [-Wparentheses]
>>    if (ctx != dev_priv->kernel_context)
>>       ^
>
> Likely there should be 2 pairs of braces added:
>
>         list_for_each_entry(ctx, &dev_priv->context_list, link) {
>                 if (ctx != dev_priv->kernel_context) {
>                         for_each_ring(ring, dev_priv, i)
>                                 i915_dump_lrc_obj(m, ctx, ring);
>                 }
>         }
>

Added in version 2 of the patch.
The previous patch already got rid of the warning, but this one adds
braces to the loop as well.
Thanks,

Reinoud.

View attachment "avoid_warning.patch" of type "text/x-patch" (636 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ