From: Matthew Garrett <matthew.garrett@nebula.com>
To: andreas.noever@gmail.com
Cc: linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org,
greg@kroah.com, bhelgaas@google.com,
Matthew Garrett <matthew.garrett@nebula.com>
Subject: [PATCH] Thunderbolt: Add support for Thunderbolt 2 host controllers
Date: Sun, 1 Jun 2014 12:13:43 -0400 [thread overview]
Message-ID: <1401639223-3441-1-git-send-email-matthew.garrett@nebula.com> (raw)
Adding extra device IDs is enough to get this working on the second-gen
Thunderbolt controller in the Mac Pro.
Signed-off-by: Matthew Garrett <matthew.garrett@nebula.com>
---
drivers/pci/quirks.c | 2 ++
drivers/thunderbolt/nhi.c | 5 +++++
drivers/thunderbolt/switch.c | 5 ++++-
3 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
index c3170d4..20e76d0 100644
--- a/drivers/pci/quirks.c
+++ b/drivers/pci/quirks.c
@@ -3083,6 +3083,8 @@ out:
}
DECLARE_PCI_FIXUP_RESUME_EARLY(PCI_VENDOR_ID_INTEL, 0x1547,
quirk_apple_wait_for_thunderbolt);
+DECLARE_PCI_FIXUP_SUSPEND_LATE(PCI_VENDOR_ID_INTEL, 0x156d,
+ quirk_apple_wait_for_thunderbolt);
#endif
static void pci_do_fixups(struct pci_dev *dev, struct pci_fixup *f,
diff --git a/drivers/thunderbolt/nhi.c b/drivers/thunderbolt/nhi.c
index 6f666fa..85b11d6 100644
--- a/drivers/thunderbolt/nhi.c
+++ b/drivers/thunderbolt/nhi.c
@@ -642,6 +642,11 @@ struct pci_device_id nhi_ids[] = {
.vendor = PCI_VENDOR_ID_INTEL, .device = 0x1547,
.subvendor = 0x2222, .subdevice = 0x1111,
},
+ {
+ .class = PCI_CLASS_SYSTEM_OTHER << 8, .class_mask = ~0,
+ .vendor = PCI_VENDOR_ID_INTEL, .device = 0x156c,
+ .subvendor = 0x2222, .subdevice = 0x1111,
+ },
{ 0,}
};
diff --git a/drivers/thunderbolt/switch.c b/drivers/thunderbolt/switch.c
index 2e19045..1fccdbf 100644
--- a/drivers/thunderbolt/switch.c
+++ b/drivers/thunderbolt/switch.c
@@ -294,8 +294,11 @@ static int tb_plug_events_active(struct tb_switch *sw, bool active)
if (active) {
data = data & 0xFFFFFF83;
- if (sw->config.device_id == 0x1547)
+ switch (sw->config.device_id) {
+ case 0x1547:
+ case 0x156d:
data |= 4;
+ }
} else {
data = data | 0x7c;
}
--
2.0.0
next reply other threads:[~2014-06-01 16:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-01 16:13 Matthew Garrett [this message]
2014-06-01 20:42 ` Andreas Noever
2014-06-01 22:05 ` Matthew Garrett
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1401639223-3441-1-git-send-email-matthew.garrett@nebula.com \
--to=matthew.garrett@nebula.com \
--cc=andreas.noever@gmail.com \
--cc=bhelgaas@google.com \
--cc=greg@kroah.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®