Fix issue printing memory module sizes
Resolves: #2080596 Signed-off-by: Aristeu Rozanski <arozansk@redhat.com>
This commit is contained in:
parent
74367be5a2
commit
60fd567b32
51
9415b7449c70f5ea4a0209ddb89c2f5f392d3b4b.patch
Normal file
51
9415b7449c70f5ea4a0209ddb89c2f5f392d3b4b.patch
Normal file
@ -0,0 +1,51 @@
|
||||
commit 9415b7449c70f5ea4a0209ddb89c2f5f392d3b4b
|
||||
Author: Muralidhara M K <muralimk@amd.com>
|
||||
Date: Tue Jul 27 06:36:45 2021 -0500
|
||||
|
||||
rasdaemon: ras-mc-ctl: Fix script to parse dimm sizes
|
||||
|
||||
Removes trailing spaces at the end of a line from
|
||||
file location and fixes --layout option to parse dimm nodes
|
||||
to get the size of each dimm from ras-mc-ctl.
|
||||
|
||||
Issue is reported https://github.com/mchehab/rasdaemon/issues/43
|
||||
Where '> ras-mc-ctl --layout' reports all 0s
|
||||
|
||||
With this change the layout option prints the correct dimm sizes
|
||||
> sudo ras-mc-ctl --layout
|
||||
+-----------------------------------------------+
|
||||
| mc0 |
|
||||
| csrow0 | csrow1 | csrow2 | csrow3 |
|
||||
----------+-----------------------------------------------+
|
||||
...
|
||||
channel7: | 16384 MB | 0 MB | 0 MB | 0 MB |
|
||||
channel6: | 16384 MB | 0 MB | 0 MB | 0 MB |
|
||||
...
|
||||
----------+-----------------------------------------------+
|
||||
|
||||
Signed-off-by: Muralidhara M K <muralimk@amd.com>
|
||||
Signed-off-by: Naveen Krishna Chatradhi <nchatrad@amd.com>
|
||||
Cc: Yazen Ghannam <yazen.ghannam@amd.com>
|
||||
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
|
||||
Link: https://lkml.kernel.org/r/20210810183855.129076-1-nchatrad@amd.com/
|
||||
|
||||
diff --git a/util/ras-mc-ctl.in b/util/ras-mc-ctl.in
|
||||
index 1e3aeb7..b22dd60 100755
|
||||
--- a/util/ras-mc-ctl.in
|
||||
+++ b/util/ras-mc-ctl.in
|
||||
@@ -246,6 +246,7 @@ sub parse_dimm_nodes
|
||||
if (($file =~ /max_location$/)) {
|
||||
open IN, $file;
|
||||
my $location = <IN>;
|
||||
+ $location =~ s/\s+$//;
|
||||
close IN;
|
||||
my @temp = split(/ /, $location);
|
||||
|
||||
@@ -288,6 +289,7 @@ sub parse_dimm_nodes
|
||||
|
||||
open IN, $file;
|
||||
my $location = <IN>;
|
||||
+ $location =~ s/\s+$//;
|
||||
close IN;
|
||||
|
||||
my @pos;
|
@ -1,6 +1,6 @@
|
||||
Name: rasdaemon
|
||||
Version: 0.6.7
|
||||
Release: 6%{?dist}
|
||||
Release: 7%{?dist}
|
||||
Summary: Utility to receive RAS error tracings
|
||||
License: GPLv2
|
||||
URL: http://git.infradead.org/users/mchehab/rasdaemon.git
|
||||
@ -24,6 +24,7 @@ Patch15: fc1dd37d422fc907416afd028514fff59b63ae12.patch
|
||||
Patch16: 6bc43db1b6b3d73805179c21d1dd5521e8dc0f74.patch
|
||||
Patch17: 2b6a54b0d31e02e657171fd27f4e31d996756bc6.patch
|
||||
Patch18: 7ccf12f5ae26a055926d175d908c7930293438c4.patch
|
||||
Patch19: 9415b7449c70f5ea4a0209ddb89c2f5f392d3b4b.patch
|
||||
|
||||
ExcludeArch: s390 s390x
|
||||
BuildRequires: make
|
||||
@ -77,6 +78,7 @@ an utility for reporting current error counts from the EDAC sysfs files.
|
||||
%patch16 -p1
|
||||
%patch17 -p1
|
||||
%patch18 -p1
|
||||
%patch19 -p1
|
||||
|
||||
# The tarball is locked in time the first time aclocal was ran and will keep
|
||||
# requiring an older version of automake
|
||||
@ -112,6 +114,9 @@ sed -i "s/^PAGE_CE_ACTION=.*/PAGE_CE_ACTION=account/" %{buildroot}/%{_sysconfdir
|
||||
%{_sysconfdir}/sysconfig/rasdaemon
|
||||
|
||||
%changelog
|
||||
* Mon May 02 2022 Aristeu Rozanski <aris@redhat.com> 0.6.7-7
|
||||
- Fix issue printing memory module sizes [2080596]
|
||||
|
||||
* Thu Mar 31 2022 Aristeu Rozanski <aris@redhat.com> 0.6.7-6
|
||||
- Merging 2065729 fixes into 9.1 branch [2067499]
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user