[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87inqzcjfy.fsf@ketchup.i-did-not-set--mail-host-address--so-tickle-me>
Date: Sun, 04 Dec 2016 19:23:45 -0500
From: Vivien Didelot <vivien.didelot@...oirfairelinux.com>
To: Andrew Lunn <andrew@...n.ch>
Cc: David Miller <davem@...emloft.net>, netdev <netdev@...r.kernel.org>
Subject: Re: [PATCH v1 net-next 1/5] net: dsa: mv88e6xxx: Reserved Management frames to CPU
Hi Andrew,
Andrew Lunn <andrew@...n.ch> writes:
>> You can have several implementations in the same file (e.g. global1.c),
>> so again the only value is the function name, not the struct member.
>
> The structure member have g1_ has a lot of value.
>
> if (chip->info->ops->set_cpu_port) {
> err = chip->info->ops->set_cpu_port(chip, upstream_port);
> if (err)
> return err;
> }
>
> Where to i need to go look for set_cpu_port? I have no idea.
In your chip's ops definition, as for any ops structure. Same as for
your example right below which is unfortunately not a solution per-se.
>
> if (chip->info->ops->g1_set_cpu_port) {
> err = chip->info->ops->g1_set_cpu_port(chip, upstream_port);
> if (err)
> return err;
> }
>
> Humm, the hint tells me it is in global1.c. And i also know that all
> of them are in global1.c.
Until a new chip relocates a feature somewhere else.
Then you'll have to rename the structure member(s) because you have a
policy saying "no prefix means different set of registers".
Vivien
Powered by blists - more mailing lists