From patchwork Thu Jan 21 23:10:21 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Rafael Antognolli X-Patchwork-Id: 8085771 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 4232A9FC69 for ; Thu, 21 Jan 2016 23:07:38 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 6D39320460 for ; Thu, 21 Jan 2016 23:07:37 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 0416420462 for ; Thu, 21 Jan 2016 23:07:36 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 572FA6E31B; Thu, 21 Jan 2016 15:07:32 -0800 (PST) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by gabe.freedesktop.org (Postfix) with ESMTP id B56A56E303; Thu, 21 Jan 2016 15:07:30 -0800 (PST) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga101.jf.intel.com with ESMTP; 21 Jan 2016 15:07:29 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.22,327,1449561600"; d="scan'208";a="865782353" Received: from di-604.jf.intel.com (HELO apicaltest.jf.intel.com) ([10.7.199.72]) by orsmga001.jf.intel.com with ESMTP; 21 Jan 2016 15:07:30 -0800 From: Rafael Antognolli To: intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org Date: Thu, 21 Jan 2016 15:10:21 -0800 Message-Id: <1453417821-2811-5-git-send-email-rafael.antognolli@intel.com> X-Mailer: git-send-email 2.4.3 In-Reply-To: <1453417821-2811-1-git-send-email-rafael.antognolli@intel.com> References: <1453417821-2811-1-git-send-email-rafael.antognolli@intel.com> MIME-Version: 1.0 Cc: Alex Deucher Subject: [Intel-gfx] [PATCH v10 4/4] drm/radeon: Fix WARN_ON if DRM_DP_AUX_CHARDEV is enabled X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Lukas Wunner Rafael Antognolli's new DRM_DP_AUX_CHARDEV feature causes a WARN_ON if drm_dp_aux->dev == drm_connector->kdev and drm_dp_aux_unregister() is called after drm_connector_unregister(). radeon is the only driver affected by this besides i915. (amdgpu calls drm_dp_aux_unregister() before drm_connector_unregister().) Cc: Rafael Antognolli Cc: Ville Syrjälä Cc: Alex Deucher Signed-off-by: Lukas Wunner --- drivers/gpu/drm/radeon/radeon_display.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon_display.c b/drivers/gpu/drm/radeon/radeon_display.c index b3bb923..a885dae 100644 --- a/drivers/gpu/drm/radeon/radeon_display.c +++ b/drivers/gpu/drm/radeon/radeon_display.c @@ -1684,6 +1684,9 @@ void radeon_modeset_fini(struct radeon_device *rdev) radeon_fbdev_fini(rdev); kfree(rdev->mode_info.bios_hardcoded_edid); + /* free i2c buses */ + radeon_i2c_fini(rdev); + if (rdev->mode_info.mode_config_initialized) { radeon_afmt_fini(rdev); drm_kms_helper_poll_fini(rdev->ddev); @@ -1691,8 +1694,6 @@ void radeon_modeset_fini(struct radeon_device *rdev) drm_mode_config_cleanup(rdev->ddev); rdev->mode_info.mode_config_initialized = false; } - /* free i2c buses */ - radeon_i2c_fini(rdev); } static bool is_hdtv_mode(const struct drm_display_mode *mode)