On Fri, Jul 17, 2015 at 04:32:00PM -0500, Bjorn Helgaas wrote: > @@ -98,13 +81,13 @@ void pci_disable_ats(struct pci_dev *dev) > { > u16 ctrl; > > - BUG_ON(!dev->ats || !dev->ats->is_enabled); > + BUG_ON(!dev->ats_cap || !dev->ats_enabled); So since dev->ats_enabled can only get set to 1 of dev->ats_cap != 0, wouldn't it be sufficient to just do a BUG_ON(!dev->ats_enabled)? > static inline int pci_ats_enabled(struct pci_dev *dev) > { > - return dev->ats && dev->ats->is_enabled; > + return dev->ats_cap && dev->ats_enabled; > } Here too, can't we just return dev->ats_enabled? Joerg -- To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html