Return-Path: Received: from userp2130.oracle.com ([156.151.31.86]:57504 "EHLO userp2130.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726077AbeHTRaw (ORCPT ); Mon, 20 Aug 2018 13:30:52 -0400 Date: Mon, 20 Aug 2018 17:14:54 +0300 From: Dan Carpenter To: kbuild@01.org, Al Viro Cc: kbuild-all@01.org, linux-fsdevel@vger.kernel.org Subject: [vfs:net-endian.chelsio 2/14] drivers/net/ethernet/chelsio/cxgb4/cxgb4_tc_flower.c:434 valid_l4_mask() warn: should this be a bitwise op? Message-ID: <20180820141454.bco7vf6pbp75rivu@mwanda> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Sender: linux-fsdevel-owner@vger.kernel.org List-ID: tree: https://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs.git net-endian.chelsio head: 04e3509dd351491432ad0d985ac0a175177cdf21 commit: 26ed0a72b445d4b1b8dccb768d989601a218a5a5 [2/14] cxgb4: fix TC-PEDIT-related parts of cxgb4_tc_flower on big-endian smatch warnings: drivers/net/ethernet/chelsio/cxgb4/cxgb4_tc_flower.c:434 valid_l4_mask() warn: should this be a bitwise op? # https://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs.git/commit/?id=26ed0a72b445d4b1b8dccb768d989601a218a5a5 git remote add vfs https://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs.git git remote update vfs git checkout 26ed0a72b445d4b1b8dccb768d989601a218a5a5 vim +434 drivers/net/ethernet/chelsio/cxgb4/cxgb4_tc_flower.c 62488e4b Kumar Sanghvi 2017-09-21 429 26ed0a72 Al Viro 2018-08-16 430 static bool valid_l4_mask(__be32 mask) 557ccbf9 Kumar Sanghvi 2017-10-18 431 { 26ed0a72 Al Viro 2018-08-16 432 /* Either the SPORT OR DPORT can be set, but NOT BOTH. 557ccbf9 Kumar Sanghvi 2017-10-18 433 */ 26ed0a72 Al Viro 2018-08-16 @434 return !(mask && htonl(0xffff)) || !(mask & htonl(0xffff0000)); ^^ This should be "(mask & htonl(0xffff))". 557ccbf9 Kumar Sanghvi 2017-10-18 435 } 557ccbf9 Kumar Sanghvi 2017-10-18 436 --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation