xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] Cleanup to tools/tests
@ 2021-01-13 12:34 Andrew Cooper
  2021-01-13 12:34 ` [PATCH 1/3] tools/tests: Drop obsolete running scripts Andrew Cooper
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Andrew Cooper @ 2021-01-13 12:34 UTC (permalink / raw)
  To: Xen-devel
  Cc: Andrew Cooper, Andrew Cooper, George Dunlap, Ian Jackson,
	Jan Beulich, Stefano Stabellini, Wei Liu, Julien Grall,
	Tamas K Lengyel

Move two non-test things out of tests/ and drop some obsolete infrastructure.

Andrew Cooper (3):
  tools/tests: Drop obsolete running scripts
  tools: Move xen-access from tests/ to misc/
  tools: Move memshrtool from tests/ to misc/

 .gitignore                                         |  5 --
 tools/misc/.gitignore                              |  2 +
 tools/misc/Makefile                                |  8 +++
 tools/{tests/xen-access => misc}/xen-access.c      |  1 +
 .../memshrtool.c => misc/xen-memshare-tool.c}      |  0
 tools/tests/Makefile                               |  5 --
 tools/tests/mem-sharing/Makefile                   | 31 -----------
 tools/tests/run_tests.sh                           | 61 ----------------------
 tools/tests/utests/run_all_tests.py                | 23 --------
 tools/tests/xen-access/Makefile                    | 33 ------------
 10 files changed, 11 insertions(+), 158 deletions(-)
 rename tools/{tests/xen-access => misc}/xen-access.c (99%)
 rename tools/{tests/mem-sharing/memshrtool.c => misc/xen-memshare-tool.c} (100%)
 delete mode 100644 tools/tests/mem-sharing/Makefile
 delete mode 100644 tools/tests/run_tests.sh
 delete mode 100644 tools/tests/utests/run_all_tests.py
 delete mode 100644 tools/tests/xen-access/Makefile

-- 
2.11.0



^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 1/3] tools/tests: Drop obsolete running scripts
  2021-01-13 12:34 [PATCH 0/3] Cleanup to tools/tests Andrew Cooper
@ 2021-01-13 12:34 ` Andrew Cooper
  2021-01-13 13:03   ` Ian Jackson
  2021-01-13 12:34 ` [PATCH 2/3] tools: Move xen-access from tests/ to misc/ Andrew Cooper
  2021-01-13 12:34 ` [PATCH 3/3] tools: Move memshrtool " Andrew Cooper
  2 siblings, 1 reply; 12+ messages in thread
From: Andrew Cooper @ 2021-01-13 12:34 UTC (permalink / raw)
  To: Xen-devel; +Cc: Andrew Cooper, Andrew Cooper, Ian Jackson

The python unit tests were dropped in Xen 4.12 due to being obsolete, but the
scripts to run the tests were missed.  Clean up .gitignore as well

Also drop the libxenctrl {C,LD}FLAGS adjustments in the Makefile.  This logic
isn't used, and isn't appropriate even in principle, as there are tests in
here which don't want to use libxenctrl.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
---
CC: Ian Jackson <iwj@xenproject.org>
---
 .gitignore                          |  3 --
 tools/tests/Makefile                |  3 --
 tools/tests/run_tests.sh            | 61 -------------------------------------
 tools/tests/utests/run_all_tests.py | 23 --------------
 4 files changed, 90 deletions(-)
 delete mode 100644 tools/tests/run_tests.sh
 delete mode 100644 tools/tests/utests/run_all_tests.py

diff --git a/.gitignore b/.gitignore
index b169d78ed7..1b54ea3111 100644
--- a/.gitignore
+++ b/.gitignore
@@ -274,9 +274,6 @@ tools/tests/x86_emulator/x86_emulate
 tools/tests/x86_emulator/xop*.[ch]
 tools/tests/xen-access/xen-access
 tools/tests/xenstore/xs-test
-tools/tests/regression/installed/*
-tools/tests/regression/build/*
-tools/tests/regression/downloads/*
 tools/tests/mem-sharing/memshrtool
 tools/tests/mce-test/tools/xen-mceinj
 tools/tests/vpci/list.h
diff --git a/tools/tests/Makefile b/tools/tests/Makefile
index ed3bed404b..9077fa14d3 100644
--- a/tools/tests/Makefile
+++ b/tools/tests/Makefile
@@ -1,9 +1,6 @@
 XEN_ROOT = $(CURDIR)/../..
 include $(XEN_ROOT)/tools/Rules.mk
 
-CFLAGS  += $(CFLAGS_libxenctrl)
-LDLIBS += $(LDLIBS_libxenctrl)
-
 SUBDIRS-y :=
 SUBDIRS-$(CONFIG_X86) += cpu-policy
 SUBDIRS-$(CONFIG_X86) += mce-test
diff --git a/tools/tests/run_tests.sh b/tools/tests/run_tests.sh
deleted file mode 100644
index c492876b4b..0000000000
--- a/tools/tests/run_tests.sh
+++ /dev/null
@@ -1,61 +0,0 @@
-#!/bin/bash
-#
-# This runs the available unit-tests with all different supported
-# python versions.
-# 
-# To run this this must be 'cd'ed to the tests directory.
-#
-
-ENABLE_UNSUPPORTED=0
-
-function usage()
-{
-    printf "Usage: %s: [-u]\n" $0
-    printf "   -u: run test with unsupported python versions also\n"
-}
-
-function run_one_test()
-{
-    PYTHON=$1
-    PYTHON_EXECUTABLE=`echo $PYTHON | tr -d "-"`
-    echo "+++ Running tests with $PYTHON"
-    export LD_LIBRARY_PATH=./regression/installed/$PYTHON/lib
-    ./regression/installed/$PYTHON/bin/$PYTHON_EXECUTABLE \
-	utests/run_all_tests.py
-    echo "--- Finished tests with $PYTHON"
-}
-
-function run_all_tests()
-{
-    for PYTHON in $@;
-    do
-	run_one_test $PYTHON
-    done
-}
-
-while getopts u name
-do
-    case $name in
-	h)  usage; exit 0;;
-	u)  ENABLE_UNSUPPORTED=1;;
-	?)  usage; exit 2;;
-    esac
-done
-
-# Build the different python versions
-(cd regression && make -j4 runtime-environment)
-
-# Supported: when an unit test fails this should be seen as an error
-PYTHON_SUPPORTED="python-2.4 python-2.5 python-2.6"
-# Unsupported: failure should be seen as a hint
-PYTHON_UNSUPPORTED="python-3.1"
-
-export PYTHONPATH=`echo $PWD/../python/build/lib.*`:$PWD
-
-set -e
-run_all_tests $PYTHON_SUPPORTED
-
-if test $ENABLE_UNSUPPORTED -eq 1
-then
-    run_all_tests $PYTHON_UNSUPPORTED
-fi
diff --git a/tools/tests/utests/run_all_tests.py b/tools/tests/utests/run_all_tests.py
deleted file mode 100644
index 7318c81ff2..0000000000
--- a/tools/tests/utests/run_all_tests.py
+++ /dev/null
@@ -1,23 +0,0 @@
-#============================================================================
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of version 2.1 of the GNU Lesser General Public
-# License as published by the Free Software Foundation.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; If not, see <http://www.gnu.org/licenses/>.
-#============================================================================
-# Copyright (C) 2009 flonatel GmbH & Co. KG
-#============================================================================
-
-import unittest
-
-suite = unittest.TestSuite([])
-
-if __name__ == "__main__":
-    testresult = unittest.TextTestRunner(verbosity=3).run(suite)
-
-- 
2.11.0



^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 2/3] tools: Move xen-access from tests/ to misc/
  2021-01-13 12:34 [PATCH 0/3] Cleanup to tools/tests Andrew Cooper
  2021-01-13 12:34 ` [PATCH 1/3] tools/tests: Drop obsolete running scripts Andrew Cooper
