Re: [PATCH net-next v3 5/5] net-next: dsa: add dsa support for Mediatek MT7530 switch

2017-05-24 Thread Andrey Jr. Melnikov
In gmane.linux.kernel sean.w...@mediatek.com wrote:
> From: Sean Wang 

> MT7530 is a 7-ports Gigabit Ethernet Switch that could be found on
> Mediatek router platforms such as MT7623A or MT7623N platform which
> includes 7-port Gigabit Ethernet MAC and 5-port Gigabit Ethernet PHY.
> Among these ports, The port from 0 to 4 are the user ports connecting
> with the remote devices while the port 5 and 6 are the CPU ports
> connecting into Mediatek Ethernet GMAC.

> For port 6, it can communicate with the CPU via Mediatek Ethernet GMAC
> through either the TRGMII or RGMII which could be controlled by phy-mode
> in the dt-bindings to specify which mode is preferred to use. And for
> port 5, only RGMII can be specified. However, currently, only port 6 is
> being supported in this DSA driver.

> The driver is made with the reference to qca8k and other existing DSA
> driver. The most of the essential callbacks of the DSA are already
> support in the driver, including tag insert for user port distinguishing,
> port control, bridge offloading, STP setup and ethtool operation to allow
> DSA to model each user port into a standalone netdevice as the other DSA
> driver had done.

What about JUMBO frames and large MTU support? devlink support?



Re: [PATCH net-next] net: ipv6: put autoconf routes into per-interface tables

2017-01-10 Thread Andrey Jr. Melnikov
David Ahern  wrote:
> On 1/9/17 8:30 PM, Lorenzo Colitti wrote:
> > On Tue, Jan 10, 2017 at 12:04 PM, David Ahern  
> > wrote:
> >>> I have no firsthand experience of this myself, but if the problems
> >>> that Andrey reports above in this thread are real, then those would
> >>> indicate that the code is not well-supported. Being unable to accept
> >>> DAD is a pretty serious issue. Andrey, what version of the kernel did
> >>> you see this on?
> >>
> >> Are you referencing an Android or google thread? This patch thread has not 
> >> mentioned any IPv6 problems.
> > 
> > No, this thread. I see message-ID 8cddkd-etc.ln1@banana.localnet in
> > this thread. If you didn't get it, I also see it in the comments on
> > patchwork - https://patchwork.ozlabs.org/patch/711956/
> > 

> Odd that I did not get that -- checked spam and trash.

> Andrey is missing 830218c1add1da16519b71909e5cf21522b7d062 which tells me the 
> comment is not based on 4.10 or net-next:

> $ git describe 830218c1add1da16519b71909e5cf21522b7d062
> v4.8-14744-g830218c1add1

Good catch. I'm running 4.8 without this patch. Current 4.10-rc works. Sorry
for noise.



Re: [PATCH net-next] net: ipv6: put autoconf routes into per-interface tables

2017-01-09 Thread Andrey Jr. Melnikov
David Ahern  wrote:
> On 1/6/17 8:30 AM, Lorenzo Colitti wrote:
> > This patch adds a per-interface sysctl to have the kernel put
> > autoconf routes into different tables. This allows each interface
> > to have its own routing table if desired.  Choosing the default
> > interface, or using different interfaces at the same time on a
> > per-socket or per-packet basis) can be done using policy routing
> > mechanisms that use as SO_BINDTODEVICE / IPV6_PKTINFO, mark-based
> > routing, or UID-based routing to select specific routing tables.

> Why not use the VRF capability then? create a VRF and assign the interface to 
> it. 
> End result is the same -- separate tables and the need to use a 
> bind-to-device API to hit those routes.

Show *really working* config with VRF & IPv6?

In my tests - kernel unable to accept DAD, fill logs with "ICMPv6: RA: 
ndisc_router_discovery failed to add default route"
and nothing work. VRF interface don't contains IPv6 address.



[PATCH] iproute: disallow ip rule del without parameters

2016-08-24 Thread Andrey Jr. Melnikov
Disallow run `ip rule del` without any parameter to avoid delete any first
rule from table.

Signed-off-by: Andrey Jr. Melnikov 
---

diff --git a/ip/iprule.c b/ip/iprule.c
index 8f24206..70562c5 100644
--- a/ip/iprule.c
+++ b/ip/iprule.c
@@ -346,6 +346,11 @@ static int iprule_modify(int cmd, int argc, char **argv)
req.r.rtm_type = RTN_UNICAST;
}
 
+   if (cmd == RTM_DELRULE && argc == 0) {
+   fprintf(stderr, "\"ip rule del\" requires arguments.\n");
+   return -1;
+   }
+
while (argc > 0) {
if (strcmp(*argv, "not") == 0) {
req.r.rtm_flags |= FIB_RULE_INVERT;