Received: from mail-pl1-f170.google.com (mail-pl1-f170.google.com [209.85.214.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AABF050256 for ; Tue, 28 Nov 2023 22:44:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="FUjd3wRY" Received: by mail-pl1-f170.google.com with SMTP id d9443c01a7336-1cf8e569c35so40323705ad.0 for ; Tue, 28 Nov 2023 14:44:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1701211441; x=1701816241; darn=lists.linux.dev; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=S82OeIFgLCvh256HJbJ3opR/BbBczAujBeHjSezbKYo=; b=FUjd3wRYwXIGWndy1TXaVQE+NW3Xf7F5IVJwbmKYVAJaLBW5yUPMviYsZT1NUl4BJ2 IrOR51cIxw39gz5MJzewN5slP9MG6GZSSdQVuT4zoKzUc1uJVDhFhxUur+g1PmCij1Ch yYOEiynCV4EhPd2TfaguxvvhcG9GtKsxKHP91NCuMj4k2Deiv6io+mmk1K2ENIP7wvwi yNjygZ86GuN79tU8YcwbSCmPJJyBw2l2twk6M6kP3iqyZ+OV6jYtszarRs92mEMDuEcd eBGfqG1WIGWoNFSNljFVwDVeHWSb2Jcp6K6Naevux9Vz90Zf1x4JbTZ5xg/izP2R7QH7 RUSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701211441; x=1701816241; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=S82OeIFgLCvh256HJbJ3opR/BbBczAujBeHjSezbKYo=; b=wiu2bs6hE4L/F8g51CmOElLP4f4IF7MVPMC9q7z3//cOurxNpenT0NUtr+h4TD3+G7 P173NpxZeXZeeov3alT1UgfA2rg7Cx4CYXBeXVF1FY1bJHBWHihGTgQ4O9umtDrkGa1T xKgaZDhxyV60BoaJBLq0ZV7TrvxvkVIQrRvT9vMA4btRt2NHFuOA9HXdAzUQfvoDVZR2 nVAlz2xUSJDOIk2+Zw/luV+GEG0mApDInOx/LnLplvtvLDgcGYyhwdihvMmZYXjLaG47 RCF87po3Yae4mZrv8fquAa0v8VAc0CvaHq67UPFqZzOBvanEx7y6tAHtlfYJwBEBQ/aY Chww== X-Gm-Message-State: AOJu0YyDgDVLAU8txrp6fTuY2faHTHUSawh7jXrRMi8CMWokA10M23QK hGF5x8YApHTBoL6Mm/oxdhzD75XbIso= X-Google-Smtp-Source: AGHT+IF3jKXaLesyPNAHvslgUDY0174PhsHXnQMqcVH0b1YInFVNovczFKRAHmnWtKVgptbNJjVjBw== X-Received: by 2002:a17:90b:4c91:b0:285:bd52:32df with SMTP id my17-20020a17090b4c9100b00285bd5232dfmr9072407pjb.30.1701211440876; Tue, 28 Nov 2023 14:44:00 -0800 (PST) Received: from DT.local (c-71-202-158-162.hsd1.ca.comcast.net. [71.202.158.162]) by smtp.gmail.com with ESMTPSA id s5-20020a17090a5d0500b00280469602bcsm9868120pji.2.2023.11.28.14.43.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 28 Nov 2023 14:44:00 -0800 (PST) From: nifan.cxl@gmail.com To: mcgrof@kernel.org Cc: nmtadam.samsung@gmail.com, kdevops@lists.linux.dev, jlayton@kernel.org, a.manzanares@samsung.com, Fan Ni Subject: [PATCH 0/4] CXL: add test workflow for dynamic capacity device Date: Tue, 28 Nov 2023 14:42:00 -0800 Message-ID: <20231128224331.324500-1-nifan.cxl@gmail.com> X-Mailer: git-send-email 2.42.0 Precedence: bulk X-Mailing-List: kdevops@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit From: Fan Ni The patch series add test workflow for CXL dynamic capacity device (DCD) in Qemu. Patch 1: add new options in kconfig to enable qmp interface for qemu so qemu can be launched with qmp interface enabled, which is needed for CXL test like error injection, dynamic capacity extent add/release. Patch 2: add a new cxl topology where a DCD device is directly attached to the root port of a host bridge. For the device itself, it has no static volatile or non-volatile capacity but only dynamic regions with no DC extents added yet. Path 3: add a new make command "cxl-create-dc-region" to create DC region for dynamic capacity, which is needed before dc extents can be added. We also fixed "make cxl" command as the regular cxl-mem-setup worklfow does not work for dcd device. Patch 4: add a new make command "cxl-dcd-setup" to add dc extents, and convert dynamic capacity to system ram and online it. With the patch series, we can play with DCD device in two ways, First workflow: After system bringup, run "make cxl" which will create DC region, create dax device and convert it to system ram. The other workflow: After system bringup, and if ndctl is already available in the guest, perform the following two steps: 1) make cxl-create-dc-region: create a DC region; 2) make cxl-dcd-setup: add dc extents, create dax device and convert it to system ram. Fan Ni (4): qemu: Add QMP connection option for QMP interface access CXL: Add a new topology to support DCD device emulation CXL: Add new make command to create DC region for DCD device CXL: Setup DCD device as onlined system memory playbooks/roles/cxl/defaults/main.yml | 2 + .../cxl/tasks/cxl-create-dc-region/main.yml | 27 +++++++ .../roles/cxl/tasks/cxl-dcd-setup/main.yml | 79 +++++++++++++++++++ playbooks/roles/cxl/tasks/main.yml | 16 ++++ playbooks/roles/gen_nodes/defaults/main.yml | 4 + .../roles/gen_nodes/templates/Vagrantfile.j2 | 19 ++++- scripts/gen-nodes.Makefile | 12 +++ vagrant/Kconfig | 23 ++++++ workflows/cxl/Makefile | 19 ++++- 9 files changed, 197 insertions(+), 4 deletions(-) create mode 100644 playbooks/roles/cxl/tasks/cxl-create-dc-region/main.yml create mode 100644 playbooks/roles/cxl/tasks/cxl-dcd-setup/main.yml -- 2.42.0