Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp1600797imm; Tue, 10 Jul 2018 04:56:33 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcXwiOzb52+e3io4kjjvr/AcABic9spFB8V+2rUVhYFO7saImMKSDcF7ByzJ6R3xdlPoqFu X-Received: by 2002:a63:383:: with SMTP id 125-v6mr16698536pgd.421.1531223793603; Tue, 10 Jul 2018 04:56:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531223793; cv=none; d=google.com; s=arc-20160816; b=ErxQoy0mYJ6E4BnMX+NLuqOhCWrRy85tTBE4z8T4L0VskazwtOsA4l8JN71VU6992k ZVUCuuaP61ZTggmmGmtaVZu5eQ+gQkNJsidZU/r+nZN7nOhDPSrut7CCTUlxh3H+thCP RHWYiO8KYcNVb/BcwZY2fyXz7+UI2PuxlNwa2WID8KE5AaAJdyYOfTNrkNZ5bKPTQ0pN nAKfLjv/zAVWto2+7+D2aEHeGfzsHY4aJAB6Yf/9/f5mp6UBK4cCeEVSQSVV9XxLfpB2 LN2asN80r2XBBDL2nzoCBJ+y5SXRgUKr1T8ufNIiWLAiyehzuHqgyZSnesFk8mhsQJOq 65QA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:arc-authentication-results; bh=jTSQ563MyDtXCPTX3HK/esn63ECYJcdb5bcWgmEaJ6k=; b=0ET9k4iVdDW0hKViFJLqtNUpB8SDpB4Own+edk0PqiDGnrqOMUJnzdNaslH9cupQ0P Te+q6F9llIp/yiLMVYIdahBzWCIZGltupwgtAGT+J4PrHw7QuIxlx6MH012B+MFNz3ao xnTJ9r+kI/gVkSsRn8pdnSy+o3H2fSTayS9HFBzjfn3dIuSCEP0BEuNYbCyv+18kJjfA zBsbzlJCExK0Bwjn7+zIyJ6xkWp1OMC6qIWypw7j5Pp3PXYwjxjBX1u/WOVqN7hz5RWF JGL3pHZGTsqzJHoCmXjWatWl+jM4+WkROA1itcynONIO0ZCaHLOuMW5elFuDBP2mbFSk PSbQ== 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 f3-v6si15994360plr.214.2018.07.10.04.56.18; Tue, 10 Jul 2018 04:56:33 -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 S933187AbeGJLzk (ORCPT + 99 others); Tue, 10 Jul 2018 07:55:40 -0400 Received: from www262.sakura.ne.jp ([202.181.97.72]:45001 "EHLO www262.sakura.ne.jp" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751715AbeGJLzj (ORCPT ); Tue, 10 Jul 2018 07:55:39 -0400 Received: from fsav301.sakura.ne.jp (fsav301.sakura.ne.jp [153.120.85.132]) by www262.sakura.ne.jp (8.15.2/8.15.2) with ESMTP id w6ABtbC4061923; Tue, 10 Jul 2018 20:55:37 +0900 (JST) (envelope-from penguin-kernel@i-love.sakura.ne.jp) Received: from www262.sakura.ne.jp (202.181.97.72) by fsav301.sakura.ne.jp (F-Secure/fsigk_smtp/530/fsav301.sakura.ne.jp); Tue, 10 Jul 2018 20:55:37 +0900 (JST) X-Virus-Status: clean(F-Secure/fsigk_smtp/530/fsav301.sakura.ne.jp) Received: from [192.168.1.8] (softbank126074194044.bbtec.net [126.74.194.44]) (authenticated bits=0) by www262.sakura.ne.jp (8.15.2/8.15.2) with ESMTPSA id w6ABtbo6061919 (version=TLSv1.2 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 10 Jul 2018 20:55:37 +0900 (JST) (envelope-from penguin-kernel@i-love.sakura.ne.jp) Subject: Re: [PATCH] x86: Avoid pr_cont() in show_opcodes() To: Josh Poimboeuf , Peter Zijlstra Cc: Ingo Molnar , mingo@redhat.com, linux-kernel@vger.kernel.org, Andy Lutomirski , Borislav Petkov , Linus Torvalds , Thomas Gleixner References: <1530943625-3288-1-git-send-email-penguin-kernel@I-love.SAKURA.ne.jp> <20180707111209.GA27768@gmail.com> <20180709084953.GB2476@hirez.programming.kicks-ass.net> <20180709191034.pyadc3cy7ulwaf2o@treble> From: Tetsuo Handa Message-ID: Date: Tue, 10 Jul 2018 20:55:41 +0900 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.9.0 MIME-Version: 1.0 In-Reply-To: <20180709191034.pyadc3cy7ulwaf2o@treble> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2018/07/10 4:11, Josh Poimboeuf wrote: > On Mon, Jul 09, 2018 at 10:49:53AM +0200, Peter Zijlstra wrote: >> On Sat, Jul 07, 2018 at 10:54:28PM +0900, Tetsuo Handa wrote: >>>>> Since syzbot is confused by concurrent printk() messages [1], >>>>> this patch changes show_opcodes() to use snprintf(). >> >> But how big of a problem is that really? We can't very well remove all >> pr_cont stuff from the kernel. > > I'd say we should try to make oopses as legible as possible. > > Also KERN_CONT is inherently broken, and we should avoid using it in > general, IMO. > We can't afford removing all pr_cont()/KERN_CONT. But show_opcodes() is an example of function which is expected to be SMP-safe. /* * Annotation for a "continued" line of log printout (only done after a * line that had no enclosing \n). Only to be used by core/arch code * during early bootup (a continued line is not SMP-safe otherwise). */ #define KERN_CONT KERN_SOH "c"