@ 2021-01-13 12:34 ` Andrew Cooper
  2021-01-13 13:03   ` Ian Jackson
  2021-01-13 18:50   ` Tamas K Lengyel
  2021-01-13 12:34 ` [PATCH 3/3] tools: Move memshrtool " Andrew Cooper
  2 siblings, 2 replies; 12+ messages in thread
From: Andrew Cooper @ 2021-01-13 12:34 UTC (permalink / raw)
  To: Xen-devel; +Cc: Andrew Cooper, Andrew Cooper, Ian Jackson, Tamas K Lengyel

xen-access is a tool for a human to use, rather than a test.  Move it
into misc/ as a more appropriate location to live.

Move the -DXC_WANT_COMPAT_DEVICEMODEL_API from CFLAGS into xen-access.c itself
to avoid adding Makefile complexity.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
---
CC: Ian Jackson <iwj@xenproject.org>
CC: Tamas K Lengyel <tamas@tklengyel.com>
---
 .gitignore                                    |  1 -
 tools/misc/.gitignore                         |  1 +
 tools/misc/Makefile                           |  4 ++++
 tools/{tests/xen-access => misc}/xen-access.c |  1 +
 tools/tests/Makefile                          |  1 -
 tools/tests/xen-access/Makefile               | 33 ---------------------------
 6 files changed, 6 insertions(+), 35 deletions(-)
 rename tools/{tests/xen-access => misc}/xen-access.c (99%)
 delete mode 100644 tools/tests/xen-access/Makefile

