mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
To: "Krzysztof Wilczyński" <kw@linux.com>
Cc: Kishon Vijay Abraham I <kishon@ti.com>,
	Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>,
	Bjorn Helgaas <bhelgaas@google.com>,
	linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] PCI: endpoint: Use sysfs_emit() in "show" functions
Date: Mon, 19 Jul 2021 23:54:52 +0900	[thread overview]
Message-ID: <af1d4c61-53ff-f4e9-a708-33251b7e6470@socionext.com> (raw)
In-Reply-To: <20210719034313.GA274232@rocinante>

Hi Krzysztof,

Thank you for reviewing.

On 2021/07/19 12:43, Krzysztof Wilczyński wrote:
> Hello Hayashi-san,
> 
> Thank you for sending the patch over!
> 
>> Convert sprintf() in sysfs "show" functions to sysfs_emit() in order to
>> check for buffer overruns in sysfs outputs.
> 
> Nice catch!

I actually executed "cat" against configfs to meet the issue and found
your solution in pci-sysfs.

> 
> A small nitpick: what you are changing here are technically not sysfs
> objects since all of these are related to configfs.  Having said that,
> configfs shares the same semantics for normal attributes with sysfs, so
> a maximum size of PAGE_SIZE applies here too, and thus sysfs_emit()
> would work fine.

Thank you for helpful information.
I understand that applying sysfs_emit() to configfs is no problem.

> 
> Thank you for taking care of this!
> 
> Reviewed-by: Krzysztof Wilczyński <kw@linux.com>
> 
> 	Krzysztof
> 
Thank you,

---
Best Regards
Kunihiko Hayashi

  reply	other threads:[~2021-07-19 14:55 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-19  2:44 Kunihiko Hayashi
2021-07-19  3:43 ` Krzysztof Wilczyński
2021-07-19 14:54   ` Kunihiko Hayashi [this message]
2021-07-19 15:18     ` Krzysztof Wilczyński
2021-07-20  1:08       ` Kunihiko Hayashi

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=af1d4c61-53ff-f4e9-a708-33251b7e6470@socionext.com \
    --to=hayashi.kunihiko@socionext.com \
    --cc=bhelgaas@google.com \
    --cc=kishon@ti.com \
    --cc=kw@linux.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lorenzo.pieralisi@arm.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®