[U-Boot] [PATCH 7/8] x86: Probe pinctrl driver in cpu_init_r()
Bin Meng
bmeng.cn at gmail.com
Sat Jun 11 02:59:27 CEST 2016
Hi Simon,
On Fri, Jun 10, 2016 at 8:35 AM, Simon Glass <sjg at chromium.org> wrote:
> On 8 June 2016 at 06:07, Bin Meng <bmeng.cn at gmail.com> wrote:
>> At present pinctrl driver gets probed in ich6_gpio driver's probe
>> routine, which has two issues:
>>
>> - Pin's PADs only gets configured when GPIO driver is probed, which
>> is not done by default. This leaves the board in a partially
>> functional state as we must initialize PADs correctly to get
>> perepherals fully working.
>> - The probe routine of pinctrl driver is called multiple times, as
>> normally there are multiple GPIO controllers. It should really
>> be called just once.
>>
>> Move the call to syscon_get_by_driver_data() from ich6_gpio driver
>> to cpu_init_r().
>>
>> Signed-off-by: Bin Meng <bmeng.cn at gmail.com>
>>
>> ---
>>
>> arch/x86/cpu/cpu.c | 5 +++++
>> drivers/gpio/intel_ich6_gpio.c | 7 -------
>> 2 files changed, 5 insertions(+), 7 deletions(-)
>
> I suppose this is better. But will the pins always be set up even if
> the GPIO driver is not used until later?
>
I checked ich6_gpio and broadwell_gpio driver. Looks we are OK as the
pinctrl driver only needs the GPIO base address.
> Reviewed-by: Simon Glass <sjg at chromium.org>
Regards,
Bin
More information about the U-Boot
mailing list