Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp5980594imu; Tue, 13 Nov 2018 15:05:57 -0800 (PST) X-Google-Smtp-Source: AJdET5f8Q7y6h1SiIRloPv38tky4bI6kKZVL5+hOM4hvmEli8fXTH0ax9EoAVqAlOBdHYkjisg5t X-Received: by 2002:a17:902:7c94:: with SMTP id y20-v6mr7060956pll.218.1542150357390; Tue, 13 Nov 2018 15:05:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542150357; cv=none; d=google.com; s=arc-20160816; b=IJsH2n28eDskJSGEJcQuKr3qwVMNxx1KzQSZTjItDUgH1JOTYavLpdY4yyAS9nT8r3 dSVBQP3Drb20D8kL+GWJErddNEnFeuOciPA2yq1Sfe4UVVDygOvGi2DCzpIbCn2vUOoV +Qmhm5rzx/77PZ5TNe2v7f4MN9jXFXGQsPYlM5klYKzugQvrwTmrbqB02yTS1V/MxPUd tmzIoqLhN9r55i+Yd+l5YiQl08TNnIQoUimia4WWkEOGsyLbXdxCS46TAX9E+Fg/99I5 qaAwcTEyZQyQS50/fRcE0Ya7bKHfHsxZluYAIqsk6i5H6zyM5d0KCXQyoAdrZAab246C nesw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=h6AHhwGHYuQuXe8JyBZryvhftN8YVroPDgAZIhnmaCM=; b=rA5oZImo/0SGRIPvqmGxpJXTO6uSLzvE7NRkqHhQnrwjVcxdCN6CEKMu6pJVW/Mhky TIBzcesVPomkuUgEH7ju3E9PEhQHiZ3hx4uXpcaONv2NKHD9hexHCRrOdgqotmJY8uEY VUd5aIiXFXx/9VQfdnnwk0G3U9B/o9qGK/9TmYh+iT1gv61blE7aqc7haD7D3jEfxbZm sag9URj9EUOjebE7bN4VZgHUePa7qTutd9lDPmVjLJvC55GenGs49e2Aiggcum669gT6 IgdRiElGkXnxcPWDiH607StVMJodMFNpKp/XW55CpXBpGOyQ2AwQL7Py9fXm4x2B/KMo mXsg== 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 h16si20847434pgj.203.2018.11.13.15.05.41; Tue, 13 Nov 2018 15:05:57 -0800 (PST) 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 S1731634AbeKNJFl (ORCPT + 99 others); Wed, 14 Nov 2018 04:05:41 -0500 Received: from mx2.suse.de ([195.135.220.15]:45216 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726531AbeKNJFl (ORCPT ); Wed, 14 Nov 2018 04:05:41 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id EBD09AFBB; Tue, 13 Nov 2018 23:05:14 +0000 (UTC) Date: Wed, 14 Nov 2018 00:05:12 +0100 From: Petr Mladek To: Steven Rostedt Cc: Qian Cai , Andy Shevchenko , linux-kernel@vger.kernel.org, "Tobin C. Harding" , Geert Uytterhoeven , Rasmus Villemoes Subject: Re: WARNING: CPU: 26 PID: 64391 at lib/vsprintf.c:2193 set_precision+0x84/0x90 Message-ID: <20181113230511.5di75uyht7ecdcvl@pathway.suse.cz> References: <1542128132.12945.19.camel@gmx.us> <20181113172920.GI10650@smile.fi.intel.com> <1542135498.12945.20.camel@gmx.us> <20181113142317.379dbaf7@vmware.local.home> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20181113142317.379dbaf7@vmware.local.home> User-Agent: NeoMutt/20170421 (1.8.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue 2018-11-13 14:23:17, Steven Rostedt wrote: > On Tue, 13 Nov 2018 13:58:18 -0500 > Qian Cai wrote: > > > > Care to print the len and name parameters before this line? > > len = 60612; name = > > How big are pages on arm64? Because we shouldn't get to this path if > the string is bigger than PAGE_SIZE. But I know that on PPC64, > PAGE_SIZE can be 64K, and 60612 is less than that. Thus, if we get > there, the test is against signed int:16 (16 bit signed integer) that > can go up to most 32768. If the string size is bigger than that, you > would get this error. > > I would just say to ignore it. I tend to agree. > The only thing that can happen if > someone does this is to trigger the warning. Unless if it is considered > a form of DOS, where userspace just bombards the console by triggering > this waring. We are actually on the safe side because it is WARN_ONCE(). > But I don't see a problem with the actual design. There's > no reason we should be processing string variables bigger than 32768 in > vsprintf. It is not even needed in this case. The string is limited also by MODULE_NAME_LEN. Best Regards, Petr