[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <72ad213d-7074-e4ca-6799-94da01c38f8e@gmail.com>
Date: Wed, 11 Oct 2017 09:07:20 -0600
From: David Ahern <dsahern@...il.com>
To: Ido Schimmel <idosch@...sch.org>
Cc: netdev@...r.kernel.org, jiri@...lanox.com, idosch@...lanox.com,
kjlx@...pleofstupid.com
Subject: Re: [RFC net-next 4/4] mlxsw: spectrum_router: Add extack message for
RIF and VRF overflow
On 10/11/17 8:13 AM, Ido Schimmel wrote:
> On Tue, Oct 10, 2017 at 09:41:05AM -0700, David Ahern wrote:
>> Add extack argument down to mlxsw_sp_rif_create and mlxsw_sp_vr_create
>> to set an error message on RIF or VR overflow. Now an overflow of
>> either resource the use gets an informative message as opposed to
>
> s/the/in/ ?
'use' is supposed to be 'user'
>> diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
>> index 7d53fdf2c0a8..ec4d313b9eca 100644
>> --- a/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
>> +++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
>> @@ -731,14 +731,17 @@ static struct mlxsw_sp_fib *mlxsw_sp_vr_fib(const struct mlxsw_sp_vr *vr,
>> }
>>
>> static struct mlxsw_sp_vr *mlxsw_sp_vr_create(struct mlxsw_sp *mlxsw_sp,
>> - u32 tb_id)
>> + u32 tb_id,
>> + struct netlink_ext_ack *extack)
>> {
>> struct mlxsw_sp_vr *vr;
>> int err;
>>
>> vr = mlxsw_sp_vr_find_unused(mlxsw_sp);
>> - if (!vr)
>> + if (!vr) {
>> + NL_SET_ERR_MSG(extack, "spectrum: Exceeded number of supported VRF");
>
> Maybe:
> "spectrum: Exceeded number of supported VRF devices"
In this context the overflow is virtual routers in spectrum as opposed
to VRF devices in the kernel context. The existence of the VRF device
has no bearing until a port is enslaved to it.
How about:
"spectrum: Exceeded number of supported virtual routers"
Powered by blists - more mailing lists