* [PATCH] drm/exynos: Make exynos_drm_init() call late during the bootup
@ 2014-05-14 11:39 Naveen Krishna Chatradhi
2014-05-21 6:39 ` Naveen Krishna Ch
2014-05-21 15:46 ` Thierry Reding
0 siblings, 2 replies; 5+ messages in thread
From: Naveen Krishna Chatradhi @ 2014-05-14 11:39 UTC (permalink / raw)
To: dri-devel, linux-samsung-soc; +Cc: seanpaul, inki.dae, naveenkrishna.ch
exynos_drm_init() does probing of various drivers like dp_panel,
hdmi, fimd, mixer, etc in an order and finally binds them together.
Some of the drm devices (Eg: dp_panel) try to do regulator_get()
and enable few supplies during their probe.
Chances are that, these devices may get probed before the respective
supply/PMIC is hooked. In such cases, dp_panel would continue with
"dummy regulator". Which is not what the system wants.
Lets give the core connectivity and regulators modules some time
to hookup the supplies before Exynos DRM devices comes into picture.
Signed-off-by: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
---
This change is proposed after
1. Discussing with I2C/SPI & DMA subsystem maintainers and Others
@ https://lkml.org/lkml/2014/5/9/333
Trying to change the I2C, SPI and DMA drivers as subsys_initcall()
Which was strictly opposed, as a flaw was found in DRM subsystem.
2. -EPROBE_DEFER won't work well with the current sequency of
platform_driver_register()s in exynos_drm_init()
3. bridge_panel mechanism is under RFC and no conclusions were drawn yet.
We should be able to probe each DRM device independently and let PROBE_DEFER
take care of dependencies. But, this could cause lot of bootup time.
late_initcall() of DRM works well and fixes all the above issues for now.
Kindly suggest, if an alternative/better mechanism is out there.
Thanks,
drivers/gpu/drm/exynos/exynos_drm_drv.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.c b/drivers/gpu/drm/exynos/exynos_drm_drv.c
index 4cef88f..78c185a 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_drv.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_drv.c
@@ -692,7 +692,7 @@ static void exynos_drm_exit(void)
platform_driver_unregister(&exynos_drm_platform_driver);
}
-module_init(exynos_drm_init);
+late_initcall(exynos_drm_init);
module_exit(exynos_drm_exit);
MODULE_AUTHOR("Inki Dae <inki.dae@samsung.com>");
--
1.7.9.5
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] drm/exynos: Make exynos_drm_init() call late during the bootup
2014-05-14 11:39 [PATCH] drm/exynos: Make exynos_drm_init() call late during the bootup Naveen Krishna Chatradhi
@ 2014-05-21 6:39 ` Naveen Krishna Ch
2014-05-21 15:46 ` Thierry Reding
1 sibling, 0 replies; 5+ messages in thread
From: Naveen Krishna Ch @ 2014-05-21 6:39 UTC (permalink / raw)
To: Naveen Krishna Chatradhi
Cc: dri-devel, linux-samsung-soc@vger.kernel.org, seanpaul, inki.dae,
dianders, sjg, Kukjin Kim, broonie
Hello Everyone,
On 14 May 2014 17:09, Naveen Krishna Chatradhi <ch.naveen@samsung.com> wrote:
> exynos_drm_init() does probing of various drivers like dp_panel,
> hdmi, fimd, mixer, etc in an order and finally binds them together.
>
> Some of the drm devices (Eg: dp_panel) try to do regulator_get()
> and enable few supplies during their probe.
> Chances are that, these devices may get probed before the respective
> supply/PMIC is hooked. In such cases, dp_panel would continue with
> "dummy regulator". Which is not what the system wants.
>
> Lets give the core connectivity and regulators modules some time
> to hookup the supplies before Exynos DRM devices comes into picture.
>
> Signed-off-by: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
> ---
> This change is proposed after
> 1. Discussing with I2C/SPI & DMA subsystem maintainers and Others
> @ https://lkml.org/lkml/2014/5/9/333
> Trying to change the I2C, SPI and DMA drivers as subsys_initcall()
> Which was strictly opposed, as a flaw was found in DRM subsystem.
>
> 2. -EPROBE_DEFER won't work well with the current sequency of
> platform_driver_register()s in exynos_drm_init()
>
> 3. bridge_panel mechanism is under RFC and no conclusions were drawn yet.
>
> We should be able to probe each DRM device independently and let PROBE_DEFER
> take care of dependencies. But, this could cause lot of bootup time.
>
> late_initcall() of DRM works well and fixes all the above issues for now.
> Kindly suggest, if an alternative/better mechanism is out there.
>
> Thanks,
> drivers/gpu/drm/exynos/exynos_drm_drv.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.c b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> index 4cef88f..78c185a 100644
> --- a/drivers/gpu/drm/exynos/exynos_drm_drv.c
> +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> @@ -692,7 +692,7 @@ static void exynos_drm_exit(void)
> platform_driver_unregister(&exynos_drm_platform_driver);
> }
>
> -module_init(exynos_drm_init);
> +late_initcall(exynos_drm_init);
> module_exit(exynos_drm_exit);
>
> MODULE_AUTHOR("Inki Dae <inki.dae@samsung.com>");
Kindly, show some light on this change.
Also adding more reviewers.
> --
> 1.7.9.5
>
--
Shine bright,
(: Nav :)
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] drm/exynos: Make exynos_drm_init() call late during the bootup
2014-05-14 11:39 [PATCH] drm/exynos: Make exynos_drm_init() call late during the bootup Naveen Krishna Chatradhi
2014-05-21 6:39 ` Naveen Krishna Ch
@ 2014-05-21 15:46 ` Thierry Reding
2014-05-26 5:39 ` Naveen Krishna Ch
1 sibling, 1 reply; 5+ messages in thread
From: Thierry Reding @ 2014-05-21 15:46 UTC (permalink / raw)
To: Naveen Krishna Chatradhi; +Cc: dri-devel, linux-samsung-soc, naveenkrishna.ch
[-- Attachment #1: Type: text/plain, Size: 1377 bytes --]
On Wed, May 14, 2014 at 05:09:45PM +0530, Naveen Krishna Chatradhi wrote:
> exynos_drm_init() does probing of various drivers like dp_panel,
> hdmi, fimd, mixer, etc in an order and finally binds them together.
>
> Some of the drm devices (Eg: dp_panel) try to do regulator_get()
> and enable few supplies during their probe.
> Chances are that, these devices may get probed before the respective
> supply/PMIC is hooked. In such cases, dp_panel would continue with
> "dummy regulator". Which is not what the system wants.
>
> Lets give the core connectivity and regulators modules some time
> to hookup the supplies before Exynos DRM devices comes into picture.
>
> Signed-off-by: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
> ---
> This change is proposed after
> 1. Discussing with I2C/SPI & DMA subsystem maintainers and Others
> @ https://lkml.org/lkml/2014/5/9/333
> Trying to change the I2C, SPI and DMA drivers as subsys_initcall()
> Which was strictly opposed, as a flaw was found in DRM subsystem.
>
> 2. -EPROBE_DEFER won't work well with the current sequency of
> platform_driver_register()s in exynos_drm_init()
Then this is the problem that you need to fix. If the driver doesn't
handle -EPROBE_DEFER properly then that means the driver is broken. No
amount of initcall ordering can fix this for you.
Thierry
[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] drm/exynos: Make exynos_drm_init() call late during the bootup
2014-05-21 15:46 ` Thierry Reding
@ 2014-05-26 5:39 ` Naveen Krishna Ch
2014-05-27 13:02 ` Inki Dae
0 siblings, 1 reply; 5+ messages in thread
From: Naveen Krishna Ch @ 2014-05-26 5:39 UTC (permalink / raw)
To: Thierry Reding
Cc: Naveen Krishna Chatradhi, dri-devel,
linux-samsung-soc@vger.kernel.org, seanpaul, inki.dae, a.hajda
Hello Everyone,
On 21 May 2014 21:16, Thierry Reding <thierry.reding@gmail.com> wrote:
> On Wed, May 14, 2014 at 05:09:45PM +0530, Naveen Krishna Chatradhi wrote:
>> exynos_drm_init() does probing of various drivers like dp_panel,
>> hdmi, fimd, mixer, etc in an order and finally binds them together.
>>
>> Some of the drm devices (Eg: dp_panel) try to do regulator_get()
>> and enable few supplies during their probe.
>> Chances are that, these devices may get probed before the respective
>> supply/PMIC is hooked. In such cases, dp_panel would continue with
>> "dummy regulator". Which is not what the system wants.
>>
>> Lets give the core connectivity and regulators modules some time
>> to hookup the supplies before Exynos DRM devices comes into picture.
>>
>> Signed-off-by: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
>> ---
>> This change is proposed after
>> 1. Discussing with I2C/SPI & DMA subsystem maintainers and Others
>> @ https://lkml.org/lkml/2014/5/9/333
>> Trying to change the I2C, SPI and DMA drivers as subsys_initcall()
>> Which was strictly opposed, as a flaw was found in DRM subsystem.
>>
>> 2. -EPROBE_DEFER won't work well with the current sequency of
>> platform_driver_register()s in exynos_drm_init()
>
> Then this is the problem that you need to fix. If the driver doesn't
> handle -EPROBE_DEFER properly then that means the driver is broken. No
> amount of initcall ordering can fix this for you.
We seem to have a problem with the probe sequencing and usage of _EPROBE_DEFER
in DRM. Component way of registration doesnt seem to fix everything.
Inki Dae,
Is there any discussion or approach underway.
Anyone working on this.
>
> Thierry
--
Shine bright,
(: Nav :)
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] drm/exynos: Make exynos_drm_init() call late during the bootup
2014-05-26 5:39 ` Naveen Krishna Ch
@ 2014-05-27 13:02 ` Inki Dae
0 siblings, 0 replies; 5+ messages in thread
From: Inki Dae @ 2014-05-27 13:02 UTC (permalink / raw)
To: Naveen Krishna Ch
Cc: linux-samsung-soc@vger.kernel.org, dri-devel, a.hajda,
Naveen Krishna Chatradhi
On 2014년 05월 26일 14:39, Naveen Krishna Ch wrote:
> Hello Everyone,
>
> On 21 May 2014 21:16, Thierry Reding <thierry.reding@gmail.com> wrote:
>> On Wed, May 14, 2014 at 05:09:45PM +0530, Naveen Krishna Chatradhi wrote:
>>> exynos_drm_init() does probing of various drivers like dp_panel,
>>> hdmi, fimd, mixer, etc in an order and finally binds them together.
>>>
>>> Some of the drm devices (Eg: dp_panel) try to do regulator_get()
>>> and enable few supplies during their probe.
>>> Chances are that, these devices may get probed before the respective
>>> supply/PMIC is hooked. In such cases, dp_panel would continue with
>>> "dummy regulator". Which is not what the system wants.
>>>
>>> Lets give the core connectivity and regulators modules some time
>>> to hookup the supplies before Exynos DRM devices comes into picture.
>>>
>>> Signed-off-by: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
>>> ---
>>> This change is proposed after
>>> 1. Discussing with I2C/SPI & DMA subsystem maintainers and Others
>>> @ https://lkml.org/lkml/2014/5/9/333
>>> Trying to change the I2C, SPI and DMA drivers as subsys_initcall()
>>> Which was strictly opposed, as a flaw was found in DRM subsystem.
>>>
>>> 2. -EPROBE_DEFER won't work well with the current sequency of
>>> platform_driver_register()s in exynos_drm_init()
>>
>> Then this is the problem that you need to fix. If the driver doesn't
>> handle -EPROBE_DEFER properly then that means the driver is broken. No
>> amount of initcall ordering can fix this for you.
>
> We seem to have a problem with the probe sequencing and usage of _EPROBE_DEFER
> in DRM. Component way of registration doesnt seem to fix everything.
>
> Inki Dae,
> Is there any discussion or approach underway.
> Anyone working on this.
Hi,
I have just posted a patch series, [PATCH 0/2] drm/exynos: consider
deferred probe case, to resolve that issue. With this, it wouldn't need
your patch anymore.
Thanks,
Inki Dae
>>
>> Thierry
>
>
>
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2014-05-27 13:02 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-14 11:39 [PATCH] drm/exynos: Make exynos_drm_init() call late during the bootup Naveen Krishna Chatradhi
2014-05-21 6:39 ` Naveen Krishna Ch
2014-05-21 15:46 ` Thierry Reding
2014-05-26 5:39 ` Naveen Krishna Ch
2014-05-27 13:02 ` Inki Dae
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.