Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp69422rdh; Wed, 22 Nov 2023 18:50:29 -0800 (PST) X-Google-Smtp-Source: AGHT+IEokqWkU8WmErcU52yL46+ymTnLz9gp/upb/FCFqkvfTu3c3Gx1bYyOHA4gEpj5ZSEwFED2 X-Received: by 2002:a17:902:b096:b0:1cf:7666:4dd0 with SMTP id p22-20020a170902b09600b001cf76664dd0mr4515793plr.39.1700707829346; Wed, 22 Nov 2023 18:50:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700707829; cv=none; d=google.com; s=arc-20160816; b=PSy0Ywn0Dawoivk9MaEY/vFPQsPO2boA0LmL0zOP0puCeC95Ia0JA0gutNrBWjguGf fAeZBHHf40sWtuyKgEzMqgNGXNQ3nrFs0w7BXBIIAQKTKwjRAOYE685gmsrnCffDeWCU 41SasVTF3rS5CefG/wzFhcG8434g1xqFRglhuPJADxQFxzGa+1NR+5tQ9nc/2fbe5Q7i fP8FHaORSuZkpACywuO2aZASafXzOOZ1tzCaKRfVpdsnglj8T7gYan8/rxIkQ6GYJoSK fAdBIq5ZeQqu3ua2TIWaXXcDQPxxVD+Dr7CUfoN63zJ1ESSat4e/ccX56Xp585EKbyJx Kkbg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=D08p5YAHoEvBUZt7xMX5L9P22HbicVdwPxBXjnz6Npw=; fh=GbebbnE2F8e92f3kjqt0KIciPhs0CC8RnHsQtME/EHI=; b=uZLQK98vG9JBWh1JR/BsnaRM8zS9Al4i5TNvDb0rXHewlv7ABqcTFaDlworQ4tdwTR UIKvx2vdwVf20JBfv9tjhIpqBz85eCguVhv11GwRfsyOAiCOS15+0DjRgIsd4qb4dpAu uzAAGxVaN6l6FQzDInuye2hv53wajeqTWRordsySqmsfWbzD0IsKiHrKOrxEXtuBTzaH Ls4xUeDJCWRvwelEiW89d0voGpbsX3Tr32ucRN22zKtfbrIn40nn0jgvNrQnh0D0IRLP KZQnso7E48m9GYDfUJFiLEm7IriIVBjrobUNYrIDbLcEISSatWHSansMSDTUr8QWJAWM oVCg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=OEgSz4bM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id jj14-20020a170903048e00b001cf6aac6b5fsi212233plb.559.2023.11.22.18.50.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Nov 2023 18:50:29 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=OEgSz4bM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 2EA61829BC56; Wed, 22 Nov 2023 18:50:28 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232694AbjKWCuR (ORCPT + 99 others); Wed, 22 Nov 2023 21:50:17 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47636 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232615AbjKWCuQ (ORCPT ); Wed, 22 Nov 2023 21:50:16 -0500 Received: from mail-lf1-x130.google.com (mail-lf1-x130.google.com [IPv6:2a00:1450:4864:20::130]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CAFEC101; Wed, 22 Nov 2023 18:50:20 -0800 (PST) Received: by mail-lf1-x130.google.com with SMTP id 2adb3069b0e04-50aabfa1b75so511449e87.3; Wed, 22 Nov 2023 18:50:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700707819; x=1701312619; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=D08p5YAHoEvBUZt7xMX5L9P22HbicVdwPxBXjnz6Npw=; b=OEgSz4bMFRfas0c6CWJPm9GTZlMeWGgtqYRfijgTcSYSehXIpoP5OOHVUGlvpNAOJW IFsNHKJx5zJWATQP64aqh/3SbwsLUEYeSKl550vjP3fcpEWDBiK88ms/tpHY6SUr0Tkg 1HVIb8Ruce6Sa/qcnK0/kn1DYPvy4eia8TDLKl5v2QnEXfVxeEqxxF0wamcRjTS+N6Eg wDiNgaDuxawpTiaWyIjttTBKcO+aJsMMq0BX3KrE6D0CHG6AUOjxTHx6UH1hgbQ38o4A 72xSDKaM5TTlOT0dkUCaL998L5acBL4HFreEOo909l40e6dPfVeU9PIcjZaAU7fPBBIJ dECw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700707819; x=1701312619; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=D08p5YAHoEvBUZt7xMX5L9P22HbicVdwPxBXjnz6Npw=; b=IIrdNTi6XwzwDizv6IWa6ov/5eloIANdKsYZYlmgvFCYyUyn8K05t2GoUBEp16DuAj bxAGmXkSnrdAizV3LLDJ/GUCzncDX/dhrB2EZVxLARm4hjCgVYk4YelPxL2Vq8RB7DK9 bpPslT099Ah33Z8rmCrnSQ3x/1S2TDkNx3bwA/zlf/+QiF2XvWdbVUpVf1z3C4RRnmxB AehIMpeSx5ZST3b2TsGu7ftahfXRy66ABpjxOcqd1EmkOwiO4mpDippPo2cY1L6JVs1A fpwqF77kefkaEx+BohiL6Tfdy38GTY7zr176tATiEdcnFkBABoEyqbQiFpiWW96FG0Me pPkQ== X-Gm-Message-State: AOJu0YzRaX1T4kRie7xWxRyxzFyw1LjHGyGfJYWJea82ix3EmGfUu1dx D5YaipouN01XPlPxB34tWJQPcFjMdbBXYWvrdE0= X-Received: by 2002:a05:6512:158e:b0:507:a766:ad27 with SMTP id bp14-20020a056512158e00b00507a766ad27mr4204558lfb.16.1700707818800; Wed, 22 Nov 2023 18:50:18 -0800 (PST) MIME-Version: 1.0 References: <20231003-d44206f71d0b22e539833697@orel> <20231122-b471122622059496906801c1@orel> In-Reply-To: <20231122-b471122622059496906801c1@orel> From: Haibo Xu Date: Thu, 23 Nov 2023 10:50:07 +0800 Message-ID: Subject: Re: [PATCH v3 2/9] KVM: selftests: Unify the makefile rule for split targets To: Andrew Jones Cc: Haibo Xu , Paul Walmsley , Palmer Dabbelt , Albert Ou , Paolo Bonzini , Shuah Khan , Marc Zyngier , Oliver Upton , James Morse , Suzuki K Poulose , Zenghui Yu , Anup Patel , Atish Patra , Sean Christopherson , Ricardo Koller , Vishal Annapurve , Vipin Sharma , David Matlack , Aaron Lewis , Colton Lewis , Thomas Huth , linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org, kvm@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev, kvm-riscv@lists.infradead.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Wed, 22 Nov 2023 18:50:28 -0800 (PST) On Wed, Nov 22, 2023 at 4:13=E2=80=AFPM Andrew Jones wrote: > > On Sun, Oct 08, 2023 at 10:58:57AM +0800, Haibo Xu wrote: > > On Tue, Oct 3, 2023 at 6:28=E2=80=AFPM Andrew Jones wrote: > > > > > > On Thu, Sep 14, 2023 at 09:36:56AM +0800, Haibo Xu wrote: > > > > A separate makefile rule was used for split targets which was added > > > > in patch(KVM: arm64: selftests: Split get-reg-list test code). This > > > > could be avoided by minor changes to the recipes of current rule. > > > > > > > > Signed-off-by: Haibo Xu > > > > --- > > > > tools/testing/selftests/kvm/Makefile | 6 ++---- > > > > 1 file changed, 2 insertions(+), 4 deletions(-) > > > > > > > > diff --git a/tools/testing/selftests/kvm/Makefile b/tools/testing/s= elftests/kvm/Makefile > > > > index a3bb36fb3cfc..7972269e8c5f 100644 > > > > --- a/tools/testing/selftests/kvm/Makefile > > > > +++ b/tools/testing/selftests/kvm/Makefile > > > > @@ -249,13 +249,10 @@ TEST_DEP_FILES +=3D $(patsubst %.o, %.d, $(SP= LIT_TESTS_OBJS)) > > > > -include $(TEST_DEP_FILES) > > > > > > > > $(TEST_GEN_PROGS) $(TEST_GEN_PROGS_EXTENDED): %: %.o > > > > - $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) $(TARGET_ARCH) $< $(LI= BKVM_OBJS) $(LDLIBS) -o $@ > > > > + $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) $(TARGET_ARCH) $^ $(LD= LIBS) -o $@ > > > > $(TEST_GEN_OBJ): $(OUTPUT)/%.o: %.c > > > > $(CC) $(CFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c $< -o $@ > > > > > > > > -$(SPLIT_TESTS_TARGETS): %: %.o $(SPLIT_TESTS_OBJS) > > > > - $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) $(TARGET_ARCH) $^ $(LD= LIBS) -o $@ > > > > - > > > > EXTRA_CLEAN +=3D $(LIBKVM_OBJS) $(TEST_DEP_FILES) $(TEST_GEN_OBJ) = $(SPLIT_TESTS_OBJS) cscope.* > > > > > > > > x :=3D $(shell mkdir -p $(sort $(dir $(LIBKVM_C_OBJ) $(LIBKVM_S_OB= J)))) > > > > @@ -274,6 +271,7 @@ $(LIBKVM_STRING_OBJ): $(OUTPUT)/%.o: %.c > > > > x :=3D $(shell mkdir -p $(sort $(dir $(TEST_GEN_PROGS)))) > > > > $(TEST_GEN_PROGS): $(LIBKVM_OBJS) > > > > $(TEST_GEN_PROGS_EXTENDED): $(LIBKVM_OBJS) > > > > +$(SPLIT_TESTS_TARGETS): $(OUTPUT)/%: $(ARCH_DIR)/%.o > > > > > > > > cscope: include_paths =3D $(LINUX_TOOL_INCLUDE) $(LINUX_HDR_PATH) = include lib .. > > > > cscope: > > > > -- > > > > 2.34.1 > > > > > > > > > > I just noticed that with and without this patch we're building the > > > arch-specific part in tools/testing/selftests/kvm/riscv even when we = have > > > an $(OUTPUT) directory (e.g. O=3Dbuild). Those build artifacts should= be in > > > build/kselftest/kvm/riscv instead. > > > > > > > Thanks for pointing it out. I will have a look in next week! > > > > Hi Haibo, > > Paolo just fixed this > > https://lore.kernel.org/all/20231121165631.1170797-1-pbonzini@redhat.com/ > Thanks for the info! I will rebase the patch set in next version. Thanks, Haibo > Thanks, > drew