hw/cxl: Push linking of CXL targets into i386/pc rather than in machine.c

Whilst here take the oportunity to shorten the function name.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: Ben Widawsky <ben@bwidawsk.net>
Message-Id: <20220608145440.26106-4-Jonathan.Cameron@huawei.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
Jonathan Cameron 2022-06-08 15:54:35 +01:00 committed by Michael S. Tsirkin
parent 513598050a
commit dab390ff24
6 changed files with 10 additions and 10 deletions

View file

@ -8,7 +8,7 @@
#include "hw/cxl/cxl.h"
#include "hw/cxl/cxl_host.h"
void cxl_fixed_memory_window_link_targets(Error **errp) {};
void cxl_fmws_link_targets(CXLState *stat, Error **errp) {};
void cxl_machine_init(Object *obj, CXLState *state) {};
const MemoryRegionOps cfmws_ops;

View file

@ -68,14 +68,12 @@ static void cxl_fixed_memory_window_config(CXLState *cxl_state,
return;
}
void cxl_fixed_memory_window_link_targets(Error **errp)
void cxl_fmws_link_targets(CXLState *cxl_state, Error **errp)
{
MachineState *ms = MACHINE(qdev_get_machine());
if (ms->cxl_devices_state && ms->cxl_devices_state->fixed_windows) {
if (cxl_state && cxl_state->fixed_windows) {
GList *it;
for (it = ms->cxl_devices_state->fixed_windows; it; it = it->next) {
for (it = cxl_state->fixed_windows; it; it = it->next) {
CXLFixedWindow *fw = it->data;
int i;