From: Jiri Pirko <jiri@resnulli.us>
To: Ido Schimmel <idosch@idosch.org>
Cc: Jakub Kicinski <kuba@kernel.org>,
netdev@vger.kernel.org, davem@davemloft.net, jiri@nvidia.com,
danieller@nvidia.com, mlxsw@nvidia.com,
Ido Schimmel <idosch@nvidia.com>
Subject: Re: [PATCH net-next 1/2] mlxsw: Register physical ports as a devlink resource
Date: Wed, 13 Jan 2021 14:39:02 +0100 [thread overview]
Message-ID: <20210113133902.GH3565223@nanopsycho.orion> (raw)
In-Reply-To: <20210113083241.GA1757975@shredder.lan>
Wed, Jan 13, 2021 at 09:32:41AM CET, idosch@idosch.org wrote:
>On Tue, Jan 12, 2021 at 08:21:22PM -0800, Jakub Kicinski wrote:
>> On Tue, 12 Jan 2021 10:39:30 +0200 Ido Schimmel wrote:
>> > From: Danielle Ratson <danieller@nvidia.com>
>> >
>> > The switch ASIC has a limited capacity of physical ('flavour physical'
>> > in devlink terminology) ports that it can support. While each system is
>> > brought up with a different number of ports, this number can be
>> > increased via splitting up to the ASIC's limit.
>> >
>> > Expose physical ports as a devlink resource so that user space will have
>> > visibility to the maximum number of ports that can be supported and the
>> > current occupancy.
>>
>> Any thoughts on making this a "generic" resource?
>
>It might be possible to allow drivers to pass the maximum number of
>physical ports to devlink during their initialization. Devlink can then
>use it as an indication to register the resource itself instead of the
>driver. It can report the current occupancy without driver intervention
>since the list of ports is maintained in devlink.
>
>There might be an issue with the resource identifier which is a 64-bit
>number passed from drivers. I think we can partition this to identifiers
>allocated by devlink / drivers.
>
>Danielle / Jiri?
There is no concept of "generic resource". And I think it is a good
reason for it, as the resource is something which is always quite
hw-specific. Port number migth be one exception. Can you think of
anything else? If not, I would vote for not having "generic resource"
just for this one case.
next prev parent reply other threads:[~2021-01-13 13:39 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-12 8:39 [PATCH net-next 0/2] mlxsw: Expose number of physical ports Ido Schimmel
2021-01-12 8:39 ` [PATCH net-next 1/2] mlxsw: Register physical ports as a devlink resource Ido Schimmel
2021-01-13 4:21 ` Jakub Kicinski
2021-01-13 8:32 ` Ido Schimmel
2021-01-13 13:39 ` Jiri Pirko [this message]
2021-01-13 14:26 ` Ido Schimmel
2021-01-13 18:46 ` Jakub Kicinski
2021-01-12 8:39 ` [PATCH net-next 2/2] selftests: mlxsw: Add a scale test for physical ports Ido Schimmel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210113133902.GH3565223@nanopsycho.orion \
--to=jiri@resnulli.us \
--cc=danieller@nvidia.com \
--cc=davem@davemloft.net \
--cc=idosch@idosch.org \
--cc=idosch@nvidia.com \
--cc=jiri@nvidia.com \
--cc=kuba@kernel.org \
--cc=mlxsw@nvidia.com \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.