On 11/08/2017 03:15 AM, Russell King - ARM Linux wrote: > On Tue, Nov 07, 2017 at 07:49:08PM -0800, Florian Fainelli wrote: >> The SFP module identification code in sfp_sm_mod_probe() will reject SFF >> modules soldered down because they have an identified of 0x2, while the code >> currently checks for 0x3 only (SFP_PHYS_ID_SFP), update that. >> >> Signed-off-by: Florian Fainelli <f.faine...@gmail.com> >> --- >> drivers/net/phy/sfp.c | 5 +++-- >> include/linux/sfp.h | 1 + >> 2 files changed, 4 insertions(+), 2 deletions(-) >> >> diff --git a/drivers/net/phy/sfp.c b/drivers/net/phy/sfp.c >> index e381811e5f11..942288aa9cdb 100644 >> --- a/drivers/net/phy/sfp.c >> +++ b/drivers/net/phy/sfp.c >> @@ -463,8 +463,9 @@ static int sfp_sm_mod_probe(struct sfp *sfp) >> vendor, part, rev, sn, date); >> >> /* We only support SFP modules, not the legacy GBIC modules. */ >> - if (sfp->id.base.phys_id != SFP_PHYS_ID_SFP || >> - sfp->id.base.phys_ext_id != SFP_PHYS_EXT_ID_SFP) { >> + if ((sfp->id.base.phys_id != SFP_PHYS_ID_SFP && >> + sfp->id.base.phys_id != SFP_PHYS_ID_SFF) || >> + sfp->id.base.phys_ext_id != SFP_PHYS_EXT_ID_SFP) { > > I'd prefer that we do something like the patch I sent a couple of nights > ago, having a separate compatible for the SFF modules (since they have > no insert signal as SFF is soldered in place) and use that to decide > which phys_id we accept here.
Fair enough. -- Florian