public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@linux.intel.com>
To: Dave Gordon <david.s.gordon@intel.com>, intel-gfx@lists.freedesktop.org
Cc: Akinobu Mita <akinobu.mita@gmail.com>
Subject: Re: [PATCH] lib/scatterlist: fix kerneldoc for sg_pcopy_{to, from}_buffer()
Date: Thu, 23 Apr 2015 01:13:04 +0300	[thread overview]
Message-ID: <87zj5z4xsf.fsf@intel.com> (raw)
In-Reply-To: <1429702249-4065-1-git-send-email-david.s.gordon@intel.com>

On Wed, 22 Apr 2015, Dave Gordon <david.s.gordon@intel.com> wrote:
> The kerneldoc for the functions doesn't match the code; the
> last two parameters (buflen, skip) have been transposed, which
> is confusing, especially as they're both integral types and the
> compiler won't warn about swapping them.
>
> These functions and the kerneldoc were introduced in commit:
>     df642cea lib/scatterlist: introduce sg_pcopy_from_buffer() ...
>     Author: Akinobu Mita <akinobu.mita@gmail.com>
>     Date:   Mon Jul 8 16:01:54 2013 -0700
>
>     The only difference between sg_pcopy_{from,to}_buffer() and
>     sg_copy_{from,to}_buffer() is an additional argument that
>     specifies the number of bytes to skip the SG list before
>     copying.
>
> The functions have the extra argument at the end, but the kerneldoc
> lists it in penultimate position.

Please run 'scripts/get_maintainer.pl -f lib/scatterlist.c' to get a
list of people/lists to send your patch to. Not much we can do on
intel-gfx.

BR,
Jani.


>
> Signed-off-by: Dave Gordon <david.s.gordon@intel.com>
> ---
>  lib/scatterlist.c |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/lib/scatterlist.c b/lib/scatterlist.c
> index c9f2e8c..233ebe7 100644
> --- a/lib/scatterlist.c
> +++ b/lib/scatterlist.c
> @@ -697,8 +697,8 @@ EXPORT_SYMBOL(sg_copy_to_buffer);
>   * @sgl:		 The SG list
>   * @nents:		 Number of SG entries
>   * @buf:		 Where to copy from
> - * @skip:		 Number of bytes to skip before copying
>   * @buflen:		 The number of bytes to copy
> + * @skip:		 Number of bytes to skip before copying
>   *
>   * Returns the number of copied bytes.
>   *
> @@ -715,8 +715,8 @@ EXPORT_SYMBOL(sg_pcopy_from_buffer);
>   * @sgl:		 The SG list
>   * @nents:		 Number of SG entries
>   * @buf:		 Where to copy to
> - * @skip:		 Number of bytes to skip before copying
>   * @buflen:		 The number of bytes to copy
> + * @skip:		 Number of bytes to skip before copying
>   *
>   * Returns the number of copied bytes.
>   *
> -- 
> 1.7.9.5
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

      parent reply	other threads:[~2015-04-22 22:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-22 11:30 [PATCH] lib/scatterlist: fix kerneldoc for sg_pcopy_{to, from}_buffer() Dave Gordon
2015-04-22 15:01 ` shuang.he
2015-04-22 22:13 ` Jani Nikula [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=87zj5z4xsf.fsf@intel.com \
    --to=jani.nikula@linux.intel.com \
    --cc=akinobu.mita@gmail.com \
    --cc=david.s.gordon@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    /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