Debian Patches

Status for mstflint/4.31.0+1-4

Patch Description Author Forwarded Bugs Origin Last update
0001-Remove-unused-arch-dependent-define-U64L.patch [PATCH 1/3] Remove unused arch-dependent define U64L Tzafrir Cohen <tzafrir@debian.org> no 2024-01-28
0002-Remove-unused-arch-dependent-macros-from-packet_comm.patch [PATCH 2/3] Remove unused arch-dependent macros from packet_commons.h Tzafrir Cohen <tzafrir@debian.org> no 2024-01-28
0003-Avoid-all-arch-dependent-format-macros.patch [PATCH 3/3] Avoid all arch-dependent format macros Tzafrir Cohen <tzafrir@debian.org> no 2024-01-28
0005-Add-missing-shebang-to-Python-scripts.patch Add missing shebang to Python scripts
`mlxconfig/mstprivhost.py` and `small_utils/mstfwreset.py` are Python
scripts that are executable, but they lack a shebang.

https://github.com/Mellanox/mstflint/pull/219
Benjamin Drung <benjamin.drung@cloud.ionos.com> no 2019-10-21
fix_interpreters.patch Fix shebang lines of some executable scripts
===================================================================
Tzafrir Cohen <nvidia@cohens.org.il> no
remove_fwmgr_install.patch Avoid installing firmware manager for now
Upstream made debian/install an autoconf-generated file with the extra
line 'etc/*' being remmed-out if installation of firmware manager is
disabled.

The option --enable-fw-mgr is not used on our package build for now, so
we'll deal with that later.


===================================================================
Tzafrir Cohen <tzafrir@debian.org> no
revert_runtime_test.patch Revert test for fallback of a test of broken std:regex
Some older versions of GCC (e.g. 4.8.5 in RHEL7 have a broken std::regex.
Currently this is detected by running generated code, and that breaks
cross-building.

On Debian we will have newer GCC anyway, so we don't care.


===================================================================
Tzafrir Cohen <tzafrir@debian.org> no
fwctrl-include-missing-function-declarations.patch [PATCH] fwctrl: include missing function declarations
The fwctrl fails to build with the following error:

fwctrl.c: In function 'fwctl_control_access_register':
fwctrl.c:190:27: error: implicit declaration of function 'return_by_reg_status' [-Wimplicit-function-declaration]
190 | *reg_status = return_by_reg_status(cmd_status);
| ^~~~~~~~~~~~~~~~~~~~
In file included from fwctrl.c:45:
fwctrl.c:195:56: error: implicit declaration of function 'm_err2str' [-Wimplicit-function-declaration]
195 | reg_id, cmd_status, *reg_status, m_err2str(status));
|

This commit adds the return_by_reg_status prototype to the
mtcr_ul_com.h file and includes mtcr_ul_com.h and mtcr.h
(where the m_err2str prototype is defined) inside fwctrl.c.
Til Kaiser <mail@tk154.de> no 2025-02-07
fwctrl-fix-reg-status-typo.patch [PATCH] fwctrl: fix reg status typo
There is the following build error:

fwctrl.c: In function 'fwctl_control_access_register':
fwctrl.c:197:66: error: incompatible type for argument 1 of 'm_err2str'
197 | reg_id, cmd_status, *reg_status, m_err2str(status));
| ^~~~~~
| |
| void *
../include/mtcr_ul/fwctrl_ioctl.h:47:81: note: in definition of macro 'FWCTL_DEBUG_PRINT'
47 | printf("%s: %s %d: " format, FWCTL_ENV_VAR_DEBUG, __func__, __LINE__, ##arg); \
| ^~~
In file included from fwctrl.c:43:
../include/mtcr_ul/mtcr.h:173:30: note: expected 'MError' but argument is of type 'void *'
173 | const char* m_err2str(MError status);
| ~~~~~~~^~~~~~

Looking at the format string, this seems to be just a typo,
so fix that to the correct variable name.
Til Kaiser <mail@tk154.de> no 2025-02-07
dev_mgt-include-missing-function-declaration.patch [PATCH] dev_mgt: include missing function declaration
The dev_mgt fails to build with the following error:

tools_dev_types.c: In function 'dm_get_device_id_inner':
tools_dev_types.c:695:13: error: implicit declaration of function 'read_device_id'; did you mean 'dm_get_device_id'? [-Wimplicit-function-declaration]
695 | if (read_device_id(mf, &dword) != 4) {
| ^~~~~~~~~~~~~~
| dm_get_device_id

This commit includes mtcr_ul_com.h (where read_device_id
is defined) into tools_dev_types.c to fix the error.
Til Kaiser <mail@tk154.de> no 2025-02-07
kernel_fallthrough.patch kernel: Explicit fallthrough
diff --git a/kernel/mst_main.c b/kernel/mst_main.c
index 06d6f89..fc4a4a0 100644
Tzafrir Cohen <nvidia@cohens.org.il> no
kernel_ioremap_check_null.patch Test return of ioremap with non-NULL
Don't consider the result of ioremap a pointer that can include an errno
(was that the rationale?).

Avoids an error of considering a pointer as an int.

diff --git a/kernel/mst_main.c b/kernel/mst_main.c
index 06d6f89..d39a4e6 100644
Tzafrir Cohen <nvidia@cohens.org.il> no
kernel_statify.patch statify local functions
Declare functions that are not exported as local. Otherwise we get an
error that they don't have a pre-declaration.

diff --git a/kernel/mst_main.c b/kernel/mst_main.c
index 06d6f89..d39a4e6 100644
Tzafrir Cohen <nvidia@cohens.org.il> no

All known versions for source package 'mstflint'

Links