linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: patrice.chotard@st.com
Cc: linux-gpio@vger.kernel.org
Subject: re: pinctrl: stm32: Implement .pin_config_dbg_show()
Date: Tue, 17 May 2016 10:31:52 +0300	[thread overview]
Message-ID: <20160517073152.GB10872@mwanda> (raw)

Hello Patrice Chotard,

The patch 3beed93c1617: "pinctrl: stm32: Implement
.pin_config_dbg_show()" from Apr 29, 2016, leads to the following
static checker warning:

	drivers/pinctrl/stm32/pinctrl-stm32.c:798 stm32_pconf_dbg_show()
	warn: excess argument passed to 'seq_printf'

drivers/pinctrl/stm32/pinctrl-stm32.c
   781          /* output */
   782          case 1:
   783                  drive = stm32_pconf_get_driving(bank, offset);
   784                  speed = stm32_pconf_get_speed(bank, offset);
   785                  val = stm32_pconf_output_get(bank, offset);
   786                  seq_printf(s, "- %s - %s - %s - %s %s",
   787                             val ? "high" : "low",
   788                             drive ? "open drain" : "push pull",
   789                             biasing[bias],
   790                             speeds[speed], "speed");
   791                  break;
   792  
   793          /* alternate */
   794          case 2:
   795                  drive = stm32_pconf_get_driving(bank, offset);
   796                  speed = stm32_pconf_get_speed(bank, offset);
   797                  seq_printf(s, "%d - %s -%s", alt,
   798                             drive ? "open drain" : "push pull",
   799                             biasing[bias],
   800                             speeds[speed], "speed");

Yup.  Too many arguments.  Also do you want a space between "-%s"?

   801                  break;
   802  
   803          /* analog */
   804          case 3:
   805                  break;
   806          }

regards,
dan carpenter

             reply	other threads:[~2016-05-17  7:32 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-17  7:31 Dan Carpenter [this message]
2016-05-17  7:40 ` pinctrl: stm32: Implement .pin_config_dbg_show() Patrice Chotard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160517073152.GB10872@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=linux-gpio@vger.kernel.org \
    --cc=patrice.chotard@st.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).