Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp2314608yba; Fri, 10 May 2019 09:26:55 -0700 (PDT) X-Google-Smtp-Source: APXvYqwyP2xDYFnxn3sJ0wC09EhW0EK77kykri6MIL8BgrxNLzVRMVOAhZQYatE08exI8tN22/vI X-Received: by 2002:aa7:8f22:: with SMTP id y2mr3351469pfr.22.1557505615371; Fri, 10 May 2019 09:26:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557505615; cv=none; d=google.com; s=arc-20160816; b=VUp4HMfixv8GfxGXwhLsYSY/giU8xoqGDkNrbpbMqEDkqJh7HMa2C1O1Baj+P69+yi ABy+orh/xLXK6WIkKX51lBeU1Mf5jWb9qgpkIJK9uMkvMXs9kUEMzOv+blyHaRRf0EAO eXXMIRRrDwqkZfMStmXZiFAaxbLH81WLILlKM6RohomUMq4MH6U74R857+qO7GdgZI76 qpJLNfoGeR1KTJxxBTrLsTgCnczzmNlpINBRCZ5GhgLisDXbFGHypDD8a9fDwkC5WNHD lU+QxkcYVvVwMV+aNJL8aJMUPWUkpOo41jKQrDFPt4WKl5M5fcqbQZ9nEy1gdXJ0imln twFA== 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:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date; bh=tuTKWz+E6QQ/i2rFZ7Os3CmBeKekf4332B7HTucAniU=; b=Ej6LMlv2LE/s3eBttNXQaTD1A2UVZsr/s17Am8TBhX/o2IH9GwXwS+WGGp8hCP+ljp 5JdsIm7nTfopm2y+r/yiZfNg0FKE/1ma5N+grCdVPVbXEZDNDebEj6st/z6LO3Nn7JNi +W9Vn1q2UkucywFzHgzU32c3dMmw5to8wAu3XB2CUMEhTXX2WM4+rnvjTO6OmslOM12Y js1u5Eq3ry7sK0nNasQ6PVgahOxzG70OQv9WSO+U1QO/M6td13CbqaiI4BUHcX4UhjBN 3r1rbq8axBqKV6SRakS9GVqDhfZGEdVDI42b5R7IQYThpzdS2XiHvcWOBkeN2nUIlVaA 94Sg== 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 p3si5860870pld.239.2019.05.10.09.26.39; Fri, 10 May 2019 09:26:55 -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 S1727800AbfEJQYG (ORCPT + 99 others); Fri, 10 May 2019 12:24:06 -0400 Received: from mail.kernel.org ([198.145.29.99]:46294 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727346AbfEJQYF (ORCPT ); Fri, 10 May 2019 12:24:05 -0400 Received: from gandalf.local.home (cpe-66-24-58-225.stny.res.rr.com [66.24.58.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 76EF420882; Fri, 10 May 2019 16:24:03 +0000 (UTC) Date: Fri, 10 May 2019 12:24:01 -0400 From: Steven Rostedt To: Petr Mladek Cc: Linus Torvalds , Andy Shevchenko , Rasmus Villemoes , "Tobin C . Harding" , Michal Hocko , Sergey Senozhatsky , Sergey Senozhatsky , linux-kernel@vger.kernel.org, Michael Ellerman , linuxppc-dev@lists.ozlabs.org, Russell Currey , Christophe Leroy , Stephen Rothwell , Heiko Carstens , linux-arch@vger.kernel.org, linux-s390@vger.kernel.org, Martin Schwidefsky Subject: Re: [PATCH] vsprintf: Do not break early boot with probing addresses Message-ID: <20190510122401.21a598f6@gandalf.local.home> In-Reply-To: <20190510084213.22149-1-pmladek@suse.com> References: <20190510081635.GA4533@jagdpanzerIV> <20190510084213.22149-1-pmladek@suse.com> X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 10 May 2019 10:42:13 +0200 Petr Mladek wrote: > static const char *check_pointer_msg(const void *ptr) > { > - char byte; > - > if (!ptr) > return "(null)"; > > - if (probe_kernel_address(ptr, byte)) > + if ((unsigned long)ptr < PAGE_SIZE || IS_ERR_VALUE(ptr)) > return "(efault)"; > < PAGE_SIZE ? do you mean: < TASK_SIZE ? -- Steve