i386/pc: factor out cxl range start to helper
authorJoao Martins <joao.m.martins@oracle.com>
Tue, 19 Jul 2022 17:00:09 +0000 (18:00 +0100)
committerMichael S. Tsirkin <mst@redhat.com>
Tue, 26 Jul 2022 14:40:58 +0000 (10:40 -0400)
commit42bed0712725ce338fc1cad725c3d9cf5cf443dc
tree49af67bb10149f2f6264cf0f4efdc3b37ecebe3a
parent55668e409bcaf04e6af7acb44037d5f18c6b786e
i386/pc: factor out cxl range start to helper

Factor out the calculation of the base address of the memory region.
It will be used later on for the cxl range end counterpart calculation
and as well in pc_memory_init() CXL memory region initialization, thus
avoiding duplication.

Cc: Jonathan Cameron <jonathan.cameron@huawei.com>
Signed-off-by: Joao Martins <joao.m.martins@oracle.com>
Acked-by: Igor Mammedov <imammedo@redhat.com>
Message-Id: <20220719170014.27028-7-joao.m.martins@oracle.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/i386/pc.c