diff --git a/.gitignore b/.gitignore index 2045b45..b460b60 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -SOURCES/mstflint-4.8.0.tar.gz +SOURCES/mstflint-4.9.0-3.tar.gz diff --git a/.mstflint.metadata b/.mstflint.metadata index 05933a1..adbe9e8 100644 --- a/.mstflint.metadata +++ b/.mstflint.metadata @@ -1 +1 @@ -be896725828c4274c423ae198efa9f47c7803d7e SOURCES/mstflint-4.8.0.tar.gz +acbb381ef32aa2b27b937b76d72e0c22cb656097 SOURCES/mstflint-4.9.0-3.tar.gz diff --git a/SOURCES/0001-Extend-buffer-for-a-few-arrays.patch b/SOURCES/0001-Extend-buffer-for-a-few-arrays.patch deleted file mode 100644 index ffac349..0000000 --- a/SOURCES/0001-Extend-buffer-for-a-few-arrays.patch +++ /dev/null @@ -1,47 +0,0 @@ -From b947fc631d499fa6e041b6c460320bcd253f4671 Mon Sep 17 00:00:00 2001 -From: Honggang Li -Date: Wed, 22 Feb 2017 01:42:25 -0500 -Subject: [PATCH] Extend buffer for a few arrays - -Signed-off-by: Honggang Li ---- - mtcr_ul/mtcr_ul_com.c | 8 ++++---- - 1 file changed, 4 insertions(+), 4 deletions(-) - -diff --git a/mtcr_ul/mtcr_ul_com.c b/mtcr_ul/mtcr_ul_com.c -index 50a663f..1335b43 100644 ---- a/mtcr_ul/mtcr_ul_com.c -+++ b/mtcr_ul/mtcr_ul_com.c -@@ -1353,7 +1353,7 @@ int mdevices_v_ul(char *buf, int len, int mask, int verbosity) - } - - char inbuf[64]; -- char fname[64]; -+ char fname[300]; - - d = opendir("/sys/bus/pci/devices"); - if (d == NULL) { -@@ -1369,7 +1369,7 @@ int mdevices_v_ul(char *buf, int len, int mask, int verbosity) - continue; - } else if (sz > 4 && strcmp(dir->d_name + sz - 4, "00.0") && !verbosity) { - // Skip virtual functions -- char physfn[64]; -+ char physfn[300]; - DIR* physfndir; - sprintf(physfn, "/sys/bus/pci/devices/%s/physfn", dir->d_name); - if ((physfndir = opendir(physfn)) != NULL) { -@@ -1993,9 +1993,9 @@ int mclose_ul(mfile *mf) - return 0; - } - --#define IBDR_MAX_NAME_SIZE 128 -+#define IBDR_MAX_NAME_SIZE 300 - #define BDF_NAME_SIZE 12 --#define DEV_DIR_MAX_SIZE 128 -+#define DEV_DIR_MAX_SIZE 300 - static - int get_inband_dev_from_pci(char* inband_dev, char* pci_dev) - { --- -2.7.4 - diff --git a/SOURCES/0001-Return-zero-when-fread-reach-the-end-of-vpd-file.patch b/SOURCES/0001-Return-zero-when-fread-reach-the-end-of-vpd-file.patch deleted file mode 100644 index e69a33d..0000000 --- a/SOURCES/0001-Return-zero-when-fread-reach-the-end-of-vpd-file.patch +++ /dev/null @@ -1,33 +0,0 @@ -From 1a097ee9a70a92dd8e81618e42ee3795e2dad004 Mon Sep 17 00:00:00 2001 -From: Honggang Li -Date: Wed, 6 Dec 2017 23:59:43 -0500 -Subject: [PATCH] Return zero when fread reach the end of vpd file - -Fixes: 4201e56ec8e8 (Title: use mvpd in mstvpd) -Signed-off-by: Honggang Li ---- - mtcr_ul/mtcr_ul_com.c | 8 +++++--- - 1 file changed, 5 insertions(+), 3 deletions(-) - -diff --git a/mtcr_ul/mtcr_ul_com.c b/mtcr_ul/mtcr_ul_com.c -index ddafd0a..9f328b5 100644 ---- a/mtcr_ul/mtcr_ul_com.c -+++ b/mtcr_ul/mtcr_ul_com.c -@@ -2575,9 +2575,11 @@ int mvpd_read4_ul_int(mfile *mf, unsigned int offset, u_int8_t value[4]){ - return errno; - } - if (fread(value, 1, 4, f) < 1) { -- //fprintf(stderr, "Failed to read from (%s): %s\n", proc_dev, strerror(errno)); -- fclose(f); -- return errno; -+ if (!feof(f)) { -+ //fprintf(stderr, "Failed to read from (%s): %s\n", proc_dev, strerror(errno)); -+ fclose(f); -+ return errno; -+ } - } - fclose(f); - return 0; --- -1.8.3.1 - diff --git a/SPECS/mstflint.spec b/SPECS/mstflint.spec index 26888f2..2f068fe 100644 --- a/SPECS/mstflint.spec +++ b/SPECS/mstflint.spec @@ -1,14 +1,14 @@ Name: mstflint Summary: Mellanox firmware burning tool -Version: 4.8.0 +Version: 4.9.0 Release: 3%{?dist} License: GPLv2+ or BSD Group: Applications/System -Source: https://github.com/Mellanox/%{name}/files/1457191/%{name}-%{version}.tar.gz -Patch1: 0001-Extend-buffer-for-a-few-arrays.patch -Patch2: 0001-Return-zero-when-fread-reach-the-end-of-vpd-file.patch +# Source downloaded from https://github.com/Mellanox/%{name}/releases/download/v%{version}-3/%{name}-%{version}.tar.gz +# Rename it as mstflint-4.9.0-3.tar.gz +Source: mstflint-4.9.0-3.tar.gz Url: https://github.com/Mellanox/mstflint -BuildRequires: libstdc++-devel, zlib-devel, libibmad-devel +BuildRequires: libstdc++-devel, zlib-devel, libibmad-devel, rdma-core-devel BuildRequires: libcurl-devel, boost-devel, libxml2-devel, openssl-devel Obsoletes: openib-mstflint <= 1.4 openib-tvflash <= 0.9.2 tvflash <= 0.9.0 ExcludeArch: s390 s390x @@ -19,8 +19,6 @@ for network adapters based on Mellanox Technologies chips. %prep %setup -q -%patch1 -p1 -%patch2 -p1 find . -type f -iname '*.[ch]' -exec chmod a-x '{}' ';' find . -type f -iname '*.cpp' -exec chmod a-x '{}' ';' @@ -47,6 +45,14 @@ find %{buildroot} -type f -name libmtcr_ul.a -delete %{_mandir}/man1/* %changelog +* Sun May 6 2018 Honggang Li - 4.9.0-3 +- Rebase to latest upstream release v4.9.0-3 +- Resolves: bz1541740 + +* Tue Apr 17 2018 Honggang Li - 4.9.0-1 +- Rebase to latest upstream release v4.9.0-1 +- Resolves: bz1541740, bz1541489 + * Thu Dec 7 2017 Honggang Li - 4.8.0-3 - Fixes mstvpd for mlx5 devices - Resolves: bz1515993