aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/pci')
-rw-r--r--drivers/pci/dmar.c12
-rw-r--r--drivers/pci/htirq.c16
-rw-r--r--drivers/pci/intel-iommu.c2
-rw-r--r--drivers/pci/intr_remapping.c2
-rw-r--r--drivers/pci/msi.c10
5 files changed, 21 insertions, 21 deletions
diff --git a/drivers/pci/dmar.c b/drivers/pci/dmar.c
index 09933eb9126b..12e02bf92c4a 100644
--- a/drivers/pci/dmar.c
+++ b/drivers/pci/dmar.c
@@ -1226,7 +1226,7 @@ const char *dmar_get_fault_reason(u8 fault_reason, int *fault_type)
1226 1226
1227void dmar_msi_unmask(struct irq_data *data) 1227void dmar_msi_unmask(struct irq_data *data)
1228{ 1228{
1229 struct intel_iommu *iommu = irq_data_get_irq_data(data); 1229 struct intel_iommu *iommu = irq_data_get_irq_handler_data(data);
1230 unsigned long flag; 1230 unsigned long flag;
1231 1231
1232 /* unmask it */ 1232 /* unmask it */
@@ -1240,7 +1240,7 @@ void dmar_msi_unmask(struct irq_data *data)
1240void dmar_msi_mask(struct irq_data *data) 1240void dmar_msi_mask(struct irq_data *data)
1241{ 1241{
1242 unsigned long flag; 1242 unsigned long flag;
1243 struct intel_iommu *iommu = irq_data_get_irq_data(data); 1243 struct intel_iommu *iommu = irq_data_get_irq_handler_data(data);
1244 1244
1245 /* mask it */ 1245 /* mask it */
1246 spin_lock_irqsave(&iommu->register_lock, flag); 1246 spin_lock_irqsave(&iommu->register_lock, flag);
@@ -1252,7 +1252,7 @@ void dmar_msi_mask(struct irq_data *data)
1252 1252
1253void dmar_msi_write(int irq, struct msi_msg *msg) 1253void dmar_msi_write(int irq, struct msi_msg *msg)
1254{ 1254{
1255 struct intel_iommu *iommu = get_irq_data(irq); 1255 struct intel_iommu *iommu = irq_get_handler_data(irq);
1256 unsigned long flag; 1256 unsigned long flag;
1257 1257
1258 spin_lock_irqsave(&iommu->register_lock, flag); 1258 spin_lock_irqsave(&iommu->register_lock, flag);
@@ -1264,7 +1264,7 @@ void dmar_msi_write(int irq, struct msi_msg *msg)
1264 1264
1265void dmar_msi_read(int irq, struct msi_msg *msg) 1265void dmar_msi_read(int irq, struct msi_msg *msg)
1266{ 1266{
1267 struct intel_iommu *iommu = get_irq_data(irq); 1267 struct intel_iommu *iommu = irq_get_handler_data(irq);
1268 unsigned long flag; 1268 unsigned long flag;
1269 1269
1270 spin_lock_irqsave(&iommu->register_lock, flag); 1270 spin_lock_irqsave(&iommu->register_lock, flag);
@@ -1382,12 +1382,12 @@ int dmar_set_interrupt(struct intel_iommu *iommu)
1382 return -EINVAL; 1382 return -EINVAL;
1383 } 1383 }
1384 1384
1385 set_irq_data(irq, iommu); 1385 irq_set_handler_data(irq, iommu);
1386 iommu->irq = irq; 1386 iommu->irq = irq;
1387 1387
1388 ret = arch_setup_dmar_msi(irq); 1388 ret = arch_setup_dmar_msi(irq);
1389 if (ret) { 1389 if (ret) {
1390 set_irq_data(irq, NULL); 1390 irq_set_handler_data(irq, NULL);
1391 iommu->irq = 0; 1391 iommu->irq = 0;
1392 destroy_irq(irq); 1392 destroy_irq(irq);
1393 return ret; 1393 return ret;
diff --git a/drivers/pci/htirq.c b/drivers/pci/htirq.c
index 834842aa5bbf..db057b6fe0c8 100644
--- a/drivers/pci/htirq.c
+++ b/drivers/pci/htirq.c
@@ -34,7 +34,7 @@ struct ht_irq_cfg {
34 34
35void write_ht_irq_msg(unsigned int irq, struct ht_irq_msg *msg) 35void write_ht_irq_msg(unsigned int irq, struct ht_irq_msg *msg)
36{ 36{
37 struct ht_irq_cfg *cfg = get_irq_data(irq); 37 struct ht_irq_cfg *cfg = irq_get_handler_data(irq);
38 unsigned long flags; 38 unsigned long flags;
39 spin_lock_irqsave(&ht_irq_lock, flags); 39 spin_lock_irqsave(&ht_irq_lock, flags);
40 if (cfg->msg.address_lo != msg->address_lo) { 40 if (cfg->msg.address_lo != msg->address_lo) {
@@ -53,13 +53,13 @@ void write_ht_irq_msg(unsigned int irq, struct ht_irq_msg *msg)
53 53
54void fetch_ht_irq_msg(unsigned int irq, struct ht_irq_msg *msg) 54void fetch_ht_irq_msg(unsigned int irq, struct ht_irq_msg *msg)
55{ 55{
56 struct ht_irq_cfg *cfg = get_irq_data(irq); 56 struct ht_irq_cfg *cfg = irq_get_handler_data(irq);
57 *msg = cfg->msg; 57 *msg = cfg->msg;
58} 58}
59 59
60void mask_ht_irq(struct irq_data *data) 60void mask_ht_irq(struct irq_data *data)
61{ 61{
62 struct ht_irq_cfg *cfg = irq_data_get_irq_data(data); 62 struct ht_irq_cfg *cfg = irq_data_get_irq_handler_data(data);
63 struct ht_irq_msg msg = cfg->msg; 63 struct ht_irq_msg msg = cfg->msg;
64 64
65 msg.address_lo |= 1; 65 msg.address_lo |= 1;
@@ -68,7 +68,7 @@ void mask_ht_irq(struct irq_data *data)
68 68
69void unmask_ht_irq(struct irq_data *data) 69void unmask_ht_irq(struct irq_data *data)
70{ 70{
71 struct ht_irq_cfg *cfg = irq_data_get_irq_data(data); 71 struct ht_irq_cfg *cfg = irq_data_get_irq_handler_data(data);
72 struct ht_irq_msg msg = cfg->msg; 72 struct ht_irq_msg msg = cfg->msg;
73 73
74 msg.address_lo &= ~1; 74 msg.address_lo &= ~1;
@@ -126,7 +126,7 @@ int __ht_create_irq(struct pci_dev *dev, int idx, ht_irq_update_t *update)
126 kfree(cfg); 126 kfree(cfg);
127 return -EBUSY; 127 return -EBUSY;
128 } 128 }
129 set_irq_data(irq, cfg); 129 irq_set_handler_data(irq, cfg);
130 130
131 if (arch_setup_ht_irq(irq, dev) < 0) { 131 if (arch_setup_ht_irq(irq, dev) < 0) {
132 ht_destroy_irq(irq); 132 ht_destroy_irq(irq);
@@ -162,9 +162,9 @@ void ht_destroy_irq(unsigned int irq)
162{ 162{
163 struct ht_irq_cfg *cfg; 163 struct ht_irq_cfg *cfg;
164 164
165 cfg = get_irq_data(irq); 165 cfg = irq_get_handler_data(irq);
166 set_irq_chip(irq, NULL); 166 irq_set_chip(irq, NULL);
167 set_irq_data(irq, NULL); 167 irq_set_handler_data(irq, NULL);
168 destroy_irq(irq); 168 destroy_irq(irq);
169 169
170 kfree(cfg); 170 kfree(cfg);
diff --git a/drivers/pci/intel-iommu.c b/drivers/pci/intel-iommu.c
index a4115f1afe1f..7da3bef60d87 100644
--- a/drivers/pci/intel-iommu.c
+++ b/drivers/pci/intel-iommu.c
@@ -1206,7 +1206,7 @@ void free_dmar_iommu(struct intel_iommu *iommu)
1206 iommu_disable_translation(iommu); 1206 iommu_disable_translation(iommu);
1207 1207
1208 if (iommu->irq) { 1208 if (iommu->irq) {
1209 set_irq_data(iommu->irq, NULL); 1209 irq_set_handler_data(iommu->irq, NULL);
1210 /* This will mask the irq */ 1210 /* This will mask the irq */
1211 free_irq(iommu->irq, iommu); 1211 free_irq(iommu->irq, iommu);
1212 destroy_irq(iommu->irq); 1212 destroy_irq(iommu->irq);
diff --git a/drivers/pci/intr_remapping.c b/drivers/pci/intr_remapping.c
index ec87cd66f3eb..a22557b20283 100644
--- a/drivers/pci/intr_remapping.c
+++ b/drivers/pci/intr_remapping.c
@@ -50,7 +50,7 @@ static DEFINE_SPINLOCK(irq_2_ir_lock);
50 50
51static struct irq_2_iommu *irq_2_iommu(unsigned int irq) 51static struct irq_2_iommu *irq_2_iommu(unsigned int irq)
52{ 52{
53 struct irq_cfg *cfg = get_irq_chip_data(irq); 53 struct irq_cfg *cfg = irq_get_chip_data(irq);
54 return cfg ? &cfg->irq_2_iommu : NULL; 54 return cfg ? &cfg->irq_2_iommu : NULL;
55} 55}
56 56
diff --git a/drivers/pci/msi.c b/drivers/pci/msi.c
index 44b0aeee83e5..2f10328bf661 100644
--- a/drivers/pci/msi.c
+++ b/drivers/pci/msi.c
@@ -236,7 +236,7 @@ void __read_msi_msg(struct msi_desc *entry, struct msi_msg *msg)
236 236
237void read_msi_msg(unsigned int irq, struct msi_msg *msg) 237void read_msi_msg(unsigned int irq, struct msi_msg *msg)
238{ 238{
239 struct msi_desc *entry = get_irq_msi(irq); 239 struct msi_desc *entry = irq_get_msi_desc(irq);
240 240
241 __read_msi_msg(entry, msg); 241 __read_msi_msg(entry, msg);
242} 242}
@@ -253,7 +253,7 @@ void __get_cached_msi_msg(struct msi_desc *entry, struct msi_msg *msg)
253 253
254void get_cached_msi_msg(unsigned int irq, struct msi_msg *msg) 254void get_cached_msi_msg(unsigned int irq, struct msi_msg *msg)
255{ 255{
256 struct msi_desc *entry = get_irq_msi(irq); 256 struct msi_desc *entry = irq_get_msi_desc(irq);
257 257
258 __get_cached_msi_msg(entry, msg); 258 __get_cached_msi_msg(entry, msg);
259} 259}
@@ -297,7 +297,7 @@ void __write_msi_msg(struct msi_desc *entry, struct msi_msg *msg)
297 297
298void write_msi_msg(unsigned int irq, struct msi_msg *msg) 298void write_msi_msg(unsigned int irq, struct msi_msg *msg)
299{ 299{
300 struct msi_desc *entry = get_irq_msi(irq); 300 struct msi_desc *entry = irq_get_msi_desc(irq);
301 301
302 __write_msi_msg(entry, msg); 302 __write_msi_msg(entry, msg);
303} 303}
@@ -354,7 +354,7 @@ static void __pci_restore_msi_state(struct pci_dev *dev)
354 if (!dev->msi_enabled) 354 if (!dev->msi_enabled)
355 return; 355 return;
356 356
357 entry = get_irq_msi(dev->irq); 357 entry = irq_get_msi_desc(dev->irq);
358 pos = entry->msi_attrib.pos; 358 pos = entry->msi_attrib.pos;
359 359
360 pci_intx_for_msi(dev, 0); 360 pci_intx_for_msi(dev, 0);
@@ -519,7 +519,7 @@ static void msix_program_entries(struct pci_dev *dev,
519 PCI_MSIX_ENTRY_VECTOR_CTRL; 519 PCI_MSIX_ENTRY_VECTOR_CTRL;
520 520
521 entries[i].vector = entry->irq; 521 entries[i].vector = entry->irq;
522 set_irq_msi(entry->irq, entry); 522 irq_set_msi_desc(entry->irq, entry);
523 entry->masked = readl(entry->mask_base + offset); 523 entry->masked = readl(entry->mask_base + offset);
524 msix_mask_irq(entry, 1); 524 msix_mask_irq(entry, 1);
525 i++; 525 i++;