[libvirt] [PATCH] nodeinfodata: Remove broken symlinks

The 7c3c7f217ebae5 commit introduced a nodeinfo test. In order to do that, some parts of sysfs had to be copied. However, sysfs is full of symlinks, so during copying some symlinks broke. Remove them, as on different systems they can point to different files or be broken. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- tests/nodeinfodata/linux-f21-mustang/cpu/cpu0/subsystem | 1 - tests/nodeinfodata/linux-f21-mustang/cpu/cpu1/subsystem | 1 - tests/nodeinfodata/linux-f21-mustang/cpu/cpu2/subsystem | 1 - tests/nodeinfodata/linux-f21-mustang/cpu/cpu3/subsystem | 1 - tests/nodeinfodata/linux-f21-mustang/cpu/cpu4/subsystem | 1 - tests/nodeinfodata/linux-f21-mustang/cpu/cpu5/subsystem | 1 - tests/nodeinfodata/linux-f21-mustang/cpu/cpu6/subsystem | 1 - tests/nodeinfodata/linux-f21-mustang/cpu/cpu7/subsystem | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu0/firmware_node | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu0/subsystem | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu1/firmware_node | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu1/subsystem | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu2/firmware_node | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu2/subsystem | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu3/firmware_node | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu3/subsystem | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu4/firmware_node | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu4/subsystem | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu5/firmware_node | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu5/subsystem | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu6/firmware_node | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu6/subsystem | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu7/firmware_node | 1 - tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu7/subsystem | 1 - 24 files changed, 24 deletions(-) delete mode 120000 tests/nodeinfodata/linux-f21-mustang/cpu/cpu0/subsystem delete mode 120000 tests/nodeinfodata/linux-f21-mustang/cpu/cpu1/subsystem delete mode 120000 tests/nodeinfodata/linux-f21-mustang/cpu/cpu2/subsystem delete mode 120000 tests/nodeinfodata/linux-f21-mustang/cpu/cpu3/subsystem delete mode 120000 tests/nodeinfodata/linux-f21-mustang/cpu/cpu4/subsystem delete mode 120000 tests/nodeinfodata/linux-f21-mustang/cpu/cpu5/subsystem delete mode 120000 tests/nodeinfodata/linux-f21-mustang/cpu/cpu6/subsystem delete mode 120000 tests/nodeinfodata/linux-f21-mustang/cpu/cpu7/subsystem delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu0/firmware_node delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu0/subsystem delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu1/firmware_node delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu1/subsystem delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu2/firmware_node delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu2/subsystem delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu3/firmware_node delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu3/subsystem delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu4/firmware_node delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu4/subsystem delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu5/firmware_node delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu5/subsystem delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu6/firmware_node delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu6/subsystem delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu7/firmware_node delete mode 120000 tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu7/subsystem diff --git a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu0/subsystem b/tests/nodeinfodata/linux-f21-mustang/cpu/cpu0/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu0/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu1/subsystem b/tests/nodeinfodata/linux-f21-mustang/cpu/cpu1/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu1/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu2/subsystem b/tests/nodeinfodata/linux-f21-mustang/cpu/cpu2/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu2/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu3/subsystem b/tests/nodeinfodata/linux-f21-mustang/cpu/cpu3/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu3/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu4/subsystem b/tests/nodeinfodata/linux-f21-mustang/cpu/cpu4/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu4/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu5/subsystem b/tests/nodeinfodata/linux-f21-mustang/cpu/cpu5/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu5/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu6/subsystem b/tests/nodeinfodata/linux-f21-mustang/cpu/cpu6/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu6/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu7/subsystem b/tests/nodeinfodata/linux-f21-mustang/cpu/cpu7/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-f21-mustang/cpu/cpu7/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu0/firmware_node b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu0/firmware_node deleted file mode 120000 index 1e6224c..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu0/firmware_node +++ /dev/null @@ -1 +0,0 @@ -../../../LNXSYSTM:00/LNXSYBUS:00/ACPI0007:00 \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu0/subsystem b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu0/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu0/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu1/firmware_node b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu1/firmware_node deleted file mode 120000 index 63b63d0..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu1/firmware_node +++ /dev/null @@ -1 +0,0 @@ -../../../LNXSYSTM:00/LNXSYBUS:00/ACPI0007:01 \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu1/subsystem b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu1/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu1/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu2/firmware_node b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu2/firmware_node deleted file mode 120000 index 85914d0..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu2/firmware_node +++ /dev/null @@ -1 +0,0 @@ -../../../LNXSYSTM:00/LNXSYBUS:00/ACPI0007:02 \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu2/subsystem b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu2/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu2/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu3/firmware_node b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu3/firmware_node deleted file mode 120000 index cfa456c..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu3/firmware_node +++ /dev/null @@ -1 +0,0 @@ -../../../LNXSYSTM:00/LNXSYBUS:00/ACPI0007:03 \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu3/subsystem b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu3/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu3/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu4/firmware_node b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu4/firmware_node deleted file mode 120000 index b7ae1a3..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu4/firmware_node +++ /dev/null @@ -1 +0,0 @@ -../../../LNXSYSTM:00/LNXSYBUS:00/ACPI0007:04 \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu4/subsystem b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu4/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu4/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu5/firmware_node b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu5/firmware_node deleted file mode 120000 index b25a125..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu5/firmware_node +++ /dev/null @@ -1 +0,0 @@ -../../../LNXSYSTM:00/LNXSYBUS:00/ACPI0007:05 \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu5/subsystem b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu5/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu5/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu6/firmware_node b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu6/firmware_node deleted file mode 120000 index 1dd9cb9..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu6/firmware_node +++ /dev/null @@ -1 +0,0 @@ -../../../LNXSYSTM:00/LNXSYBUS:00/ACPI0007:06 \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu6/subsystem b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu6/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu6/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu7/firmware_node b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu7/firmware_node deleted file mode 120000 index a1a9eed..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu7/firmware_node +++ /dev/null @@ -1 +0,0 @@ -../../../LNXSYSTM:00/LNXSYBUS:00/ACPI0007:07 \ No newline at end of file diff --git a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu7/subsystem b/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu7/subsystem deleted file mode 120000 index 758c291..0000000 --- a/tests/nodeinfodata/linux-rhelsa-3.19.0-mustang/cpu/cpu7/subsystem +++ /dev/null @@ -1 +0,0 @@ -../../../../bus/cpu \ No newline at end of file -- 2.0.5

