[OpenWrt-Devel] [PATCH 2/3] swconfig: support receiving SWITCH_TYPE_LINK from kernel

Rafał Miłecki zajec5 at gmail.com
Mon Dec 21 01:31:33 EST 2015


On 20 December 2015 at 22:56, Florian Fainelli <florian at openwrt.org> wrote:
> Le 16 déc. 2015 09:21, "Rafał Miłecki" <zajec5 at gmail.com> a écrit :
>>
>> When using cli, print link state the same way kernel used to do it.
>> This will allow kernel switching PORT_LINK from SWITCH_TYPE_STRING.
>>
>> Signed-off-by: Rafał Miłecki <zajec5 at gmail.com>
>> ---
> [snip]
>> +                               link->eee &
>> SWLIB_LINK_FLAG_ADVERTISED_100BASET_FULL ? "eee100 " : "",
>> +                               link->eee &
>> SWLIB_LINK_FLAG_ADVERTISED_1000BASET_FULL ? "eee1000 " : "",
>
> EEE needs to be advertised, supported, and enabled on both link partners to
> be used,what you are printing here is not very clear, as this is just the
> advertised side

This behavior is copied from the current implementation. This is what
kernel was putting in a string so far and sending to the user space.
Do we want to change it? Should I handle it in this patch or separated
one? I hope there aren't send screen scraping tools using "get link".

-- 
Rafał
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


More information about the openwrt-devel mailing list