From c8b349af3b1234b647612c5ecd89ecad30ed5c32 Mon Sep 17 00:00:00 2001 From: Alex Williamson Date: Tue, 24 Jan 2012 15:45:28 +0100 Subject: [PATCH 3/5] pci-assign: Remove bogus PCIe lnkcap wmask setting RH-Author: Alex Williamson Message-id: <20120124154528.27090.5692.stgit@bling.home> Patchwork-id: 36788 O-Subject: [PATCH 3/4] pci-assign: Remove bogus PCIe lnkcap wmask setting Bugzilla: 754565 RH-Acked-by: Laszlo Ersek RH-Acked-by: Markus Armbruster RH-Acked-by: Don Dutile Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=754565 Upstream commit: 0cbb68b1ce40e9b7e0b8cea5fd849f5c6bd09aee All the fields of lnkcap are read-only and this is setting it with mask values from LNKCTL. Just below it, we indicate link control is read only, so this appears to be a stray chunk left in from development. Trivial comment fix while we're here. Signed-off-by: Alex Williamson Signed-off-by: Avi Kivity --- hw/device-assignment.c | 6 +----- 1 files changed, 1 insertions(+), 5 deletions(-) Signed-off-by: Michal Novotny --- hw/device-assignment.c | 6 +----- 1 files changed, 1 insertions(+), 5 deletions(-) diff --git a/hw/device-assignment.c b/hw/device-assignment.c index 7c0740c..99c5419 100644 --- a/hw/device-assignment.c +++ b/hw/device-assignment.c @@ -1492,7 +1492,7 @@ static int assigned_device_pci_cap_init(PCIDevice *pci_dev) pci_set_long(pci_dev->config + pos + PCI_EXP_DEVCAP, devcap); /* device control: clear all error reporting enable bits, leaving - * leaving only a few host values. Note, these are + * only a few host values. Note, these are * all writable, but not passed to hw. */ devctl = pci_get_word(pci_dev->config + pos + PCI_EXP_DEVCTL); @@ -1511,10 +1511,6 @@ static int assigned_device_pci_cap_init(PCIDevice *pci_dev) PCI_EXP_LNKCAP_ASPMS | PCI_EXP_LNKCAP_L0SEL | PCI_EXP_LNKCAP_L1EL); pci_set_long(pci_dev->config + pos + PCI_EXP_LNKCAP, lnkcap); - pci_set_word(pci_dev->wmask + pos + PCI_EXP_LNKCAP, - PCI_EXP_LNKCTL_ASPMC | PCI_EXP_LNKCTL_RCB | - PCI_EXP_LNKCTL_CCC | PCI_EXP_LNKCTL_ES | - PCI_EXP_LNKCTL_CLKREQ_EN | PCI_EXP_LNKCTL_HAWD); /* Link control, pass existing read-only copy. Should be writable? */ -- 1.7.7.5