Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp4632314pxu; Tue, 13 Oct 2020 03:25:24 -0700 (PDT) X-Google-Smtp-Source: ABdhPJweCJqyRrdJydTYx05sGwGz4OvYQDBRnaD0MAa0/WyYZshbEX2OuoSLQYLnia3pJp0pURVs X-Received: by 2002:a17:906:345a:: with SMTP id d26mr22439158ejb.190.1602584723946; Tue, 13 Oct 2020 03:25:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1602584723; cv=none; d=google.com; s=arc-20160816; b=S8scjr9mC8tZn3df2wqtchqIFaA75BeQ/aqfCkJUhuCvScguslFNaciqM9qt8uLf5J iYsQxMl4z4vTfwP+uoZJaqBQwFqEmeHdihzmsRsApCOilnwHEW+Lo8FZNBCOTlbXzhW4 KERaI5uckPGkwnnOmHK1kNd6AMVaoK1IXmeGFI0MVNdR81e/2JhCljGV8lTqG0bV7i65 0lutYEWQ8XOubl02DPyj3c2L/jQxZw3GWpNS33aN8silVUfccPi1l79O71xVQKc3tCEV ziBp6lVsFfOBGXZzSoAnnXIHt6pXwxBJEaTEyrshxciRqLAC+tD4kKmWmsJo7PV3/N33 pmdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=GP/tSxU+2ueJJAD5XvrlcBqjjbcVqs1GAlfX4xS/x5o=; b=qeYDBt5pFkRcu2zWUkuArtNOinfzcu+xlSZZgUfCSv1ItmyNwNTh70vQbQqFQyBTQj RzTSeQ4gGj8UW+lhFICoNO4F9r9xOBbBGuSew5CGQRFzsuE2GOPDkd6S3nv/DNIvyBtm sQMEKfwgJTl4dQEPxoQqvBKJAh6olw0kK2N/N+9caYw3LANW44lI1KFqvCXVRYXWMwsM XlsJqiq6VAIeeCeTiFJvCEqU9w2el1/1Oe1wn1QSiJMAELSSzvjID78slVxae17XuLNU kUgfDiGAxevC4rCEWa5zPf9osijzeCzZe2EXheOMgmpas60u/p4fMXc+XHYhey/Owjf+ bD0g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=Zmyj6b1x; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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. [23.128.96.18]) by mx.google.com with ESMTP id x12si14389341eje.374.2020.10.13.03.25.01; Tue, 13 Oct 2020 03:25:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=Zmyj6b1x; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S2387466AbgJLUqu (ORCPT + 99 others); Mon, 12 Oct 2020 16:46:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40942 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731466AbgJLUqs (ORCPT ); Mon, 12 Oct 2020 16:46:48 -0400 Received: from mail-pl1-x643.google.com (mail-pl1-x643.google.com [IPv6:2607:f8b0:4864:20::643]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1BAA4C0613E3 for ; Mon, 12 Oct 2020 13:46:32 -0700 (PDT) Received: by mail-pl1-x643.google.com with SMTP id 1so3477105ple.2 for ; Mon, 12 Oct 2020 13:46:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to; bh=GP/tSxU+2ueJJAD5XvrlcBqjjbcVqs1GAlfX4xS/x5o=; b=Zmyj6b1xn7fgYQ4LeerdVC70u737/gGJRwdCYnv5k4lAJ4ZAWiq77J6HTWNtPLy5Fb +xId2w1AJdlP4b4Gk+cO+qmKRbcZL0o4WUamdOMbP0HnLbSjH7bnxsZclfoKc6+wueKq Y4WFwLXKO7dsLcGwu3W0ytOyLYRM/b67FrN7deWaZaARnBxEiuSQkhaYtEFWV3FNh1DJ mYsz/GpTkpDNVka9ngAw3/WAJVbib0KRuj33mR5fuEcT+qGLmQdkwuO6TrpxS1rNI4ix t8Vacy6eZIRybQE0PFe7c5weaxWzTGWykb5XWW2C6WIttIokJ30keX8fgYRcZYI7D11N 1gcg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to; bh=GP/tSxU+2ueJJAD5XvrlcBqjjbcVqs1GAlfX4xS/x5o=; b=A1eT6tvhr9NJHYUQevBPg28YSqbPlx1kWIoDQzjlbILzFhGdLGnl0vBIiPJfo9AVZA dc8vtM6EtzJ8jPFcA41zq/J4abSlviWpkh21zij0ak3HY8hH5RDGX0/qiybL57ZbBMx9 kOjXTE87gi3AgVaFK0qlc+G1eHqyV8xFhujAU9naAULCsj3jk29is59bMMn5BDoO0VgT DAztuBEawEVCoEPjbawhLYyFnaFQ0U8h/hlnNvGToGNVN19r5hlo5g69MWyxdbJaFQ5f jyaK4sP7vzjaq2B8RHHOnPTgtnMIIWq/yzZ2Wv0o0+Ntt6HUM45uD5OmPJ5qPEqStNHK Tu1w== X-Gm-Message-State: AOAM5317KBAul8r+vaTwXQhKh2SfRzWTNho2XzdlVdHkgPZr3CflNUW3 OXAHscbuXeE1w+KnsNqNCykzXw== X-Received: by 2002:a17:902:70c8:b029:d4:d4d5:f140 with SMTP id l8-20020a17090270c8b02900d4d4d5f140mr9444301plt.33.1602535591364; Mon, 12 Oct 2020 13:46:31 -0700 (PDT) Received: from google.com ([2620:15c:2cb:201:c634:6bff:fe71:d8d1]) by smtp.gmail.com with ESMTPSA id q5sm9065695pjg.0.2020.10.12.13.46.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Oct 2020 13:46:30 -0700 (PDT) Date: Mon, 12 Oct 2020 13:46:25 -0700 From: Brendan Higgins To: Andy Shevchenko Cc: Petr Mladek , Rasmus Villemoes , Arpitha Raghunandan <98.arpi@gmail.com>, skhan@linuxfoundation.org, rostedt@goodmis.org, sergey.senozhatsky@gmail.com, kunit-dev@googlegroups.com, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, linux-kernel-mentees@lists.linuxfoundation.org Subject: Re: [PATCH] lib: Convert test_printf.c to KUnit Message-ID: <20201012204625.GA56597@google.com> References: <20200817043028.76502-1-98.arpi@gmail.com> <20200821113710.GA26290@alley> <20200821122849.GS1891694@smile.fi.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20200821122849.GS1891694@smile.fi.intel.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Aug 21, 2020 at 03:28:49PM +0300, Andy Shevchenko wrote: > On Fri, Aug 21, 2020 at 01:37:10PM +0200, Petr Mladek wrote: > > On Mon 2020-08-17 09:06:32, Rasmus Villemoes wrote: > > > On 17/08/2020 06.30, Arpitha Raghunandan wrote: > > > > Converts test lib/test_printf.c to KUnit. > > > > More information about KUnit can be found at > > > > https://www.kernel.org/doc/html/latest/dev-tools/kunit/index.html. > > > > KUnit provides a common framework for unit tests in the kernel. > > > > > > So I can continue to build a kernel with some appropriate CONFIG set to > > > y, boot it under virt-me, run dmesg and see if I broke printf? That's > > > what I do now, and I don't want to have to start using some enterprisy > > > framework. > > > > I had the same concern. I have tried it. Sorry you feel that way. Do you have any suggestions on how we can make it seem less enterprisy? Seems like there are people here who are not a fan of the output format, so of which we can fix here, some of which is part of KTAP[1]. > Which raises an obvious question: did the people who convert this test this > themselves? Looks like a janitor work in the area without understanding the > area good enough. Looks to me like Arpitha ran it, but you are right, we don't have a lot of familiarity with this area; we were treating it as "janitor work" as you say. Our intention was just to take some existing tests and as non-invasively as possible, get them to report using a common format, and maybe even get some of the tests to follow a common pattern. > Probably I will NAK all those patches from now on, until it will be good commit > messages and cover of risen aspects, including reference to before and after > outcome for passed and failed test cases. Fair enough, hopefully we can address these issues in the next revision. One issue though, with the "before and after outcome" you are referencing; are you referring to the issue that Petr pointed out in how they are inconsistent: ? ?+ original code: vsnprintf(buf, 6, "%pi4|%pI4", ...) wrote '127.0', expected '127-0' ? ?+ kunit code: vsnprintf(buf, 20, "%pi4|%pI4", ...) wrote '127.000.000.001|127', expected '127-000.000.001|127' ? (I think Rasmus addressed this.) Or are your referring to something else? > Brendan, I guess the ball now on your side to prove this is good activity. And I see that we are off to a great start! :-) In all seriousness, I am really sorry about this. I kind of bungled this up trying to go after too many of these conversions at once. Arpitha, can you get this follow up patch out? [1] https://lore.kernel.org/linux-kselftest/CY4PR13MB1175B804E31E502221BC8163FD830@CY4PR13MB1175.namprd13.prod.outlook.com/