OMAP GPIO ready too later
Hi everyone:
On my board there has a gpio watchdong connected on am3358. And I found that the omap gpio device ready too later so it takes about 5 seconds when the gpio-wdt is ready.
I had tested on some version of linux, check when the OMAP GPIO is ready. Next is the log:
v4.19 [ 0.195191] OMAP GPIO hardware version 0.1
v5.4 [ 1.168868] OMAP GPIO hardware version 0.1
v5.9 [ 4.598052] OMAP GPIO hardware version 0.1
v5.15 [ 1.253851] OMAP GPIO hardware version 0.1
I can't find which commit slowdown omap gpio driver. could you please give me some advice?
Thanks
Hi,
Quoted 11 lines · qianfan
Hi everyone:
On my board there has a gpio watchdong connected on am3358. And I found that the omap gpio device ready too later so it takes about 5 seconds when the gpio-wdt is ready.
I had tested on some version of linux, check when the OMAP GPIO is ready. Next is the log:
v4.19 [ 0.195191] OMAP GPIO hardware version 0.1
Quoted 8 lines
v5.4 [ 1.168868] OMAP GPIO hardware version 0.1
v5.9 [ 4.598052] OMAP GPIO hardware version 0.1
v5.15 [ 1.253851] OMAP GPIO hardware version 0.1
I can't find which commit slowdown omap gpio driver. could you please give me some advice?
We've moved to probe pretty much everything at normal module_init time instead of trying to probe everything early. Only clocks and system timers need to be probed early for the omap variants.
One of the reasons for the device drivers probing later on during the boot is caused by drivers/bus/ti-sysc.c. As ti-sysc is the parent device on the interconnect, none of it's child devices probe before it. And there should not be any need to probe ti-sysc early. The total boot-up time should be about the same, just the probe order has changed. If there are issues with the boot-up time in general, then that's a bug.
Maybe you want to configure the watchdog in the bootloader initially until the Linux device drivers get probed?
Regards,
Tony
Quoted 33 lines · Tony Lindgren
Hi,
Quoted 11 lines · qianfan
Hi everyone:
On my board there has a gpio watchdong connected on am3358. And I found that the omap gpio device ready too later so it takes about 5 seconds when the gpio-wdt is ready.
I had tested on some version of linux, check when the OMAP GPIO is ready. Next is the log:
v4.19 [ 0.195191] OMAP GPIO hardware version 0.1
Quoted 8 lines
v5.4 [ 1.168868] OMAP GPIO hardware version 0.1
v5.9 [ 4.598052] OMAP GPIO hardware version 0.1
v5.15 [ 1.253851] OMAP GPIO hardware version 0.1
I can't find which commit slowdown omap gpio driver. could you please give me some advice?
We've moved to probe pretty much everything at normal
module_inittime instead of trying to probe everything early. Only clocks and system timers need to be probed early for the omap variants.One of the reasons for the device drivers probing later on during the boot is caused by
drivers/bus/ti-sysc.c. As ti-sysc is the parent device on the interconnect, none of it's child devices probe before it. And there should not be any need to probe ti-sysc early. The total boot-up time should be about the same, just the probe order has changed. If there are issues with the boot-up time in general, then that's a bug.
Quoted 2 lines
Maybe you want to configure the watchdog in the bootloader initially until the Linux device drivers get probed?
Yes, the gpio watchdog is alived on bootloader, I want find a good way to feed it until linux driver ready. gpio-wdt.c has an option CONFIG_GPIO_WATCHDOG_ARCH_INITCALL which will register gpio-wdt driver on arch_innitcall, but this feature doesn't work on am335x platform due to the gpio driver ready too later.
Quoted 4 lines
Regards,
Tony
Quoted 35 lines · qianfan
Quoted 33 lines · Tony Lindgren
Hi,
Quoted 11 lines · qianfan
Hi everyone:
On my board there has a gpio watchdong connected on am3358. And I found that the omap gpio device ready too later so it takes about 5 seconds when the gpio-wdt is ready.
I had tested on some version of linux, check when the OMAP GPIO is ready. Next is the log:
v4.19 [ 0.195191] OMAP GPIO hardware version 0.1
Quoted 8 lines
v5.4 [ 1.168868] OMAP GPIO hardware version 0.1
v5.9 [ 4.598052] OMAP GPIO hardware version 0.1
v5.15 [ 1.253851] OMAP GPIO hardware version 0.1
I can't find which commit slowdown omap gpio driver. could you please give me some advice?
We've moved to probe pretty much everything at normal
module_inittime instead of trying to probe everything early. Only clocks and system timers need to be probed early for the omap variants.One of the reasons for the device drivers probing later on during the boot is caused by
drivers/bus/ti-sysc.c. As ti-sysc is the parent device on the interconnect, none of it's child devices probe before it. And there should not be any need to probe ti-sysc early. The total boot-up time should be about the same, just the probe order has changed. If there are issues with the boot-up time in general, then that's a bug.
Quoted 8 lines
Quoted 2 lines
Maybe you want to configure the watchdog in the bootloader initially until the Linux device drivers get probed?
Yes, the gpio watchdog is alived on bootloader, I want find a good way to feed it until linux driver ready.
gpio-wdt.chas an optionCONFIG_GPIO_WATCHDOG_ARCH_INITCALLwhich will register gpio-wdt driver onarch_innitcall, but this feature doesn't work on am335x platform due to the gpio driver ready too later.
Well seems like the boottime of 1.25 seconds to having the gpio probed should be way longer than your bootloader configured watchdog timeout :) What do you have the bootloader set the watchdog timeout?
Regards,
Tony
Quoted 37 lines · Tony Lindgren
Quoted 36 lines · qianfan
Quoted 35 lines · Tony Lindgren
Hi,
Quoted 11 lines · qianfan
Hi everyone:
On my board there has a gpio watchdong connected on am3358. And I found that the omap gpio device ready too later so it takes about 5 seconds when the gpio-wdt is ready.
I had tested on some version of linux, check when the OMAP GPIO is ready. Next is the log:
v4.19 [ 0.195191] OMAP GPIO hardware version 0.1
Quoted 8 lines
v5.4 [ 1.168868] OMAP GPIO hardware version 0.1
v5.9 [ 4.598052] OMAP GPIO hardware version 0.1
v5.15 [ 1.253851] OMAP GPIO hardware version 0.1
I can't find which commit slowdown omap gpio driver. could you please give me some advice?
We've moved to probe pretty much everything at normal
module_inittime instead of trying to probe everything early. Only clocks and system timers need to be probed early for the omap variants.One of the reasons for the device drivers probing later on during the boot is caused by
drivers/bus/ti-sysc.c. As ti-sysc is the parent device on the interconnect, none of it's child devices probe before it. And there should not be any need to probe ti-sysc early. The total boot-up time should be about the same, just the probe order has changed. If there are issues with the boot-up time in general, then that's a bug.Maybe you want to configure the watchdog in the bootloader initially until the Linux device drivers get probed?
Quoted 8 lines
Quoted 5 lines
Yes, the gpio watchdog is alived on bootloader, I want find a good way to feed it until linux driver ready.
gpio-wdt.chas an optionCONFIG_GPIO_WATCHDOG_ARCH_INITCALLwhich will register gpio-wdt driver onarch_innitcall, but this feature doesn't work on am335x platform due to the gpio driver ready too later.Well seems like the boottime of 1.25 seconds to having the gpio probed should be way longer than your bootloader configured watchdog timeout :) What do you have the bootloader set the watchdog timeout?
I had sniffer the gpio data by using logic analysis, when the linux gpio-wdt driver toggle watchdog pin, it passed about 5 seconds after the u-boot done. And the gpio watchdog's deadline is 1.6s.
Quoted 4 lines
Regards,
Tony
Quoted 7 lines · qianfan
Quoted 3 lines · Tony Lindgren
Well seems like the boottime of 1.25 seconds to having the gpio probed should be way longer than your bootloader configured watchdog timeout :) What do you have the bootloader set the watchdog timeout?
I had sniffer the gpio data by using logic analysis, when the linux gpio-wdt driver toggle watchdog pin, it passed about 5 seconds after the u-boot done. And the gpio watchdog's deadline is 1.6s.
Well on my beaglebone black looks like gpios are initialized around 1.7s, but pinctrl is initialized around 0.25s. You could create some driver that in it's init sets the related gpio pin to PIN_OUTPUT_PULLUP | SAFE_MODE to kick the gpio watchdog, and then exits releasing the pinmux so the gpio based driver can take over. Or maybe your gpio watchdog driver could do pin configuration in init, then do what it currently does in probe.
Of course booting things faster would be the best solution, but that can easily get delayed with kernel updates with deferred probe for example.
Regards,
Tony