From patchwork Mon Sep 29 16:00:33 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 4997721 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id CFAF9BEEA6 for ; Mon, 29 Sep 2014 16:00:42 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9D24E20172 for ; Mon, 29 Sep 2014 16:00:41 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 6BFC2201C0 for ; Mon, 29 Sep 2014 16:00:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754380AbaI2QAk (ORCPT ); Mon, 29 Sep 2014 12:00:40 -0400 Received: from mout.kundenserver.de ([212.227.126.187]:50855 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753536AbaI2QAj (ORCPT ); Mon, 29 Sep 2014 12:00:39 -0400 Received: from wuerfel.localnet (HSI-KBW-134-3-133-35.hsi14.kabel-badenwuerttemberg.de [134.3.133.35]) by mrelayeu.kundenserver.de (node=mreue007) with ESMTP (Nemesis) id 0MR6eg-1Xgzuc09Hi-00UMmi; Mon, 29 Sep 2014 18:00:36 +0200 From: Arnd Bergmann To: Tomi Valkeinen Cc: Steffen Trumtrar , Laurent Pinchart , Philipp Zabel , Jean-Christophe Plagniol-Villard , linux-fbdev@vger.kernel.org Subject: [PATCH] videomode: provide dummy of_get_display_timing helper Date: Mon, 29 Sep 2014 18:00:33 +0200 Message-ID: <1957575.to7BPgiTer@wuerfel> User-Agent: KMail/4.11.5 (Linux/3.16.0-10-generic; KDE/4.11.5; x86_64; ; ) MIME-Version: 1.0 X-Provags-ID: V02:K0:cjETFjz6AfzmM+0S7Xlvn3j6ZjoJJ0oKDbt8RKXsnl/ F7P8LJFoAhp/G2mH9LIpkuo2dYEw1EF+4IMBM5kno9MKkg3Lo1 mPuZK5DrXtXqRPKmwk/N8/iupGsL+Rv+JP87jKRd6jpTSed3Nv cGtrTSRe/sjReG2CW+5Z2QaWct2U00BgM4WNdKvSebqIRWAHCe YhK8ivBLfHHstFMcpdYDX7yjfSCmuirvQj6/4dQgbjBl6WPq4b 3LEWlz/UKXiuDkYsMzJYyXfWND2sAwMAiM1ilzYq4X5CWEyzTI KATj5+300XBJXighGGO2y6izgmlwmzX6m7a0iM4k0AZGqyv0Hr hm7jo7FTz5kw5+/VfF0I= X-UI-Out-Filterresults: notjunk:1; Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Spam-Status: No, score=-7.7 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham 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 If CONFIG_OF is disabled but we build any driver that tries to use of_get_display_timing, we get this link error: ERROR: "of_get_display_timing" [drivers/gpu/drm/rcar-du/rcar-du-drm.ko] undefined! This adds an empty inline function as an alternative, to avoid changing each driver using this function when we want to build them without CONFIG_OF. Signed-off-by: Arnd Bergmann --- To unsubscribe from this list: send the line "unsubscribe linux-fbdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/include/video/of_display_timing.h b/include/video/of_display_timing.h index 79e6697af6cf..02b6eb7c3ded 100644 --- a/include/video/of_display_timing.h +++ b/include/video/of_display_timing.h @@ -15,8 +15,17 @@ struct display_timings; #define OF_USE_NATIVE_MODE -1 +#ifdef CONFIG_OF int of_get_display_timing(struct device_node *np, const char *name, struct display_timing *dt); +#else +static inline int of_get_display_timing(struct device_node *np, const char *name, + struct display_timing *dt) +{ + return -ENOSYS; +} + +#endif struct display_timings *of_get_display_timings(struct device_node *np); int of_display_timings_exist(struct device_node *np);