All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefano Brivio <sbrivio@redhat.com>
To: Gokce Kuler <gokcekuler@gmail.com>
Cc: outreachy-kernel@googlegroups.com, gregkh@linuxfoundation.org,
	elder@kernel.org, johan@kernel.org, mgreer@animalcreek.com,
	vaibhav.sr@gmail.com
Subject: Re: [Outreachy kernel] [PATCH] staging: greybus: quoted string split across lines
Date: Sun, 5 Apr 2020 01:31:52 +0200	[thread overview]
Message-ID: <20200405013152.2593e3ab@elisabeth> (raw)
In-Reply-To: <20200404005122.GA6315@siyah2>

Gökçe,

On Sat, 4 Apr 2020 03:51:22 +0300
Gokce Kuler <gokcekuler@gmail.com> wrote:

> Quoted string merge to upper line.
> 
> Signed-off-by: Gokce Kuler <gokcekuler@gmail.com>
> ---
>  drivers/staging/greybus/audio_manager_sysfs.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/staging/greybus/audio_manager_sysfs.c b/drivers/staging/greybus/audio_manager_sysfs.c
> index ab882cc..d7216e9 100644
> --- a/drivers/staging/greybus/audio_manager_sysfs.c
> +++ b/drivers/staging/greybus/audio_manager_sysfs.c
> @@ -18,8 +18,7 @@ static ssize_t manager_sysfs_add_store(struct kobject *kobj,
>  	struct gb_audio_manager_module_descriptor desc = { {0} };
>  
>  	int num = sscanf(buf,
> -			"name=%" GB_AUDIO_MANAGER_MODULE_NAME_LEN_SSCANF "s "
> -			"vid=%d pid=%d intf_id=%d i/p devices=0x%X o/p devices=0x%X",
> +			"name=%" GB_AUDIO_MANAGER_MODULE_NAME_LEN_SSCANF "s vid=%d pid=%d intf_id=%d i/p devices=0x%X o/p devices=0x%X",

Is this reported by...? checkpatch? Because I don't see the problem
with a sscanf().

That is, the rationale for keeping quoted strings unwrapped is that
they end up in kernel logs, and one might want to find the equivalent
point in the sources. But with a sscanf(), I'm not sure we need it.

-- 
Stefano



  reply	other threads:[~2020-04-04 23:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-04  0:51 [PATCH] staging: greybus: quoted string split across lines Gokce Kuler
2020-04-04 23:31 ` Stefano Brivio [this message]
2020-04-05  7:15 ` Greg KH
2020-04-06 10:15   ` Johan Hovold

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=20200405013152.2593e3ab@elisabeth \
    --to=sbrivio@redhat.com \
    --cc=elder@kernel.org \
    --cc=gokcekuler@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=johan@kernel.org \
    --cc=mgreer@animalcreek.com \
    --cc=outreachy-kernel@googlegroups.com \
    --cc=vaibhav.sr@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.