use of uninitialized value in mv88e6185_port_link_state

From: Rasmus Villemoes <hidden>
Date: 2019-05-28 08:13:57

Hi,

mv88e6185_port_link_state starts by inspecting state->interface. AFAICT,
it can be called from two places:

mv88e6xxx_link_state <-
dsa_slave_phylink_mac_link_state <-
phylink_get_mac_state

which does initialize state->interface before passing it, but also from
mv88e6xxx_port_setup_mac, which passes an uninitialized stack variable.
This seems like a bug, but I don't know what the proper fix would be.
Simply initialize state.interface to mode?

Rasmus
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help