Update the vgaarb patches to pick up a small switcheroo fix from airlied

This commit is contained in:
Josh Boyer 2012-05-16 12:35:56 -04:00
parent 34b6abb66f
commit 0e8b5cac91
2 changed files with 95 additions and 2 deletions

View File

@ -54,7 +54,7 @@ Summary: The Linux kernel
# For non-released -rc kernels, this will be appended after the rcX and
# gitX tags, so a 3 here would become part of release "0.rcX.gitX.3"
#
%global baserelease 2
%global baserelease 3
%global fedora_build %{baserelease}
# base_sublevel is the kernel version we're starting with and patching
@ -2417,6 +2417,9 @@ fi
# '-' | |
# '-'
%changelog
* Wed May 16 2012 Josh Boyer <jwboyer@redhat.com>
- Update the vgaarb patches to pick up a small switcheroo fix from airlied
* Tue May 15 2012 Dennis Gilmore <dennis@ausil.us>
- add patch to setup usb correctly on beagleboards
- allows networking to work

View File

@ -431,7 +431,7 @@ index c4b9dc2..2723c07 100644
#define vga_readb(x) (*(x))
#define vga_writeb(x, y) (*(y) = (x))
+#if CONFIG_FB_EFI
+#ifdef CONFIG_FB_EFI
+#define __ARCH_HAS_VGA_DEFAULT_DEVICE
+extern struct pci_dev *vga_default_device(void);
+extern void vga_set_default_device(struct pci_dev *pdev);
@ -550,3 +550,93 @@ 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/
Path: news.gmane.org!not-for-mail
From: Dave Airlie <airlied@gmail.com>
Newsgroups: gmane.linux.kernel
Subject: [PATCH] x86/vga: set the default device from the fixup.
Date: Mon, 14 May 2012 17:01:20 +0100
Lines: 42
Approved: news@gmane.org
Message-ID: <1337011280-7166-1-git-send-email-airlied@gmail.com>
NNTP-Posting-Host: plane.gmane.org
X-Trace: dough.gmane.org 1337011751 27684 80.91.229.3 (14 May 2012 16:09:11 GMT)
X-Complaints-To: usenet@dough.gmane.org
NNTP-Posting-Date: Mon, 14 May 2012 16:09:11 +0000 (UTC)
Cc: Dave Airlie <airlied@redhat.com>, Matthew Garrett <mjg@redhat.com>,
"H. Peter Anvin" <hpa@zytor.com>
To: linux-kernel@vger.kernel.org
Original-X-From: linux-kernel-owner@vger.kernel.org Mon May 14 18:09:10 2012
Return-path: <linux-kernel-owner@vger.kernel.org>
Envelope-to: glk-linux-kernel-3@plane.gmane.org
Original-Received: from vger.kernel.org ([209.132.180.67])
by plane.gmane.org with esmtp (Exim 4.69)
(envelope-from <linux-kernel-owner@vger.kernel.org>)
id 1STxpW-0007oo-4X
for glk-linux-kernel-3@plane.gmane.org; Mon, 14 May 2012 18:09:02 +0200
Original-Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand
id S1756889Ab2ENQIs (ORCPT <rfc822;glk-linux-kernel-3@m.gmane.org>);
Mon, 14 May 2012 12:08:48 -0400
Original-Received: from mx1.redhat.com ([209.132.183.28]:34445 "EHLO mx1.redhat.com"
rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP
id S1756736Ab2ENQIm (ORCPT <rfc822;linux-kernel@vger.kernel.org>);
Mon, 14 May 2012 12:08:42 -0400
Original-Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24])
by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q4EG8ftT012092
(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK);
Mon, 14 May 2012 12:08:42 -0400
Original-Received: from optimus.redhat.com (vpn1-5-164.ams2.redhat.com [10.36.5.164])
by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id q4EG5Ch0001452;
Mon, 14 May 2012 12:05:12 -0400
X-Scanned-By: MIMEDefang 2.68 on 10.5.11.24
Original-Sender: linux-kernel-owner@vger.kernel.org
Precedence: bulk
List-ID: <linux-kernel.vger.kernel.org>
X-Mailing-List: linux-kernel@vger.kernel.org
Xref: news.gmane.org gmane.linux.kernel:1296685
Archived-At: <http://permalink.gmane.org/gmane.linux.kernel/1296685>
From: Dave Airlie <airlied@redhat.com>
Since Matthew's efi/vga changes on non-EFI machines we were failing
to tell the vgaarb/switcheroo what the default device was, this
sets the default device in the quirk if none has been set before.
This fixes the switcheroo on my T410s.
[hpa: please ack to put this on top of the other patches in my -next tree].
Signed-off-by: Dave Airlie <airlied@redhat.com>
Cc: Matthew Garrett <mjg@redhat.com>
Cc: H. Peter Anvin <hpa@zytor.com>
---
arch/x86/pci/fixup.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/arch/x86/pci/fixup.c b/arch/x86/pci/fixup.c
index d0e6e40..cf81c02 100644
--- a/arch/x86/pci/fixup.c
+++ b/arch/x86/pci/fixup.c
@@ -7,6 +7,7 @@
#include <linux/pci.h>
#include <linux/init.h>
#include <asm/pci_x86.h>
+#include <asm/vga.h>
static void __devinit pci_fixup_i450nx(struct pci_dev *d)
{
@@ -348,6 +349,8 @@ static void __devinit pci_fixup_video(struct pci_dev *pdev)
if (config & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) {
pdev->resource[PCI_ROM_RESOURCE].flags |= IORESOURCE_ROM_SHADOW;
dev_printk(KERN_DEBUG, &pdev->dev, "Boot video device\n");
+ if (vga_default_device() == NULL)
+ vga_set_default_device(pdev);
}
}
DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_ANY_ID, PCI_ANY_ID,
--
1.7.6