From: Dan Carpenter <dan.carpenter@oracle.com>
To: Andrew Jye Shih Chuang <andrewjschuang@gmail.com>
Cc: William Hubbs <w.d.hubbs@gmail.com>,
Chris Brannon <chris@the-brannons.com>,
Kirk Reiser <kirk@reisers.ca>,
Samuel Thibault <samuel.thibault@ens-lyon.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
speakup@linux-speakup.org, devel@driverdev.osuosl.org,
linux-kernel@vger.kernel.org,
lkcamp-request@lists.libreplanetbr.org
Subject: Re: [PATCH] staging: speakup: separate 80+ chars lines.
Date: Thu, 19 Apr 2018 10:51:17 +0300 [thread overview]
Message-ID: <20180419075117.bc3ppzxqhrbl7blg@mwanda> (raw)
In-Reply-To: <5ad83b71.1c69fb81.f8458.0d85@mx.google.com>
On Thu, Apr 19, 2018 at 03:47:10AM -0300, Andrew Jye Shih Chuang wrote:
> Increase readability of code following the Kernel coding style by breaking long lines and thus eliminating the checkpatch.pl warning.
>
The commit message also needs to be wrapped. I do it at 72 characters
like an email. Roughly around the 70 character mark is fine.
> @@ -1233,7 +1234,8 @@ int spk_set_key_info(const u_char *key_info, u_char *k_buffer)
> key_data_len = (states + 1) * (num_keys + 1);
> if (key_data_len + SHIFT_TBL_SIZE + 4 >= sizeof(spk_key_buf)) {
> pr_debug("too many key_infos (%d over %u)\n",
> - key_data_len + SHIFT_TBL_SIZE + 4, (unsigned int)(sizeof(spk_key_buf)));
> + key_data_len + SHIFT_TBL_SIZE + 4,
> + (unsigned int)(sizeof(spk_key_buf)));
This cast isn't needed. Just change the %u to %lu in the printk:
pr_debug("too many key_infos (%d over %lu)\n",
key_data_len + SHIFT_TBL_SIZE + 4,
sizeof(spk_key_buf));
regards,
dan carpenter
prev parent reply other threads:[~2018-04-19 7:51 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-19 6:47 Andrew Jye Shih Chuang
2018-04-19 6:55 ` Willy Tarreau
2018-04-19 7:51 ` Dan Carpenter [this message]
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=20180419075117.bc3ppzxqhrbl7blg@mwanda \
--to=dan.carpenter@oracle.com \
--cc=andrewjschuang@gmail.com \
--cc=chris@the-brannons.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=kirk@reisers.ca \
--cc=linux-kernel@vger.kernel.org \
--cc=lkcamp-request@lists.libreplanetbr.org \
--cc=samuel.thibault@ens-lyon.org \
--cc=speakup@linux-speakup.org \
--cc=w.d.hubbs@gmail.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
all inboxes | Powered by JetHome®