Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp617301ybl; Wed, 28 Aug 2019 02:52:03 -0700 (PDT) X-Google-Smtp-Source: APXvYqz49ZUUzwGW4A31a6YnefliwDoBm2Mv1xJZbm/Siahu03FjaTia3GSjPnPfUqjAqyfaijOR X-Received: by 2002:a63:eb56:: with SMTP id b22mr2707935pgk.355.1566985923667; Wed, 28 Aug 2019 02:52:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1566985923; cv=none; d=google.com; s=arc-20160816; b=NL5cxTMD/txFpwwlUILTLPtQQwkiKXwJfzy8tOaNtjrZN0gPNVpF1rTw/fyQJo+ASx S0k9bT+CNkCzK008THPfUNRsUeRfBcVNZ5VQHeCzs54oWjEwUxrpQBwrs+HFxrfWl5bm yQfYEU7vTRIGMPwIrELR3dKy5DJCGkcWUzX9xH6moewW7tjX5dehpcgsi4xXi1R/VjS0 hjtd8EB4xeG0CxgbynoznPRrb6IYvRCfX8PQ7QJXaQb65uXe7cVTIC0pwIx40d2zl/pG hprfK39aXyl2KzdMrsh+jbaXt9dYM8f2MdoF7LPB4GIIV6BuPeaHkBIrqeUYcmt+a8gP qSYw== 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:dkim-signature; bh=H9qTuXYwqZLDg1PwjPrbon+pf8OaOqm2VC7Mf5a70pw=; b=SQtNrHX5hwsf1JH8bmsFJxwEPK6tS0XuYGmeN2HBHgwjwNFOwpurgV+ru6o6bTPfkF aRR17igvREeviWwTHWzl84lY6Eb/y/+WRu7g18u68Dn6F5b5Q57xviVicZ2/IlLHQs5k 8UBSweTNR/AniHM28aaHbVhrWAxFLi//j7FzBgbVrv9wAPcsDDdXZHza1PaUEwBAc5Wt XOLoK3pEBs7ENaYL7sL0526kLXOaAewni450zxWfd9123k3nopavS9KMGAZzq/xD4YlZ Duh1dBdX74Z+pgCptwnMf0SL6ADMwWa0A0mm5v2DPen3bsDK8QmJ26O4wo+3pg3md7AL l3lQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=lNevBVC2; 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=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 85si1745175pgb.583.2019.08.28.02.51.47; Wed, 28 Aug 2019 02:52:03 -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=@gmail.com header.s=20161025 header.b=lNevBVC2; 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=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726400AbfH1Jtf (ORCPT + 99 others); Wed, 28 Aug 2019 05:49:35 -0400 Received: from mail-pf1-f196.google.com ([209.85.210.196]:37260 "EHLO mail-pf1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726272AbfH1Jte (ORCPT ); Wed, 28 Aug 2019 05:49:34 -0400 Received: by mail-pf1-f196.google.com with SMTP id y9so1377995pfl.4; Wed, 28 Aug 2019 02:49:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=H9qTuXYwqZLDg1PwjPrbon+pf8OaOqm2VC7Mf5a70pw=; b=lNevBVC2SXUBMPDCPlOyjPp24N+F341HJEFOMyCyD8OhnXgHIOg9PiKbY1LOQ7XI+e howHZCbR7GZpY2B7gHriw4jXLSl0yK8RrmhzJxBgkziyHi3hkF5krMGjF1ytKo0T7GTz Wyyn94Mzvqskh//k9PkYAF4vX4PZ+MnE915U6UlTXWr39tQSszoqfnS0INjQaEcOtcva GoMT43bAUsAIjmBpVf0h7HqCwx/KmeOYjCqgfeqFNZ9Rms3fyHwOOk5XVxYLx4KfpW6S eZnP4zscYLzMvrb8BsTJv8Ve2Uh/g6++G/18rWW1b3+BUghz6AV0GPwV5KT2LwPcpgfI KgmQ== 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:in-reply-to:user-agent; bh=H9qTuXYwqZLDg1PwjPrbon+pf8OaOqm2VC7Mf5a70pw=; b=l+VXs8RujL+20WxwoKzwepT9en3RzgsZB8UYvd5EUo2WbsBzEmmV8VvjsWk0kkT2sy PtOUDg6ncsyZ/dh0oQKV1SeIAayclE0bUi9f3u32RERUUHdYyV2Dgzq1GwEf0F7VZovI K1ua+/31RJK7kXsyT4WHROjOg/tVCAyv2kdGZ4a6RM1Bqz89hzmtevIR5DKxc9RJDcOs l0EeBr9TUmiYjYoT/02YZgDabTICHVENdigXYcAwXatnAPH4njl2+h+9OwROSmxbBtBE Z6zKXgQPGfKAyAQHDUyXucGyTimnxmH5gwaqClwS5/4WqKsKd0Swq+sUYQlNBjVjiAM3 7ong== X-Gm-Message-State: APjAAAUzOVmUYpoSyxwsvrk+E67XyKJXzxUUwjmxVBVBKbu48093o5N/ wUEfxs15lOZ0klJmxreOtlg= X-Received: by 2002:a17:90a:ba04:: with SMTP id s4mr3440843pjr.73.1566985774011; Wed, 28 Aug 2019 02:49:34 -0700 (PDT) Received: from localhost ([39.7.47.251]) by smtp.gmail.com with ESMTPSA id k14sm2051086pfi.98.2019.08.28.02.49.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2019 02:49:33 -0700 (PDT) Date: Wed, 28 Aug 2019 18:49:29 +0900 From: Sergey Senozhatsky To: Brendan Higgins Cc: shuah@kernel.org, kunit-dev@googlegroups.com, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, frowand.list@gmail.com, sboyd@kernel.org, pmladek@suse.com, sergey.senozhatsky@gmail.com, rostedt@goodmis.org, Randy Dunlap , Stephen Rothwell , Sergey Senozhatsky Subject: Re: [PATCH v2] kunit: fix failure to build without printk Message-ID: <20190828094929.GA14038@jagdpanzerIV> References: <20190828093143.163302-1-brendanhiggins@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190828093143.163302-1-brendanhiggins@google.com> User-Agent: Mutt/1.12.1 (2019-06-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On (08/28/19 02:31), Brendan Higgins wrote: [..] > Previously KUnit assumed that printk would always be present, which is > not a valid assumption to make. Fix that by removing call to > vprintk_emit, and calling printk directly. > > Reported-by: Randy Dunlap > Link: https://lore.kernel.org/linux-kselftest/0352fae9-564f-4a97-715a-fabe016259df@kernel.org/T/#t > Cc: Stephen Rothwell > Cc: Sergey Senozhatsky > Signed-off-by: Brendan Higgins [..] > -static void kunit_vprintk(const struct kunit *test, > - const char *level, > - struct va_format *vaf) > -{ > - kunit_printk_emit(level[1] - '0', "\t# %s: %pV", test->name, vaf); > -} This patch looks good to me. I like the removal of recursive vsprintf() (%pV). -ss