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: <85acc1d3523a3c6f88687d3491f83380@walle.cc>
Date:   Thu, 07 Jan 2021 10:19:28 +0100
From:   Michael Walle <michael@...le.cc>
To:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc:     Saravana Kannan <saravanak@...gle.com>,
        "Rafael J. Wysocki" <rafael@...nel.org>, kernel-team@...roid.com,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH v1] driver core: Fix device link device name collision

Am 2021-01-07 10:00, schrieb Greg Kroah-Hartman:
> On Wed, Jan 06, 2021 at 03:26:41PM -0800, Saravana Kannan wrote:
>> The device link device's name was of the form:
>> <supplier-dev-name>--<consumer-dev-name>
>> 
>> This can cause name collision as reported here [1] as device names are
>> not globally unique. Since device names have to be unique within the
>> bus/class, add the bus/class name as a prefix to the device names used 
>> to
>> construct the device link device name.
>> 
>> So the devuce link device's name will be of the form:
>> <supplier-bus-name>:<supplier-dev-name>--<consumer-bus-name><consumer-dev-name>
> 
> Minor nit, you forgot a ':' in the consumer side of the link here.  The
> code is correct.
> 
>> 
>> [1] - 
>> https://lore.kernel.org/lkml/20201229033440.32142-1-michael@walle.cc/
>> Reported-by: Michael Walle <michael@...le.cc>
>> Signed-off-by: Saravana Kannan <saravanak@...gle.com>
>> ---
>> 
>> Michael,
>> 
>> Can you please test this? This should fix your issue.
>> 
>> Having said that, do you have some local DT changes when you are 
>> testing
>> this? Because it's not obvious from the DT in upstream what dependency
>> is even being derived from the firmware. I don't see any dependency in
>> upstream DT files between mdio_bus/0000:00:00.1 and
>> pci0000:00/0000:00:00.1
> 
> That looks really odd, why is the mdio bus using the same names as the
> pci bus?

Logically the MDIO bus belongs to the ENETC, although its actually an 
own
PCI device [1]. What do you think its name should be?

> But anyway, your dev_bus_name() change here looks good, I'll take that
> as a separate patch no matter what happens here :)

I'm just testing this patch, looks like it doesn't fix it for now. But
anyways. Shouldn't there be a Fixes tag for this patch? I.e. 5.11 is
broken right now.

[1] 
https://elixir.bootlin.com/linux/latest/source/drivers/net/ethernet/freescale/enetc/enetc_pf.c#L748

-michael

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