Re: [PATCH 02/12] pinctrl: basic Nomadik pinctrl interface

From: Linus Walleij
Date: Fri May 11 2012 - 03:12:53 EST


On Wed, May 9, 2012 at 10:34 PM, Stephen Warren <swarren@xxxxxxxxxxxxx> wrote:
> On 05/08/2012 03:44 AM, Linus Walleij wrote:

>> +     /* Poke in other ASIC variants here */
>> +     if (platid->driver_data == PINCTRL_NMK_DB8500)
>> +             nmk_pinctrl_db8500_init(&npct->soc);
>
> Other platforms have a unique top-level driver for each variant, with
> the probe() function for each variant calling into a utility function.
> That way, the common/utility code doesn't need to contain a
> table/list/... of all the variants. Can the same approach be used here?

Now I see why I did this, it doesn't show in the patch but this driver
now has two platform_driver structs and two probes.

So I thought it'd be messy to have the two probes in two different
files, with criss-cross calling, as simple as that.

The goal is to merge them into one probe function providing
all resources though, I'm refactoring stepwise since the mess
up in the arch needs to be handled in some separate step
and I have enough hamming distance already as it is ...

I'm rolling a v2 with the other change though.

Yours,
Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/