From patchwork Mon Jun 24 09:21:53 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Vetter X-Patchwork-Id: 11012709 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 2167818E8 for ; Mon, 24 Jun 2019 09:22:05 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1122A28AF3 for ; Mon, 24 Jun 2019 09:22:05 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 03F9128B4C; Mon, 24 Jun 2019 09:22:05 +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=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED 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 8992928AF3 for ; Mon, 24 Jun 2019 09:22:04 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 30AB589337; Mon, 24 Jun 2019 09:22:03 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-ed1-x543.google.com (mail-ed1-x543.google.com [IPv6:2a00:1450:4864:20::543]) by gabe.freedesktop.org (Postfix) with ESMTPS id 7113389337 for ; Mon, 24 Jun 2019 09:22:01 +0000 (UTC) Received: by mail-ed1-x543.google.com with SMTP id e3so20706999edr.10 for ; Mon, 24 Jun 2019 02:22:01 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=+BUYv0zqx8JIAejbVUFuWCyUFzi0Ma0oiXTkdM9XeBA=; b=taQMXXBXQqS6s1mDwwICQ4f6zEY2I6dvaoW5mNalgU8xeHhI5/r+NWlhpXRK8mVGdE uja2mGWmb1SUY/Hdgh4M7tmDrAUWC0/gQIAPj/de1Z/UG0D5y5HuucoT7dSaZlRHd51+ 60Vp1ObIXqbCq3IJjxV2NUirbeRe8DV1MJEF7bcdJic7JWu/VQjJ+RginX+UnTIp5eic 9NrXOTV3efygoNSVNkzIbMQmNFSl3CUxqpabG5l+tP8AQyS5zPEfvkejGxaioY8LtUFK gatzDsP8pf6FAHt7EWGpmlmRjRR7hrXTDc0bJ95XIAc2XtuR5mYB0NiwVmWyTy1rR5GS 43UQ== X-Gm-Message-State: APjAAAXy2m949VkJXNsvG4v46uTAlwDxIClo61CejL/NusgcPL38g8ws m/erlPkyYzDA0HwwUwOX99/KnuH6gAg= X-Google-Smtp-Source: APXvYqz8Q2nVLs1tDAdsiwqZ2dYDUxN/Py220zuadxrweoxy+8stjJzd4MvG81Wi2CYIZ1kAGnzZXw== X-Received: by 2002:a17:906:1dcb:: with SMTP id v11mr1768180ejh.218.1561368119634; Mon, 24 Jun 2019 02:21:59 -0700 (PDT) Received: from phenom.ffwll.local ([2a02:168:569e:0:3106:d637:d723:e855]) by smtp.gmail.com with ESMTPSA id c3sm1769156ejo.43.2019.06.24.02.21.58 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 02:21:58 -0700 (PDT) From: Daniel Vetter To: DRI Development Subject: [PATCH] vga_switcheroo: Depend upon fbcon being built-in, if enabled Date: Mon, 24 Jun 2019 11:21:53 +0200 Message-Id: <20190624092153.23375-1-daniel.vetter@ffwll.ch> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ffwll.ch; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=+BUYv0zqx8JIAejbVUFuWCyUFzi0Ma0oiXTkdM9XeBA=; b=D5WZwKUOqaEYxf9YiCGA1hGGeS+fnJ87Uk5TnGhZMEmbhxOZBjbdtmZi5JFaciO6rf fYk4DRN8WEzOg5rJR6avnD3k16txo0YzxSmxnlh68316/FKyoLfFUebCQ7IGOZqBH7ii KwbVftADxitSPXm1+Z5+bbC5EWcXZytEwhHbc= X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Sean Paul , Stephen Rothwell , Hans de Goede , kbuild test robot , Bartlomiej Zolnierkiewicz , David Airlie , Daniel Vetter , linux-fbdev@vger.kernel.org, Yisheng Xie , Maxime Ripard , Daniel Vetter , Lee Jones , Daniel Thompson , Sam Ravnborg Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Fixes linking fail when fbcon/fbdev is modular and vgaswitcheroo is enabled: x86_64-linux-gnu-ld: drivers/gpu/vga/vga_switcheroo.o: in function `vga_switchto_stage2': vga_switcheroo.c:(.text+0x997): undefined reference to `fbcon_remap_all' v2: I first tried to fix this with an EXPORT_SYMBOL, but vga_switcheroo is never a module, so this doesn't work. Reported-by: Stephen Rothwell Reported-by: kbuild test robot Fixes: 1cd51b5d200d ("vgaswitcheroo: call fbcon_remap_all directly") Cc: Stephen Rothwell Cc: Lukas Wunner Cc: Daniel Vetter Cc: Sam Ravnborg Cc: Maarten Lankhorst Cc: David Airlie Cc: Daniel Vetter Cc: Maxime Ripard Cc: Sean Paul Cc: Bartlomiej Zolnierkiewicz Cc: Hans de Goede Cc: Yisheng Xie Cc: linux-fbdev@vger.kernel.org Cc: Daniel Thompson Cc: Lee Jones Cc: dri-devel@lists.freedesktop.org Cc: linux-fbdev@vger.kernel.org Signed-off-by: Daniel Vetter --- wrt merging probably best if Maarten adds this to the topic branch we have already and sends out an updated pull request. Apologies for the mess. -Daniel --- drivers/gpu/vga/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/vga/Kconfig b/drivers/gpu/vga/Kconfig index 84ab482d0db6..c8c770b05ed9 100644 --- a/drivers/gpu/vga/Kconfig +++ b/drivers/gpu/vga/Kconfig @@ -23,6 +23,7 @@ config VGA_SWITCHEROO depends on X86 depends on ACPI depends on PCI + depends on (FRAMEBUFFER_CONSOLE=n || FB=y) select VGA_ARB help Many laptops released in 2008/9/10 have two GPUs with a multiplexer