On Wed, Apr 01, 2015 at 11:01:11AM +0200, Michal Privoznik wrote:
The 7c3c7f217ebae5 commit introduced a nodeinfo test. In order to do that, some parts of sysfs had to be copied. However, sysfs is full of symlinks, so during copying some symlinks broke. Remove them, as on different systems they can point to different files or be broken.
That commit introduced only two thirds of the files, the rest is from f5c2d6 (just in case you want to update the commit message). But! Not only we don't need these, but power and uevent don't need to be there either, do they? And core_siblings(_list) is also not something we (will) use since it's just a syntax sugar for parsing data for all CPUs (that we do anyway). If you want to clean the test data a bit, I suggest you clean tests/nodeinfodata/*/cpu/cpu*/{uevent,power,topology/core_siblings*,firmware_node,subsystem} files too. That's 202 files you can get rid of.

On 01.04.2015 15:02, Martin Kletzander wrote:
On Wed, Apr 01, 2015 at 11:01:11AM +0200, Michal Privoznik wrote:
The 7c3c7f217ebae5 commit introduced a nodeinfo test. In order to do that, some parts of sysfs had to be copied. However, sysfs is full of symlinks, so during copying some symlinks broke. Remove them, as on different systems they can point to different files or be broken.
That commit introduced only two thirds of the files, the rest is from f5c2d6 (just in case you want to update the commit message).
But! Not only we don't need these, but power and uevent don't need to be there either, do they? And core_siblings(_list) is also not something we (will) use since it's just a syntax sugar for parsing data for all CPUs (that we do anyway).
If you want to clean the test data a bit, I suggest you clean tests/nodeinfodata/*/cpu/cpu*/{uevent,power,topology/core_siblings*,firmware_node,subsystem}
files too. That's 202 files you can get rid of.
good point. Although I'd leave core_siblings and topology - it's currently not used, but it may come handy when debugging our own node info code. It contains all the pieces of information that one need to reconstruct the topology. But others can be removed as you say. Will send v2. Michal

On Wed, Apr 01, 2015 at 03:30:50PM +0200, Michal Privoznik wrote:
On 01.04.2015 15:02, Martin Kletzander wrote:
On Wed, Apr 01, 2015 at 11:01:11AM +0200, Michal Privoznik wrote:
The 7c3c7f217ebae5 commit introduced a nodeinfo test. In order to do that, some parts of sysfs had to be copied. However, sysfs is full of symlinks, so during copying some symlinks broke. Remove them, as on different systems they can point to different files or be broken.
That commit introduced only two thirds of the files, the rest is from f5c2d6 (just in case you want to update the commit message).
But! Not only we don't need these, but power and uevent don't need to be there either, do they? And core_siblings(_list) is also not something we (will) use since it's just a syntax sugar for parsing data for all CPUs (that we do anyway).
If you want to clean the test data a bit, I suggest you clean tests/nodeinfodata/*/cpu/cpu*/{uevent,power,topology/core_siblings*,firmware_node,subsystem}
files too. That's 202 files you can get rid of.
good point. Although I'd leave core_siblings and topology - it's currently not used, but it may come handy when debugging our own node info code. It contains all the pieces of information that one need to reconstruct the topology. But others can be removed as you say. Will send v2.
I meant that the info in core_siblings* can be reconstructed from all the other data, but that's right that we might validate it with that additional files.
participants (2)
-
Martin Kletzander
-
Michal Privoznik