On Fri, Apr 15, 2016 at 07:21:23PM -0400, Vivien Didelot wrote: > There is no point in having special case for the revision when probing a > switch model. The code gets cluttered with unnecessary defines, and > leads to errors when code such as mv88e6131_setup compares > PORT_SWITCH_ID_6131_B2 to ps->id which mask the revision. > > Drop every revision definitions, add a ps->rev variable for eventual > runtime checking and lookup only the product number.
You forgot to update the commit message. ps->rev has been removed in this version. > > /* Look up the exact switch ID */ This comment now becomes meaningless. Please delete. > for (i = 0; i < num; ++i) > - if (table[i].id == ret) > + if (table[i].id == (ret & 0xfff0)) > return table[i].name; Andrew