Re: [PATCH 2/4] pinctrl: Remove unsafe __refdata

From: Linus Walleij
Date: Thu Oct 20 2011 - 05:54:11 EST


On Thu, Oct 20, 2011 at 11:46 AM, Barry Song <21cnbao@xxxxxxxxx> wrote:

> 2011/10/20 Stephen Warren <swarren@xxxxxxxxxx>:
>> A pin controller's pin definitions are used both during pinctrl_register()
>> and pinctrl_unregister(). The latter happens outside of __init/__devinit
>> time, and hence it is unsafe to mark the pin array as __refdata.
>
> Thanks.
> Acked-by: Barry Song <Baohua.Song@xxxxxxx>
>
> missed this when porting prima2 pinmux driver. is this __refdata used
> just due to a typo?

No the problem was I misunderstood what __refdata means.

It means it is kept around but can reference initidata.

But I thought it meant "kept around in general".

I don't think it's causing bugs actually because it wasn't referencing
any initdata. But it's better like this.

Thanks,
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/