All of lore.kernel.org
 help / color / mirror / Atom feed
* drm bridge control from another driver
@ 2019-02-11  6:52 ` Vinay Simha B N
  2019-02-11  8:32   ` Andrzej Hajda
  0 siblings, 1 reply; 11+ messages in thread
From: Vinay Simha B N @ 2019-02-11  6:52 UTC (permalink / raw)
  To: open list:DRM PANEL DRIVERS


[-- Attachment #1.1: Type: text/plain, Size: 228 bytes --]

hi,

is it possible to control the drm bridge from another driver in irq
handler(enable/disable the bridge)?

is there a way to control the "dpms force off" and "dpms force on" in the
interrupt handler?

-- 
regards,
vinaysimha

[-- Attachment #1.2: Type: text/html, Size: 431 bytes --]

[-- Attachment #2: Type: text/plain, Size: 160 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: drm bridge control from another driver
  2019-02-11  6:52 ` drm bridge control from another driver Vinay Simha B N
@ 2019-02-11  8:32   ` Andrzej Hajda
  2019-02-11  8:40     ` Daniel Vetter
  0 siblings, 1 reply; 11+ messages in thread
From: Andrzej Hajda @ 2019-02-11  8:32 UTC (permalink / raw)
  To: Vinay Simha B N, open list:DRM PANEL DRIVERS

On 11.02.2019 07:52, Vinay Simha B N wrote:
> hi,
>
> is it possible to control the drm bridge from another driver in irq
> handler(enable/disable the bridge)?


If you mean 'in irq context' the answer is no, usually enable/disable
callbacks can sleep, so cannot be called from atomic context.


>
> is there a way to control the "dpms force off" and "dpms force on" in
> the interrupt handler?


Could you elaborate more on both subjects.


Regards

Andrzej


>
> -- 
> regards,
> vinaysimha
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel


_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: drm bridge control from another driver
  2019-02-11  8:32   ` Andrzej Hajda
@ 2019-02-11  8:40     ` Daniel Vetter
  2019-02-11  9:11       ` Vinay Simha B N
  0 siblings, 1 reply; 11+ messages in thread
From: Daniel Vetter @ 2019-02-11  8:40 UTC (permalink / raw)
  To: Andrzej Hajda; +Cc: Vinay Simha B N, open list:DRM PANEL DRIVERS

On Mon, Feb 11, 2019 at 09:32:54AM +0100, Andrzej Hajda wrote:
> On 11.02.2019 07:52, Vinay Simha B N wrote:
> > hi,
> >
> > is it possible to control the drm bridge from another driver in irq
> > handler(enable/disable the bridge)?
> 
> 
> If you mean 'in irq context' the answer is no, usually enable/disable
> callbacks can sleep, so cannot be called from atomic context.
> 
> 
> >
> > is there a way to control the "dpms force off" and "dpms force on" in
> > the interrupt handler?
> 
> 
> Could you elaborate more on both subjects.

Yeah, please explain what you want to use this for. dpms on/off is
controlled by userspace, the kernel should not change that state behind
usersapce's back. If this is for some manuel refresh display, then that's
a bit a different story ofc, but for that you don't want to do a real dpms
force off/on.
-Daniel
> 
> 
> Regards
> 
> Andrzej
> 
> 
> >
> > -- 
> > regards,
> > vinaysimha
> >
> > _______________________________________________
> > dri-devel mailing list
> > dri-devel@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/dri-devel
> 
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: drm bridge control from another driver
  2019-02-11  8:40     ` Daniel Vetter
@ 2019-02-11  9:11       ` Vinay Simha B N
  2019-02-13 13:40         ` Vinay Simha B N via dri-devel
  0 siblings, 1 reply; 11+ messages in thread
From: Vinay Simha B N @ 2019-02-11  9:11 UTC (permalink / raw)
  To: Daniel Vetter; +Cc: open list:DRM PANEL DRIVERS


[-- Attachment #1.1: Type: text/plain, Size: 1946 bytes --]

dsi2hdmi(adv7511) chip operating temperature range is -10 degC to +85 degC.
We want to enable/disable the bridge only when temperature range is
inbetween these range.

We have temperature control chip to read the temp, tLow an tHigh can be
set. whenever interrupt(alert) triggers we want to enablel/disable the
bridge.

Any suggestion what is the better way to handle this scenario?

regards,
vinaysimha

On Mon, Feb 11, 2019 at 2:10 PM Daniel Vetter <daniel@ffwll.ch> wrote:

> On Mon, Feb 11, 2019 at 09:32:54AM +0100, Andrzej Hajda wrote:
> > On 11.02.2019 07:52, Vinay Simha B N wrote:
> > > hi,
> > >
> > > is it possible to control the drm bridge from another driver in irq
> > > handler(enable/disable the bridge)?
> >
> >
> > If you mean 'in irq context' the answer is no, usually enable/disable
> > callbacks can sleep, so cannot be called from atomic context.
> >
> >
> > >
> > > is there a way to control the "dpms force off" and "dpms force on" in
> > > the interrupt handler?
> >
> >
> > Could you elaborate more on both subjects.
>
> Yeah, please explain what you want to use this for. dpms on/off is
> controlled by userspace, the kernel should not change that state behind
> usersapce's back. If this is for some manuel refresh display, then that's
> a bit a different story ofc, but for that you don't want to do a real dpms
> force off/on.
> -Daniel
> >
> >
> > Regards
> >
> > Andrzej
> >
> >
> > >
> > > --
> > > regards,
> > > vinaysimha
> > >
> > > _______________________________________________
> > > dri-devel mailing list
> > > dri-devel@lists.freedesktop.org
> > > https://lists.freedesktop.org/mailman/listinfo/dri-devel
> >
> >
> > _______________________________________________
> > dri-devel mailing list
> > dri-devel@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/dri-devel
>
> --
> Daniel Vetter
> Software Engineer, Intel Corporation
> http://blog.ffwll.ch
>


-- 
regards,
vinaysimha

[-- Attachment #1.2: Type: text/html, Size: 3173 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: drm bridge control from another driver
  2019-02-11  9:11       ` Vinay Simha B N
@ 2019-02-13 13:40         ` Vinay Simha B N via dri-devel
  2019-02-13 14:14           ` Andrzej Hajda via dri-devel
  0 siblings, 1 reply; 11+ messages in thread
From: Vinay Simha B N via dri-devel @ 2019-02-13 13:40 UTC (permalink / raw)
  To: Daniel Vetter, Andrzej Hajda; +Cc: open list:DRM PANEL DRIVERS


[-- Attachment #1.1: Type: text/plain, Size: 2250 bytes --]

Andrzej/Daniel,

please suggest any input on the scenario for temperature control and dsi
bridge enable/disable.

On Mon, Feb 11, 2019 at 2:41 PM Vinay Simha B N <simhavcs@gmail.com> wrote:

> dsi2hdmi(adv7511) chip operating temperature range is -10 degC to +85
> degC. We want to enable/disable the bridge only when temperature range is
> inbetween these range.
>
> We have temperature control chip to read the temp, tLow an tHigh can be
> set. whenever interrupt(alert) triggers we want to enablel/disable the
> bridge.
>
> Any suggestion what is the better way to handle this scenario?
>
> regards,
> vinaysimha
>
> On Mon, Feb 11, 2019 at 2:10 PM Daniel Vetter <daniel@ffwll.ch> wrote:
>
>> On Mon, Feb 11, 2019 at 09:32:54AM +0100, Andrzej Hajda wrote:
>> > On 11.02.2019 07:52, Vinay Simha B N wrote:
>> > > hi,
>> > >
>> > > is it possible to control the drm bridge from another driver in irq
>> > > handler(enable/disable the bridge)?
>> >
>> >
>> > If you mean 'in irq context' the answer is no, usually enable/disable
>> > callbacks can sleep, so cannot be called from atomic context.
>> >
>> >
>> > >
>> > > is there a way to control the "dpms force off" and "dpms force on" in
>> > > the interrupt handler?
>> >
>> >
>> > Could you elaborate more on both subjects.
>>
>> Yeah, please explain what you want to use this for. dpms on/off is
>> controlled by userspace, the kernel should not change that state behind
>> usersapce's back. If this is for some manuel refresh display, then that's
>> a bit a different story ofc, but for that you don't want to do a real dpms
>> force off/on.
>> -Daniel
>> >
>> >
>> > Regards
>> >
>> > Andrzej
>> >
>> >
>> > >
>> > > --
>> > > regards,
>> > > vinaysimha
>> > >
>> > > _______________________________________________
>> > > dri-devel mailing list
>> > > dri-devel@lists.freedesktop.org
>> > > https://lists.freedesktop.org/mailman/listinfo/dri-devel
>> >
>> >
>> > _______________________________________________
>> > dri-devel mailing list
>> > dri-devel@lists.freedesktop.org
>> > https://lists.freedesktop.org/mailman/listinfo/dri-devel
>>
>> --
>> Daniel Vetter
>> Software Engineer, Intel Corporation
>> http://blog.ffwll.ch
>>
>
>
> --
> regards,
> vinaysimha
>


-- 
regards,
vinaysimha

[-- Attachment #1.2: Type: text/html, Size: 3801 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: drm bridge control from another driver
  2019-02-13 13:40         ` Vinay Simha B N via dri-devel
@ 2019-02-13 14:14           ` Andrzej Hajda via dri-devel
  2019-02-13 14:31             ` Vinay Simha B N via dri-devel
  0 siblings, 1 reply; 11+ messages in thread
From: Andrzej Hajda via dri-devel @ 2019-02-13 14:14 UTC (permalink / raw)
  To: Vinay Simha B N, Daniel Vetter; +Cc: open list:DRM PANEL DRIVERS

On 13.02.2019 14:40, Vinay Simha B N wrote:
> Andrzej/Daniel,
>
> please suggest any input on the scenario for temperature control and
> dsi bridge enable/disable.
>
> On Mon, Feb 11, 2019 at 2:41 PM Vinay Simha B N <simhavcs@gmail.com
> <mailto:simhavcs@gmail.com>> wrote:
>
>     dsi2hdmi(adv7511) chip operating temperature range is -10 degC
>     to +85 degC. We want to enable/disable the bridge only when
>     temperature range is inbetween these range.
>
>     We have temperature control chip to read the temp, tLow an tHigh
>     can be set. whenever interrupt(alert) triggers we want to
>     enablel/disable the bridge.
>
>     Any suggestion what is the better way to handle this scenario?
>

Why do you need to bother about this quite big range at all?

I guess the best would be to set whole platform operating temperature
range, and poweroff/sleep/slow down/??? whole system, not just one
random chip, which probably is not the most fragile piece, am I right?


If you really insist on handling it per chip, you can try to investigate
following paths:

1. Just disable the chip, without noticing drm, other drivers, or
userspace, and re-enable it if temperature become acceptable, but I am
not sure if this will not change behavior of other chips.

2. Disable the chip and report to the drm subsystem
connector_status_disconnected - this will cause drm to stop display
pipeline and userspace notification.


Regards

Andrzej


>
>     regards,
>     vinaysimha
>
>     On Mon, Feb 11, 2019 at 2:10 PM Daniel Vetter <daniel@ffwll.ch
>     <mailto:daniel@ffwll.ch>> wrote:
>
>         On Mon, Feb 11, 2019 at 09:32:54AM +0100, Andrzej Hajda wrote:
>         > On 11.02.2019 07:52, Vinay Simha B N wrote:
>         > > hi,
>         > >
>         > > is it possible to control the drm bridge from another
>         driver in irq
>         > > handler(enable/disable the bridge)?
>         >
>         >
>         > If you mean 'in irq context' the answer is no, usually
>         enable/disable
>         > callbacks can sleep, so cannot be called from atomic context.
>         >
>         >
>         > >
>         > > is there a way to control the "dpms force off" and "dpms
>         force on" in
>         > > the interrupt handler?
>         >
>         >
>         > Could you elaborate more on both subjects.
>
>         Yeah, please explain what you want to use this for. dpms on/off is
>         controlled by userspace, the kernel should not change that
>         state behind
>         usersapce's back. If this is for some manuel refresh display,
>         then that's
>         a bit a different story ofc, but for that you don't want to do
>         a real dpms
>         force off/on.
>         -Daniel
>         >
>         >
>         > Regards
>         >
>         > Andrzej
>         >
>         >
>         > >
>         > > --
>         > > regards,
>         > > vinaysimha
>         > >
>         > > _______________________________________________
>         > > dri-devel mailing list
>         > > dri-devel@lists.freedesktop.org
>         <mailto:dri-devel@lists.freedesktop.org>
>         > > https://lists.freedesktop.org/mailman/listinfo/dri-devel
>         >
>         >
>         > _______________________________________________
>         > dri-devel mailing list
>         > dri-devel@lists.freedesktop.org
>         <mailto:dri-devel@lists.freedesktop.org>
>         > https://lists.freedesktop.org/mailman/listinfo/dri-devel
>
>         -- 
>         Daniel Vetter
>         Software Engineer, Intel Corporation
>         http://blog.ffwll.ch
>
>
>
>     -- 
>     regards,
>     vinaysimha
>
>
>
> -- 
> regards,
> vinaysimha


_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: drm bridge control from another driver
  2019-02-13 14:14           ` Andrzej Hajda via dri-devel
@ 2019-02-13 14:31             ` Vinay Simha B N via dri-devel
  2019-02-14 14:33               ` Andrzej Hajda via dri-devel
  0 siblings, 1 reply; 11+ messages in thread
From: Vinay Simha B N via dri-devel @ 2019-02-13 14:31 UTC (permalink / raw)
  To: Andrzej Hajda; +Cc: open list:DRM PANEL DRIVERS


[-- Attachment #1.1: Type: text/plain, Size: 4962 bytes --]

On Wed, Feb 13, 2019 at 7:44 PM Andrzej Hajda <a.hajda@samsung.com> wrote:

> On 13.02.2019 14:40, Vinay Simha B N wrote:
> > Andrzej/Daniel,
> >
> > please suggest any input on the scenario for temperature control and
> > dsi bridge enable/disable.
> >
> > On Mon, Feb 11, 2019 at 2:41 PM Vinay Simha B N <simhavcs@gmail.com
> > <mailto:simhavcs@gmail.com>> wrote:
> >
> >     dsi2hdmi(adv7511) chip operating temperature range is -10 degC
> >     to +85 degC. We want to enable/disable the bridge only when
> >     temperature range is inbetween these range.
> >
> >     We have temperature control chip to read the temp, tLow an tHigh
> >     can be set. whenever interrupt(alert) triggers we want to
> >     enablel/disable the bridge.
> >
> >     Any suggestion what is the better way to handle this scenario?
> >
>
> Why do you need to bother about this quite big range at all?
>
we are looking for -10 deg C, this system will be used in a place where
temp goes beyond -20 deg C... processor(apq8016/410c) can handle upto -30,
but dsi2hdmi(adv7533) chip if enabled beyond -10 deg C, life of the chip
goes down or it cannot operate at all.

>
> I guess the best would be to set whole platform operating temperature
> range, and poweroff/sleep/slow down/??? whole system, not just one
> random chip, which probably is not the most fragile piece, am I right?
>
> right now we are focused only to disable the hdmi chip if temp goes beyond
-10, since this is only chip in board faces temp issue, other components
are fine to go upto -30 deg C.

>
> If you really insist on handling it per chip, you can try to investigate
> following paths:
>
> 1. Just disable the chip, without noticing drm, other drivers, or
> userspace, and re-enable it if temperature become acceptable, but I am
> not sure if this will not change behavior of other chips.
>
> dsi2hdmi tied with drm framework, i need to enable/disable the bridge. i
can disable the regulators enabled for it , but this does not work as we
want.


> 2. Disable the chip and report to the drm subsystem
> connector_status_disconnected - this will cause drm to stop display
> pipeline and userspace notification.
>
> any references/driver on how to disable and report to drm susbsystem will
help to implement.
connector_status_disconnected i need to call in the interrupt handler of
tmp102 driver.

in userspace when i tried manually  below commands, there is no impact in
the display.
/sys/class/drm/card0-HDMI-A-1/status
echo off > status
echo on > status

>
> Regards
>
> Andrzej
>
>
> >
> >     regards,
> >     vinaysimha
> >
> >     On Mon, Feb 11, 2019 at 2:10 PM Daniel Vetter <daniel@ffwll.ch
> >     <mailto:daniel@ffwll.ch>> wrote:
> >
> >         On Mon, Feb 11, 2019 at 09:32:54AM +0100, Andrzej Hajda wrote:
> >         > On 11.02.2019 07:52, Vinay Simha B N wrote:
> >         > > hi,
> >         > >
> >         > > is it possible to control the drm bridge from another
> >         driver in irq
> >         > > handler(enable/disable the bridge)?
> >         >
> >         >
> >         > If you mean 'in irq context' the answer is no, usually
> >         enable/disable
> >         > callbacks can sleep, so cannot be called from atomic context.
> >         >
> >         >
> >         > >
> >         > > is there a way to control the "dpms force off" and "dpms
> >         force on" in
> >         > > the interrupt handler?
> >         >
> >         >
> >         > Could you elaborate more on both subjects.
> >
> >         Yeah, please explain what you want to use this for. dpms on/off
> is
> >         controlled by userspace, the kernel should not change that
> >         state behind
> >         usersapce's back. If this is for some manuel refresh display,
> >         then that's
> >         a bit a different story ofc, but for that you don't want to do
> >         a real dpms
> >         force off/on.
> >         -Daniel
> >         >
> >         >
> >         > Regards
> >         >
> >         > Andrzej
> >         >
> >         >
> >         > >
> >         > > --
> >         > > regards,
> >         > > vinaysimha
> >         > >
> >         > > _______________________________________________
> >         > > dri-devel mailing list
> >         > > dri-devel@lists.freedesktop.org
> >         <mailto:dri-devel@lists.freedesktop.org>
> >         > > https://lists.freedesktop.org/mailman/listinfo/dri-devel
> >         >
> >         >
> >         > _______________________________________________
> >         > dri-devel mailing list
> >         > dri-devel@lists.freedesktop.org
> >         <mailto:dri-devel@lists.freedesktop.org>
> >         > https://lists.freedesktop.org/mailman/listinfo/dri-devel
> >
> >         --
> >         Daniel Vetter
> >         Software Engineer, Intel Corporation
> >         http://blog.ffwll.ch
> >
> >
> >
> >     --
> >     regards,
> >     vinaysimha
> >
> >
> >
> > --
> > regards,
> > vinaysimha
>
>
>

-- 
regards,
vinaysimha

[-- Attachment #1.2: Type: text/html, Size: 8055 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: drm bridge control from another driver
  2019-02-13 14:31             ` Vinay Simha B N via dri-devel
@ 2019-02-14 14:33               ` Andrzej Hajda via dri-devel
  2019-02-18 15:19                 ` Vinay Simha B N
  0 siblings, 1 reply; 11+ messages in thread
From: Andrzej Hajda via dri-devel @ 2019-02-14 14:33 UTC (permalink / raw)
  To: Vinay Simha B N; +Cc: open list:DRM PANEL DRIVERS

On 13.02.2019 15:31, Vinay Simha B N wrote:
>
>
> On Wed, Feb 13, 2019 at 7:44 PM Andrzej Hajda <a.hajda@samsung.com
> <mailto:a.hajda@samsung.com>> wrote:
>
>     On 13.02.2019 14:40, Vinay Simha B N wrote:
>     > Andrzej/Daniel,
>     >
>     > please suggest any input on the scenario for temperature control and
>     > dsi bridge enable/disable.
>     >
>     > On Mon, Feb 11, 2019 at 2:41 PM Vinay Simha B N
>     <simhavcs@gmail.com <mailto:simhavcs@gmail.com>
>     > <mailto:simhavcs@gmail.com <mailto:simhavcs@gmail.com>>> wrote:
>     >
>     >     dsi2hdmi(adv7511) chip operating temperature range is -10 degC
>     >     to +85 degC. We want to enable/disable the bridge only when
>     >     temperature range is inbetween these range.
>     >
>     >     We have temperature control chip to read the temp, tLow an tHigh
>     >     can be set. whenever interrupt(alert) triggers we want to
>     >     enablel/disable the bridge.
>     >
>     >     Any suggestion what is the better way to handle this scenario?
>     >
>
>     Why do you need to bother about this quite big range at all?
>
> we are looking for -10 deg C, this system will be used in a place
> where temp goes beyond -20 deg C... processor(apq8016/410c) can handle
> upto -30, but dsi2hdmi(adv7533) chip if enabled beyond -10 deg C, life
> of the chip goes down or it cannot operate at all. 
>
>
>     I guess the best would be to set whole platform operating temperature
>     range, and poweroff/sleep/slow down/??? whole system, not just one
>     random chip, which probably is not the most fragile piece, am I right?
>
> right now we are focused only to disable the hdmi chip if temp goes
> beyond -10, since this is only chip in board faces temp issue, other
> components are fine to go upto -30 deg C.
>
>
>     If you really insist on handling it per chip, you can try to
>     investigate
>     following paths:
>
>     1. Just disable the chip, without noticing drm, other drivers, or
>     userspace, and re-enable it if temperature become acceptable, but I am
>     not sure if this will not change behavior of other chips.
>
> dsi2hdmi tied with drm framework, i need to enable/disable the bridge.
> i can disable the regulators enabled for it , but this does not work
> as we want.
>  
>
>     2. Disable the chip and report to the drm subsystem
>     connector_status_disconnected - this will cause drm to stop display
>     pipeline and userspace notification.
>
> any references/driver on how to disable and report to drm susbsystem
> will help to implement.
> connector_status_disconnected i need to call in the interrupt handler
> of tmp102 driver.


Look at the code of adv7511_hpd_work, it evaluates connector status
based on ADV7511_REG_STATUS, so you can put there temperature check
also, and call 'schedule_work(&adv7511->hpd_work)'

if temperature passes valid temp range.

If you want to do it in mainline, please consult it with adv7511
authors/commiters.


Regards

Andrzej


>
> in userspace when i tried manually  below commands, there is no impact
> in the display.
> /sys/class/drm/card0-HDMI-A-1/status
> echo off > status
> echo on > status
>
>
>     Regards
>
>     Andrzej
>
>
>     >
>     >     regards,
>     >     vinaysimha
>     >
>     >     On Mon, Feb 11, 2019 at 2:10 PM Daniel Vetter
>     <daniel@ffwll.ch <mailto:daniel@ffwll.ch>
>     >     <mailto:daniel@ffwll.ch <mailto:daniel@ffwll.ch>>> wrote:
>     >
>     >         On Mon, Feb 11, 2019 at 09:32:54AM +0100, Andrzej Hajda
>     wrote:
>     >         > On 11.02.2019 07:52, Vinay Simha B N wrote:
>     >         > > hi,
>     >         > >
>     >         > > is it possible to control the drm bridge from another
>     >         driver in irq
>     >         > > handler(enable/disable the bridge)?
>     >         >
>     >         >
>     >         > If you mean 'in irq context' the answer is no, usually
>     >         enable/disable
>     >         > callbacks can sleep, so cannot be called from atomic
>     context.
>     >         >
>     >         >
>     >         > >
>     >         > > is there a way to control the "dpms force off" and "dpms
>     >         force on" in
>     >         > > the interrupt handler?
>     >         >
>     >         >
>     >         > Could you elaborate more on both subjects.
>     >
>     >         Yeah, please explain what you want to use this for. dpms
>     on/off is
>     >         controlled by userspace, the kernel should not change that
>     >         state behind
>     >         usersapce's back. If this is for some manuel refresh
>     display,
>     >         then that's
>     >         a bit a different story ofc, but for that you don't want
>     to do
>     >         a real dpms
>     >         force off/on.
>     >         -Daniel
>     >         >
>     >         >
>     >         > Regards
>     >         >
>     >         > Andrzej
>     >         >
>     >         >
>     >         > >
>     >         > > --
>     >         > > regards,
>     >         > > vinaysimha
>     >         > >
>     >         > > _______________________________________________
>     >         > > dri-devel mailing list
>     >         > > dri-devel@lists.freedesktop.org
>     <mailto:dri-devel@lists.freedesktop.org>
>     >         <mailto:dri-devel@lists.freedesktop.org
>     <mailto:dri-devel@lists.freedesktop.org>>
>     >         > > https://lists.freedesktop.org/mailman/listinfo/dri-devel
>     >         >
>     >         >
>     >         > _______________________________________________
>     >         > dri-devel mailing list
>     >         > dri-devel@lists.freedesktop.org
>     <mailto:dri-devel@lists.freedesktop.org>
>     >         <mailto:dri-devel@lists.freedesktop.org
>     <mailto:dri-devel@lists.freedesktop.org>>
>     >         > https://lists.freedesktop.org/mailman/listinfo/dri-devel
>     >
>     >         --
>     >         Daniel Vetter
>     >         Software Engineer, Intel Corporation
>     >         http://blog.ffwll.ch
>     >
>     >
>     >
>     >     --
>     >     regards,
>     >     vinaysimha
>     >
>     >
>     >
>     > --
>     > regards,
>     > vinaysimha
>
>
>
>
> -- 
> regards,
> vinaysimha


_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: drm bridge control from another driver
  2019-02-14 14:33               ` Andrzej Hajda via dri-devel
@ 2019-02-18 15:19                 ` Vinay Simha B N
  2019-02-20 14:20                   ` Vinay Simha B N
  2019-02-20 14:42                   ` A H
  0 siblings, 2 replies; 11+ messages in thread
From: Vinay Simha B N @ 2019-02-18 15:19 UTC (permalink / raw)
  To: Andrzej Hajda, lars; +Cc: open list:DRM PANEL DRIVERS


[-- Attachment #1.1: Type: text/plain, Size: 7280 bytes --]

added the temperature alert irq handler in adv driver , in the irq
calling schedule_work(&adv7511->hpd_work); , initially in the
adv7511_detect , if we set status = connector_status_disconnected; later
when irq handler calls the schedule work, hpd does not works.
[   55.052677] [drm] Cannot find any crtc or sizes
[   55.058786] [drm] Cannot find any crtc or sizes

by default driver of adv, hpd does not works as expected, board boots
without hdmi connected, after postboot if we connect hdmi , in irq hpd_work
,but to get the display we need to press ctrl+alt+backspace.


On Thu, Feb 14, 2019 at 8:03 PM Andrzej Hajda <a.hajda@samsung.com> wrote:

> On 13.02.2019 15:31, Vinay Simha B N wrote:
> >
> >
> > On Wed, Feb 13, 2019 at 7:44 PM Andrzej Hajda <a.hajda@samsung.com
> > <mailto:a.hajda@samsung.com>> wrote:
> >
> >     On 13.02.2019 14:40, Vinay Simha B N wrote:
> >     > Andrzej/Daniel,
> >     >
> >     > please suggest any input on the scenario for temperature control
> and
> >     > dsi bridge enable/disable.
> >     >
> >     > On Mon, Feb 11, 2019 at 2:41 PM Vinay Simha B N
> >     <simhavcs@gmail.com <mailto:simhavcs@gmail.com>
> >     > <mailto:simhavcs@gmail.com <mailto:simhavcs@gmail.com>>> wrote:
> >     >
> >     >     dsi2hdmi(adv7511) chip operating temperature range is -10 degC
> >     >     to +85 degC. We want to enable/disable the bridge only when
> >     >     temperature range is inbetween these range.
> >     >
> >     >     We have temperature control chip to read the temp, tLow an
> tHigh
> >     >     can be set. whenever interrupt(alert) triggers we want to
> >     >     enablel/disable the bridge.
> >     >
> >     >     Any suggestion what is the better way to handle this scenario?
> >     >
> >
> >     Why do you need to bother about this quite big range at all?
> >
> > we are looking for -10 deg C, this system will be used in a place
> > where temp goes beyond -20 deg C... processor(apq8016/410c) can handle
> > upto -30, but dsi2hdmi(adv7533) chip if enabled beyond -10 deg C, life
> > of the chip goes down or it cannot operate at all.
> >
> >
> >     I guess the best would be to set whole platform operating temperature
> >     range, and poweroff/sleep/slow down/??? whole system, not just one
> >     random chip, which probably is not the most fragile piece, am I
> right?
> >
> > right now we are focused only to disable the hdmi chip if temp goes
> > beyond -10, since this is only chip in board faces temp issue, other
> > components are fine to go upto -30 deg C.
> >
> >
> >     If you really insist on handling it per chip, you can try to
> >     investigate
> >     following paths:
> >
> >     1. Just disable the chip, without noticing drm, other drivers, or
> >     userspace, and re-enable it if temperature become acceptable, but I
> am
> >     not sure if this will not change behavior of other chips.
> >
> > dsi2hdmi tied with drm framework, i need to enable/disable the bridge.
> > i can disable the regulators enabled for it , but this does not work
> > as we want.
> >
> >
> >     2. Disable the chip and report to the drm subsystem
> >     connector_status_disconnected - this will cause drm to stop display
> >     pipeline and userspace notification.
> >
> > any references/driver on how to disable and report to drm susbsystem
> > will help to implement.
> > connector_status_disconnected i need to call in the interrupt handler
> > of tmp102 driver.
>
>
> Look at the code of adv7511_hpd_work, it evaluates connector status
> based on ADV7511_REG_STATUS, so you can put there temperature check
> also, and call 'schedule_work(&adv7511->hpd_work)'
>
> if temperature passes valid temp range.
>
> If you want to do it in mainline, please consult it with adv7511
> authors/commiters.
>
>
> Regards
>
> Andrzej
>
>
> >
> > in userspace when i tried manually  below commands, there is no impact
> > in the display.
> > /sys/class/drm/card0-HDMI-A-1/status
> > echo off > status
> > echo on > status
> >
> >
> >     Regards
> >
> >     Andrzej
> >
> >
> >     >
> >     >     regards,
> >     >     vinaysimha
> >     >
> >     >     On Mon, Feb 11, 2019 at 2:10 PM Daniel Vetter
> >     <daniel@ffwll.ch <mailto:daniel@ffwll.ch>
> >     >     <mailto:daniel@ffwll.ch <mailto:daniel@ffwll.ch>>> wrote:
> >     >
> >     >         On Mon, Feb 11, 2019 at 09:32:54AM +0100, Andrzej Hajda
> >     wrote:
> >     >         > On 11.02.2019 07:52, Vinay Simha B N wrote:
> >     >         > > hi,
> >     >         > >
> >     >         > > is it possible to control the drm bridge from another
> >     >         driver in irq
> >     >         > > handler(enable/disable the bridge)?
> >     >         >
> >     >         >
> >     >         > If you mean 'in irq context' the answer is no, usually
> >     >         enable/disable
> >     >         > callbacks can sleep, so cannot be called from atomic
> >     context.
> >     >         >
> >     >         >
> >     >         > >
> >     >         > > is there a way to control the "dpms force off" and
> "dpms
> >     >         force on" in
> >     >         > > the interrupt handler?
> >     >         >
> >     >         >
> >     >         > Could you elaborate more on both subjects.
> >     >
> >     >         Yeah, please explain what you want to use this for. dpms
> >     on/off is
> >     >         controlled by userspace, the kernel should not change that
> >     >         state behind
> >     >         usersapce's back. If this is for some manuel refresh
> >     display,
> >     >         then that's
> >     >         a bit a different story ofc, but for that you don't want
> >     to do
> >     >         a real dpms
> >     >         force off/on.
> >     >         -Daniel
> >     >         >
> >     >         >
> >     >         > Regards
> >     >         >
> >     >         > Andrzej
> >     >         >
> >     >         >
> >     >         > >
> >     >         > > --
> >     >         > > regards,
> >     >         > > vinaysimha
> >     >         > >
> >     >         > > _______________________________________________
> >     >         > > dri-devel mailing list
> >     >         > > dri-devel@lists.freedesktop.org
> >     <mailto:dri-devel@lists.freedesktop.org>
> >     >         <mailto:dri-devel@lists.freedesktop.org
> >     <mailto:dri-devel@lists.freedesktop.org>>
> >     >         > >
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
> >     >         >
> >     >         >
> >     >         > _______________________________________________
> >     >         > dri-devel mailing list
> >     >         > dri-devel@lists.freedesktop.org
> >     <mailto:dri-devel@lists.freedesktop.org>
> >     >         <mailto:dri-devel@lists.freedesktop.org
> >     <mailto:dri-devel@lists.freedesktop.org>>
> >     >         > https://lists.freedesktop.org/mailman/listinfo/dri-devel
> >     >
> >     >         --
> >     >         Daniel Vetter
> >     >         Software Engineer, Intel Corporation
> >     >         http://blog.ffwll.ch
> >     >
> >     >
> >     >
> >     >     --
> >     >     regards,
> >     >     vinaysimha
> >     >
> >     >
> >     >
> >     > --
> >     > regards,
> >     > vinaysimha
> >
> >
> >
> >
> > --
> > regards,
> > vinaysimha
>
>
>

-- 
regards,
vinaysimha

[-- Attachment #1.2: Type: text/html, Size: 11690 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: drm bridge control from another driver
  2019-02-18 15:19                 ` Vinay Simha B N
@ 2019-02-20 14:20                   ` Vinay Simha B N
  2019-02-20 14:42                   ` A H
  1 sibling, 0 replies; 11+ messages in thread
From: Vinay Simha B N @ 2019-02-20 14:20 UTC (permalink / raw)
  To: Andrzej Hajda, lars, Laurent.pinchart, Archit Taneja, David Airlie
  Cc: open list:DRM PANEL DRIVERS, open list


[-- Attachment #1.1: Type: text/plain, Size: 7947 bytes --]

hi,

i had added one more irq control for temperature control check in adv7511,
if i call irq_proces as similar to hpd it does not work, initially if(
adv7511->alert_status == connector_status_connected) no irq works.

https://github.com/vinaysimha/kernel-msm/commit/8ee2b9104fa56765320d4846086d91b8271f5609

please suggest.

On Mon, Feb 18, 2019 at 8:49 PM Vinay Simha B N <simhavcs@gmail.com> wrote:

> added the temperature alert irq handler in adv driver , in the irq
> calling schedule_work(&adv7511->hpd_work); , initially in the
> adv7511_detect , if we set status = connector_status_disconnected; later
> when irq handler calls the schedule work, hpd does not works.
> [   55.052677] [drm] Cannot find any crtc or sizes
> [   55.058786] [drm] Cannot find any crtc or sizes
>
> by default driver of adv, hpd does not works as expected, board boots
> without hdmi connected, after postboot if we connect hdmi , in irq hpd_work
> ,but to get the display we need to press ctrl+alt+backspace.
>
>
> On Thu, Feb 14, 2019 at 8:03 PM Andrzej Hajda <a.hajda@samsung.com> wrote:
>
>> On 13.02.2019 15:31, Vinay Simha B N wrote:
>> >
>> >
>> > On Wed, Feb 13, 2019 at 7:44 PM Andrzej Hajda <a.hajda@samsung.com
>> > <mailto:a.hajda@samsung.com>> wrote:
>> >
>> >     On 13.02.2019 14:40, Vinay Simha B N wrote:
>> >     > Andrzej/Daniel,
>> >     >
>> >     > please suggest any input on the scenario for temperature control
>> and
>> >     > dsi bridge enable/disable.
>> >     >
>> >     > On Mon, Feb 11, 2019 at 2:41 PM Vinay Simha B N
>> >     <simhavcs@gmail.com <mailto:simhavcs@gmail.com>
>> >     > <mailto:simhavcs@gmail.com <mailto:simhavcs@gmail.com>>> wrote:
>> >     >
>> >     >     dsi2hdmi(adv7511) chip operating temperature range is -10 degC
>> >     >     to +85 degC. We want to enable/disable the bridge only when
>> >     >     temperature range is inbetween these range.
>> >     >
>> >     >     We have temperature control chip to read the temp, tLow an
>> tHigh
>> >     >     can be set. whenever interrupt(alert) triggers we want to
>> >     >     enablel/disable the bridge.
>> >     >
>> >     >     Any suggestion what is the better way to handle this scenario?
>> >     >
>> >
>> >     Why do you need to bother about this quite big range at all?
>> >
>> > we are looking for -10 deg C, this system will be used in a place
>> > where temp goes beyond -20 deg C... processor(apq8016/410c) can handle
>> > upto -30, but dsi2hdmi(adv7533) chip if enabled beyond -10 deg C, life
>> > of the chip goes down or it cannot operate at all.
>> >
>> >
>> >     I guess the best would be to set whole platform operating
>> temperature
>> >     range, and poweroff/sleep/slow down/??? whole system, not just one
>> >     random chip, which probably is not the most fragile piece, am I
>> right?
>> >
>> > right now we are focused only to disable the hdmi chip if temp goes
>> > beyond -10, since this is only chip in board faces temp issue, other
>> > components are fine to go upto -30 deg C.
>> >
>> >
>> >     If you really insist on handling it per chip, you can try to
>> >     investigate
>> >     following paths:
>> >
>> >     1. Just disable the chip, without noticing drm, other drivers, or
>> >     userspace, and re-enable it if temperature become acceptable, but I
>> am
>> >     not sure if this will not change behavior of other chips.
>> >
>> > dsi2hdmi tied with drm framework, i need to enable/disable the bridge.
>> > i can disable the regulators enabled for it , but this does not work
>> > as we want.
>> >
>> >
>> >     2. Disable the chip and report to the drm subsystem
>> >     connector_status_disconnected - this will cause drm to stop display
>> >     pipeline and userspace notification.
>> >
>> > any references/driver on how to disable and report to drm susbsystem
>> > will help to implement.
>> > connector_status_disconnected i need to call in the interrupt handler
>> > of tmp102 driver.
>>
>>
>> Look at the code of adv7511_hpd_work, it evaluates connector status
>> based on ADV7511_REG_STATUS, so you can put there temperature check
>> also, and call 'schedule_work(&adv7511->hpd_work)'
>>
>> if temperature passes valid temp range.
>>
>> If you want to do it in mainline, please consult it with adv7511
>> authors/commiters.
>>
>>
>> Regards
>>
>> Andrzej
>>
>>
>> >
>> > in userspace when i tried manually  below commands, there is no impact
>> > in the display.
>> > /sys/class/drm/card0-HDMI-A-1/status
>> > echo off > status
>> > echo on > status
>> >
>> >
>> >     Regards
>> >
>> >     Andrzej
>> >
>> >
>> >     >
>> >     >     regards,
>> >     >     vinaysimha
>> >     >
>> >     >     On Mon, Feb 11, 2019 at 2:10 PM Daniel Vetter
>> >     <daniel@ffwll.ch <mailto:daniel@ffwll.ch>
>> >     >     <mailto:daniel@ffwll.ch <mailto:daniel@ffwll.ch>>> wrote:
>> >     >
>> >     >         On Mon, Feb 11, 2019 at 09:32:54AM +0100, Andrzej Hajda
>> >     wrote:
>> >     >         > On 11.02.2019 07:52, Vinay Simha B N wrote:
>> >     >         > > hi,
>> >     >         > >
>> >     >         > > is it possible to control the drm bridge from another
>> >     >         driver in irq
>> >     >         > > handler(enable/disable the bridge)?
>> >     >         >
>> >     >         >
>> >     >         > If you mean 'in irq context' the answer is no, usually
>> >     >         enable/disable
>> >     >         > callbacks can sleep, so cannot be called from atomic
>> >     context.
>> >     >         >
>> >     >         >
>> >     >         > >
>> >     >         > > is there a way to control the "dpms force off" and
>> "dpms
>> >     >         force on" in
>> >     >         > > the interrupt handler?
>> >     >         >
>> >     >         >
>> >     >         > Could you elaborate more on both subjects.
>> >     >
>> >     >         Yeah, please explain what you want to use this for. dpms
>> >     on/off is
>> >     >         controlled by userspace, the kernel should not change that
>> >     >         state behind
>> >     >         usersapce's back. If this is for some manuel refresh
>> >     display,
>> >     >         then that's
>> >     >         a bit a different story ofc, but for that you don't want
>> >     to do
>> >     >         a real dpms
>> >     >         force off/on.
>> >     >         -Daniel
>> >     >         >
>> >     >         >
>> >     >         > Regards
>> >     >         >
>> >     >         > Andrzej
>> >     >         >
>> >     >         >
>> >     >         > >
>> >     >         > > --
>> >     >         > > regards,
>> >     >         > > vinaysimha
>> >     >         > >
>> >     >         > > _______________________________________________
>> >     >         > > dri-devel mailing list
>> >     >         > > dri-devel@lists.freedesktop.org
>> >     <mailto:dri-devel@lists.freedesktop.org>
>> >     >         <mailto:dri-devel@lists.freedesktop.org
>> >     <mailto:dri-devel@lists.freedesktop.org>>
>> >     >         > >
>> https://lists.freedesktop.org/mailman/listinfo/dri-devel
>> >     >         >
>> >     >         >
>> >     >         > _______________________________________________
>> >     >         > dri-devel mailing list
>> >     >         > dri-devel@lists.freedesktop.org
>> >     <mailto:dri-devel@lists.freedesktop.org>
>> >     >         <mailto:dri-devel@lists.freedesktop.org
>> >     <mailto:dri-devel@lists.freedesktop.org>>
>> >     >         >
>> https://lists.freedesktop.org/mailman/listinfo/dri-devel
>> >     >
>> >     >         --
>> >     >         Daniel Vetter
>> >     >         Software Engineer, Intel Corporation
>> >     >         http://blog.ffwll.ch
>> >     >
>> >     >
>> >     >
>> >     >     --
>> >     >     regards,
>> >     >     vinaysimha
>> >     >
>> >     >
>> >     >
>> >     > --
>> >     > regards,
>> >     > vinaysimha
>> >
>> >
>> >
>> >
>> > --
>> > regards,
>> > vinaysimha
>>
>>
>>
>
> --
> regards,
> vinaysimha
>


-- 
regards,
vinaysimha

[-- Attachment #1.2: Type: text/html, Size: 13247 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: drm bridge control from another driver
  2019-02-18 15:19                 ` Vinay Simha B N
  2019-02-20 14:20                   ` Vinay Simha B N
@ 2019-02-20 14:42                   ` A H
  1 sibling, 0 replies; 11+ messages in thread
From: A H @ 2019-02-20 14:42 UTC (permalink / raw)
  To: Vinay Simha B N; +Cc: open list:DRM PANEL DRIVERS


[-- Attachment #1.1: Type: text/plain, Size: 8302 bytes --]

Hi,

Writing from non-standard mail composer, forgive formatting mistakes.

On Tue, Feb 19, 2019 at 5:22 PM Vinay Simha B N <simhavcs@gmail.com> wrote:

> added the temperature alert irq handler in adv driver , in the irq
> calling schedule_work(&adv7511->hpd_work); , initially in the
> adv7511_detect , if we set status = connector_status_disconnected; later
> when irq handler calls the schedule work, hpd does not works.
> [   55.052677] [drm] Cannot find any crtc or sizes
> [   55.058786] [drm] Cannot find any crtc or sizes
>
> by default driver of adv, hpd does not works as expected, board boots
> without hdmi connected, after postboot if we connect hdmi , in irq hpd_work
> ,but to get the display we need to press ctrl+alt+backspace.
>
>
Apparently driver has some problems with hotplug handling. As you wrote
earlier:
> in userspace when i tried manually  below commands, there is no impact in
the display.
> /sys/class/drm/card0-HDMI-A-1/status
> echo off > status
> echo on > status

It suggests that code has some issues with hotplug detection/reporting.
The rule should be that if connector status changes
drm_kms_helper_hotplug_event should be called, it looks like it is not.

Regards
Andrzej



> On Thu, Feb 14, 2019 at 8:03 PM Andrzej Hajda <a.hajda@samsung.com> wrote:
>
>> On 13.02.2019 15:31, Vinay Simha B N wrote:
>> >
>> >
>> > On Wed, Feb 13, 2019 at 7:44 PM Andrzej Hajda <a.hajda@samsung.com
>> > <mailto:a.hajda@samsung.com>> wrote:
>> >
>> >     On 13.02.2019 14:40, Vinay Simha B N wrote:
>> >     > Andrzej/Daniel,
>> >     >
>> >     > please suggest any input on the scenario for temperature control
>> and
>> >     > dsi bridge enable/disable.
>> >     >
>> >     > On Mon, Feb 11, 2019 at 2:41 PM Vinay Simha B N
>> >     <simhavcs@gmail.com <mailto:simhavcs@gmail.com>
>> >     > <mailto:simhavcs@gmail.com <mailto:simhavcs@gmail.com>>> wrote:
>> >     >
>> >     >     dsi2hdmi(adv7511) chip operating temperature range is -10 degC
>> >     >     to +85 degC. We want to enable/disable the bridge only when
>> >     >     temperature range is inbetween these range.
>> >     >
>> >     >     We have temperature control chip to read the temp, tLow an
>> tHigh
>> >     >     can be set. whenever interrupt(alert) triggers we want to
>> >     >     enablel/disable the bridge.
>> >     >
>> >     >     Any suggestion what is the better way to handle this scenario?
>> >     >
>> >
>> >     Why do you need to bother about this quite big range at all?
>> >
>> > we are looking for -10 deg C, this system will be used in a place
>> > where temp goes beyond -20 deg C... processor(apq8016/410c) can handle
>> > upto -30, but dsi2hdmi(adv7533) chip if enabled beyond -10 deg C, life
>> > of the chip goes down or it cannot operate at all.
>> >
>> >
>> >     I guess the best would be to set whole platform operating
>> temperature
>> >     range, and poweroff/sleep/slow down/??? whole system, not just one
>> >     random chip, which probably is not the most fragile piece, am I
>> right?
>> >
>> > right now we are focused only to disable the hdmi chip if temp goes
>> > beyond -10, since this is only chip in board faces temp issue, other
>> > components are fine to go upto -30 deg C.
>> >
>> >
>> >     If you really insist on handling it per chip, you can try to
>> >     investigate
>> >     following paths:
>> >
>> >     1. Just disable the chip, without noticing drm, other drivers, or
>> >     userspace, and re-enable it if temperature become acceptable, but I
>> am
>> >     not sure if this will not change behavior of other chips.
>> >
>> > dsi2hdmi tied with drm framework, i need to enable/disable the bridge.
>> > i can disable the regulators enabled for it , but this does not work
>> > as we want.
>> >
>> >
>> >     2. Disable the chip and report to the drm subsystem
>> >     connector_status_disconnected - this will cause drm to stop display
>> >     pipeline and userspace notification.
>> >
>> > any references/driver on how to disable and report to drm susbsystem
>> > will help to implement.
>> > connector_status_disconnected i need to call in the interrupt handler
>> > of tmp102 driver.
>>
>>
>> Look at the code of adv7511_hpd_work, it evaluates connector status
>> based on ADV7511_REG_STATUS, so you can put there temperature check
>> also, and call 'schedule_work(&adv7511->hpd_work)'
>>
>> if temperature passes valid temp range.
>>
>> If you want to do it in mainline, please consult it with adv7511
>> authors/commiters.
>>
>>
>> Regards
>>
>> Andrzej
>>
>>
>> >
>> > in userspace when i tried manually  below commands, there is no impact
>> > in the display.
>> > /sys/class/drm/card0-HDMI-A-1/status
>> > echo off > status
>> > echo on > status
>> >
>> >
>> >     Regards
>> >
>> >     Andrzej
>> >
>> >
>> >     >
>> >     >     regards,
>> >     >     vinaysimha
>> >     >
>> >     >     On Mon, Feb 11, 2019 at 2:10 PM Daniel Vetter
>> >     <daniel@ffwll.ch <mailto:daniel@ffwll.ch>
>> >     >     <mailto:daniel@ffwll.ch <mailto:daniel@ffwll.ch>>> wrote:
>> >     >
>> >     >         On Mon, Feb 11, 2019 at 09:32:54AM +0100, Andrzej Hajda
>> >     wrote:
>> >     >         > On 11.02.2019 07:52, Vinay Simha B N wrote:
>> >     >         > > hi,
>> >     >         > >
>> >     >         > > is it possible to control the drm bridge from another
>> >     >         driver in irq
>> >     >         > > handler(enable/disable the bridge)?
>> >     >         >
>> >     >         >
>> >     >         > If you mean 'in irq context' the answer is no, usually
>> >     >         enable/disable
>> >     >         > callbacks can sleep, so cannot be called from atomic
>> >     context.
>> >     >         >
>> >     >         >
>> >     >         > >
>> >     >         > > is there a way to control the "dpms force off" and
>> "dpms
>> >     >         force on" in
>> >     >         > > the interrupt handler?
>> >     >         >
>> >     >         >
>> >     >         > Could you elaborate more on both subjects.
>> >     >
>> >     >         Yeah, please explain what you want to use this for. dpms
>> >     on/off is
>> >     >         controlled by userspace, the kernel should not change that
>> >     >         state behind
>> >     >         usersapce's back. If this is for some manuel refresh
>> >     display,
>> >     >         then that's
>> >     >         a bit a different story ofc, but for that you don't want
>> >     to do
>> >     >         a real dpms
>> >     >         force off/on.
>> >     >         -Daniel
>> >     >         >
>> >     >         >
>> >     >         > Regards
>> >     >         >
>> >     >         > Andrzej
>> >     >         >
>> >     >         >
>> >     >         > >
>> >     >         > > --
>> >     >         > > regards,
>> >     >         > > vinaysimha
>> >     >         > >
>> >     >         > > _______________________________________________
>> >     >         > > dri-devel mailing list
>> >     >         > > dri-devel@lists.freedesktop.org
>> >     <mailto:dri-devel@lists.freedesktop.org>
>> >     >         <mailto:dri-devel@lists.freedesktop.org
>> >     <mailto:dri-devel@lists.freedesktop.org>>
>> >     >         > >
>> https://lists.freedesktop.org/mailman/listinfo/dri-devel
>> >     >         >
>> >     >         >
>> >     >         > _______________________________________________
>> >     >         > dri-devel mailing list
>> >     >         > dri-devel@lists.freedesktop.org
>> >     <mailto:dri-devel@lists.freedesktop.org>
>> >     >         <mailto:dri-devel@lists.freedesktop.org
>> >     <mailto:dri-devel@lists.freedesktop.org>>
>> >     >         >
>> https://lists.freedesktop.org/mailman/listinfo/dri-devel
>> >     >
>> >     >         --
>> >     >         Daniel Vetter
>> >     >         Software Engineer, Intel Corporation
>> >     >         http://blog.ffwll.ch
>> >     >
>> >     >
>> >     >
>> >     >     --
>> >     >     regards,
>> >     >     vinaysimha
>> >     >
>> >     >
>> >     >
>> >     > --
>> >     > regards,
>> >     > vinaysimha
>> >
>> >
>> >
>> >
>> > --
>> > regards,
>> > vinaysimha
>>
>>
>>
>
> --
> regards,
> vinaysimha
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

[-- Attachment #1.2: Type: text/html, Size: 13517 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2019-02-20 14:43 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CGME20190211081604epcas2p1aca89827ef59c84f2b40aa29483213c0@epcas2p1.samsung.com>
2019-02-11  6:52 ` drm bridge control from another driver Vinay Simha B N
2019-02-11  8:32   ` Andrzej Hajda
2019-02-11  8:40     ` Daniel Vetter
2019-02-11  9:11       ` Vinay Simha B N
2019-02-13 13:40         ` Vinay Simha B N via dri-devel
2019-02-13 14:14           ` Andrzej Hajda via dri-devel
2019-02-13 14:31             ` Vinay Simha B N via dri-devel
2019-02-14 14:33               ` Andrzej Hajda via dri-devel
2019-02-18 15:19                 ` Vinay Simha B N
2019-02-20 14:20                   ` Vinay Simha B N
2019-02-20 14:42                   ` A H

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.