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: <20181004.095845.964782412753569093.davem@davemloft.net>
Date:   Thu, 04 Oct 2018 09:58:45 -0700 (PDT)
From:   David Miller <davem@...emloft.net>
To:     natechancellor@...il.com
Cc:     Ariel.Elior@...ium.com, netdev@...r.kernel.org,
        linux-kernel@...r.kernel.org, ndesaulniers@...gle.com,
        Dept-EngEverestLinuxL2@...ium.com, Tomer.Tayar@...ium.com
Subject: Re: [PATCH v2] qed: Avoid implicit enum conversion in
 qed_ooo_submit_tx_buffers

From: Nathan Chancellor <natechancellor@...il.com>
Date: Thu,  4 Oct 2018 09:39:20 -0700

> Clang warns when one enumerated type is implicitly converted to another.
> 
> drivers/net/ethernet/qlogic/qed/qed_ll2.c:799:32: warning: implicit
> conversion from enumeration type 'enum core_tx_dest' to different
> enumeration type 'enum qed_ll2_tx_dest' [-Wenum-conversion]
>                 tx_pkt.tx_dest = p_ll2_conn->tx_dest;
>                                ~ ~~~~~~~~~~~~^~~~~~~
> 1 warning generated.
> 
> Fix this by using a switch statement to convert between the enumerated
> values since they are not 1 to 1, which matches how the rest of the
> driver handles this conversion.
> 
> Link: https://github.com/ClangBuiltLinux/linux/issues/125
> Suggested-by: Tomer Tayar <Tomer.Tayar@...ium.com>
> Signed-off-by: Nathan Chancellor <natechancellor@...il.com>
> ---
> 
> v1 -> v2:
> 
> * Use an explicit switch statement to convert between the enumerated
>   types like the rest of the driver, as suggested by Tomer.

Applied to net-next.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