Skip to contentSkip to conversation

Support for early wakeup in DRM

DISCUSSION [email protected] 2 participants 5 messages Feb 20, 2020 – Feb 22, 2020

lore
Share & tools
lore
#0 lore raw

Hello All,

I am seeking recommendations for DRM compatible methods of updating the HW other than frame commit path. When exiting idle/runtime_suspend, the driver votes for a bunch of resources including power/clk/bandwidth as a part of first commit handling. This usually adds a few millisecond delay before processing the frame. The requirement is to find possible ways to reduce this delay by providing an early intimation to the framework to "prepare" the HW by voting for the resources and keep the HW ready to process an imminent frame commit. Especially in performance oriented Automotive world, these delays are very time critical and we are working on ways to mitigate them.

DRM framework converges all the parameters affecting the HW in terms of DRM properties in a single COMMIT call. To address the above issue, we need a parallel channel which should allow the framework to make necessary changes to the HW without violating the master access privileges.

Before resorting to custom downstream ways, I want to check with the community for folks who might have encountered and resolved such issues.

Thanks and Regards,

Jeykumar S

Qualcomm Inc.

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#1 lore raw
Quoted 22 lines · On Thu, Feb 20, 2020 at 10:45:57AM -0800, [email protected] wrote:

Hello All,

I am seeking recommendations for DRM compatible methods of updating the HW other than frame commit path. When exiting idle/runtime_suspend, the driver votes for a bunch of resources including power/clk/bandwidth as a part of first commit handling. This usually adds a few millisecond delay before processing the frame. The requirement is to find possible ways to reduce this delay by providing an early intimation to the framework to "prepare" the HW by voting for the resources and keep the HW ready to process an imminent frame commit. Especially in performance oriented Automotive world, these delays are very time critical and we are working on ways to mitigate them.

DRM framework converges all the parameters affecting the HW in terms of DRM properties in a single COMMIT call. To address the above issue, we need a parallel channel which should allow the framework to make necessary changes to the HW without violating the master access privileges.

Quoted 2 lines

Before resorting to custom downstream ways, I want to check with the community for folks who might have encountered and resolved such issues.

Just enable the display, which will grab all the clocks and everything? Once the display is on a commit should be possible on the next frame, at least for well-working drivers.
-Daniel

Quoted 16 lines

Thanks and Regards,

Jeykumar S

Qualcomm Inc.

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Signature · 7 lines
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
#2 lore raw
Quoted 32 lines · Daniel Vetter
Quoted 3 lines · On Thu, Feb 20, 2020 at 10:45:57AM -0800, [email protected] wrote:

Hello All,

I am seeking recommendations for DRM compatible methods of updating the

HW

Quoted 1 line

other than frame commit path. When exiting idle/runtime_suspend, the

driver

Quoted 1 line

votes for a bunch of resources including power/clk/bandwidth as a part

of

Quoted 3 lines

first commit handling. This usually adds a few millisecond delay before processing the frame. The requirement is to find possible ways to reduce this delay by providing an early intimation to the framework to

"prepare"

Quoted 2 lines

the HW by voting for the resources and keep the HW ready to process an imminent frame commit. Especially in performance oriented Automotive

world,

Quoted 1 line

these delays are very time critical and we are working on ways to

mitigate

Quoted 5 lines

them.

DRM framework converges all the parameters affecting the HW in terms of

DRM

Quoted 1 line

properties in a single COMMIT call. To address the above issue, we need

a

Quoted 1 line

parallel channel which should allow the framework to make necessary

changes

Quoted 4 lines

to the HW without violating the master access privileges.

Quoted 8 lines
Quoted 2 lines

Before resorting to custom downstream ways, I want to check with the community for folks who might have encountered and resolved such issues.

Just enable the display, which will grab all the clocks and everything? Once the display is on a commit should be possible on the next frame, at least for well-working drivers.
-Daniel

I believe even to turn on the display, DRM will need an explicit commit (probably without any planes/pixel buffers). For cases like smart panels, where we can keep the panel on(panel internal RAM refresh) and power collapse the display HW, resuming back with an explicit commit will push a black (or default color programmed in the HW) frame causing a glitch.

Thanks and Regards,
Jeykumar S.

Quoted 12 lines
Quoted 11 lines

Thanks and Regards,

Jeykumar S

Qualcomm Inc.

Quoted 4 lines
Quoted 4 lines

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#3 lore raw
Quoted 47 lines · On Thu, Feb 20, 2020 at 01:24:00PM -0800, [email protected] wrote:
Quoted 37 lines · Daniel Vetter
Quoted 4 lines · On Thu, Feb 20, 2020 at 10:45:57AM -0800, [email protected] wrote:

Hello All,

I am seeking recommendations for DRM compatible methods of updating the

HW

Quoted 1 line

other than frame commit path. When exiting idle/runtime_suspend, the

driver

Quoted 1 line

votes for a bunch of resources including power/clk/bandwidth as a part

of

Quoted 5 lines

first commit handling. This usually adds a few millisecond delay before
processing the frame. The requirement is to find possible ways to reduce
this delay by providing an early intimation to the framework to

