Re: [PATCH] octeontx2-af: Fix uninitialized scalar variable

2025-02-13 Thread Paolo Abeni
On 2/11/25 6:50 AM, Michal Swiatkowski wrote: > On Mon, Feb 10, 2025 at 09:01:52PM -0500, Ethan Carter Edwards wrote: >> The variable *max_mtu* is uninitialized in the function >> otx2_get_max_mtu. It is only assigned in the if-statement, leaving the >> possibility of returning an uninitialized val

Re: [PATCH] octeontx2-af: Fix uninitialized scalar variable

2025-02-10 Thread Michal Swiatkowski
On Mon, Feb 10, 2025 at 09:01:52PM -0500, Ethan Carter Edwards wrote: > The variable *max_mtu* is uninitialized in the function > otx2_get_max_mtu. It is only assigned in the if-statement, leaving the > possibility of returning an uninitialized value. In which case? If rc == 0 at the end of the fu

[PATCH] octeontx2-af: Fix uninitialized scalar variable

2025-02-10 Thread Ethan Carter Edwards
The variable *max_mtu* is uninitialized in the function otx2_get_max_mtu. It is only assigned in the if-statement, leaving the possibility of returning an uninitialized value. 1500 is the industry standard networking mtu and therefore should be the default. If the function detects that the hardwar