Giter Club home page Giter Club logo

Comments (11)

amery avatar amery commented on September 7, 2024

isn't this kind of too long?

from linux-sunxi.

Quarx2k avatar Quarx2k commented on September 7, 2024

I'm not tested <15 sec.
But 15sec is no problem to use hdmi. After connect cable we should wait <15sec.

from linux-sunxi.

killerkink avatar killerkink commented on September 7, 2024

isnt the original delay set at 200ms?

hdmi_delay_ms(200); @ drv_hdmi.c

from linux-sunxi.

Quarx2k avatar Quarx2k commented on September 7, 2024

Yes, you right. Then better to increase hdmi_delay_ms. And make suspend for it.

from linux-sunxi.

killerkink avatar killerkink commented on September 7, 2024

i have tesed 1sec with good response. but I believe 2 sec is reasonable for cutting down on the polling and getting a good detection.

from linux-sunxi.

hipboi avatar hipboi commented on September 7, 2024

thanks @Quarx2k for the fix. This is a long issue of Allwinner. I looked at this today. Another way to fix is to change in drivers/video/sun4i/hdmi/aw/hdmi_core.c function __s32 main_Hpd_Check(void); change the hdmi_delay_ms(1) to hdmi_delay_ms(10). i can not explain it with my current understanding of the kernel schedule. can anyone explain this?

from linux-sunxi.

polarcat avatar polarcat commented on September 7, 2024

I think that we could simply replace hdmi_delay_ms() with msleep(). Please correct me if I am wrong.

from linux-sunxi.

hipboi avatar hipboi commented on September 7, 2024

On Tue, Sep 11, 2012 at 6:19 PM, Aliaksei Katovich <[email protected]

wrote:

I think that we could simply replace hdmi_delay_ms() with msleep(). Please
correct me if I am wrong.

yes, that also works. can anyone explain this?

โ€”
Reply to this email directly or view it on GitHubhttps://github.com/amery/linux-allwinner/issues/43#issuecomment-8455122.

Keep simple, stay foolish.

from linux-sunxi.

polarcat avatar polarcat commented on September 7, 2024

does msleep(1) produce the same effect as hdmi_delay_ms(1)?

from linux-sunxi.

hipboi avatar hipboi commented on September 7, 2024

On Tue, Sep 11, 2012 at 6:46 PM, Aliaksei Katovich <[email protected]

wrote:

does msleep(1) produce the same effect as hdmi_delay_ms(1)?

no. hdmi_delay_ms uses set_current_state(TASK_INTERRUPTIBLE), but msleep
uses schedule_timeout_uninterruptible(timeout). Interesting, i need to
google the difference between TASK_INTERRUPTIBLE and TASK_UNINTERRUPTIBLE.
but from hardware point of view, they are the same, wait for some time, and
check again.

โ€”
Reply to this email directly or view it on GitHubhttps://github.com/amery/linux-allwinner/issues/43#issuecomment-8455695.

Keep simple, stay foolish.

from linux-sunxi.

polarcat avatar polarcat commented on September 7, 2024

On Tue, Sep 11, 2012 at 6:46 PM, Aliaksei Katovich
<[email protected]

wrote:
does msleep(1) produce the same effect as hdmi_delay_ms(1)?

no. hdmi_delay_ms uses set_current_state(TASK_INTERRUPTIBLE), but
msleep
uses schedule_timeout_uninterruptible(timeout). Interesting, i need to
google the difference between TASK_INTERRUPTIBLE and
TASK_UNINTERRUPTIBLE.
but from hardware point of view, they are the same, wait for some time,
and
check again.

I would anyway recommend to use plain msleep() here, regardless of your
findings. E.g. jiffies calculations like this (see. hdmi_delay_ms)

    __u32 timeout = t*HZ/1000

look suspicious to me.

รข
Reply to this email directly or view it on
GitHub<https://github.com/amery/linux-allwinner/issues/43#issuecomment-
8455695>.

--
Keep simple, stay foolish.

โ€”
Reply to this email directly or [1]view it on GitHub.
[J6T91GIPIyhU-8ti4GCGP71oDyae5wcKbWrmQLuV4jMv0PuTIo6eLnz7eoGYz3O_.gif]

References

  1. https://github.com/amery/linux-allwinner/issues/43#issuecomment-8456078

from linux-sunxi.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.