[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20181217.113119.1920042287405234188.davem@davemloft.net>
Date: Mon, 17 Dec 2018 11:31:19 -0800 (PST)
From: David Miller <davem@...emloft.net>
To: frank-w@...lic-files.de
Cc: matthias.bgg@...il.com, netdev@...r.kernel.org,
sean.wang@...iatek.com, andrew@...n.ch,
linux-mediatek@...ts.infradead.org
Subject: Re: [PATCH 2/8] net: dsa: add helper functions
From: Frank Wunderlich <frank-w@...lic-files.de>
Date: Fri, 14 Dec 2018 17:48:41 +0100
> @@ -255,6 +255,24 @@ static void dsa_tree_teardown_default_cpu(struct dsa_switch_tree *dst)
> dst->cpu_dp = NULL;
> }
>
> +static int dsa_user_parse(struct dsa_port *port, u32 index,
> + struct dsa_switch *ds)
> +{
> + struct device_node *cpu_port;
> + const unsigned int *cpu_port_reg;
> + int cpu_port_index;
Please order local variables from longest to shortest line.
Also, for ->upstream_port, since it is ultimately used as a u8 maybe
it's best to define it as a u8 in the structure?
Thanks.
Powered by blists - more mailing lists