Linux-NVME Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: mwilck@suse.com (Martin Wilck)
Subject: [PATCH] nvmet: fix space padding in serial number
Date: Thu, 05 Apr 2018 21:35:10 +0200	[thread overview]
Message-ID: <1522956910.22625.26.camel@suse.com> (raw)
In-Reply-To: <20180405191941.318707-1-daniel.verkamp@intel.com>

On Thu, 2018-04-05@12:19 -0700, Daniel Verkamp wrote:
> Commit 42de82a8b544 previously attempted to fix this, and it did
> correctly pad the MN and FR fields with spaces, but the SN field
> still
> contains 0 bytes.  The current code fills out the first 16 bytes with
> hex2bin, leaving the last 4 bytes zeroed.  Rather than adding a lot
> of
> error-prone math to avoid overwriting SN twice, just set the whole
> thing
> to spaces up front (it's only 20 bytes).
> 
> Fixes: 42de82a8b544 ("nvmet: don't report 0-bytes in serial number")
> Signed-off-by: Daniel Verkamp <daniel.verkamp at intel.com>

Reviewed-by: Martin Wilck <mwilck at suse.com>

-- 
Dr. Martin Wilck <mwilck at suse.com>, Tel. +49 (0)911 74053 2107
SUSE Linux GmbH, GF: Felix Imend?rffer, Jane Smithard, Graham Norton
HRB 21284 (AG N?rnberg)

  reply	other threads:[~2018-04-05 19:35 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-05 19:19 [PATCH] nvmet: fix space padding in serial number Daniel Verkamp
2018-04-05 19:35 ` Martin Wilck [this message]
2018-04-05 19:50   ` Keith Busch

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=1522956910.22625.26.camel@suse.com \
    --to=mwilck@suse.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