BUG: drm_crtc_helper_set_config does not work
On Fri, Mar 9, 2012 at 5:28 PM, Yufeng Shen wrote: > On Fri, Mar 9, 2012 at 3:15 AM, Maarten Maathuis > wrote: >> On Fri, Mar 9, 2012 at 2:50 AM, Yufeng Shen wrote: >>> So a simple case of ?disabling a CRTC and then re-enabling it. >>> >>> Disabling: >>> >>> CRTC X is originally connected to output Y >>> >>> 1. XRRSetCrtcConfig() ? ?is called to disable CRTC ?X >>> >>> 2. drm_helper_connector_dpms() ? then gets called on the connector >>> connected to CRTC X, >>> ? ?in the function, >>> ? ?the ?connector->encoder ?is set to DPMS OFF, ? and the >>> encoder->crtc ?set to DPMS OFF >>> ? ?but the ?encoder->crtc ? is still CRTC X >>> >>> Re-enabling: >>> >>> 3. XRRSetCrtcConfig() ? ?is called to to enable CRTC ?X ?on output Y >>> >>> 4. drm_crtc_helper_set_config () ?is now called, >>> suppose ? fb is not changed, ?mode is not changed, encoder is not changed >>> and the ? encoder->crtc ?is not changed, >>> then we have ? mode_changed == false ? ?and ?the mode is not reset >>> >>> So the CRTC X won't be connected to output Y. >>> >>> What I don't understand the code is that why ?XRRSetCrtcConfig() ?ends >>> up only calling ?drm_helper_connector_dpms() ?? >>> I think it should do more than that, at least it should set the >>> related ?encoder->crtc = NULL >>> >>> any comments ? >>> ___ >>> dri-devel mailing list >>> dri-devel at lists.freedesktop.org >>> http://lists.freedesktop.org/mailman/listinfo/dri-devel >> >> As far as i know DPMS designed is a simple switch, meaning that the >> mode remains active, so if you do DPMS ON it should come back. If for >> some reason the driver is disconnecting the encoder from the crtc, >> then it is the drivers responsibility to reconnect it when DPMS ON >> happens. >> >> But don't take my word for it, others may have more/other information. >> > > Yes, I was thinking ideally DPMS call should enable/disable DPMS state, and > XRRSetCrtcConfig call should enable/disable CRTC. > > But it seems that, when using XRRSetCrtcConfig to disable CRTC, > the CRTC itself is disabled, the DPMS is disabled (DPMS OFF), > and then when using XRRSetCrtcConfig to re-enable the CRTC, > it only checks whether the CRTC that connected to the encoder is > changed (whether a new crtc is assigned), but does not check whether > the CRTC itself is previously disabled or not. ?So it considers the encoder > is connected to the same CRTC and does no thing to re-enable the CRTC. > > >> -- >> Far away from the primal instinct, the song seems to fade away, the >> river get wider between your thoughts and the things we do and say. What i meant is that you should get a DPMS ON call somewhere in the driver. The driver should then re-enable things. If the driver disconnects the encoder for DPMS OFF, then it will also have to reconnect it for DPMS ON. -- Far away from the primal instinct, the song seems to fade away, the river get wider between your thoughts and the things we do and say.
答复: [korg]help: How to submit a kernel driver on kernel.org.
Hi Paul, Thank you very much for your great help. Here is the first patch. Regards Aaron -- ???: Paul Menzel [mailto:paulepanter at users.sourceforge.net] : 2012?3?6? 22:38 ???: Alex Deucher ??: Aaron.Chen ???; caesar.qiu ???; dri-devel at lists.freedesktop.org ??: Re: [korg]help: How to submit a kernel driver on kernel.org. Dear Aaron, Am Dienstag, den 06.03.2012, 08:47 -0500 schrieb Alex Deucher: > On Mon, Mar 5, 2012 at 11:13 PM, Aaron.Chen ??? wrote: > > Thank you very much for your guide. It's a great help for me. > > > > But I still have a little problem with the patch thing. I'm not familiar > > with the git. > > 1.Shall I need to do the clone and get the source location and target > > directory first? > > 2.Where is the source location and target directory? > > 3.Our driver has pass the customer's test from kernel version 2.6.5 to > > 3.0.0, So what shall I do to submit a driver cover all these kernel version. you can only get new features included upstream in the latest Linux kernel. So earliest version would be 3.4. You have to maintain you own repository for earlier version. But backporting should be not so much trouble if you have it included upstream. > > 4.or just email you the source code and tell you the changes? > > > > I'm looking forward your re-guide. Thank you so much. > > Your best bet it to clone Linus' git tree and then apply your patches: > > 1. clone Linus' git tree: > git clone > git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git you can do this in between. cd linux git config --global user.name "??? (Aaron Chen)" git config --global user.email aaron.chen at siliconmotion.com > 2.a) apply your first patch >b) if you patch adds new files to the source tree, add them: > git add path/to/files/file.c > git add path/to/files/file.h > etc. if the patch only modifies patches that are already > in the tree, you do not need to add them. >c) when the patch is applied commit it: >git commit -a -s >d) when you run the commit command you will be prompted to > enter a commit message. The commit message has the following format: > > subsystem: patch description > > description of what the patch does. > > Signed-off-by: Your name > > E.g., > > fb: add initial code for video 5000 graphics > > This adds the initial support for the video 5000 graphics adapter. It > supports vga and lcd connectors. > > Signed-off-by: Joe Developer > > e) repeat steps a-d for all of your patches 3. generate patches: > git format-patch -n > > where n is the number of patches you committed. E.g., if your driver > consists of 5 patches: > git format-patch -5 > > 4. Send the patches to the list. Aaron, Git is nowadays documented pretty well. So just use git help command (like `git help commit`) to read the manual. Additionally you can just search for it using your favorite search engine. Interesting reads should be [1][2][3]. Thanks, Paul [1] http://schacon.github.com/git/user-manual.html#cleaning-up-history [2] http://git-scm.com/documentation [3] http://progit.org/book/ -- next part -- A non-text attachment was scrubbed... Name: 0001-fb-add-initial-code-for-smi-graphics.patch Type: application/octet-stream Size: 688721 bytes Desc: 0001-fb-add-initial-code-for-smi-graphics.patch URL: <http://lists.freedesktop.org/archives/dri-devel/attachments/20120309/562d545a/attachment-0001.obj>
regression(?) 3.3-rc4 -> 3.3-rc5: drm intel hangs
Hi everyone, currently 3.3.0-rc6+ I just was hit by that after wake up from ram: On Di, 28 Feb 2012, Daniel Vetter wrote: > > Feb 28 11:42:47 mithrandir kernel: [15627.756071] > > [drm:i915_hangcheck_elapsed] *ERROR* Hangcheck timer elapsed... GPU hung > > Feb 28 11:42:47 mithrandir kernel: [15627.756087] [drm] capturing error > > event; look for more information in /debug/dri/0/i915_error_state > > Wee need this i915_error_state file from debugfs (you might need to mount > that first again) to diagnose gpu hangs. Also, it only contains > information after a crash, so you need to rehang your machine if you've > rebooted since then. Now I could get that file from debugfs, and the dmesg output with proper debug value. Attached are both. Please let me know if I can provide any other information. Best wishes Norbert Norbert Preiningpreining@{jaist.ac.jp, logic.at, debian.org} JAIST, Japan TeX Live & Debian Developer DSA: 0x09C5B094 fp: 14DF 2E6C 0307 BE6D AD76 A9C0 D2BF 4AA3 09C5 B094 NAZEING (participial vb.) The rather unconvincing noises of pretended interest which an adult has to make when brought a small dull object for admiration by a child. --- Douglas Adams, The Meaning of Liff -- next part -- A non-text attachment was scrubbed... Name: dmesg.txt.gz Type: application/octet-stream Size: 7394 bytes Desc: not available URL: <http://lists.freedesktop.org/archives/dri-devel/attachments/20120309/f2ed0da9/attachment-0001.obj> -- next part -- ?'OO i915_error_state ??O?-?q????????d??F,?q[? ?a?I?# zr$9p?}f???-??I????U?f?/O??b?|??W???~?%?>?|?|???^>???/?_] ??_~?]?>??_???_???C???~?/?~???_}?~???~???,???>?f??;?o~??/??7?|3????1d?|??O/???O_???w???,???t?I??J*E)H6??L?|]?p???O?W ?SD??x???"??B?)?i?{/Ocz?#?]^,.^,??h???/???/?8?i,??Xb{i?X???z???s?bI?y??yy?R ?r???)-??O_?3??#?i?v??t???)?S?v??2?o?AX:h?w?|???h???:????S"??OY??T#a??SSN?? Xr?S?K`?N KN KN K???\??`?:G?t?%?K????O)j,9????%K??O9?Xr?K?%? K.?,?P#a???#?t??TK??dw??NkD??vze??*?Y??Z#?Og??M#h?h??q?Q???<h?A38?OG??u??P?p???Q5??}?? ??hw?fp'hw?fpxw?OY?j,???F#?Q??*???1?!F?w??{??c:??/y>