From patchwork Wed Oct 5 21:47:03 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Agner X-Patchwork-Id: 9363481 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 4629C600C8 for ; Wed, 5 Oct 2016 21:47:42 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2DD0E28CC6 for ; Wed, 5 Oct 2016 21:47:42 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2226628D05; Wed, 5 Oct 2016 21:47:42 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id E82C828CC6 for ; Wed, 5 Oct 2016 21:47:41 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 8FCB26E324; Wed, 5 Oct 2016 21:47:38 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail.kmu-office.ch (mail.kmu-office.ch [178.209.48.109]) by gabe.freedesktop.org (Postfix) with ESMTPS id 6E8DA6E324 for ; Wed, 5 Oct 2016 21:47:35 +0000 (UTC) Received: from trochilidae.toradex.int (75-146-58-181-Washington.hfc.comcastbusiness.net [75.146.58.181]) by mail.kmu-office.ch (Postfix) with ESMTPSA id 73B305C2F05; Wed, 5 Oct 2016 23:41:36 +0200 (CEST) From: Stefan Agner To: meng.yi@nxp.com, dri-devel@lists.freedesktop.org Subject: [PATCH v2 5/5] drm/fsl-dcu: only init fbdev if required Date: Wed, 5 Oct 2016 14:47:03 -0700 Message-Id: <20161005214703.1604-8-stefan@agner.ch> X-Mailer: git-send-email 2.10.0 In-Reply-To: <20161005214703.1604-1-stefan@agner.ch> References: <20161005214703.1604-1-stefan@agner.ch> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=agner.ch; s=dkim; t=1475703697; bh=yfSJcoehM0O0SWbh1JooXCwP3cfNoXZBRwqzGT5hL0s=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References; b=KhYrHgHMIDt/lyGM4nlncBkgumhJEBqyxSFWPLG4b7FJ8xe88LUwOWUkAbJt6FjJvMaxePeUZ4wA66Gw0BvT74HzJLV2nWmEU8uk7Mk4vGgAyPjadxgT4GfN5Q44VS6g3i6BC4oXRhG66+i/r88+APLJvyMkAzTuuPJ8OFoHS0M= Cc: jianwei.wang.chn@gmail.com, linux-kernel@vger.kernel.org, alison.wang@freescale.com X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP There is no need to request a CMA backed framebuffer if fbdev emulation is not enabled. Signed-off-by: Stefan Agner --- drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c b/drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c index 07969f5..86dd4e3 100644 --- a/drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c +++ b/drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c @@ -87,7 +87,8 @@ static int fsl_dcu_load(struct drm_device *dev, unsigned long flags) goto done; dev->irq_enabled = true; - fsl_dcu_fbdev_init(dev); + if (IS_ENABLED(CONFIG_DRM_FBDEV_EMULATION)) + fsl_dcu_fbdev_init(dev); return 0; done: