Linux-NVME Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: keith.busch@intel.com (Keith Busch)
Subject: [PATCH] nvme-pci: fix HMB size calculation
Date: Tue, 25 Jul 2017 11:50:36 -0400	[thread overview]
Message-ID: <20170725155036.GE11979@localhost.localdomain> (raw)
In-Reply-To: <20170725154134.23338-1-hch@lst.de>

On Tue, Jul 25, 2017@05:41:34PM +0200, Christoph Hellwig wrote:
> It's possible the preferred HMB size may not be a multiple of the
> chunk_size. This patch moves len to function scope and uses that in
> the for loop increment so the last iteration doesn't cause the total
> size to exceed the allocated HMB size.
> 
> Based on an earlier patch from Keith Busch.
> 
> Signed-off-by: Christoph Hellwig <hch at lst.de>
> Reported-by: Dan Carpenter <dan.carpenter at oracle.com>
> Fixes: 87ad72a59a38 ("nvme-pci: implement host memory buffer support")

Looks good.

Reviewed-by: Keith Busch <keith.busch at intel.com>

      reply	other threads:[~2017-07-25 15:50 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-25 15:41 [PATCH] nvme-pci: fix HMB size calculation Christoph Hellwig
2017-07-25 15:50 ` Keith Busch [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=20170725155036.GE11979@localhost.localdomain \
    --to=keith.busch@intel.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