From patchwork Tue Nov 3 22:04:54 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiko Thiery X-Patchwork-Id: 1393467 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=busybox.net (client-ip=140.211.166.136; helo=silver.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=g9Xt0FeP; dkim-atps=neutral Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4CQkNr0MJMz9sRK for ; Wed, 4 Nov 2020 09:05:15 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 4DB77226FC; Tue, 3 Nov 2020 22:05:11 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id iroa+mEQdcQ2; Tue, 3 Nov 2020 22:05:09 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by silver.osuosl.org (Postfix) with ESMTP id B2E6C2107A; Tue, 3 Nov 2020 22:05:09 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id CF0401BF356 for ; Tue, 3 Nov 2020 22:05:08 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id C59492107A for ; Tue, 3 Nov 2020 22:05:08 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tofmGvr74Gem for ; Tue, 3 Nov 2020 22:05:08 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wm1-f65.google.com (mail-wm1-f65.google.com [209.85.128.65]) by silver.osuosl.org (Postfix) with ESMTPS id 753D4204C4 for ; Tue, 3 Nov 2020 22:05:07 +0000 (UTC) Received: by mail-wm1-f65.google.com with SMTP id p22so692460wmg.3 for ; Tue, 03 Nov 2020 14:05:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=xkrwYMdTHFkDGTuHgr1VEDMFrLbJ086is1CuJCimCqg=; b=g9Xt0FeP0hNpKnvCY6LUYKiCYQs/XmW4/6OAvzfWlbivvc3xYzDHRQXRvmu5bQ2r9e NSQxRD6DNSURmMp04rUx9CQvpYbUXz9aISDuvD9ZW/CEWDfqEO1s3orxgcEqfhobMKyL DEtDdSIePuOZgWMSG62iJc5R00nEf+/XPtKUCfuNkLmlRilNOK1GSS0c5I2duZDSetm7 7Qrr6AGVv22wg0B+TovU8i5HcfNqQn6F6TMQn8QCgHy6eKj+nfZDa84vW1YWvN6eJDoo YR0WfbpnZePlxfNYHK22oJuAtU0ES33XC732jwGyfT3RDlfOHpnsLXBcewRefrt3Y0LT krWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=xkrwYMdTHFkDGTuHgr1VEDMFrLbJ086is1CuJCimCqg=; b=GmLeMf/Szij7j/ekWxfvNMYAN+EUcZCHWbmANzW8NdDxkSlLgqAe1UNDx3fU23qerl KzyreZq78CUiDqQPUK/pBprqFZIeA/i2IST1gSK0+ow9QpqNT7RDQmy4OzcWMeS6lK44 EqLIKATKBV4ZXlBW56HyVcImv76Xo97AWp4dWoEGeYXjLUbe2cT9uWHWTG0r3DC7tnf+ neitw027eDX/Nl+q9OohIuyuND/iyEIPFQfkTMrSX+tTRGPpa/nf19vfrvkTl+uoJGVR /LtCmfbJElCwQJWJ96L8QSPiSUCOkPEKG+pPaWr9do3qx+uuK03lyTlvQ5zoDzsNKMD9 +5zQ== X-Gm-Message-State: AOAM5317858tQtiZNOqFJvoeK2A2G4PfocjEpHWLbUFtklhymv5R9vQi 7zP5nxf10H88ZiO1YpcubtP9oLDyY8N1MQ== X-Google-Smtp-Source: ABdhPJzC+nNGnu6sawPOCruWUgjezdpOhfhkRl3BOw6Xmg/of1flhPIYK91f+q/ASSh9H012m4lc8w== X-Received: by 2002:a1c:f604:: with SMTP id w4mr1259213wmc.87.1604441104927; Tue, 03 Nov 2020 14:05:04 -0800 (PST) Received: from t450s.fritz.box (ip1f1312b9.dynamic.kabel-deutschland.de. [31.19.18.185]) by smtp.gmail.com with ESMTPSA id c2sm89274wmf.47.2020.11.03.14.05.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 Nov 2020 14:05:04 -0800 (PST) From: Heiko Thiery To: buildroot@buildroot.org Date: Tue, 3 Nov 2020 23:04:54 +0100 Message-Id: <20201103220454.12557-1-heiko.thiery@gmail.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Subject: [Buildroot] [PATCH 1/1] package/rt-tests: fix build issue for unsupported architectures X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Heiko Thiery , Thomas Petazzoni Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Release v1.9 introduced the oslat tool that only builds for supported architectures (i386, x86_64, PPC64) and leads to a build failure for the whole suite. An upstream patch changes this build error to a runtime warning. Fixes: - http://autobuild.buildroot.net/results/72322cf7239a91211b0be74c01b55873340763f8 Signed-off-by: Heiko Thiery --- ...-Allow-build-for-not-supported-archs.patch | 52 +++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 package/rt-tests/0002-rt-tests-oslat-Allow-build-for-not-supported-archs.patch diff --git a/package/rt-tests/0002-rt-tests-oslat-Allow-build-for-not-supported-archs.patch b/package/rt-tests/0002-rt-tests-oslat-Allow-build-for-not-supported-archs.patch new file mode 100644 index 0000000000..96b36d60dd --- /dev/null +++ b/package/rt-tests/0002-rt-tests-oslat-Allow-build-for-not-supported-archs.patch @@ -0,0 +1,52 @@ +From 165b597e3003c6870f5980e8902014d9344e6cf3 Mon Sep 17 00:00:00 2001 +From: Peter Xu +Date: Thu, 1 Oct 2020 14:47:26 -0400 +Subject: [PATCH] rt-tests: oslat: Allow build for not supported archs + +Now rt-tests won't build for archs other than x86/i386/ppc64 after oslat is +merged. Instead of failing the build, let's make it pass. However, whenever +oslat is executed, instead of running the real program, dump an error message, +so that people can try to implement the frc() function for it when there's a +real need for the new arch. + +Signed-off-by: Peter Xu +Signed-off-by: John Kacur + +[Taken from: +https://git.kernel.org/pub/scm/utils/rt-tests/rt-tests.git/commit/src/oslat/oslat.c?h=unstable/devel/latest&id=165b597e3003c6870f5980e8902014d9344e6cf3] +Signed-off-by: Heiko Thiery +--- + src/oslat/oslat.c | 10 +++++++++- + 1 file changed, 9 insertions(+), 1 deletion(-) + +diff --git a/src/oslat/oslat.c b/src/oslat/oslat.c +index f1a82f2..a8b6155 100644 +--- a/src/oslat/oslat.c ++++ b/src/oslat/oslat.c +@@ -69,7 +69,9 @@ static inline void frc(uint64_t *pval) + __asm__ __volatile__("mfspr %0, 268\n" : "=r" (*pval)); + } + # else +-# error Need frc() for this platform. ++# define relax() do { } while (0) ++# define frc(x) ++# define FRC_MISSING + # endif + #else + # error Need to add support for this compiler. +@@ -810,6 +812,12 @@ int main(int argc, char *argv[]) + int i, n_cores; + cpu_set_t cpu_set; + ++#ifdef FRC_MISSING ++ printf("This architecture is not yet supported. " ++ "Please implement frc() function first for %s.\n", argv[0]); ++ return 0; ++#endif ++ + CPU_ZERO(&cpu_set); + + g.app_name = argv[0]; +-- +2.20.1 +