From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752752AbdKMOAp (ORCPT ); Mon, 13 Nov 2017 09:00:45 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:58502 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751188AbdKMOAo (ORCPT ); Mon, 13 Nov 2017 09:00:44 -0500 Date: Mon, 13 Nov 2017 15:00:50 +0100 From: Greg Kroah-Hartman To: Rasmus Villemoes Cc: Kees Cook , speakup@linux-speakup.org, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 3/5] staging: speakup: Apply format_template attribute Message-ID: <20171113140050.GB3436@kroah.com> References: <20171112211911.27779-1-linux@rasmusvillemoes.dk> <20171112211911.27779-3-linux@rasmusvillemoes.dk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20171112211911.27779-3-linux@rasmusvillemoes.dk> User-Agent: Mutt/1.9.1 (2017-09-22) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Nov 12, 2017 at 10:19:09PM +0100, Rasmus Villemoes wrote: > This serves as human-readable documentation as well as allowing the > format_template plugin to complain about any static initializers of this > struct member that do not have the same set of printf specifiers. > > Signed-off-by: Rasmus Villemoes > --- > drivers/staging/speakup/spk_types.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/staging/speakup/spk_types.h b/drivers/staging/speakup/spk_types.h > index c50de6035a9a..156000c0c4d3 100644 > --- a/drivers/staging/speakup/spk_types.h > +++ b/drivers/staging/speakup/spk_types.h > @@ -108,7 +108,7 @@ struct st_var_header { > }; > > struct num_var_t { > - char *synth_fmt; > + char *synth_fmt __format_template("%d"); > int default_val; > int low; > int high; > -- > 2.11.0 Acked-by: Greg Kroah-Hartman