linux-edac.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: Borislav Petkov <bp@alien8.de>,
	Xiongfeng Wang <wangxiongfeng2@huawei.com>
Cc: mchehab@kernel.org, tony.luck@intel.com,
	linux-edac@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] EDAC/mc_sysfs: Add missing newlines when printing {max,dimm}_location
Date: Fri, 18 Sep 2020 06:31:04 -0700	[thread overview]
Message-ID: <6f6be4f64a016c5be82b1fd21ce2402653a8961b.camel@perches.com> (raw)
In-Reply-To: <20200918071227.GA6585@zn.tnic>

On Fri, 2020-09-18 at 09:12 +0200, Borislav Petkov wrote:
> On Fri, Sep 18, 2020 at 10:37:28AM +0800, Xiongfeng Wang wrote:
> > Thansk a lot. I will send another version. Also I will change the
> > 'snprintf' in 'dimmdev_location_show()' to 'scnprintf'
> 
> No need to send another one - I have everything locally and just amended
> it.

A generic question about sysfs is whether or not the
PAGE_SIZE buf output should be newline terminated or
not if an the buffer is completely filled and the
desired output cannot be newline terminated.

Likely not.

NUL termination without newline should be enough to
indicate overrun.



      reply	other threads:[~2020-09-18 13:31 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-14  2:48 [PATCH v2] EDAC/mc_sysfs: Add missing newlines when printing {max,dimm}_location Xiongfeng Wang
2020-09-16 17:00 ` Borislav Petkov
2020-09-17 11:38   ` Xiongfeng Wang
2020-09-17 15:28     ` Joe Perches
2020-09-17 16:25     ` Borislav Petkov
2020-09-18  2:37       ` Xiongfeng Wang
2020-09-18  7:12         ` Borislav Petkov
2020-09-18 13:31           ` Joe Perches [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=6f6be4f64a016c5be82b1fd21ce2402653a8961b.camel@perches.com \
    --to=joe@perches.com \
    --cc=bp@alien8.de \
    --cc=linux-edac@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=tony.luck@intel.com \
    --cc=wangxiongfeng2@huawei.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).