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  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]
Date:   Sun, 17 Nov 2019 16:04:43 +0000
From:   Russell King - ARM Linux admin <>
To:     Ioana Ciornei <>
Subject: Re: [PATCH net-next v4 0/5] dpaa2-eth: add MAC/PHY support through

On Thu, Oct 31, 2019 at 01:18:27AM +0200, Ioana Ciornei wrote:
> The dpaa2-eth driver now has support for connecting to its associated PHY
> device found through standard OF bindings. The PHY interraction is handled
> by PHYLINK and even though, at the moment, only RGMII_* phy modes are
> supported by the driver, this is just the first step into adding the
> necessary changes to support the entire spectrum of capabilities.
> This comes after feedback on the initial DPAA2 MAC RFC submitted here:
> The notable change is that now, the DPMAC is not a separate driver, and
> communication between the DPMAC and DPNI no longer happens through
> firmware. Rather, the DPMAC is now a set of API functions that other
> net_device drivers (DPNI, DPSW, etc) can use for PHY management.
> The change is incremental, because the DPAA2 architecture has many modes of
> connecting net devices in hardware loopback (for example DPNI to DPNI).
> Those operating modes do not have a DPMAC and phylink instance.
> The documentation patch provides a more complete view of the software
> architecture and the current implementation.


I've just switched from using the previous solution to this solution,
and when I use the following on SolidRun's Clearfog CX platform:

# ls-addni dpmac.7
# ls-addni dpmac.8

I get lots of warnings spat out of the kernel:

------------[ cut here ]------------
Unable to drop a managed device link reference WARNING: CPU: 0 PID: 1580 drivers/base/core.c:456 device_link_put_kref+0x40/0x64
Modules linked in: nf_tables nfnetlink mlx4_en fsl_dpaa2_ptp crct10dif_ce ptp_qoriq mlx4_core m25p80 spi_nor sbsa_gwdt qsfp vhost_net tun vhost tap ip_tables x_tables
CPU: 0 PID: 1580 Comm: irq/128-dprc.1 Not tainted 5.3.0+ #491
Hardware name: SolidRun LX2160A Clearfog CX (DT)
pstate: 60400005 (nZCv daif +PAN -UAO)
pc : device_link_put_kref+0x40/0x64
lr : device_link_put_kref+0x40/0x64
sp : ffffff8015583a10
x29: ffffff8015583a10 x28: 0000000000000000
x27: ffffffe2d0bc3ab4 x26: ffffff8015583dbc
x25: ffffff8010c48bb0 x24: ffffffe2d08a8000
x23: ffffffe2d0bc0000 x22: ffffffe2d0bc1560
x21: ffffffe2d0bc1560 x20: ffffffe2d1058b80
x19: ffffff8010f3f570 x18: 0000000000000000
x17: 0000000000000000 x16: 0000000000000000
x15: ffffffffffffffff x14: 0000000000000040
x13: 0000000000000220 x12: 0000000000000018
x11: 0000000000000000 x10: ffffffe2ecb2c1e0
x9 : 0000000000000000 x8 : 00000000ad126c4a
x7 : 0000000000000000 x6 : ffffff801015aa18
x5 : 0000000000000000 x4 : 0000000000000000
x3 : 0000000000000000 x2 : ffffffe2f1a118e8
x1 : ffffffe2ecb2c140 x0 : 000000000000002e
Call trace:
---[ end trace 8308e7d5e463dbb1 ]---
------------[ cut here ]------------
Unable to drop a managed device link reference
... repeats ...

The other thing I see is that with dpmac.7 added, I get all the iommu
group messages, and buried in there is:

fsl_dpaa2_eth dpni.1: Probed interface eth1

as expected.  When I issue the dpmac.8 command (which is when all those
warnings are spat out) I see:

fsl_dpaa2_eth dpni.2: Probed interface eth1

So dpni.1 has gone, eth1 has gone to be replaced by dpni.2 bound to eth1.

Looking in /sys/bus/fsl-mc/devices/dpni.[12]/ it seems that both
devices still exist, but dpni.1 has been unbound from the dpaa2 eth

If I then ask for dpmac.9 and dpmac.10, then everything works as
expected, they become eth2 and eth3 respectively, and eth1 doesn't
get unbound.

The warnings are caused by calls to device_link_del() scattered
throughout the DPAA2/FSL-MC code - you can't remove the device links
which are not created with DL_FLAG_STATELESS - but you can't create
a device link with the DL_FLAG_STATELESS flag set and with the
autoprobe/autoremove flags set - please read the documentation for

Merely deleting the calls doesn't seem to be the right thing either -
I don't think the devices go away, so the links will persist.

RMK's Patch system:
FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down 622kbps up
According to 11.9Mbps down 500kbps up

Powered by blists - more mailing lists