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: <20190206214432.GB32483@lunn.ch>
Date:   Wed, 6 Feb 2019 22:44:32 +0100
From:   Andrew Lunn <andrew@...n.ch>
To:     Leo Li <leoyang.li@....com>
Cc:     Pankaj Bansal <pankaj.bansal@....com>,
        Shawn Guo <shawnguo@...nel.org>,
        Florian Fainelli <f.fainelli@...il.com>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "linux-arm-kernel@...ts.infradead.org" 
        <linux-arm-kernel@...ts.infradead.org>
Subject: Re: [PATCH v2] arm64: dts: lx2160aqds: Add mdio mux nodes

> > > >  &i2c0 {
> > > >         status = "okay";
> > > >
> > > > +       fpga@66 {
> > > > +               compatible = "fsl,lx2160aqds-fpga", "fsl,fpga-qixis-i2c";
> > > > +               reg = <0x66>;
> > > > +               #address-cells = <1>;
> > > > +               #size-cells = <0>;
> > > > +
> > > > +               mdio-mux-1@54 {
> > >
> > > Still no compatible string defined for the node.  Probably should be
> > > "mdio-mux- mmioreg", "mdio-mux"
> > 
> > it is not a specific device. MDIO mux is meant to be controlled by some
> > registers of parent device (FPGA).
> > Therefore, IMO this should not be a device and there should not be any
> > "compatible" property for it.
 
> If it is not a device why we are defining a device node for it?  It
> is probably not a physical device per se, but it can be considered a
> virtual device provided by FPGA.

It is a physical device. But it happens to be embedded inside another
device. And that embedded is not performed as a bus with devices on
it, so the device tree concepts don't fit directly.

> This also bring up another question that why this device cannot
> reuse the existing drivers/net/phy/mdio-mux-mmioreg.c driver?

Because it is on an i2c bus, not an mmio bus.

> If we think regmap is a better solution, shall we replace the
> mmioreg driver with the regmap driver?

regmap can be used with mmio. But for a single MMIO register it is a
huge framework. So it makes sense to keep mdio-mux-mmioreg simple.

If however the device is already using regmap, adding one more
register is very little overhead. And it might be possible to use this
new mux with an mmio regmap, or an spi regmap, etc. So we seem to be
covering the best of both worlds.

   Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