qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Wei Yang <richardw.yang@linux.intel.com>
To: qemu-devel@nongnu.org
Cc: mst@redhat.com, imammedo@redhat.com,
	xiaoguangrong.eric@gmail.com,
	Wei Yang <richardw.yang@linux.intel.com>
Subject: [Qemu-devel] [PATCH 3/4] nvdimm: use NVDIMM_ACPI_IO_LEN for the proper IO size
Date: Wed, 27 Feb 2019 15:51:00 +0800	[thread overview]
Message-ID: <20190227075101.6263-4-richardw.yang@linux.intel.com> (raw)
In-Reply-To: <20190227075101.6263-1-richardw.yang@linux.intel.com>

The IO range is defined to 4 bytes with NVDIMM_ACPI_IO_LEN, so it is
more proper to use this macro instead of calculating it by sizeof.

Signed-off-by: Wei Yang <richardw.yang@linux.intel.com>
---
 hw/acpi/nvdimm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/acpi/nvdimm.c b/hw/acpi/nvdimm.c
index e63a1ef15d..2457c1aa44 100644
--- a/hw/acpi/nvdimm.c
+++ b/hw/acpi/nvdimm.c
@@ -992,7 +992,7 @@ static void nvdimm_build_common_dsm(Aml *dev)
     field = aml_field(NVDIMM_DSM_IOPORT, AML_DWORD_ACC, AML_NOLOCK,
                       AML_PRESERVE);
     aml_append(field, aml_named_field(NVDIMM_DSM_NOTIFY,
-               sizeof(uint32_t) * BITS_PER_BYTE));
+               NVDIMM_ACPI_IO_LEN * BITS_PER_BYTE));
     aml_append(method, field);
 
     /*
-- 
2.19.1

  parent reply	other threads:[~2019-02-27  7:52 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-27  7:50 [Qemu-devel] [PATCH 0/4] nvdimm: clean up Wei Yang
2019-02-27  7:50 ` [Qemu-devel] [PATCH 1/4] nvdimm: fix typo in nvdimm_build_nvdimm_devices argument Wei Yang
2019-03-06 16:00   ` Igor Mammedov
2019-02-27  7:50 ` [Qemu-devel] [PATCH 2/4] nvdimm: use *function* directly instead of allocating it again Wei Yang
2019-03-06 16:02   ` Igor Mammedov
2019-02-27  7:51 ` Wei Yang [this message]
2019-03-06 16:10   ` [Qemu-devel] [PATCH 3/4] nvdimm: use NVDIMM_ACPI_IO_LEN for the proper IO size Igor Mammedov
2019-02-27  7:51 ` [Qemu-devel] [PATCH 4/4] nvdimm: build FIT in nvdimm_build_acpi Wei Yang
2019-03-06 16:14   ` Igor Mammedov
2019-03-07  3:41     ` Wei Yang

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=20190227075101.6263-4-richardw.yang@linux.intel.com \
    --to=richardw.yang@linux.intel.com \
    --cc=imammedo@redhat.com \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=xiaoguangrong.eric@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 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).