Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp4035770pxj; Tue, 15 Jun 2021 14:03:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJytIsYWqk5N+LClHd8Ypg6xiwMFAGqmsfKygV4Z2dq0T4A4sMZSqZLFLFVJK5RxDLnMLkUx X-Received: by 2002:a05:6e02:12c4:: with SMTP id i4mr994778ilm.141.1623790985193; Tue, 15 Jun 2021 14:03:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623790985; cv=none; d=google.com; s=arc-20160816; b=f8D5VLxdUTlA2WADsVHlQyHvYqGfr8rDtIbSvblExTB3rvtT1yzcM2vC3sRyU25ek8 q7bawK416rD2pk4ZvoNWEpQKjZmx89FrBWy6nlYEck2800gSuBoT/vnh/80YIgRMNKU3 WnmF0Qmwgt/l6AFMPni6Q+LMkE1oVsNocXYjjLivD0OTXPjy6lyH9w2dqOIKVBELG7u8 BWNGc7wzMWIZWvYMt3EbEvTBRKPXtPrGgvS/8jhMFYTskTygazyvP+o4U9ssXoCAavr1 3Wy9qX/dzyiMuI+PF7ezmu8QOFgb/U75bauWC6OlMRri+p3BYOzwBK6gvrnQSOf43GmW 3Qxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=CoAyLiwzAABeU8evuRFmHRs7KdWsfzJoiB5zqUSRKLU=; b=epeXaTWnNvNvuMO4QDeZ0dSeTmZBUEGKbTCxZ4kiRULe/eeJwSrnAMDabwGdfzTPEi CGNsn7ESBIhYfif9Y5Y5pd3bpgKwR0GKjfP3LlInBLV9Cwbhm5XuaRp6hQkyQiaq7Jk6 xxh+lr7A4A8X5NZiHGoJYGNQS5d1T5WuHErpFxFDzy/sYhbQQWetVbLGJsqaUNVm3IL9 Wt3PwIal01BqWseaXGd3NnvzWjMzZJ7sOyWzCnrOXXo9mlKVveJUgnyjlQ9KUntR50J9 0YApHgoKveu8YGh3joq2Gh/wrdMuV05/X9fRUDGXNMrZoH6Tt75Aty86GplKtGS18zL6 V+Cg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=RGspZKjK; 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 r133si209690jac.80.2021.06.15.14.02.40; Tue, 15 Jun 2021 14:03:05 -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=RGspZKjK; 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 S230466AbhFOVDZ (ORCPT + 99 others); Tue, 15 Jun 2021 17:03:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43816 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230144AbhFOVDZ (ORCPT ); Tue, 15 Jun 2021 17:03:25 -0400 Received: from mail-lj1-x22a.google.com (mail-lj1-x22a.google.com [IPv6:2a00:1450:4864:20::22a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0EFFCC06175F for ; Tue, 15 Jun 2021 14:01:20 -0700 (PDT) Received: by mail-lj1-x22a.google.com with SMTP id z22so602299ljh.8 for ; Tue, 15 Jun 2021 14:01:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=CoAyLiwzAABeU8evuRFmHRs7KdWsfzJoiB5zqUSRKLU=; b=RGspZKjKfe5UEq5fXSAxyfxLiMjZgAj9xSvVuw5qYO0OmjbSFGpApLjx27BLp/qzr8 x1FGp1CjXna3EqevQlSGoQyaNXpMkAt9dhDYQcE+XWk0vSgCuzA9PjxDvkYtuDSCkTES 3iqj+qpUvZ/Xz4/+7+roFDUg+bTgmiBIVTXXg5iePg7PsHDMZR7QX0EEJN5jEWWMmyLm yKDRR79jBhZhejZ3dVpd5RYq1s32gqsphLOLKZTu08VxsoCbWdO5ggMGFudRCh1/r1Ud pLj6JkOBJtwAw3KkBDj4hvtp5VoKDWBFhvr73EiPw8ofSSCTqEJFjApCy1ZaQq9ixd3h 3JNg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=CoAyLiwzAABeU8evuRFmHRs7KdWsfzJoiB5zqUSRKLU=; b=T0KOdejYYxIH6aTu73rT2zRvt1eOWFx7XKAucmcQD62SyjkfRMhQKMn3BqvBctke11 gvpan7E17W4aapUcE8WFlAAPQ7V5G6bz4N226wxg4VN47qMM/PKpQbDRcTScSaeuSzQn ooNQ+ReXDfGlxsUPyLt31YaQIyPqmran4nVERvGr/BGUfEws9dNZ+Q9P6Nv0erF+O9Bx WrlXWSZjAPc2OYzppY9i19Hh3PPmIMClpoAkz+sIAKtHD9pkTf6nq9LGLMwr2r+tAUsm BhVgmNPYqoLZ9sdWsQ4Zg+wBbljXWYYTli6Nru9smxE+HrxZTpwPWqDqmy0P0J9bRIj7 bRLw== X-Gm-Message-State: AOAM531C9C55K4xgvnGXJo2HDPlYUwUt9O5TzDR+h1ycg+PQyJBJ43D9 ebiH+bE7fZsKSbHC9C5zXRRcOYuyMfLYevbw3G2kKQ== X-Received: by 2002:a2e:9ac1:: with SMTP id p1mr1397778ljj.10.1623790877077; Tue, 15 Jun 2021 14:01:17 -0700 (PDT) MIME-Version: 1.0 References: <20210513200350.854429-1-davidgow@google.com> In-Reply-To: <20210513200350.854429-1-davidgow@google.com> From: Brendan Higgins Date: Tue, 15 Jun 2021 14:01:05 -0700 Message-ID: Subject: Re: [PATCH] kunit: Add gnu_printf specifiers To: David Gow Cc: Shuah Khan , "open list:KERNEL SELFTEST FRAMEWORK" , KUnit Development , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 13, 2021 at 1:03 PM David Gow wrote: > > Some KUnit functions use variable arguments to implement a printf-like > format string. Use the __printf() attribute to let the compiler warn if > invalid format strings are passed in. > > If the kernel is build with W=3D1, it complained about the lack of these > specifiers, e.g.: > ../lib/kunit/test.c:72:2: warning: function =E2=80=98kunit_log_append=E2= =80=99 might be a candidate for =E2=80=98gnu_printf=E2=80=99 format attribu= te [-Wsuggest-attribute=3Dformat] > > Signed-off-by: David Gow Acked-by: Brendan Higgins