diff --git a/.gitignore b/.gitignore
index 1b54ea3111..630bdf5b99 100644
--- a/.gitignore
+++ b/.gitignore
@@ -272,7 +272,6 @@ tools/tests/x86_emulator/*sse*.[ch]
 tools/tests/x86_emulator/test_x86_emulator
 tools/tests/x86_emulator/x86_emulate
 tools/tests/x86_emulator/xop*.[ch]
-tools/tests/xen-access/xen-access
 tools/tests/xenstore/xs-test
 tools/tests/mem-sharing/memshrtool
 tools/tests/mce-test/tools/xen-mceinj
diff --git a/tools/misc/.gitignore b/tools/misc/.gitignore
index c5fe2cfccd..e332ed4ec7 100644
--- a/tools/misc/.gitignore
+++ b/tools/misc/.gitignore
@@ -1 +1,2 @@
+xen-access
 xen-ucode
diff --git a/tools/misc/Makefile b/tools/misc/Makefile
index 7d37f297a9..612b7002e5 100644
--- a/tools/misc/Makefile
+++ b/tools/misc/Makefile
@@ -30,6 +30,7 @@ INSTALL_SBIN                   += xenlockprof
 INSTALL_SBIN                   += xenperf
 INSTALL_SBIN                   += xenpm
 INSTALL_SBIN                   += xenwatchdogd
+INSTALL_SBIN                   += xen-access
 INSTALL_SBIN                   += xen-livepatch
 INSTALL_SBIN                   += xen-diag
 INSTALL_SBIN += $(INSTALL_SBIN-y)
@@ -73,6 +74,9 @@ clean:
 .PHONY: distclean
 distclean: clean
 
+xen-access: xen-access.o
+	$(CC) $(LDFLAGS) -o $@ $< $(LDLIBS_libxenctrl) $(LDLIBS_libxenguest) $(LDLIBS_libxenevtchn) $(APPEND_LDFLAGS)
+
 xen-cpuid: xen-cpuid.o
 	$(CC) $(LDFLAGS) -o $@ $< $(LDLIBS_libxenctrl) $(LDLIBS_libxenguest) $(APPEND_LDFLAGS)
 
diff --git a/tools/tests/xen-access/xen-access.c b/tools/misc/xen-access.c
similarity index 99%
rename from tools/tests/xen-access/xen-access.c
rename to tools/misc/xen-access.c
index 1ab4f6705f..4bbef0bd2e 100644
--- a/tools/tests/xen-access/xen-access.c
+++ b/tools/misc/xen-access.c
@@ -38,6 +38,7 @@
 #include <sys/mman.h>
 #include <poll.h>
 
+#define XC_WANT_COMPAT_DEVICEMODEL_API
 #include <xenctrl.h>
 #include <xenevtchn.h>
 #include <xen/vm_event.h>
diff --git a/tools/tests/Makefile b/tools/tests/Makefile
index 9077fa14d3..771715be0f 100644
--- a/tools/tests/Makefile
+++ b/tools/tests/Makefile
@@ -8,7 +8,6 @@ SUBDIRS-y += mem-sharing
 ifneq ($(clang),y)
 SUBDIRS-$(CONFIG_X86) += x86_emulator
 endif
-SUBDIRS-y += xen-access
 SUBDIRS-y += xenstore
 SUBDIRS-y += depriv
 SUBDIRS-$(CONFIG_HAS_PCI) += vpci
diff --git a/tools/tests/xen-access/Makefile b/tools/tests/xen-access/Makefile
deleted file mode 100644
index 131c9f375d..0000000000
--- a/tools/tests/xen-access/Makefile
+++ /dev/null
@@ -1,33 +0,0 @@
-XEN_ROOT=$(CURDIR)/../../..
-include $(XEN_ROOT)/tools/Rules.mk
-
-CFLAGS += -Werror
-CFLAGS += -DXC_WANT_COMPAT_DEVICEMODEL_API
-
-CFLAGS += $(CFLAGS_libxenctrl)
-CFLAGS += $(CFLAGS_libxenguest)
-CFLAGS += $(CFLAGS_libxenevtchn)
-CFLAGS += $(CFLAGS_xeninclude)
-
-TARGETS-y := xen-access
-TARGETS := $(TARGETS-y)
-
-.PHONY: all
-all: build
-
-.PHONY: build
-build: $(TARGETS)
-
-.PHONY: clean
-clean:
-	$(RM) *.o $(TARGETS) *~ $(DEPS_RM)
-
-.PHONY: distclean
-distclean: clean
-
-xen-access: xen-access.o Makefile
-	$(CC) -o $@ $< $(LDFLAGS) $(LDLIBS_libxenctrl) $(LDLIBS_libxenguest) $(LDLIBS_libxenevtchn)
-
-install uninstall:
-
--include $(DEPS_INCLUDE)
-- 
2.11.0



^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 3/3] tools: Move memshrtool from tests/ to misc/
  2021-01-13 12:34 [PATCH 0/3] Cleanup to tools/tests Andrew Cooper
  2021-01-13 12:34 ` [PATCH 1/3] tools/tests: Drop obsolete running scripts Andrew Cooper
  2021-01-13 12:34 ` [PATCH 2/3] tools: Move xen-access from tests/ to misc/ Andrew Cooper
@ 2021-01-13 12:34 ` Andrew Cooper
  2021-01-13 13:01   ` Ian Jackson
  2 siblings, 1 reply; 12+ messages in thread
From: Andrew Cooper @ 2021-01-13 12:34 UTC (permalink / raw)
  To: Xen-devel; +Cc: Andrew Cooper, Andrew Cooper, Ian Jackson

memshrtool is a tool for a human to use, rather than a test.  Move it into
misc/ as a more appropriate location to live.  Also rename it to
xen-memshare-tool

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
---
CC: Ian Jackson <iwj@xenproject.org>

I'm debating dropping the tool suffix, because I don't think that's much help
either.
---
 .gitignore                                         |  1 -
 tools/misc/.gitignore                              |  1 +
 tools/misc/Makefile                                |  4 +++
 .../memshrtool.c => misc/xen-memshare-tool.c}      |  0
 tools/tests/Makefile                               |  1 -
 tools/tests/mem-sharing/Makefile                   | 31 ----------------------
 6 files changed, 5 insertions(+), 33 deletions(-)
 rename tools/{tests/mem-sharing/memshrtool.c => misc/xen-memshare-tool.c} (100%)
 delete mode 100644 tools/tests/mem-sharing/Makefile

diff --git a/.gitignore b/.gitignore
index 630bdf5b99..35957cc21f 100644
--- a/.gitignore
+++ b/.gitignore
@@ -273,7 +273,6 @@ tools/tests/x86_emulator/test_x86_emulator
 tools/tests/x86_emulator/x86_emulate
 tools/tests/x86_emulator/xop*.[ch]
 tools/tests/xenstore/xs-test
-tools/tests/mem-sharing/memshrtool
 tools/tests/mce-test/tools/xen-mceinj
 tools/tests/vpci/list.h
 tools/tests/vpci/vpci.[hc]
diff --git a/tools/misc/.gitignore b/tools/misc/.gitignore
index e332ed4ec7..a01bc5b5b5 100644
--- a/tools/misc/.gitignore
+++ b/tools/misc/.gitignore
@@ -1,2 +1,3 @@
 xen-access
+xen-memshare-tool
 xen-ucode
diff --git a/tools/misc/Makefile b/tools/misc/Makefile
index 612b7002e5..fbe010a55a 100644
--- a/tools/misc/Makefile
+++ b/tools/misc/Makefile
@@ -32,6 +32,7 @@ INSTALL_SBIN                   += xenpm
 INSTALL_SBIN                   += xenwatchdogd
 INSTALL_SBIN                   += xen-access
 INSTALL_SBIN                   += xen-livepatch
+INSTALL_SBIN                   += xen-memshare-tool
 INSTALL_SBIN                   += xen-diag
 INSTALL_SBIN += $(INSTALL_SBIN-y)
 
@@ -86,6 +87,9 @@ xen-hvmctx: xen-hvmctx.o
 xen-hvmcrash: xen-hvmcrash.o
 	$(CC) $(LDFLAGS) -o $@ $< $(LDLIBS_libxenctrl) $(APPEND_LDFLAGS)
 
+xen-memshare-tool: xen-memshare-tool.o
+	$(CC) $(LDFLAGS) -o $@ $< $(LDLIBS_libxenctrl) $(APPEND_LDFLAGS)
+
 xenperf: xenperf.o
 	$(CC) $(LDFLAGS) -o $@ $< $(LDLIBS_libxenctrl) $(APPEND_LDFLAGS)
 
diff --git a/tools/tests/mem-sharing/memshrtool.c b/tools/misc/xen-memshare-tool.c
similarity index 100%
rename from tools/tests/mem-sharing/memshrtool.c
rename to tools/misc/xen-memshare-tool.c
diff --git a/tools/tests/Makefile b/tools/tests/Makefile
index 771715be0f..fc9b715951 100644
--- a/tools/tests/Makefile
+++ b/tools/tests/Makefile
@@ -4,7 +4,6 @@ include $(XEN_ROOT)/tools/Rules.mk
 SUBDIRS-y :=
 SUBDIRS-$(CONFIG_X86) += cpu-policy
 SUBDIRS-$(CONFIG_X86) += mce-test
-SUBDIRS-y += mem-sharing
 ifneq ($(clang),y)
 SUBDIRS-$(CONFIG_X86) += x86_emulator
 endif
diff --git a/tools/tests/mem-sharing/Makefile b/tools/tests/mem-sharing/Makefile
deleted file mode 100644
index 5cd96e4cc9..0000000000
--- a/tools/tests/mem-sharing/Makefile
+++ /dev/null
@@ -1,31 +0,0 @@
-XEN_ROOT=$(CURDIR)/../../..
-include $(XEN_ROOT)/tools/Rules.mk
-
-CFLAGS += -Werror
-
-CFLAGS += $(CFLAGS_libxenctrl)
-CFLAGS += $(CFLAGS_xeninclude)
-
-TARGETS-y := 
-TARGETS-$(CONFIG_X86) += memshrtool
-TARGETS := $(TARGETS-y)
-
-.PHONY: all
-all: build
-
-.PHONY: build
-build: $(TARGETS)
-
-.PHONY: clean
-clean:
-	$(RM) *.o $(TARGETS) *~ $(DEPS_RM)
-
-.PHONY: distclean
-distclean: clean
-
-memshrtool: memshrtool.o
-	$(CC) -o $@ $< $(LDFLAGS) $(LDLIBS_libxenctrl)
-
--include $(DEPS_INCLUDE)
-
-install uninstall:
-- 
2.11.0



^ permalink raw reply related	[flat|nested] 12+ messages in thread

* Re: [PATCH 3/3] tools: Move memshrtool from tests/ to misc/
  2021-01-13 12:34 ` [PATCH 3/3] tools: Move memshrtool " Andrew Cooper
@ 2021-01-13 13:01   ` Ian Jackson
  2021-01-13 13:18     ` Andrew Cooper
  0 siblings, 1 reply; 12+ messages in thread
From: Ian Jackson @ 2021-01-13 13:01 UTC (permalink / raw)
  To: Andrew Cooper; +Cc: Xen-devel, Andrew Cooper

Andrew Cooper writes ("[PATCH 3/3] tools: Move memshrtool from tests/ to misc/"):
> memshrtool is a tool for a human to use, rather than a test.  Move it into
> misc/ as a more appropriate location to live.  Also rename it to
> xen-memshare-tool

Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH 1/3] tools/tests: Drop obsolete running scripts
  2021-01-13 12:34 ` [PATCH 1/3] tools/tests: Drop obsolete running scripts Andrew Cooper
@ 2021-01-13 13:03   ` Ian Jackson
  2021-01-13 13:15     ` Andrew Cooper
  0 siblings, 1 reply; 12+ messages in thread
From: Ian Jackson @ 2021-01-13 13:03 UTC (permalink / raw)
  To: Andrew Cooper; +Cc: Xen-devel, Andrew Cooper

Andrew Cooper writes ("[PATCH 1/3] tools/tests: Drop obsolete running scripts"):
> The python unit tests were dropped in Xen 4.12 due to being obsolete, but the
> scripts to run the tests were missed.  Clean up .gitignore as well

I'm happy with this part.

> Also drop the libxenctrl {C,LD}FLAGS adjustments in the Makefile.  This logic
> isn't used, and isn't appropriate even in principle, as there are tests in
> here which don't want to use libxenctrl.

It's not clear to me that it's EBW to link all the tests to libxenctrl
simply to make the build easier.

In a later patch you add these settings back as part of a particular
test target.

I don't much mind it being done this way, and you've done the work, so
I am giving this my ack, but I just wanted to register my qualm in
case you had a second thought.

FTR, however, IMO the -DXC_WANT_COMPAT_DEVICEMODEL_API that you move
to a specific test program in a later patch is something that ought
not to be applied to all tests, so there doing it that way is
necessary - thanks.

Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>

Ian.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH 2/3] tools: Move xen-access from tests/ to misc/
  2021-01-13 12:34 ` [PATCH 2/3] tools: Move xen-access from tests/ to misc/ Andrew Cooper
@ 2021-01-13 13:03   ` Ian Jackson
  2021-01-13 18:50   ` Tamas K Lengyel
  1 sibling, 0 replies; 12+ messages in thread
From: Ian Jackson @ 2021-01-13 13:03 UTC (permalink / raw)
  To: Andrew Cooper; +Cc: Xen-devel, Andrew Cooper, Tamas K  Lengyel

Andrew Cooper writes ("[PATCH 2/3] tools: Move xen-access from tests/ to misc/"):
> xen-access is a tool for a human to use, rather than a test.  Move it
> into misc/ as a more appropriate location to live.
> 
> Move the -DXC_WANT_COMPAT_DEVICEMODEL_API from CFLAGS into xen-access.c itself
> to avoid adding Makefile complexity.

Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH 1/3] tools/tests: Drop obsolete running scripts
  2021-01-13 13:03   ` Ian Jackson
@ 2021-01-13 13:15     ` Andrew Cooper
  0 siblings, 0 replies; 12+ messages in thread
From: Andrew Cooper @ 2021-01-13 13:15 UTC (permalink / raw)
  To: Ian Jackson, Andrew Cooper; +Cc: Xen-devel

On 13/01/2021 13:03, Ian Jackson wrote:
> Andrew Cooper writes ("[PATCH 1/3] tools/tests: Drop obsolete running scripts"):
>> The python unit tests were dropped in Xen 4.12 due to being obsolete, but the
>> scripts to run the tests were missed.  Clean up .gitignore as well
> I'm happy with this part.
>
>> Also drop the libxenctrl {C,LD}FLAGS adjustments in the Makefile.  This logic
>> isn't used, and isn't appropriate even in principle, as there are tests in
>> here which don't want to use libxenctrl.
> It's not clear to me that it's EBW to link all the tests to libxenctrl
> simply to make the build easier.
>
> In a later patch you add these settings back as part of a particular
> test target.
>
> I don't much mind it being done this way, and you've done the work, so
> I am giving this my ack, but I just wanted to register my qualm in
> case you had a second thought.

These lines aren't used, because this Makefile doesn't compile/link any
code.  They don't apply to subdirs.

More than half the remaining content in tests/ really are unit tests,
and must not be linked against libxc if they want to be run outside of
dom0 (e.g. the developers build box.)

> FTR, however, IMO the -DXC_WANT_COMPAT_DEVICEMODEL_API that you move
> to a specific test program in a later patch is something that ought
> not to be applied to all tests, so there doing it that way is
> necessary - thanks.
>
> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>

Thanks,

~Andrew


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH 3/3] tools: Move memshrtool from tests/ to misc/
  2021-01-13 13:01   ` Ian Jackson
@ 2021-01-13 13:18     ` Andrew Cooper
  2021-01-13 13:33       ` Ian Jackson
  0 siblings, 1 reply; 12+ messages in thread
From: Andrew Cooper @ 2021-01-13 13:18 UTC (permalink / raw)
  To: Ian Jackson, Andrew Cooper; +Cc: Xen-devel

On 13/01/2021 13:01, Ian Jackson wrote:
> Andrew Cooper writes ("[PATCH 3/3] tools: Move memshrtool from tests/ to misc/"):
>> memshrtool is a tool for a human to use, rather than a test.  Move it into
>> misc/ as a more appropriate location to live.  Also rename it to
>> xen-memshare-tool
> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>

Thanks, but I expect that Gitlab will tell me that I broke the ARM
build, by losing a "only build this for x86"-ism.

I've folded this delta in to resolve:

diff --git a/tools/misc/Makefile b/tools/misc/Makefile
index fbe010a55a..1774ff014f 100644
--- a/tools/misc/Makefile
+++ b/tools/misc/Makefile
@@ -22,6 +22,7 @@ INSTALL_SBIN-$(CONFIG_MIGRATE) += xen-hptool
 INSTALL_SBIN-$(CONFIG_X86)     += xen-hvmcrash
 INSTALL_SBIN-$(CONFIG_X86)     += xen-hvmctx
 INSTALL_SBIN-$(CONFIG_X86)     += xen-lowmemd
+INSTALL_SBIN-$(CONFIG_X86)     += xen-memshare-tool
 INSTALL_SBIN-$(CONFIG_X86)     += xen-mfndump
 INSTALL_SBIN-$(CONFIG_X86)     += xen-ucode
 INSTALL_SBIN                   += xencov
@@ -32,7 +33,6 @@ INSTALL_SBIN                   += xenpm
 INSTALL_SBIN                   += xenwatchdogd
 INSTALL_SBIN                   += xen-access
 INSTALL_SBIN                   += xen-livepatch
-INSTALL_SBIN                   += xen-memshare-tool
 INSTALL_SBIN                   += xen-diag
 INSTALL_SBIN += $(INSTALL_SBIN-y)
 
~Andrew


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* Re: [PATCH 3/3] tools: Move memshrtool from tests/ to misc/
  2021-01-13 13:18     ` Andrew Cooper
@ 2021-01-13 13:33       ` Ian Jackson
  0 siblings, 0 replies; 12+ messages in thread
From: Ian Jackson @ 2021-01-13 13:33 UTC (permalink / raw)
  To: Andrew Cooper; +Cc: Andrew Cooper, Xen-devel

Andrew Cooper writes ("Re: [PATCH 3/3] tools: Move memshrtool from tests/ to misc/"):
> On 13/01/2021 13:01, Ian Jackson wrote:
> > Andrew Cooper writes ("[PATCH 3/3] tools: Move memshrtool from tests/ to misc/"):
> >> memshrtool is a tool for a human to use, rather than a test.  Move it into
> >> misc/ as a more appropriate location to live.  Also rename it to
> >> xen-memshare-tool
> > Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
> 
> Thanks, but I expect that Gitlab will tell me that I broke the ARM
> build, by losing a "only build this for x86"-ism.
> 
> I've folded this delta in to resolve:

Ooops.  Thanks.

Ian.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH 2/3] tools: Move xen-access from tests/ to misc/
  2021-01-13 12:34 ` [PATCH 2/3] tools: Move xen-access from tests/ to misc/ Andrew Cooper
  2021-01-13 13:03   ` Ian Jackson
@ 2021-01-13 18:50   ` Tamas K Lengyel
  2021-01-13 19:08     ` Andrew Cooper
  1 sibling, 1 reply; 12+ messages in thread
From: Tamas K Lengyel @ 2021-01-13 18:50 UTC (permalink / raw)
  To: Andrew Cooper; +Cc: Xen-devel, Andrew Cooper, Ian Jackson

On Wed, Jan 13, 2021 at 7:35 AM Andrew Cooper <andrew.cooper3@citrix.com> wrote:
>
> xen-access is a tool for a human to use, rather than a test.  Move it
> into misc/ as a more appropriate location to live.
>
> Move the -DXC_WANT_COMPAT_DEVICEMODEL_API from CFLAGS into xen-access.c itself
> to avoid adding Makefile complexity.

Acked-by: Tamas K Lengyel <tamas@tklengyel.com>


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH 2/3] tools: Move xen-access from tests/ to misc/
  2021-01-13 18:50   ` Tamas K Lengyel
@ 2021-01-13 19:08     ` Andrew Cooper
  0 siblings, 0 replies; 12+ messages in thread
From: Andrew Cooper @ 2021-01-13 19:08 UTC (permalink / raw)
  To: Tamas K Lengyel, Andrew Cooper; +Cc: Xen-devel, Ian Jackson

On 13/01/2021 18:50, Tamas K Lengyel wrote:
> On Wed, Jan 13, 2021 at 7:35 AM Andrew Cooper <andrew.cooper3@citrix.com> wrote:
>> xen-access is a tool for a human to use, rather than a test.  Move it
>> into misc/ as a more appropriate location to live.
>>
>> Move the -DXC_WANT_COMPAT_DEVICEMODEL_API from CFLAGS into xen-access.c itself
>> to avoid adding Makefile complexity.
> Acked-by: Tamas K Lengyel <tamas@tklengyel.com>

Thanks.  I'll also update the MAINTAINERs path, which I forgot to do.

~Andrew


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2021-01-13 19:08 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-13 12:34 [PATCH 0/3] Cleanup to tools/tests Andrew Cooper
2021-01-13 12:34 ` [PATCH 1/3] tools/tests: Drop obsolete running scripts Andrew Cooper
2021-01-13 13:03   ` Ian Jackson
2021-01-13 13:15     ` Andrew Cooper
2021-01-13 12:34 ` [PATCH 2/3] tools: Move xen-access from tests/ to misc/ Andrew Cooper
2021-01-13 13:03   ` Ian Jackson
2021-01-13 18:50   ` Tamas K Lengyel
2021-01-13 19:08     ` Andrew Cooper
2021-01-13 12:34 ` [PATCH 3/3] tools: Move memshrtool " Andrew Cooper
2021-01-13 13:01   ` Ian Jackson
2021-01-13 13:18     ` Andrew Cooper
2021-01-13 13:33       ` Ian Jackson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).