"prepare"

Quoted 2 lines

the HW by voting for the resources and keep the HW ready to process an imminent frame commit. Especially in performance oriented Automotive

world,

Quoted 1 line

these delays are very time critical and we are working on ways to

mitigate

Quoted 6 lines

them.

DRM framework converges all the parameters affecting the HW in terms of

DRM

Quoted 2 lines

properties in a single COMMIT call. To address the above issue, we need

a

Quoted 1 line

parallel channel which should allow the framework to make necessary

changes

Quoted 4 lines

to the HW without violating the master access privileges.

Quoted 9 lines
Quoted 3 lines

Before resorting to custom downstream ways, I want to check with the community for folks who might have encountered and resolved such issues.

Just enable the display, which will grab all the clocks and everything? Once the display is on a commit should be possible on the next frame, at least for well-working drivers.
-Daniel

Quoted 5 lines

I believe even to turn on the display, DRM will need an explicit commit (probably without any planes/pixel buffers). For cases like smart panels, where we can keep the panel on(panel internal RAM refresh) and power collapse the display HW, resuming back with an explicit commit will push a black (or default color programmed in the HW) frame causing a glitch.

Uh, you might want to look into the self-refresh helpers, which do this without black frames and stuff.

But yeah if there's really a gap here (and not just you folks creatively abusing atomic kms in ways that it was not meant to be used) then we can add a property that forbids power optimization and guarantee that you can do the next screen update immediately. And then we can merge that with all the usual requirements (driver implementation that works, open source userspace, igt testcase, the full deal).

But it still feels like you're trying to do something automatically that's not meant to work like this.

Cheers, Daniel

Quoted 19 lines

Thanks and Regards,
Jeykumar S.

Quoted 16 lines
Quoted 16 lines

Thanks and Regards,

Jeykumar S

Qualcomm Inc.

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Signature · 7 lines
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
#4 lore raw
Quoted 54 lines · Daniel Vetter
Quoted 10 lines · On Thu, Feb 20, 2020 at 01:24:00PM -0800, [email protected] wrote:
Quoted 9 lines · Daniel Vetter
Quoted 4 lines · On Thu, Feb 20, 2020 at 10:45:57AM -0800, [email protected] wrote:

Hello All,

I am seeking recommendations for DRM compatible methods of updating the

HW

Quoted 1 line

other than frame commit path. When exiting idle/runtime_suspend, the

driver

Quoted 1 line

votes for a bunch of resources including power/clk/bandwidth as a

part

Quoted 8 lines
Quoted 8 lines

of

Quoted 5 lines

first commit handling. This usually adds a few millisecond delay before
processing the frame. The requirement is to find possible ways to reduce
this delay by providing an early intimation to the framework to

"prepare"

Quoted 1 line

the HW by voting for the resources and keep the HW ready to process

an

Quoted 20 lines
Quoted 20 lines
Quoted 1 line

imminent frame commit. Especially in performance oriented Automotive

world,

Quoted 1 line

these delays are very time critical and we are working on ways to

mitigate

Quoted 6 lines

them.

DRM framework converges all the parameters affecting the HW in terms of

DRM

Quoted 2 lines

properties in a single COMMIT call. To address the above issue, we need

a

Quoted 1 line

parallel channel which should allow the framework to make necessary

changes

Quoted 4 lines

to the HW without violating the master access privileges.

Quoted 5 lines
Quoted 5 lines
Quoted 3 lines

Before resorting to custom downstream ways, I want to check with the community for folks who might have encountered and resolved such issues.

Just enable the display, which will grab all the clocks and

everything?

Quoted 1 line
Quoted 1 line

Once the display is on a commit should be possible on the next frame,

at

Quoted 5 lines
Quoted 3 lines

least for well-working drivers.
-Daniel

I believe even to turn on the display, DRM will need an explicit commit (probably without any planes/pixel buffers). For cases like smart

Quoted 9 lines

panels,

Quoted 2 lines

where we can keep the panel on(panel internal RAM refresh) and power collapse the display HW, resuming back with an explicit commit will push

a

Quoted 1 line

black (or default color programmed in the HW) frame causing a glitch.

Uh, you might want to look into the self-refresh helpers, which do this without black frames and stuff.

I believe you are referring to Sean's PSR changes: https://patchwork.freedesktop.org/series/57366/
Will take a look.

Thanks and Regards,
Jeykumar S.

Quoted 7 lines

But yeah if there's really a gap here (and not just you folks creatively abusing atomic kms in ways that it was not meant to be used) then we can add a property that forbids power optimization and guarantee that you can do the next screen update immediately. And then we can merge that with all the usual requirements (driver implementation that works, open source userspace, igt testcase, the full deal).

Quoted 24 lines

But it still feels like you're trying to do something automatically that's not meant to work like this.

Cheers, Daniel

Quoted 19 lines

Thanks and Regards,
Jeykumar S.

Quoted 16 lines
Quoted 16 lines

Thanks and Regards,

Jeykumar S

Qualcomm Inc.

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel