From patchwork Wed Jul 13 21:03:38 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 102022 Delivered-To: patch@linaro.org Received: by 10.140.29.52 with SMTP id a49csp1197960qga; Wed, 13 Jul 2016 14:04:30 -0700 (PDT) X-Received: by 10.66.160.41 with SMTP id xh9mr17235531pab.85.1468443869968; Wed, 13 Jul 2016 14:04:29 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z2si2268319pax.288.2016.07.13.14.04.29; Wed, 13 Jul 2016 14:04:29 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of netdev-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 netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=netdev-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751426AbcGMVEW (ORCPT + 4 others); Wed, 13 Jul 2016 17:04:22 -0400 Received: from mout.kundenserver.de ([217.72.192.74]:55157 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751159AbcGMVET (ORCPT ); Wed, 13 Jul 2016 17:04:19 -0400 Received: from wuerfel.lan. ([78.42.132.4]) by mrelayeu.kundenserver.de (mreue103) with ESMTPA (Nemesis) id 0LzYuY-1bIPDC3KqY-014gra; Wed, 13 Jul 2016 23:04:04 +0200 From: Arnd Bergmann To: Jiri Pirko Cc: netdev@vger.kernel.org, Steven Rostedt , Ingo Molnar , "David S . Miller" , linux-kernel@vger.kernel.org, Arnd Bergmann Subject: [PATCH net-next 2/2] devlink: fix trace format string Date: Wed, 13 Jul 2016 23:03:38 +0200 Message-Id: <20160713210338.1647521-2-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 In-Reply-To: <20160713210338.1647521-1-arnd@arndb.de> References: <20160713210338.1647521-1-arnd@arndb.de> X-Provags-ID: V03:K0:p/o3s9USe7SBu+KUIOeLJZGXb6MK6hJayuKeIrfym4uqY1N5II7 Z8iFEOmgAzJgPv7aCmR75Z76sAYF9WS8UeyjUP8n2hJZ6CpRjGMtVXwpaCuDJnk0h6jnhcW /8k8fP9Fd0NHl9zEjNUqNpAMrfm/Bn/MIvPnA7KtuWYibpiAl4QMdPYr+ACukgpirp5rYGO WgVSfRNeu7kQww5dmAxHA== X-UI-Out-Filterresults: notjunk:1; V01:K0:1fIr+0JerYg=:47IqlTsntzrKE6w2fqQk36 pPUEn96dPaSVmHzBErflwWjNFnjhShHGp4uPAYIiYiDwwipRpmcprcKTnr73bexmv4yCoV89z 1r6tq4I/C7qXFyG8GiiEOmUS8MU5qsbeXoW8l3FM4JEIycnWJzaZNVnOY7q2eEQYXiw0l7m+U idwc5m/qIUFhhq7aGGxmB9GcpGGf0vTRCl63KR2yEe0ejVgTvfIfLKpLd8NyYnA/x7RJ4RAGL M3hRM2DSV5riD3CB9USrUb3NZ/A3qegrWt5uuBsY7Y8LXwM/cq0AYeZcz/XmU5tmlEiFikxQI z9bQDTk+Y6SfhPy4JGUJW2/IwGrxf7NuCWoRQJJC8rxPj6H2YDccSwyEq8ZNlYcvvrNPUpwYn JCpwDuePaZ6arYPE09ZEHYFy+d5kaCRrzy71zWYuV1vaZ4xqLMxd/6rqYWIdRAv1VSPvq6SKX pnn/jzlSMVd+77bcF+DsOb4WcC7HOrSgXo9YPwWTN1uFba/8QKgUAZHsYb5lOQElAPNUhNy1h aZQr++E+j2LZOsfpV/Bx50tWyR+Vz34y/xuJfVZkrdRLKq7ExCACgTHi/vQa5NkJq/9Bq6oJM CcD48GyOiV34hVtuFMilGCTTpf5egvdgXLy/gnlmSF9IUb4tXpHPm3baTNGA5aB2xnqLEgUKT 7RLojOJFwqPF1hKrgNG565eX9CzRiAmCE+RNWzDTqvllG7xGMSsFeRPM94obwcj01lpw= Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Including devlink.h on ARM and probably other 32-bit architectures results in a harmless warning: In file included from ../include/trace/define_trace.h:95:0, from ../include/trace/events/devlink.h:51, from ../net/core/devlink.c:30: include/trace/events/devlink.h: In function 'trace_raw_output_devlink_hwmsg': include/trace/events/devlink.h:42:12: error: format '%lu' expects argument of type 'long unsigned int', but argument 10 has type 'size_t {aka unsigned int}' [-Werror=format=] The correct format string for 'size_t' is %zu, not %lu, this works on all architectures. Signed-off-by: Arnd Bergmann Fixes: e5224f0fe2ac ("devlink: add hardware messages tracing facility") --- include/trace/events/devlink.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.9.0 diff --git a/include/trace/events/devlink.h b/include/trace/events/devlink.h index 26f92d3c7e9c..4b75a6f986fc 100644 --- a/include/trace/events/devlink.h +++ b/include/trace/events/devlink.h @@ -47,7 +47,7 @@ TRACE_EVENT(devlink_hwmsg, __entry->len = len; ), - TP_printk("bus_name=%s dev_name=%s owner_name=%s incoming=%d type=%lu buf=0x[%*phD] len=%lu", + TP_printk("bus_name=%s dev_name=%s owner_name=%s incoming=%d type=%lu buf=0x[%*phD] len=%zu", __get_str(bus_name), __get_str(dev_name), __get_str(owner_name), __entry->incoming, __entry->type, (int) __entry->len, __get_dynamic_array(buf), __entry->len)