lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YXlmSByDhPo0ZwWb@lunn.ch>
Date:   Wed, 27 Oct 2021 16:46:32 +0200
From:   Andrew Lunn <andrew@...n.ch>
To:     Yuiko.Oshino@...rochip.com
Cc:     davem@...emloft.net, netdev@...r.kernel.org,
        Nisar.Sayed@...rochip.com, UNGLinuxDriver@...rochip.com
Subject: Re: [PATCH net-next] net: phy: microchip_t1: add cable test support
 for lan87xx phy

> >> +     /* start cable diag */
> >> +     /* check if part is alive - if not, return diagnostic error */
> >> +     rc = access_ereg(phydev, PHYACC_ATTR_MODE_READ,
> >PHYACC_ATTR_BANK_SMI,
> >> +                      0x00, 0);
> >> +     if (rc < 0)
> >> +             return rc;
> >> +
> >> +     if (rc != 0x2100)
> >> +             return -ENODEV;
> >
> >What does this actually mean? Would -EOPNOTSUPP be better?
> 
> This register should return the value of 0x2100. So if the return value is different, then I assume there is no device.

If the device does not exist, can we have go this far? Would probe of
the PHY failed? Or are you talking about a device within a device? Is
cable test implemented using an optional component?

      Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