From patchwork Sat Dec 16 14:42:29 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Knut Omang X-Patchwork-Id: 10117189 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id F0818603FA for ; Sat, 16 Dec 2017 14:43:59 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E1D45290F0 for ; Sat, 16 Dec 2017 14:43:59 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D4EAE292F7; Sat, 16 Dec 2017 14:43:59 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 657E9290F0 for ; Sat, 16 Dec 2017 14:43:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753577AbdLPOnq (ORCPT ); Sat, 16 Dec 2017 09:43:46 -0500 Received: from aserp2120.oracle.com ([141.146.126.78]:37662 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756320AbdLPOnl (ORCPT ); Sat, 16 Dec 2017 09:43:41 -0500 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.21/8.16.0.21) with SMTP id vBGEhXR5115941; Sat, 16 Dec 2017 14:43:39 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : mime-version : in-reply-to : references : content-type : content-transfer-encoding; s=corp-2017-10-26; bh=9VZmfB58TUKvXsDEgjAfpRiSsGQMZrovSoyW4rD5KEs=; b=PorPe1r0GgSiQzxgKiBfTZ1vGwk+1xcYzp4h6eI9FkVr/67Qc9zCrcl9Z4hT41mnPbmn yyQ1j7pg89AeR27aiDoW98DVsTFNq8c1n3MUz4B9748f4aLs815yAXUSykroMcrz/GPh E7x+tMzIbkqIBMQ4YSejnS35qlH0UchIZYJGH82+NWU8J093s0WgzP4vmacci1/I4t62 7x6daPCcsa3Gt7tjz8K/HLPXEoxs16jAhU+TwEZWAge704jnQ95R7+R7tGQld0Zoj/G+ tY+Nf8Xa56I1MF57bbkYLsAdx2w9rEJLYCWDE7xtSI8lqrwASV6Kcvtbc7wxxcPtWzhp AA== Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by aserp2120.oracle.com with ESMTP id 2ew4xu810j-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sat, 16 Dec 2017 14:43:39 +0000 Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by userv0022.oracle.com (8.14.4/8.14.4) with ESMTP id vBGEhcdi009946 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Sat, 16 Dec 2017 14:43:38 GMT Received: from abhmp0005.oracle.com (abhmp0005.oracle.com [141.146.116.11]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id vBGEhb7b003245; Sat, 16 Dec 2017 14:43:37 GMT Received: from abi.no.oracle.com (/10.172.144.123) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Sat, 16 Dec 2017 06:43:37 -0800 From: Knut Omang To: linux-kernel@vger.kernel.org Cc: Knut Omang , linux-rdma@vger.kernel.org, netdev@vger.kernel.org, rds-devel@oss.oracle.com, Santosh Shilimkar , "David S. Miller" Subject: [PATCH v2 4/5] rds: Add runchecks.cfg for net/rds Date: Sat, 16 Dec 2017 15:42:29 +0100 Message-Id: <4dc9b2fc0ddd1eb91d9b8785ae4886c6b08f3ee5.1513430008.git-series.knut.omang@oracle.com> X-Mailer: git-send-email 2.13.6 MIME-Version: 1.0 In-Reply-To: References: X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=8746 signatures=668648 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=1 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=817 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1711220000 definitions=main-1712160223 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add a runchecks.cfg to net/rds to start "reining in" future checker errors, and making it easier to selectively clean up existing issues. This runchecks.cfg lets make C=2 M=net/rds pass with all errors/warnings suppressed See Documentation/dev-tools/runchecks.rst for motivation and details. Signed-off-by: Knut Omang Reviewed-by: Håkon Bugge Reviewed-by: Åsmund Østvold --- net/rds/runchecks.cfg | 76 ++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 76 insertions(+) create mode 100644 net/rds/runchecks.cfg diff --git a/net/rds/runchecks.cfg b/net/rds/runchecks.cfg new file mode 100644 index 0000000..2a02701 --- /dev/null +++ b/net/rds/runchecks.cfg @@ -0,0 +1,76 @@ +# +# checker suppression lists for net/rds +# +# see Documentation/dev-tools/runchecks.rst +# + +checker checkpatch +################## + +# Accept somewhat longer lines: +line_len 110 + +# Important to fix from a quality perspective: +# +except AVOID_BUG connection.c ib.c ib_cm.c ib_rdma.c ib_recv.c ib_ring.c ib_send.c info.c loop.c message.c +except AVOID_BUG rdma.c recv.c send.c stats.c tcp_recv.c transport.c +except MEMORY_BARRIER ib_recv.c send.c tcp_send.c +except WAITQUEUE_ACTIVE cong.c ib_rdma.c ib_ring.c ib_send.c +except UNNECESSARY_ELSE bind.c ib_cm.c +except MACRO_ARG_PRECEDENCE connection.c ib.h rds.h +except MACRO_ARG_REUSE rds.h +except ALLOC_SIZEOF_STRUCT cong.c ib.c ib_cm.c loop.c message.c rdma.c +except UNCOMMENTED_DEFINITION ib_cm.c + +# Code simplification: +# +except ALLOC_WITH_MULTIPLY ib.c +except PREFER_PR_LEVEL ib_cm.c ib_recv.c ib_send.c rdma_transport.c threads.c transport.c +except UNNECESSARY_ELSE ib_fmr.c +except UNNECESSARY_PARENTHESES ib_rdma.c rdma.c recv.c send.c +except PRINTK_RATELIMITED ib_frmr.c +except EMBEDDED_FUNCTION_NAME ib_rdma.c + +# Style and readability: +# +except BRACES ib_cm.c ib_rdma.c ib_recv.c send.c transport.c +except OOM_MESSAGE ib.c tcp.c +except LONG_LINE_STRING ib.c ib_recv.c ib_send.c +except FUNCTION_ARGUMENTS ib.h ib_mr.h rds.h tcp.h +except OPEN_ENDED_LINE recv.c ib_recv.c + +# Candidates to leave as exceptions (don't fix): +except MULTIPLE_ASSIGNMENTS ib_send.c +except LONG_LINE_STRING connection.c +except OPEN_BRACE connection.c + +# These are in most of the source files, ignore for all files: +# +pervasive NETWORKING_BLOCK_COMMENT_STYLE BLOCK_COMMENT_STYLE + +# These are easily autocorrected by checkpatch with --fix-inplace: +# Just ignore here - fixed in a separate commit: +# +pervasive PREFER_KERNEL_TYPES LINE_SPACING SPACING SPACE_BEFORE_TAB SPLIT_STRING +pervasive BIT_MACRO SIZEOF_PARENTHESIS LOGICAL_CONTINUATIONS GLOBAL_INITIALISERS +pervasive ALLOC_WITH_MULTIPLY TABSTOP + +# These were easy to fix manually while getting make C=2 to pass. +# Fixed in a separate commit: +# +pervasive SUSPECT_CODE_INDENT PARENTHESIS_ALIGNMENT BRACES PRINTF_L COMPARISON_TO_NULL +pervasive LOGICAL_CONTINUATIONS + + +checker sparse +############## + +except VLA connection.c +except COND_ADDRESS_ARRAY connection.c +except PTR_SUBTRACTION_BLOWS ib_recv.c +except TYPESIGN ib_frmr.c + +# This is coming from linux/dma-mapping.h: +except RETURN_VOID ib_cm.c + +pervasive BITWISE SHADOW