Received: by 10.213.65.68 with SMTP id h4csp3867893imn; Tue, 3 Apr 2018 12:04:10 -0700 (PDT) X-Google-Smtp-Source: AIpwx49I1iTJXDUiRqddFW2XK0uO6qar0fXu4YcbdNk0tHY8fLS4NSGcmraYw3z1R9n8SgdgBCQU X-Received: by 10.98.144.205 with SMTP id q74mr11495399pfk.55.1522782250332; Tue, 03 Apr 2018 12:04:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522782250; cv=none; d=google.com; s=arc-20160816; b=J9CaSrTSCLXgesx/h+vBFLD+h/Fn5tQ0ERli9To/mEbshsykBVFQi/UEFOj2idftFY I0hlzr5LyEaFhpNe+IGvePAjbDxktwG2x4nBeWk4v5MJyYjKdpp2JhQQPIVWHun8GPNO AavHELRv7+8cTkEZkj5aeMbO7rkminW2mFGrjg3WPsCNstIUKOoNc84+0J/GgUNvk51D oNuWMSISbVgJDMjN0idatfvVYuP7hVQr9O3ANFZG4zgOAD4K7BWBdk9R4SyIu2094J32 snfjqDay6PDLgWZ5g029SYovFsiFQ9IwlzOKSQlOoqUAIBUls9CL2Twbh239bOU+nNWs FcBw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=IMTgZpvRp0tCsQvbuakb6rRdsriLUHIDgMct4nDN6L0=; b=v2BDbpePDr2rns8ouwG5HYFi1cAn6EmVIv9SHmY8K1ZTQOY/W8Iy0P/GjuIHP5WN6E gx4VW8QY2qN/wCoUkh6fuOd/EDYw4SMOidRSgmPrnAYn6vEVY34bzZqPkpUB1m7IVyh8 IlJAdOfH0kAv6K9IYzSoGeoRjX9dl/TUReJTj10GTJBc6msazYXO0uxFgEteZznL//6D 0c1H/ABQ5fy2cmKCLF04s6OQD3SgEHrLFEwyUptG03jbgPfYc1mSXKPTsU1Jq6sT7wgj O9Hd99tirlUKwNNg4RdjueuFfeU0tN/t1x3F4rNO1llY6olp1ohlv3YztURIF+kul+HL nh1w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n24si2570472pff.382.2018.04.03.12.03.55; Tue, 03 Apr 2018 12:04:10 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753222AbeDCTCa (ORCPT + 99 others); Tue, 3 Apr 2018 15:02:30 -0400 Received: from mout.gmx.net ([212.227.15.15]:43451 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752788AbeDCTC3 (ORCPT ); Tue, 3 Apr 2018 15:02:29 -0400 Received: from LPT2.fritz.box ([62.143.246.157]) by mail.gmx.com (mrgmx003 [212.227.17.184]) with ESMTPSA (Nemesis) id 0LhOvA-1ehLw82M9w-00mXG1; Tue, 03 Apr 2018 21:02:24 +0200 From: Heinrich Schuchardt To: Andy Whitcroft , Joe Perches Cc: linux-kernel@vger.kernel.org, Heinrich Schuchardt Subject: [BUG] checkpatch.pl: false positive: space prohibited before open square bracket Date: Tue, 3 Apr 2018 21:02:14 +0200 Message-Id: <20180403190214.23082-1-xypron.glpk@gmx.de> X-Mailer: git-send-email 2.16.3 X-Provags-ID: V03:K0:2FpmNCEYr3DvE8t0MMbPOv3TsQfiSHBHt7HlXJ0EruoM3++FnJF klkY6o/S+34NKBxOCuitSjo+HY7qvxPkFyqhRKXyC3oWUN3BsM3a21Z9MfXJwzBa4mkL7lY seB+P7+n/wxrL4Hcr+pUA0Eh2SUsROU6Ww8UHc3SsTrdcVBL08XEd/i8F8lk+E5fyUspG8e v51RK6xag0w8jHdTW+o5Q== X-UI-Out-Filterresults: notjunk:1;V01:K0:LOz43aeYYtE=:3n9okpqaBYeFnh7oSki5re XnHzwZXdDlqGX2mlGU6eoscH3hwTt2tRbRW1jny75ljKAk4eoFz8tmej67NwnT/X5eLNTtIXB idLz5BGvsrTkTMoBaElS14S1D0SJBkD/AdxaaF3tAo4wqTEAXlfX1KivFYrAJo+x9huc+xcRX f7t9l5IWSSOujjoIxitRsi9mFOTZ5b3Xrafh3vnp773qsU5qmSUEdi+r6/4fFa4VxnA5W3j7E 6r21KsgX4daou6ZB5e86BxjZQYV7bMWLN2WDRoD47I+iSVoX8GQ1pIzR9Ass1FxOKOCt9QKTH a146fSXQ0YGNo/0sCH+lpcE6yTkav+P8JLy/lNo/LJFFWrFdycP43d4UoRYfnx1SOeuAc3szx hBhYSDNVggi4Eg8ShZOJjNXCsLWfNG+U2AbprQk17ailZSz8PIamm2cwbnT0Fh0rGELedJeYd lmpwDea+VTP/jwCnidiyUrlqLvLMhK0C3UFL8ExbWu/m8UFfhBc5AKtHeqY2pTopRQgv+wzRw OpGGINrYGdq18w0RwK3KI+GUO2wLokNIfU1B/bUWkQ7kLF4C72DgtkegHbu1jv/bqLbRwrU4x kM1krCV6ENHsjhLG00LXeWRsWU/nJrMxpKMYDE06rDHkgojUns9G7QivFcq54UqFQsrfE7yRr i29oS/skiin0cfWMBuY62jYbg2FqDsL6pmWwEzWD3IrzJxMqR3lttP96S8Vy9Y3FeiX0mE5Fq sW+m0iNChDvXFngizWkIC0OowkM8qY1wyFfn6CL+2LOEyxSQEqyKN0jCVuwe1UMl2A0VVIpnj W2aHZ2ibqMbUAEO4Yyk2ZVouAZQ3Q== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patch leads to errors "space prohibited before open square bracket '['" for the asm statement. In the inline assembler statement the bracket is not used for an index. Adding a space after a colon or a comma should be allowable. Signed-off-by: Heinrich Schuchardt --- foo.c | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 foo.c diff --git a/foo.c b/foo.c new file mode 100644 index 000000000000..7f0ed923f997 --- /dev/null +++ b/foo.c @@ -0,0 +1,11 @@ +static inline u32 deref(u32 *addr) +{ + int ret; + + asm( + "ldr %[out], [%[in]]\n\t" + : [out] "=r" (ret) + : [in] "r" (addr) + ); + return ret; +} -- 2.16.3