Received: by 10.192.165.148 with SMTP id m20csp256167imm; Tue, 24 Apr 2018 21:55:26 -0700 (PDT) X-Google-Smtp-Source: AIpwx49SQpgM5hvsXGKVvJrqSbZHf8b2kxqMRSRcFNnkrautvg29n/H3w1FsEw1FrPnx7UIVNsR9 X-Received: by 10.99.98.66 with SMTP id w63mr21996441pgb.377.1524632126077; Tue, 24 Apr 2018 21:55:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524632126; cv=none; d=google.com; s=arc-20160816; b=l5VuH0H7HTT9GylqdXEGEDCS58JNt6XdyPETEa6zs40FBP3q1oKwy3jMgCfmcg2u9f aBxSNpPV6ktOo6OC8gRscG/iBm+s1igJIM61mB2BjTQ0cPZKJqoYj+VeMbq2Xnn6Kl3/ IhAAuZmyrm/iDsVVAYicMsAqG4LkF7CNQrgKRAg74a9p0KUbMdDXCrAhMx85ACf7MN2J bikREcFfVygkpj1PyA4ktBPoC6keJgT6wuMBHim3+wRzLDkQfKb7mJUDaudh1tGIV9ui UQYOV++GoZbcmlOL3TMxqSFhxQTJSOkNo2cgzAOfpELd6XRawkOH8A97b5bXzeTNqCAD VV3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature :arc-authentication-results; bh=AqAzEcgrn7IIhkzHkhsLi8Wfzx7hew/NctTdQ6ur4fk=; b=jL+VOw1S00y0Ggub658hQoF7XqLgV9ZznT/m2g1kniRqpvZQtm/fSLi4QwUDW8MGt9 39FpL3hj57n0nfgBKWhklLCnXZFo2WY8zX2rN/WYTpGfFv0QSu2u5CN2QNIMEQBaEphG 2SPVDOD6/R0Kes3GvXYZ2Xrx/nRNejw3DSThKu/kI5JS/mUr//xylxzhmNPAGRFsv2ol EOK6YYXCuBUhrEcpysaw/HUeF3IIPxVOCgQdv0k9hxGePdH+BAs+nsGQI58IE8Nh94AO dYDeRfzl655q323RVhjXDcS+9JGGEzFQWhS0g99Qcoi/p0dp1HuS3ZNkkjN8XGin7mCe +0Xw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=SHS9VYpe; 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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b2-v6si15980131pla.365.2018.04.24.21.55.11; Tue, 24 Apr 2018 21:55:26 -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; dkim=pass header.i=@google.com header.s=20161025 header.b=SHS9VYpe; 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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751269AbeDYExu (ORCPT + 99 others); Wed, 25 Apr 2018 00:53:50 -0400 Received: from mail-wm0-f65.google.com ([74.125.82.65]:54466 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750807AbeDYExp (ORCPT ); Wed, 25 Apr 2018 00:53:45 -0400 Received: by mail-wm0-f65.google.com with SMTP id f6so4804588wmc.4 for ; Tue, 24 Apr 2018 21:53:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=AqAzEcgrn7IIhkzHkhsLi8Wfzx7hew/NctTdQ6ur4fk=; b=SHS9VYpecLCFjlgAbbJlQGAZ9XagRmnlKHY3hPvFsWh4VeaxmaugogPFy+Qy+wMzo+ 2VMjHlBnlYQmyxNOfZJ6MC8MELH0IjN4Zg/e/wx2GS50iwGws2V3ied3YxVYeFOMGMrZ oYIsN49r8BVVDfs0v9iFmkaVeC43bKVPY02aoH278u9iH0cHiqDP875fby1Td4HCAF1r 5IHsSe6Hln1CSCDV6wQjct6q4Jwq3L24wCvwQHZQlImpD/0QkEfoERI+0GCmjdoTpHd7 w3vFgCpKlpLx0WVQ9iXWlU9QRf3QPFFzh31+ztyG01xhL4XLRKjnc/3cEr+aBBJMokW7 PQ0g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=AqAzEcgrn7IIhkzHkhsLi8Wfzx7hew/NctTdQ6ur4fk=; b=DmlWwMn6IdVEfQSdd3FQzK9mVruwnwhYzLXTOCW4Q2D/Z0i+VJeBRaM6yIHgYK5Tgs IhL7HtBF8uDR3L2XGCeVlbpxAVUd3MNPfgzBZ+mVYRN6fu1Gl/8xLjid6yRE2wEDxmUO j7J6fB3zp5HFjEerS5BRRomyCxPb29uzH8JP7pUN90iyWXrjYeCErMTtSnKEShghYvFo g/1i09QP2chq6kn8A5AbcS2JEXTKAbaOtBBlxXBmWMKnjZTFatiBs123Hsl2KX9aqVF2 KaTRofMrQ3GKpj5x89OxpYKtahEQGhWqgQSZewBfe96wXShFUesI4MiwTXPtYHI+Rjae 4Gsw== X-Gm-Message-State: ALQs6tAuidXVoOXlE8EhaTZa+4HIdysbDIF6vTYKLPTof5wbrl+zX3p3 DNnAjTPw1IX637fHqj2n3xUTZj8paoqMzbkx5S2U8w== X-Received: by 10.80.246.27 with SMTP id c27mr34496543edn.196.1524632024416; Tue, 24 Apr 2018 21:53:44 -0700 (PDT) MIME-Version: 1.0 References: <20180424180812.215900-1-wvw@google.com> <20180424145056.7c29ea18@gandalf.local.home> <20180424151416.397fbbde@gandalf.local.home> <20180424152607.71fbee34@gandalf.local.home> In-Reply-To: <20180424152607.71fbee34@gandalf.local.home> From: Wei Wang Date: Wed, 25 Apr 2018 04:53:33 +0000 Message-ID: Subject: Re: [PATCH] do not call trace_printk on non-debug build To: Steven Rostedt Cc: gregkh@linuxfoundation.org, Wei Wang , Ingo Molnar , Andrew Morton , Kees Cook , Peter Zijlstra , Thomas Gleixner , Crt Mori , Alexei Starovoitov , Randy Dunlap , linux-kernel@vger.kernel.org, Joe Perches Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Apr 24, 2018 at 12:26 PM Steven Rostedt wrote: > A lot of kernel developers use trace_printk() and I want to make it as > easy to use as possible. I don't want to add a config to enable it, > because that would be something that could be rather annoying. > Let's add it to checkpatch and see if that can draining the swamp of > abusers. Currently I see f2fs trace is using this when having CONFIG_F2FS_IO_TRACE, so I am not sure how checkpatch would work. How about we add a BUILD_BUG surrounded by a config which would let us flag abuse easily on build time? > -- Steve