Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756647AbbLQO1c (ORCPT ); Thu, 17 Dec 2015 09:27:32 -0500 Received: from mail-wm0-f52.google.com ([74.125.82.52]:35800 "EHLO mail-wm0-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756221AbbLQO10 (ORCPT ); Thu, 17 Dec 2015 09:27:26 -0500 Date: Thu, 17 Dec 2015 15:27:24 +0100 From: Daniel Vetter To: Heiko =?iso-8859-1?Q?St=FCbner?= Cc: Mark yao , linux-rockchip@lists.infradead.org, linux-arm-kernel@lists.infradead.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3 0/8] drm/rockchip: covert to support atomic API Message-ID: <20151217142724.GZ30437@phenom.ffwll.local> Mail-Followup-To: Heiko =?iso-8859-1?Q?St=FCbner?= , Mark yao , linux-rockchip@lists.infradead.org, linux-arm-kernel@lists.infradead.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org References: <1450321275-31154-1-git-send-email-mark.yao@rock-chips.com> <4029109.1DucZWNrFm@diego> <56728F3F.6060309@rock-chips.com> <1817698.JgNG3flpWP@diego> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <1817698.JgNG3flpWP@diego> X-Operating-System: Linux phenom 4.2.0-1-amd64 User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 4641 Lines: 89 On Thu, Dec 17, 2015 at 01:03:53PM +0100, Heiko Stübner wrote: > Hi Mark, > > Am Donnerstag, 17. Dezember 2015, 18:32:31 schrieb Mark yao: > > On 2015年12月17日 18:00, Heiko Stübner wrote: > > > Am Donnerstag, 17. Dezember 2015, 11:01:07 schrieb Mark Yao: > > >> The series of patches coverting drm rockchip to atomic API, do some > > >> cleanup and some fixes on atomic side. > > [...] > > > > Plugging in HDMI after boot: > > > > > > [ 20.559534] ------------[ cut here ]------------ > > > [ 20.564412] WARNING: CPU: 3 PID: 74 at > > > drivers/gpu/drm/drm_atomic_helper.c:682 > > > drm_atomic_helper_update_legacy_modeset_state+0x6c/0x200() [ 20.576991] > > > Modules linked in: > > > [ 20.580175] CPU: 3 PID: 74 Comm: irq/51-ff980000 Not tainted 4.4.0-rc5+ > > > #2787 [ 20.587502] Hardware name: Rockchip (Device Tree) > > > [ 20.592347] [] (unwind_backtrace) from [] > > > (show_stack+0x20/0x24) [ 20.600319] [] (show_stack) from > > > [] (dump_stack+0x84/0xb8) [ 20.607776] [] > > > (dump_stack) from [] (warn_slowpath_common+0x98/0xc4) [ > > > 20.616087] [] (warn_slowpath_common) from [] > > > (warn_slowpath_null+0x2c/0x34) [ 20.625106] [] > > > (warn_slowpath_null) from [] > > > (drm_atomic_helper_update_legacy_modeset_state+0x6c/0x200) [ 20.636382] > > > [] (drm_atomic_helper_update_legacy_modeset_state) from > > > [] (drm_atomic_helper_commit_modeset_disables+0x1e4/0x35c) [ > > > 20.649732] [] (drm_atomic_helper_commit_modeset_disables) from > > > [] (rockchip_atomic_commit_complete+0x34/0x108) [ 20.661789] > > > [] (rockchip_atomic_commit_complete) from [] > > > (rockchip_drm_atomic_commit+0x84/0xa0) [ 20.672442] [] > > > (rockchip_drm_atomic_commit) from [] > > > (drm_atomic_commit+0x60/0x70) [ 20.681711] [] > > > (drm_atomic_commit) from [] (restore_fbdev_mode+0x128/0x258) [ > > > 20.690418] [] (restore_fbdev_mode) from [] > > > (drm_fb_helper_restore_fbdev_mode_unlocked+0x3c/0x80) [ 20.701033] > > > [] (drm_fb_helper_restore_fbdev_mode_unlocked) from > > > [] (drm_fb_helper_set_par+0x50/0x60) [ 20.711907] > > > [] (drm_fb_helper_set_par) from [] > > > (drm_fb_helper_hotplug_event+0xc8/0xe0) [ 20.721569] [] > > > (drm_fb_helper_hotplug_event) from [] > > > (rockchip_drm_output_poll_changed+0x24/0x28) [ 20.732185] [] > > > (rockchip_drm_output_poll_changed) from [] > > > (drm_kms_helper_hotplug_event+0x34/0x38) [ 20.742891] [] > > > (drm_kms_helper_hotplug_event) from [] > > > (drm_helper_hpd_irq_event+0x120/0x150) [ 20.753078] [] > > > (drm_helper_hpd_irq_event) from [] (dw_hdmi_irq+0x14c/0x18c) [ > > > 20.761772] [] (dw_hdmi_irq) from [] > > > (irq_thread_fn+0x2c/0x44) [ 20.769350] [] (irq_thread_fn) > > > from [] (irq_thread+0x118/0x21c) [ 20.777019] [] > > > (irq_thread) from [] (kthread+0xf4/0x10c) [ 20.784083] > > > [] (kthread) from [] (ret_from_fork+0x14/0x24) [ > > > 20.791300] ---[ end trace 3deaa51d288067a0 ]--- > > > > Hi Heiko > > This issue can be explained from following thread: > > https://lkml.org/lkml/2015/11/16/498 > > > > You can fix it by following changes: > > > > @@ -1667,8 +1667,6 @@ static int dw_hdmi_register(struct drm_device > > *drm, struct dw_hdmi *hdmi) > > &dw_hdmi_connector_funcs, > > DRM_MODE_CONNECTOR_HDMIA); > > > > - hdmi->connector.encoder = encoder; > > yep that fixes the warning. From the thread you mention, it looks like that > assignment should also be removed in the non-atomic case (i.MX)? > > Or if it is really necessary there could also wrap it in a conditional to only > be set for the non-atomic case. It wont work with non-atomic, but it'll only break things from the 2nd modeset onwards. Someone needs to fix that bug, since afaiu the code it'd blow up for non-atomic if you remove it on even the first modeset. -Daniel -- Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/