Commit 227f0647 authored by Ryan Desfosses's avatar Ryan Desfosses Committed by Bjorn Helgaas

PCI: Merge multi-line quoted strings

Merge quoted strings that are broken across lines into a single entity.
The compiler merges them anyway, but checkpatch complains about it, and
merging them makes it easier to grep for strings.

No functional change.

[bhelgaas: changelog, do the same for everything under drivers/pci]
Signed-off-by: default avatarRyan Desfosses <ryan@desfo.org>
Signed-off-by: default avatarBjorn Helgaas <bhelgaas@google.com>
parent 3c78bc61
...@@ -231,10 +231,7 @@ static int pci_vpd_pci22_wait(struct pci_dev *dev) ...@@ -231,10 +231,7 @@ static int pci_vpd_pci22_wait(struct pci_dev *dev)
} }
if (time_after(jiffies, timeout)) { if (time_after(jiffies, timeout)) {
dev_printk(KERN_DEBUG, &dev->dev, dev_printk(KERN_DEBUG, &dev->dev, "vpd r/w failed. This is likely a firmware bug on this device. Contact the card vendor for a firmware update\n");
"vpd r/w failed. This is likely a firmware "
"bug on this device. Contact the card "
"vendor for a firmware update.");
return -ETIMEDOUT; return -ETIMEDOUT;
} }
if (fatal_signal_pending(current)) if (fatal_signal_pending(current))
......
...@@ -277,9 +277,8 @@ static int rcar_pcie_read_conf(struct pci_bus *bus, unsigned int devfn, ...@@ -277,9 +277,8 @@ static int rcar_pcie_read_conf(struct pci_bus *bus, unsigned int devfn,
else if (size == 2) else if (size == 2)
*val = (*val >> (8 * (where & 2))) & 0xffff; *val = (*val >> (8 * (where & 2))) & 0xffff;
dev_dbg(&bus->dev, "pcie-config-read: bus=%3d devfn=0x%04x " dev_dbg(&bus->dev, "pcie-config-read: bus=%3d devfn=0x%04x where=0x%04x size=%d val=0x%08lx\n",
"where=0x%04x size=%d val=0x%08lx\n", bus->number, bus->number, devfn, where, size, (unsigned long)*val);
devfn, where, size, (unsigned long)*val);
return ret; return ret;
} }
...@@ -302,9 +301,8 @@ static int rcar_pcie_write_conf(struct pci_bus *bus, unsigned int devfn, ...@@ -302,9 +301,8 @@ static int rcar_pcie_write_conf(struct pci_bus *bus, unsigned int devfn,
if (ret != PCIBIOS_SUCCESSFUL) if (ret != PCIBIOS_SUCCESSFUL)
return ret; return ret;
dev_dbg(&bus->dev, "pcie-config-write: bus=%3d devfn=0x%04x " dev_dbg(&bus->dev, "pcie-config-write: bus=%3d devfn=0x%04x where=0x%04x size=%d val=0x%08lx\n",
"where=0x%04x size=%d val=0x%08lx\n", bus->number, bus->number, devfn, where, size, (unsigned long)val);
devfn, where, size, (unsigned long)val);
if (size == 1) { if (size == 1) {
shift = 8 * (where & 3); shift = 8 * (where & 3);
......
...@@ -351,11 +351,9 @@ static acpi_status acpiphp_add_context(acpi_handle handle, u32 lvl, void *data, ...@@ -351,11 +351,9 @@ static acpi_status acpiphp_add_context(acpi_handle handle, u32 lvl, void *data,
slot->slot = NULL; slot->slot = NULL;
bridge->nr_slots--; bridge->nr_slots--;
if (retval == -EBUSY) if (retval == -EBUSY)
pr_warn("Slot %llu already registered by another " pr_warn("Slot %llu already registered by another hotplug driver\n", sun);
"hotplug driver\n", sun);
else else
pr_warn("acpiphp_register_hotplug_slot failed " pr_warn("acpiphp_register_hotplug_slot failed (err code = 0x%x)\n", retval);
"(err code = 0x%x)\n", retval);
} }
/* Even if the slot registration fails, we can still use it. */ /* Even if the slot registration fails, we can still use it. */
} }
......
...@@ -706,8 +706,7 @@ static int ctrl_slot_setup(struct controller *ctrl, ...@@ -706,8 +706,7 @@ static int ctrl_slot_setup(struct controller *ctrl,
hotplug_slot_info->adapter_status = hotplug_slot_info->adapter_status =
get_presence_status(ctrl, slot); get_presence_status(ctrl, slot);
dbg("registering bus %d, dev %d, number %d, " dbg("registering bus %d, dev %d, number %d, ctrl->slot_device_offset %d, slot %d\n",
"ctrl->slot_device_offset %d, slot %d\n",
slot->bus, slot->device, slot->bus, slot->device,
slot->number, ctrl->slot_device_offset, slot->number, ctrl->slot_device_offset,
slot_number); slot_number);
...@@ -837,8 +836,7 @@ static int cpqhpc_probe(struct pci_dev *pdev, const struct pci_device_id *ent) ...@@ -837,8 +836,7 @@ static int cpqhpc_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
bus = pdev->subordinate; bus = pdev->subordinate;
if (!bus) { if (!bus) {
dev_notice(&pdev->dev, "the device is not a bridge, " dev_notice(&pdev->dev, "the device is not a bridge, skipping\n");
"skipping\n");
rc = -ENODEV; rc = -ENODEV;
goto err_disable_device; goto err_disable_device;
} }
......
...@@ -1045,8 +1045,7 @@ static int enable_slot(struct hotplug_slot *hs) ...@@ -1045,8 +1045,7 @@ static int enable_slot(struct hotplug_slot *hs)
rc = check_limitations(slot_cur); rc = check_limitations(slot_cur);
if (rc) { if (rc) {
err("Adding this card exceeds the limitations of this bus.\n"); err("Adding this card exceeds the limitations of this bus.\n");
err("(i.e., >1 133MHz cards running on same bus, or " err("(i.e., >1 133MHz cards running on same bus, or >2 66 PCI cards running on same bus.\n");
">2 66 PCI cards running on same bus.\n");
err("Try hot-adding into another bus\n"); err("Try hot-adding into another bus\n");
rc = -EINVAL; rc = -EINVAL;
goto error_nopower; goto error_nopower;
...@@ -1070,12 +1069,10 @@ static int enable_slot(struct hotplug_slot *hs) ...@@ -1070,12 +1069,10 @@ static int enable_slot(struct hotplug_slot *hs)
!(SLOT_PWRGD(slot_cur->status))) !(SLOT_PWRGD(slot_cur->status)))
err("power fault occurred trying to power up\n"); err("power fault occurred trying to power up\n");
else if (SLOT_BUS_SPEED(slot_cur->status)) { else if (SLOT_BUS_SPEED(slot_cur->status)) {
err("bus speed mismatch occurred. please check " err("bus speed mismatch occurred. please check current bus speed and card capability\n");
"current bus speed and card capability\n");
print_card_capability(slot_cur); print_card_capability(slot_cur);
} else if (SLOT_BUS_MODE(slot_cur->ext_status)) { } else if (SLOT_BUS_MODE(slot_cur->ext_status)) {
err("bus mode mismatch occurred. please check " err("bus mode mismatch occurred. please check current bus mode and card capability\n");
"current bus mode and card capability\n");
print_card_capability(slot_cur); print_card_capability(slot_cur);
} }
ibmphp_update_slot_info(slot_cur); ibmphp_update_slot_info(slot_cur);
...@@ -1098,8 +1095,7 @@ static int enable_slot(struct hotplug_slot *hs) ...@@ -1098,8 +1095,7 @@ static int enable_slot(struct hotplug_slot *hs)
goto error_power; goto error_power;
} }
if (SLOT_POWER(slot_cur->status) && (SLOT_BUS_SPEED(slot_cur->status))) { if (SLOT_POWER(slot_cur->status) && (SLOT_BUS_SPEED(slot_cur->status))) {
err("bus speed mismatch occurred. please check current bus " err("bus speed mismatch occurred. please check current bus speed and card capability\n");
"speed and card capability\n");
print_card_capability(slot_cur); print_card_capability(slot_cur);
goto error_power; goto error_power;
} }
......
...@@ -137,8 +137,8 @@ int ibmphp_configure_card (struct pci_func *func, u8 slotno) ...@@ -137,8 +137,8 @@ int ibmphp_configure_card (struct pci_func *func, u8 slotno)
"Please choose another device.\n", cur_func->device); "Please choose another device.\n", cur_func->device);
return -ENODEV; return -ENODEV;
} else if (class == PCI_CLASS_DISPLAY_VGA) { } else if (class == PCI_CLASS_DISPLAY_VGA) {
err ("The device %x is not supported for hot plugging. " err ("The device %x is not supported for hot plugging. Please choose another device.\n",
"Please choose another device.\n", cur_func->device); cur_func->device);
return -ENODEV; return -ENODEV;
} }
switch (hdr_type) { switch (hdr_type) {
...@@ -179,8 +179,8 @@ int ibmphp_configure_card (struct pci_func *func, u8 slotno) ...@@ -179,8 +179,8 @@ int ibmphp_configure_card (struct pci_func *func, u8 slotno)
case PCI_HEADER_TYPE_MULTIBRIDGE: case PCI_HEADER_TYPE_MULTIBRIDGE:
class >>= 8; class >>= 8;
if (class != PCI_CLASS_BRIDGE_PCI) { if (class != PCI_CLASS_BRIDGE_PCI) {
err ("This %x is not PCI-to-PCI bridge, and as is not supported for hot-plugging. " err ("This %x is not PCI-to-PCI bridge, and as is not supported for hot-plugging. Please insert another card.\n",
"Please insert another card.\n", cur_func->device); cur_func->device);
return -ENODEV; return -ENODEV;
} }
assign_alt_irq (cur_func, class_code); assign_alt_irq (cur_func, class_code);
...@@ -247,8 +247,8 @@ int ibmphp_configure_card (struct pci_func *func, u8 slotno) ...@@ -247,8 +247,8 @@ int ibmphp_configure_card (struct pci_func *func, u8 slotno)
class >>= 8; class >>= 8;
debug ("class now is %x\n", class); debug ("class now is %x\n", class);
if (class != PCI_CLASS_BRIDGE_PCI) { if (class != PCI_CLASS_BRIDGE_PCI) {
err ("This %x is not PCI-to-PCI bridge, and as is not supported for hot-plugging. " err ("This %x is not PCI-to-PCI bridge, and as is not supported for hot-plugging. Please insert another card.\n",
"Please insert another card.\n", cur_func->device); cur_func->device);
return -ENODEV; return -ENODEV;
} }
...@@ -1125,13 +1125,11 @@ static struct res_needed *scan_behind_bridge (struct pci_func *func, u8 busno) ...@@ -1125,13 +1125,11 @@ static struct res_needed *scan_behind_bridge (struct pci_func *func, u8 busno)
class >>= 8; /* to take revision out, class = class.subclass.prog i/f */ class >>= 8; /* to take revision out, class = class.subclass.prog i/f */
if (class == PCI_CLASS_NOT_DEFINED_VGA) { if (class == PCI_CLASS_NOT_DEFINED_VGA) {
err ("The device %x is VGA compatible and as is not supported for hot plugging. " err ("The device %x is VGA compatible and as is not supported for hot plugging. Please choose another device.\n", device);
"Please choose another device.\n", device);
amount->not_correct = 1; amount->not_correct = 1;
return amount; return amount;
} else if (class == PCI_CLASS_DISPLAY_VGA) { } else if (class == PCI_CLASS_DISPLAY_VGA) {
err ("The device %x is not supported for hot plugging. " err ("The device %x is not supported for hot plugging. Please choose another device.\n", device);
"Please choose another device.\n", device);
amount->not_correct = 1; amount->not_correct = 1;
return amount; return amount;
} }
...@@ -1483,12 +1481,10 @@ static int unconfigure_boot_card (struct slot *slot_cur) ...@@ -1483,12 +1481,10 @@ static int unconfigure_boot_card (struct slot *slot_cur)
debug ("hdr_type %x, class %x\n", hdr_type, class); debug ("hdr_type %x, class %x\n", hdr_type, class);
class >>= 8; /* to take revision out, class = class.subclass.prog i/f */ class >>= 8; /* to take revision out, class = class.subclass.prog i/f */
if (class == PCI_CLASS_NOT_DEFINED_VGA) { if (class == PCI_CLASS_NOT_DEFINED_VGA) {
err ("The device %x function %x is VGA compatible and is not supported for hot removing. " err ("The device %x function %x is VGA compatible and is not supported for hot removing. Please choose another device.\n", device, function);
"Please choose another device.\n", device, function);
return -ENODEV; return -ENODEV;
} else if (class == PCI_CLASS_DISPLAY_VGA) { } else if (class == PCI_CLASS_DISPLAY_VGA) {
err ("The device %x function %x is not supported for hot removing. " err ("The device %x function %x is not supported for hot removing. Please choose another device.\n", device, function);
"Please choose another device.\n", device, function);
return -ENODEV; return -ENODEV;
} }
...@@ -1513,9 +1509,7 @@ static int unconfigure_boot_card (struct slot *slot_cur) ...@@ -1513,9 +1509,7 @@ static int unconfigure_boot_card (struct slot *slot_cur)
case PCI_HEADER_TYPE_BRIDGE: case PCI_HEADER_TYPE_BRIDGE:
class >>= 8; class >>= 8;
if (class != PCI_CLASS_BRIDGE_PCI) { if (class != PCI_CLASS_BRIDGE_PCI) {
err ("This device %x function %x is not PCI-to-PCI bridge, " err ("This device %x function %x is not PCI-to-PCI bridge, and is not supported for hot-removing. Please try another card.\n", device, function);
"and is not supported for hot-removing. "
"Please try another card.\n", device, function);
return -ENODEV; return -ENODEV;
} }
rc = unconfigure_boot_bridge (busno, device, function); rc = unconfigure_boot_bridge (busno, device, function);
...@@ -1529,9 +1523,7 @@ static int unconfigure_boot_card (struct slot *slot_cur) ...@@ -1529,9 +1523,7 @@ static int unconfigure_boot_card (struct slot *slot_cur)
case PCI_HEADER_TYPE_MULTIBRIDGE: case PCI_HEADER_TYPE_MULTIBRIDGE:
class >>= 8; class >>= 8;
if (class != PCI_CLASS_BRIDGE_PCI) { if (class != PCI_CLASS_BRIDGE_PCI) {
err ("This device %x function %x is not PCI-to-PCI bridge, " err ("This device %x function %x is not PCI-to-PCI bridge, and is not supported for hot-removing. Please try another card.\n", device, function);
"and is not supported for hot-removing. "
"Please try another card.\n", device, function);
return -ENODEV; return -ENODEV;
} }
rc = unconfigure_boot_bridge (busno, device, function); rc = unconfigure_boot_bridge (busno, device, function);
......
...@@ -789,8 +789,7 @@ int ibmphp_remove_resource (struct resource_node *res) ...@@ -789,8 +789,7 @@ int ibmphp_remove_resource (struct resource_node *res)
bus_cur = find_bus_wprev (res->busno, NULL, 0); bus_cur = find_bus_wprev (res->busno, NULL, 0);
if (!bus_cur) { if (!bus_cur) {
err ("cannot find corresponding bus of the io resource to remove " err ("cannot find corresponding bus of the io resource to remove bailing out...\n");
"bailing out...\n");
return -ENODEV; return -ENODEV;
} }
......
...@@ -432,8 +432,7 @@ int __pci_hp_register(struct hotplug_slot *slot, struct pci_bus *bus, ...@@ -432,8 +432,7 @@ int __pci_hp_register(struct hotplug_slot *slot, struct pci_bus *bus,
if ((slot->info == NULL) || (slot->ops == NULL)) if ((slot->info == NULL) || (slot->ops == NULL))
return -EINVAL; return -EINVAL;
if (slot->release == NULL) { if (slot->release == NULL) {
dbg("Why are you trying to register a hotplug slot " dbg("Why are you trying to register a hotplug slot without a proper release function?\n");
"without a proper release function?\n");
return -EINVAL; return -EINVAL;
} }
......
...@@ -266,8 +266,7 @@ static int pciehp_probe(struct pcie_device *dev) ...@@ -266,8 +266,7 @@ static int pciehp_probe(struct pcie_device *dev)
rc = init_slot(ctrl); rc = init_slot(ctrl);
if (rc) { if (rc) {
if (rc == -EBUSY) if (rc == -EBUSY)
ctrl_warn(ctrl, "Slot already registered by another " ctrl_warn(ctrl, "Slot already registered by another hotplug driver\n");
"hotplug driver\n");
else else
ctrl_err(ctrl, "Slot initialization failed\n"); ctrl_err(ctrl, "Slot initialization failed\n");
goto err_out_release_ctlr; goto err_out_release_ctlr;
......
...@@ -376,14 +376,12 @@ static void handle_button_press_event(struct slot *p_slot) ...@@ -376,14 +376,12 @@ static void handle_button_press_event(struct slot *p_slot)
pciehp_get_power_status(p_slot, &getstatus); pciehp_get_power_status(p_slot, &getstatus);
if (getstatus) { if (getstatus) {
p_slot->state = BLINKINGOFF_STATE; p_slot->state = BLINKINGOFF_STATE;
ctrl_info(ctrl, ctrl_info(ctrl, "PCI slot #%s - powering off due to button press\n",
"PCI slot #%s - powering off due to button " slot_name(p_slot));
"press.\n", slot_name(p_slot));
} else { } else {
p_slot->state = BLINKINGON_STATE; p_slot->state = BLINKINGON_STATE;
ctrl_info(ctrl, ctrl_info(ctrl, "PCI slot #%s - powering on due to button press\n",
"PCI slot #%s - powering on due to button " slot_name(p_slot));
"press.\n", slot_name(p_slot));
} }
/* blink green LED and turn off amber */ /* blink green LED and turn off amber */
pciehp_green_led_blink(p_slot); pciehp_green_led_blink(p_slot);
...@@ -404,8 +402,8 @@ static void handle_button_press_event(struct slot *p_slot) ...@@ -404,8 +402,8 @@ static void handle_button_press_event(struct slot *p_slot)
else else
pciehp_green_led_off(p_slot); pciehp_green_led_off(p_slot);
pciehp_set_attention_status(p_slot, 0); pciehp_set_attention_status(p_slot, 0);
ctrl_info(ctrl, "PCI slot #%s - action canceled " ctrl_info(ctrl, "PCI slot #%s - action canceled due to button press\n",
"due to button press\n", slot_name(p_slot)); slot_name(p_slot));
p_slot->state = STATIC_STATE; p_slot->state = STATIC_STATE;
break; break;
case POWEROFF_STATE: case POWEROFF_STATE:
......
...@@ -174,12 +174,10 @@ static void pcie_write_cmd(struct controller *ctrl, u16 cmd, u16 mask) ...@@ -174,12 +174,10 @@ static void pcie_write_cmd(struct controller *ctrl, u16 cmd, u16 mask)
* event even though it supports none of power * event even though it supports none of power
* controller, attention led, power led and EMI. * controller, attention led, power led and EMI.
*/ */
ctrl_dbg(ctrl, "Unexpected CMD_COMPLETED. Need to " ctrl_dbg(ctrl, "Unexpected CMD_COMPLETED. Need to wait for command completed event\n");
"wait for command completed event.\n");
ctrl->no_cmd_complete = 0; ctrl->no_cmd_complete = 0;
} else { } else {
ctrl_dbg(ctrl, "Unexpected CMD_COMPLETED. Maybe " ctrl_dbg(ctrl, "Unexpected CMD_COMPLETED. Maybe the controller is broken\n");
"the controller is broken.\n");
} }
} }
......
...@@ -46,9 +46,8 @@ int pciehp_configure_device(struct slot *p_slot) ...@@ -46,9 +46,8 @@ int pciehp_configure_device(struct slot *p_slot)
dev = pci_get_slot(parent, PCI_DEVFN(0, 0)); dev = pci_get_slot(parent, PCI_DEVFN(0, 0));
if (dev) { if (dev) {
ctrl_err(ctrl, "Device %s already exists " ctrl_err(ctrl, "Device %s already exists at %04x:%02x:00, cannot hot-add\n",
"at %04x:%02x:00, cannot hot-add\n", pci_name(dev), pci_name(dev), pci_domain_nr(parent), parent->number);
pci_domain_nr(parent), parent->number);
pci_dev_put(dev); pci_dev_put(dev);
ret = -EEXIST; ret = -EEXIST;
goto out; goto out;
......
...@@ -250,15 +250,13 @@ static int sn_slot_enable(struct hotplug_slot *bss_hotplug_slot, ...@@ -250,15 +250,13 @@ static int sn_slot_enable(struct hotplug_slot *bss_hotplug_slot,
} }
if (rc == PCI_L1_ERR) { if (rc == PCI_L1_ERR) {
dev_dbg(&slot->pci_bus->self->dev, dev_dbg(&slot->pci_bus->self->dev, "L1 failure %d with message: %s",
"L1 failure %d with message: %s",
resp.resp_sub_errno, resp.resp_l1_msg); resp.resp_sub_errno, resp.resp_l1_msg);
return -EPERM; return -EPERM;
} }
if (rc) { if (rc) {
dev_dbg(&slot->pci_bus->self->dev, dev_dbg(&slot->pci_bus->self->dev, "insert failed with error %d sub-error %d\n",
"insert failed with error %d sub-error %d\n",
rc, resp.resp_sub_errno); rc, resp.resp_sub_errno);
return -EIO; return -EIO;
} }
...@@ -288,21 +286,18 @@ static int sn_slot_disable(struct hotplug_slot *bss_hotplug_slot, ...@@ -288,21 +286,18 @@ static int sn_slot_disable(struct hotplug_slot *bss_hotplug_slot,
} }
if ((action == PCI_REQ_SLOT_ELIGIBLE) && (rc == PCI_EMPTY_33MHZ)) { if ((action == PCI_REQ_SLOT_ELIGIBLE) && (rc == PCI_EMPTY_33MHZ)) {
dev_dbg(&slot->pci_bus->self->dev, dev_dbg(&slot->pci_bus->self->dev, "Cannot remove last 33MHz card\n");
"Cannot remove last 33MHz card\n");
return -EPERM; return -EPERM;
} }
if ((action == PCI_REQ_SLOT_ELIGIBLE) && (rc == PCI_L1_ERR)) { if ((action == PCI_REQ_SLOT_ELIGIBLE) && (rc == PCI_L1_ERR)) {
dev_dbg(&slot->pci_bus->self->dev, dev_dbg(&slot->pci_bus->self->dev, "L1 failure %d with message \n%s\n",
"L1 failure %d with message \n%s\n",
resp.resp_sub_errno, resp.resp_l1_msg); resp.resp_sub_errno, resp.resp_l1_msg);
return -EPERM; return -EPERM;
} }
if ((action == PCI_REQ_SLOT_ELIGIBLE) && rc) { if ((action == PCI_REQ_SLOT_ELIGIBLE) && rc) {
dev_dbg(&slot->pci_bus->self->dev, dev_dbg(&slot->pci_bus->self->dev, "remove failed with error %d sub-error %d\n",
"remove failed with error %d sub-error %d\n",
rc, resp.resp_sub_errno); rc, resp.resp_sub_errno);
return -EIO; return -EIO;
} }
...@@ -417,8 +412,7 @@ static int enable_slot(struct hotplug_slot *bss_hotplug_slot) ...@@ -417,8 +412,7 @@ static int enable_slot(struct hotplug_slot *bss_hotplug_slot)
phandle = acpi_device_handle(PCI_CONTROLLER(slot->pci_bus)->companion); phandle = acpi_device_handle(PCI_CONTROLLER(slot->pci_bus)->companion);
if (acpi_bus_get_device(phandle, &pdevice)) { if (acpi_bus_get_device(phandle, &pdevice)) {
dev_dbg(&slot->pci_bus->self->dev, dev_dbg(&slot->pci_bus->self->dev, "no parent device, assuming NULL\n");
"no parent device, assuming NULL\n");
pdevice = NULL; pdevice = NULL;
} }
...@@ -447,10 +441,8 @@ static int enable_slot(struct hotplug_slot *bss_hotplug_slot) ...@@ -447,10 +441,8 @@ static int enable_slot(struct hotplug_slot *bss_hotplug_slot)
ret = acpi_bus_scan(chandle); ret = acpi_bus_scan(chandle);
if (ACPI_FAILURE(ret)) { if (ACPI_FAILURE(ret)) {
printk(KERN_ERR "%s: acpi_bus_scan " printk(KERN_ERR "%s: acpi_bus_scan failed (0x%x) for slot %d func %d\n",
"failed (0x%x) for slot %d " __func__, ret, (int)(adr>>16),
"func %d\n", __func__,
ret, (int)(adr>>16),
(int)(adr&0xffff)); (int)(adr&0xffff));
/* try to continue on */ /* try to continue on */
} }
...@@ -471,11 +463,9 @@ static int enable_slot(struct hotplug_slot *bss_hotplug_slot) ...@@ -471,11 +463,9 @@ static int enable_slot(struct hotplug_slot *bss_hotplug_slot)
mutex_unlock(&sn_hotplug_mutex); mutex_unlock(&sn_hotplug_mutex);
if (rc == 0) if (rc == 0)
dev_dbg(&slot->pci_bus->self->dev, dev_dbg(&slot->pci_bus->self->dev, "insert operation successful\n");
"insert operation successful\n");
else else
dev_dbg(&slot->pci_bus->self->dev, dev_dbg(&slot->pci_bus->self->dev, "insert operation failed rc = %d\n", rc);
"insert operation failed rc = %d\n", rc);
return rc; return rc;
} }
...@@ -561,8 +551,7 @@ static int disable_slot(struct hotplug_slot *bss_hotplug_slot) ...@@ -561,8 +551,7 @@ static int disable_slot(struct hotplug_slot *bss_hotplug_slot)
acpi_status ret; acpi_status ret;
ret = acpi_unload_table_id(ssdt_id); ret = acpi_unload_table_id(ssdt_id);
if (ACPI_FAILURE(ret)) { if (ACPI_FAILURE(ret)) {
printk(KERN_ERR "%s: acpi_unload_table_id " printk(KERN_ERR "%s: acpi_unload_table_id failed (0x%x) for id %d\n",
"failed (0x%x) for id %d\n",
__func__, ret, ssdt_id); __func__, ret, ssdt_id);
/* try to continue on */ /* try to continue on */
} }
......
...@@ -143,8 +143,7 @@ static int init_slots(struct controller *ctrl) ...@@ -143,8 +143,7 @@ static int init_slots(struct controller *ctrl)
snprintf(name, SLOT_NAME_SIZE, "%d", slot->number); snprintf(name, SLOT_NAME_SIZE, "%d", slot->number);
hotplug_slot->ops = &shpchp_hotplug_slot_ops; hotplug_slot->ops = &shpchp_hotplug_slot_ops;
ctrl_dbg(ctrl, "Registering domain:bus:dev=%04x:%02x:%02x " ctrl_dbg(ctrl, "Registering domain:bus:dev=%04x:%02x:%02x hp_slot=%x sun=%x slot_device_offset=%x\n",
"hp_slot=%x sun=%x slot_device_offset=%x\n",
pci_domain_nr(ctrl->pci_dev->subordinate), pci_domain_nr(ctrl->pci_dev->subordinate),
slot->bus, slot->device, slot->hp_slot, slot->number, slot->bus, slot->device, slot->hp_slot, slot->number,
ctrl->slot_device_offset); ctrl->slot_device_offset);
......
...@@ -196,8 +196,8 @@ static int change_bus_speed(struct controller *ctrl, struct slot *p_slot, ...@@ -196,8 +196,8 @@ static int change_bus_speed(struct controller *ctrl, struct slot *p_slot,
ctrl_dbg(ctrl, "Change speed to %d\n", speed); ctrl_dbg(ctrl, "Change speed to %d\n", speed);
if ((rc = p_slot->hpc_ops->set_bus_speed_mode(p_slot, speed))) { if ((rc = p_slot->hpc_ops->set_bus_speed_mode(p_slot, speed))) {
ctrl_err(ctrl, "%s: Issue of set bus speed mode command " ctrl_err(ctrl, "%s: Issue of set bus speed mode command failed\n",
"failed\n", __func__); __func__);
return WRONG_BUS_FREQUENCY; return WRONG_BUS_FREQUENCY;
} }
return rc; return rc;
...@@ -215,8 +215,8 @@ static int fix_bus_speed(struct controller *ctrl, struct slot *pslot, ...@@ -215,8 +215,8 @@ static int fix_bus_speed(struct controller *ctrl, struct slot *pslot,
*/ */
if (flag) { if (flag) {
if (asp < bsp) { if (asp < bsp) {
ctrl_err(ctrl, "Speed of bus %x and adapter %x " ctrl_err(ctrl, "Speed of bus %x and adapter %x mismatch\n",
"mismatch\n", bsp, asp); bsp, asp);
rc = WRONG_BUS_FREQUENCY; rc = WRONG_BUS_FREQUENCY;
} }
return rc; return rc;
...@@ -250,8 +250,7 @@ static int board_added(struct slot *p_slot) ...@@ -250,8 +250,7 @@ static int board_added(struct slot *p_slot)
hp_slot = p_slot->device - ctrl->slot_device_offset; hp_slot = p_slot->device - ctrl->slot_device_offset;
ctrl_dbg(ctrl, ctrl_dbg(ctrl, "%s: p_slot->device, slot_offset, hp_slot = %d, %d ,%d\n",
"%s: p_slot->device, slot_offset, hp_slot = %d, %d ,%d\n",
__func__, p_slot->device, ctrl->slot_device_offset, hp_slot); __func__, p_slot->device, ctrl->slot_device_offset, hp_slot);
/* Power on slot without connecting to bus */ /* Power on slot without connecting to bus */
...@@ -263,8 +262,8 @@ static int board_added(struct slot *p_slot) ...@@ -263,8 +262,8 @@ static int board_added(struct slot *p_slot)
if ((ctrl->pci_dev->vendor == 0x8086) && (ctrl->pci_dev->device == 0x0332)) { if ((ctrl->pci_dev->vendor == 0x8086) && (ctrl->pci_dev->device == 0x0332)) {
if ((rc = p_slot->hpc_ops->set_bus_speed_mode(p_slot, PCI_SPEED_33MHz))) { if ((rc = p_slot->hpc_ops->set_bus_speed_mode(p_slot, PCI_SPEED_33MHz))) {
ctrl_err(ctrl, "%s: Issue of set bus speed mode command" ctrl_err(ctrl, "%s: Issue of set bus speed mode command failed\n",
" failed\n", __func__); __func__);
return WRONG_BUS_FREQUENCY; return WRONG_BUS_FREQUENCY;
} }
...@@ -277,8 +276,7 @@ static int board_added(struct slot *p_slot) ...@@ -277,8 +276,7 @@ static int board_added(struct slot *p_slot)
rc = p_slot->hpc_ops->get_adapter_speed(p_slot, &asp); rc = p_slot->hpc_ops->get_adapter_speed(p_slot, &asp);
if (rc) { if (rc) {
ctrl_err(ctrl, "Can't get adapter speed or " ctrl_err(ctrl, "Can't get adapter speed or bus mode mismatch\n");
"bus mode mismatch\n");
return WRONG_BUS_FREQUENCY; return WRONG_BUS_FREQUENCY;
} }
...@@ -289,8 +287,8 @@ static int board_added(struct slot *p_slot) ...@@ -289,8 +287,8 @@ static int board_added(struct slot *p_slot)
if (!list_empty(&ctrl->pci_dev->subordinate->devices)) if (!list_empty(&ctrl->pci_dev->subordinate->devices))
slots_not_empty = 1; slots_not_empty = 1;
ctrl_dbg(ctrl, "%s: slots_not_empty %d, adapter_speed %d, bus_speed %d," ctrl_dbg(ctrl, "%s: slots_not_empty %d, adapter_speed %d, bus_speed %d, max_bus_speed %d\n",
" max_bus_speed %d\n", __func__, slots_not_empty, asp, __func__, slots_not_empty, asp,
bsp, msp); bsp, msp);
rc = fix_bus_speed(ctrl, p_slot, slots_not_empty, asp, bsp, msp); rc = fix_bus_speed(ctrl, p_slot, slots_not_empty, asp, bsp, msp);
...@@ -490,12 +488,12 @@ static void handle_button_press_event(struct slot *p_slot) ...@@ -490,12 +488,12 @@ static void handle_button_press_event(struct slot *p_slot)
p_slot->hpc_ops->get_power_status(p_slot, &getstatus); p_slot->hpc_ops->get_power_status(p_slot, &getstatus);
if (getstatus) { if (getstatus) {
p_slot->state = BLINKINGOFF_STATE; p_slot->state = BLINKINGOFF_STATE;
ctrl_info(ctrl, "PCI slot #%s - powering off due to " ctrl_info(ctrl, "PCI slot #%s - powering off due to button press\n",
"button press.\n", slot_name(p_slot)); slot_name(p_slot));
} else { } else {
p_slot->state = BLINKINGON_STATE; p_slot->state = BLINKINGON_STATE;
ctrl_info(ctrl, "PCI slot #%s - powering on due to " ctrl_info(ctrl, "PCI slot #%s - powering on due to button press\n",
"button press.\n", slot_name(p_slot)); slot_name(p_slot));
} }
/* blink green LED and turn off amber */ /* blink green LED and turn off amber */
p_slot->hpc_ops->green_led_blink(p_slot); p_slot->hpc_ops->green_led_blink(p_slot);
...@@ -518,8 +516,8 @@ static void handle_button_press_event(struct slot *p_slot) ...@@ -518,8 +516,8 @@ static void handle_button_press_event(struct slot *p_slot)
else else
p_slot->hpc_ops->green_led_off(p_slot); p_slot->hpc_ops->green_led_off(p_slot);
p_slot->hpc_ops->set_attention_status(p_slot, 0); p_slot->hpc_ops->set_attention_status(p_slot, 0);
ctrl_info(ctrl, "PCI slot #%s - action canceled due to " ctrl_info(ctrl, "PCI slot #%s - action canceled due to button press\n",
"button press\n", slot_name(p_slot)); slot_name(p_slot));
p_slot->state = STATIC_STATE; p_slot->state = STATIC_STATE;
break; break;
case POWEROFF_STATE: case POWEROFF_STATE:
......
...@@ -341,8 +341,7 @@ static int shpc_write_cmd(struct slot *slot, u8 t_slot, u8 cmd) ...@@ -341,8 +341,7 @@ static int shpc_write_cmd(struct slot *slot, u8 t_slot, u8 cmd)
cmd_status = hpc_check_cmd_status(slot->ctrl); cmd_status = hpc_check_cmd_status(slot->ctrl);
if (cmd_status) { if (cmd_status) {
ctrl_err(ctrl, ctrl_err(ctrl, "Failed to issued command 0x%x (error code = %d)\n",
"Failed to issued command 0x%x (error code = %d)\n",
cmd, cmd_status); cmd, cmd_status);
retval = -EIO; retval = -EIO;
} }
...@@ -974,8 +973,8 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) ...@@ -974,8 +973,8 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev)
for (i = 0; i < 9 + num_slots; i++) { for (i = 0; i < 9 + num_slots; i++) {
rc = shpc_indirect_read(ctrl, i, &tempdword); rc = shpc_indirect_read(ctrl, i, &tempdword);
if (rc) { if (rc) {
ctrl_err(ctrl, ctrl_err(ctrl, "Cannot read creg (index = %d)\n",
"Cannot read creg (index = %d)\n", i); i);
goto abort; goto abort;
} }
ctrl_dbg(ctrl, " offset %d: value %x\n", i, tempdword); ctrl_dbg(ctrl, " offset %d: value %x\n", i, tempdword);
...@@ -1060,10 +1059,8 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) ...@@ -1060,10 +1059,8 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev)
/* Installs the interrupt handler */ /* Installs the interrupt handler */
rc = pci_enable_msi(pdev); rc = pci_enable_msi(pdev);
if (rc) { if (rc) {
ctrl_info(ctrl, ctrl_info(ctrl, "Can't get msi for the hotplug controller\n");
"Can't get msi for the hotplug controller\n"); ctrl_info(ctrl, "Use INTx for the hotplug controller\n");
ctrl_info(ctrl,
"Use INTx for the hotplug controller\n");
} }
rc = request_irq(ctrl->pci_dev->irq, shpc_isr, IRQF_SHARED, rc = request_irq(ctrl->pci_dev->irq, shpc_isr, IRQF_SHARED,
...@@ -1071,8 +1068,8 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) ...@@ -1071,8 +1068,8 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev)
ctrl_dbg(ctrl, "request_irq %d (returns %d)\n", ctrl_dbg(ctrl, "request_irq %d (returns %d)\n",
ctrl->pci_dev->irq, rc); ctrl->pci_dev->irq, rc);
if (rc) { if (rc) {
ctrl_err(ctrl, "Can't get irq %d for the hotplug " ctrl_err(ctrl, "Can't get irq %d for the hotplug controller\n",
"controller\n", ctrl->pci_dev->irq); ctrl->pci_dev->irq);
goto abort_iounmap; goto abort_iounmap;
} }
} }
......
...@@ -46,9 +46,9 @@ int shpchp_configure_device(struct slot *p_slot) ...@@ -46,9 +46,9 @@ int shpchp_configure_device(struct slot *p_slot)
dev = pci_get_slot(parent, PCI_DEVFN(p_slot->device, 0)); dev = pci_get_slot(parent, PCI_DEVFN(p_slot->device, 0));
if (dev) { if (dev) {
ctrl_err(ctrl, "Device %s already exists " ctrl_err(ctrl, "Device %s already exists at %04x:%02x:%02x, cannot hot-add\n",
"at %04x:%02x:%02x, cannot hot-add\n", pci_name(dev), pci_name(dev), pci_domain_nr(parent),
pci_domain_nr(parent), p_slot->bus, p_slot->device); p_slot->bus, p_slot->device);
pci_dev_put(dev); pci_dev_put(dev);
ret = -EINVAL; ret = -EINVAL;
goto out; goto out;
......
...@@ -980,8 +980,7 @@ int pci_enable_msix(struct pci_dev *dev, struct msix_entry *entries, int nvec) ...@@ -980,8 +980,7 @@ int pci_enable_msix(struct pci_dev *dev, struct msix_entry *entries, int nvec)
/* Check whether driver already requested for MSI irq */ /* Check whether driver already requested for MSI irq */
if (dev->msi_enabled) { if (dev->msi_enabled) {
dev_info(&dev->dev, "can't enable MSI-X " dev_info(&dev->dev, "can't enable MSI-X (MSI IRQ already assigned)\n");
"(MSI IRQ already assigned)\n");
return -EINVAL; return -EINVAL;
} }
status = msix_capability_init(dev, entries, nvec); status = msix_capability_init(dev, entries, nvec);
......
...@@ -286,8 +286,8 @@ static ssize_t msi_bus_store(struct device *dev, struct device_attribute *attr, ...@@ -286,8 +286,8 @@ static ssize_t msi_bus_store(struct device *dev, struct device_attribute *attr,
!!val) { !!val) {
pdev->subordinate->bus_flags ^= PCI_BUS_FLAGS_NO_MSI; pdev->subordinate->bus_flags ^= PCI_BUS_FLAGS_NO_MSI;
dev_warn(&pdev->dev, "forced subordinate bus to%s support MSI," dev_warn(&pdev->dev, "forced subordinate bus to%s support MSI, bad things could happen\n",
" bad things could happen\n", val ? "" : " not"); val ? "" : " not");
} }
return count; return count;
...@@ -945,8 +945,7 @@ void pci_create_legacy_files(struct pci_bus *b) ...@@ -945,8 +945,7 @@ void pci_create_legacy_files(struct pci_bus *b)
kfree(b->legacy_io); kfree(b->legacy_io);
b->legacy_io = NULL; b->legacy_io = NULL;
kzalloc_err: kzalloc_err:
printk(KERN_WARNING "pci: warning: could not create legacy I/O port " printk(KERN_WARNING "pci: warning: could not create legacy I/O port and ISA memory resources to sysfs\n");
"and ISA memory resources to sysfs\n");
return; return;
} }
...@@ -1006,8 +1005,7 @@ static int pci_mmap_resource(struct kobject *kobj, struct bin_attribute *attr, ...@@ -1006,8 +1005,7 @@ static int pci_mmap_resource(struct kobject *kobj, struct bin_attribute *attr,
return -ENODEV; return -ENODEV;
if (!pci_mmap_fits(pdev, i, vma, PCI_MMAP_SYSFS)) { if (!pci_mmap_fits(pdev, i, vma, PCI_MMAP_SYSFS)) {
WARN(1, "process \"%s\" tried to map 0x%08lx bytes " WARN(1, "process \"%s\" tried to map 0x%08lx bytes at page 0x%08lx on %s BAR %d (start 0x%16Lx, size 0x%16Lx)\n",
"at page 0x%08lx on %s BAR %d (start 0x%16Lx, size 0x%16Lx)\n",
current->comm, vma->vm_end-vma->vm_start, vma->vm_pgoff, current->comm, vma->vm_end-vma->vm_start, vma->vm_pgoff,
pci_name(pdev), i, pci_name(pdev), i,
(u64)pci_resource_start(pdev, i), (u64)pci_resource_start(pdev, i),
......
...@@ -555,8 +555,8 @@ static int pci_raw_set_power_state(struct pci_dev *dev, pci_power_t state) ...@@ -555,8 +555,8 @@ static int pci_raw_set_power_state(struct pci_dev *dev, pci_power_t state)
*/ */
if (state != PCI_D0 && dev->current_state <= PCI_D3cold if (state != PCI_D0 && dev->current_state <= PCI_D3cold
&& dev->current_state > state) { && dev->current_state > state) {
dev_err(&dev->dev, "invalid power transition " dev_err(&dev->dev, "invalid power transition (from state %d to %d)\n",
"(from state %d to %d)\n", dev->current_state, state); dev->current_state, state);
return -EINVAL; return -EINVAL;
} }
...@@ -603,8 +603,8 @@ static int pci_raw_set_power_state(struct pci_dev *dev, pci_power_t state) ...@@ -603,8 +603,8 @@ static int pci_raw_set_power_state(struct pci_dev *dev, pci_power_t state)
pci_read_config_word(dev, dev->pm_cap + PCI_PM_CTRL, &pmcsr); pci_read_config_word(dev, dev->pm_cap + PCI_PM_CTRL, &pmcsr);
dev->current_state = (pmcsr & PCI_PM_CTRL_STATE_MASK); dev->current_state = (pmcsr & PCI_PM_CTRL_STATE_MASK);
if (dev->current_state != state && printk_ratelimit()) if (dev->current_state != state && printk_ratelimit())
dev_info(&dev->dev, "Refused to change power state, " dev_info(&dev->dev, "Refused to change power state, currently in D%d\n",
"currently in D%d\n", dev->current_state); dev->current_state);
/* /*
* According to section 5.4.1 of the "PCI BUS POWER MANAGEMENT * According to section 5.4.1 of the "PCI BUS POWER MANAGEMENT
...@@ -1029,8 +1029,8 @@ static void pci_restore_config_dword(struct pci_dev *pdev, int offset, ...@@ -1029,8 +1029,8 @@ static void pci_restore_config_dword(struct pci_dev *pdev, int offset,
return; return;
for (;;) { for (;;) {
dev_dbg(&pdev->dev, "restoring config space at offset " dev_dbg(&pdev->dev, "restoring config space at offset %#x (was %#x, writing %#x)\n",
"%#x (was %#x, writing %#x)\n", offset, val, saved_val); offset, val, saved_val);
pci_write_config_dword(pdev, offset, saved_val); pci_write_config_dword(pdev, offset, saved_val);
if (retry-- <= 0) if (retry-- <= 0)
return; return;
...@@ -2815,8 +2815,8 @@ int pci_set_cacheline_size(struct pci_dev *dev) ...@@ -2815,8 +2815,8 @@ int pci_set_cacheline_size(struct pci_dev *dev)
if (cacheline_size == pci_cache_line_size) if (cacheline_size == pci_cache_line_size)
return 0; return 0;
dev_printk(KERN_DEBUG, &dev->dev, "cache line size of %d is not " dev_printk(KERN_DEBUG, &dev->dev, "cache line size of %d is not supported\n",
"supported\n", pci_cache_line_size << 2); pci_cache_line_size << 2);
return -EINVAL; return -EINVAL;
} }
...@@ -2952,8 +2952,8 @@ bool pci_intx_mask_supported(struct pci_dev *dev) ...@@ -2952,8 +2952,8 @@ bool pci_intx_mask_supported(struct pci_dev *dev)
* go ahead and check it. * go ahead and check it.
*/ */
if ((new ^ orig) & ~PCI_COMMAND_INTX_DISABLE) { if ((new ^ orig) & ~PCI_COMMAND_INTX_DISABLE) {
dev_err(&dev->dev, "Command register changed from " dev_err(&dev->dev, "Command register changed from 0x%x to 0x%x: driver or hardware bug?\n",
"0x%x to 0x%x: driver or hardware bug?\n", orig, new); orig, new);
} else if ((new ^ orig) & PCI_COMMAND_INTX_DISABLE) { } else if ((new ^ orig) & PCI_COMMAND_INTX_DISABLE) {
mask_supported = true; mask_supported = true;
pci_write_config_word(dev, PCI_COMMAND, orig); pci_write_config_word(dev, PCI_COMMAND, orig);
...@@ -3138,8 +3138,7 @@ static int pci_af_flr(struct pci_dev *dev, int probe) ...@@ -3138,8 +3138,7 @@ static int pci_af_flr(struct pci_dev *dev, int probe)
if (pci_wait_for_pending(dev, PCI_AF_STATUS, PCI_AF_STATUS_TP)) if (pci_wait_for_pending(dev, PCI_AF_STATUS, PCI_AF_STATUS_TP))
goto clear; goto clear;
dev_err(&dev->dev, "transaction is not cleared; " dev_err(&dev->dev, "transaction is not cleared; proceeding with reset anyway\n");
"proceeding with reset anyway\n");
clear: clear:
pci_write_config_byte(dev, pos + PCI_AF_CTRL, PCI_AF_CTRL_FLR); pci_write_config_byte(dev, pos + PCI_AF_CTRL, PCI_AF_CTRL_FLR);
......
...@@ -397,16 +397,14 @@ static int aer_inject(struct aer_error_inj *einj) ...@@ -397,16 +397,14 @@ static int aer_inject(struct aer_error_inj *einj)
if (!aer_mask_override && einj->cor_status && if (!aer_mask_override && einj->cor_status &&
!(einj->cor_status & ~cor_mask)) { !(einj->cor_status & ~cor_mask)) {
ret = -EINVAL; ret = -EINVAL;
printk(KERN_WARNING "The correctable error(s) is masked " printk(KERN_WARNING "The correctable error(s) is masked by device\n");
"by device\n");
spin_unlock_irqrestore(&inject_lock, flags); spin_unlock_irqrestore(&inject_lock, flags);
goto out_put; goto out_put;
} }
if (!aer_mask_override && einj->uncor_status && if (!aer_mask_override && einj->uncor_status &&
!(einj->uncor_status & ~uncor_mask)) { !(einj->uncor_status & ~uncor_mask)) {
ret = -EINVAL; ret = -EINVAL;
printk(KERN_WARNING "The uncorrectable error(s) is masked " printk(KERN_WARNING "The uncorrectable error(s) is masked by device\n");
"by device\n");
spin_unlock_irqrestore(&inject_lock, flags); spin_unlock_irqrestore(&inject_lock, flags);
goto out_put; goto out_put;
} }
......
...@@ -172,9 +172,7 @@ void aer_print_error(struct pci_dev *dev, struct aer_err_info *info) ...@@ -172,9 +172,7 @@ void aer_print_error(struct pci_dev *dev, struct aer_err_info *info)
int id = ((dev->bus->number << 8) | dev->devfn); int id = ((dev->bus->number << 8) | dev->devfn);
if (!info->status) { if (!info->status) {
dev_err(&dev->dev, dev_err(&dev->dev, "PCIe Bus Error: severity=%s, type=Unaccessible, id=%04x(Unregistered Agent ID)\n",
"PCIe Bus Error: severity=%s, type=Unaccessible, "
"id=%04x(Unregistered Agent ID)\n",
aer_error_severity_string[info->severity], id); aer_error_severity_string[info->severity], id);
goto out; goto out;
} }
...@@ -182,13 +180,11 @@ void aer_print_error(struct pci_dev *dev, struct aer_err_info *info) ...@@ -182,13 +180,11 @@ void aer_print_error(struct pci_dev *dev, struct aer_err_info *info)
layer = AER_GET_LAYER_ERROR(info->severity, info->status); layer = AER_GET_LAYER_ERROR(info->severity, info->status);
agent = AER_GET_AGENT(info->severity, info->status); agent = AER_GET_AGENT(info->severity, info->status);
dev_err(&dev->dev, dev_err(&dev->dev, "PCIe Bus Error: severity=%s, type=%s, id=%04x(%s)\n",
"PCIe Bus Error: severity=%s, type=%s, id=%04x(%s)\n",
aer_error_severity_string[info->severity], aer_error_severity_string[info->severity],
aer_error_layer[layer], id, aer_agent_string[agent]); aer_error_layer[layer], id, aer_agent_string[agent]);
dev_err(&dev->dev, dev_err(&dev->dev, " device [%04x:%04x] error status/mask=%08x/%08x\n",
" device [%04x:%04x] error status/mask=%08x/%08x\n",
dev->vendor, dev->device, dev->vendor, dev->device,
info->status, info->mask); info->status, info->mask);
......
...@@ -199,8 +199,7 @@ static void pcie_pme_handle_request(struct pci_dev *port, u16 req_id) ...@@ -199,8 +199,7 @@ static void pcie_pme_handle_request(struct pci_dev *port, u16 req_id)
* assuming that the PME was reported by a PCIe-PCI bridge that * assuming that the PME was reported by a PCIe-PCI bridge that
* used devfn different from zero. * used devfn different from zero.
*/ */
dev_dbg(&port->dev, "PME interrupt generated for " dev_dbg(&port->dev, "PME interrupt generated for non-existent device %02x:%02x.%d\n",
"non-existent device %02x:%02x.%d\n",
busnr, PCI_SLOT(devfn), PCI_FUNC(devfn)); busnr, PCI_SLOT(devfn), PCI_FUNC(devfn));
found = pcie_pme_from_pci_bridge(bus, 0); found = pcie_pme_from_pci_bridge(bus, 0);
} }
......
...@@ -204,8 +204,8 @@ static int pcie_portdrv_probe(struct pci_dev *dev, ...@@ -204,8 +204,8 @@ static int pcie_portdrv_probe(struct pci_dev *dev,
return -ENODEV; return -ENODEV;
if (!dev->irq && dev->pin) { if (!dev->irq && dev->pin) {
dev_warn(&dev->dev, "device [%04x:%04x] has invalid IRQ; " dev_warn(&dev->dev, "device [%04x:%04x] has invalid IRQ; check vendor BIOS\n",
"check vendor BIOS\n", dev->vendor, dev->device); dev->vendor, dev->device);
} }
status = pcie_port_device_register(dev); status = pcie_port_device_register(dev);
if (status) if (status)
......
...@@ -433,8 +433,7 @@ static void pci_read_bridge_mmio_pref(struct pci_bus *child) ...@@ -433,8 +433,7 @@ static void pci_read_bridge_mmio_pref(struct pci_bus *child)
limit |= ((unsigned long) mem_limit_hi) << 32; limit |= ((unsigned long) mem_limit_hi) << 32;
#else #else
if (mem_base_hi || mem_limit_hi) { if (mem_base_hi || mem_limit_hi) {
dev_err(&dev->dev, "can't handle 64-bit " dev_err(&dev->dev, "can't handle 64-bit address space for bridge\n");
"address space for bridge\n");
return; return;
} }
#endif #endif
...@@ -933,8 +932,7 @@ int pci_scan_bridge(struct pci_bus *bus, struct pci_dev *dev, int max, int pass) ...@@ -933,8 +932,7 @@ int pci_scan_bridge(struct pci_bus *bus, struct pci_dev *dev, int max, int pass)
(child->number > bus->busn_res.end) || (child->number > bus->busn_res.end) ||
(child->number < bus->number) || (child->number < bus->number) ||
(child->busn_res.end < bus->number)) { (child->busn_res.end < bus->number)) {
dev_info(&child->dev, "%pR %s " dev_info(&child->dev, "%pR %s hidden behind%s bridge %s %pR\n",
"hidden behind%s bridge %s %pR\n",
&child->busn_res, &child->busn_res,
(bus->number > child->busn_res.end && (bus->number > child->busn_res.end &&
bus->busn_res.end < child->number) ? bus->busn_res.end < child->number) ?
...@@ -1224,13 +1222,13 @@ int pci_setup_device(struct pci_dev *dev) ...@@ -1224,13 +1222,13 @@ int pci_setup_device(struct pci_dev *dev)
break; break;
default: /* unknown header */ default: /* unknown header */
dev_err(&dev->dev, "unknown header type %02x, " dev_err(&dev->dev, "unknown header type %02x, ignoring device\n",
"ignoring device\n", dev->hdr_type); dev->hdr_type);
return -EIO; return -EIO;
bad: bad:
dev_err(&dev->dev, "ignoring class %#08x (doesn't match header " dev_err(&dev->dev, "ignoring class %#08x (doesn't match header type %02x)\n",
"type %02x)\n", dev->class, dev->hdr_type); dev->class, dev->hdr_type);
dev->class = PCI_CLASS_NOT_DEFINED; dev->class = PCI_CLASS_NOT_DEFINED;
} }
...@@ -1305,9 +1303,8 @@ bool pci_bus_read_dev_vendor_id(struct pci_bus *bus, int devfn, u32 *l, ...@@ -1305,9 +1303,8 @@ bool pci_bus_read_dev_vendor_id(struct pci_bus *bus, int devfn, u32 *l,
return false; return false;
/* Card hasn't responded in 60 seconds? Must be stuck. */ /* Card hasn't responded in 60 seconds? Must be stuck. */
if (delay > crs_timeout) { if (delay > crs_timeout) {
printk(KERN_WARNING "pci %04x:%02x:%02x.%d: not " printk(KERN_WARNING "pci %04x:%02x:%02x.%d: not responding\n",
"responding\n", pci_domain_nr(bus), pci_domain_nr(bus), bus->number, PCI_SLOT(devfn),
bus->number, PCI_SLOT(devfn),
PCI_FUNC(devfn)); PCI_FUNC(devfn));
return false; return false;
} }
...@@ -1613,9 +1610,7 @@ static void pcie_write_mrrs(struct pci_dev *dev) ...@@ -1613,9 +1610,7 @@ static void pcie_write_mrrs(struct pci_dev *dev)
} }
if (mrrs < 128) if (mrrs < 128)
dev_err(&dev->dev, "MRRS was unable to be configured with a " dev_err(&dev->dev, "MRRS was unable to be configured with a safe value. If problems are experienced, try running with pci=pcie_bus_safe\n");
"safe value. If problems are experienced, try running "
"with pci=pcie_bus_safe.\n");
} }
static void pcie_bus_detect_mps(struct pci_dev *dev) static void pcie_bus_detect_mps(struct pci_dev *dev)
...@@ -1652,8 +1647,8 @@ static int pcie_bus_configure_set(struct pci_dev *dev, void *data) ...@@ -1652,8 +1647,8 @@ static int pcie_bus_configure_set(struct pci_dev *dev, void *data)
pcie_write_mps(dev, mps); pcie_write_mps(dev, mps);
pcie_write_mrrs(dev); pcie_write_mrrs(dev);
dev_info(&dev->dev, "Max Payload Size set to %4d/%4d (was %4d), " dev_info(&dev->dev, "Max Payload Size set to %4d/%4d (was %4d), Max Read Rq %4d\n",
"Max Read Rq %4d\n", pcie_get_mps(dev), 128 << dev->pcie_mpss, pcie_get_mps(dev), 128 << dev->pcie_mpss,
orig_mps, pcie_get_readrq(dev)); orig_mps, pcie_get_readrq(dev));
return 0; return 0;
......
...@@ -315,8 +315,7 @@ static void quirk_cs5536_vsa(struct pci_dev *dev) ...@@ -315,8 +315,7 @@ static void quirk_cs5536_vsa(struct pci_dev *dev)
if (pci_resource_len(dev, 0) != 8) { if (pci_resource_len(dev, 0) != 8) {
struct resource *res = &dev->resource[0]; struct resource *res = &dev->resource[0];
res->end = res->start + 8 - 1; res->end = res->start + 8 - 1;
dev_info(&dev->dev, "CS5536 ISA bridge bug detected " dev_info(&dev->dev, "CS5536 ISA bridge bug detected (incorrect header); workaround applied\n");
"(incorrect header); workaround applied.\n");
} }
} }
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_CS5536_ISA, quirk_cs5536_vsa); DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_CS5536_ISA, quirk_cs5536_vsa);
...@@ -400,7 +399,8 @@ static void piix4_io_quirk(struct pci_dev *dev, const char *name, unsigned int p ...@@ -400,7 +399,8 @@ static void piix4_io_quirk(struct pci_dev *dev, const char *name, unsigned int p
* let's get enough confirmation reports first. * let's get enough confirmation reports first.
*/ */
base &= -size; base &= -size;
dev_info(&dev->dev, "%s PIO at %04x-%04x\n", name, base, base + size - 1); dev_info(&dev->dev, "%s PIO at %04x-%04x\n", name, base,
base + size - 1);
} }
static void piix4_mem_quirk(struct pci_dev *dev, const char *name, unsigned int port, unsigned int enable) static void piix4_mem_quirk(struct pci_dev *dev, const char *name, unsigned int port, unsigned int enable)
...@@ -425,7 +425,8 @@ static void piix4_mem_quirk(struct pci_dev *dev, const char *name, unsigned int ...@@ -425,7 +425,8 @@ static void piix4_mem_quirk(struct pci_dev *dev, const char *name, unsigned int
* reserve it, but let's get enough confirmation reports first. * reserve it, but let's get enough confirmation reports first.
*/ */
base &= -size; base &= -size;
dev_info(&dev->dev, "%s MMIO at %04x-%04x\n", name, base, base + size - 1); dev_info(&dev->dev, "%s MMIO at %04x-%04x\n", name, base,
base + size - 1);
} }
/* /*
...@@ -668,8 +669,7 @@ static void quirk_xio2000a(struct pci_dev *dev) ...@@ -668,8 +669,7 @@ static void quirk_xio2000a(struct pci_dev *dev)
struct pci_dev *pdev; struct pci_dev *pdev;
u16 command; u16 command;
dev_warn(&dev->dev, "TI XIO2000a quirk detected; " dev_warn(&dev->dev, "TI XIO2000a quirk detected; secondary bus fast back-to-back transfers disabled\n");
"secondary bus fast back-to-back transfers disabled\n");
list_for_each_entry(pdev, &dev->subordinate->devices, bus_list) { list_for_each_entry(pdev, &dev->subordinate->devices, bus_list) {
pci_read_config_word(pdev, PCI_COMMAND, &command); pci_read_config_word(pdev, PCI_COMMAND, &command);
if (command & PCI_COMMAND_FAST_BACK) if (command & PCI_COMMAND_FAST_BACK)
...@@ -761,8 +761,8 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_SI, PCI_ANY_ID, quirk_ioapic_rmw); ...@@ -761,8 +761,8 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_SI, PCI_ANY_ID, quirk_ioapic_rmw);
static void quirk_amd_8131_mmrbc(struct pci_dev *dev) static void quirk_amd_8131_mmrbc(struct pci_dev *dev)
{ {
if (dev->subordinate && dev->revision <= 0x12) { if (dev->subordinate && dev->revision <= 0x12) {
dev_info(&dev->dev, "AMD8131 rev %x detected; " dev_info(&dev->dev, "AMD8131 rev %x detected; disabling PCI-X MMRBC\n",
"disabling PCI-X MMRBC\n", dev->revision); dev->revision);
dev->subordinate->bus_flags |= PCI_BUS_FLAGS_NO_MMRBC; dev->subordinate->bus_flags |= PCI_BUS_FLAGS_NO_MMRBC;
} }
} }
...@@ -971,7 +971,8 @@ static void quirk_mediagx_master(struct pci_dev *dev) ...@@ -971,7 +971,8 @@ static void quirk_mediagx_master(struct pci_dev *dev)
pci_read_config_byte(dev, 0x41, &reg); pci_read_config_byte(dev, 0x41, &reg);
if (reg & 2) { if (reg & 2) {
reg &= ~2; reg &= ~2;
dev_info(&dev->dev, "Fixup for MediaGX/Geode Slave Disconnect Boundary (0x41=0x%02x)\n", reg); dev_info(&dev->dev, "Fixup for MediaGX/Geode Slave Disconnect Boundary (0x41=0x%02x)\n",
reg);
pci_write_config_byte(dev, 0x41, reg); pci_write_config_byte(dev, 0x41, reg);
} }
} }
...@@ -1262,7 +1263,8 @@ static void asus_hides_smbus_lpc(struct pci_dev *dev) ...@@ -1262,7 +1263,8 @@ static void asus_hides_smbus_lpc(struct pci_dev *dev)
pci_write_config_word(dev, 0xF2, val & (~0x8)); pci_write_config_word(dev, 0xF2, val & (~0x8));
pci_read_config_word(dev, 0xF2, &val); pci_read_config_word(dev, 0xF2, &val);
if (val & 0x8) if (val & 0x8)
dev_info(&dev->dev, "i801 SMBus device continues to play 'hide and seek'! 0x%x\n", val); dev_info(&dev->dev, "i801 SMBus device continues to play 'hide and seek'! 0x%x\n",
val);
else else
dev_info(&dev->dev, "Enabled i801 SMBus device\n"); dev_info(&dev->dev, "Enabled i801 SMBus device\n");
} }
...@@ -1410,7 +1412,8 @@ static void asus_hides_ac97_lpc(struct pci_dev *dev) ...@@ -1410,7 +1412,8 @@ static void asus_hides_ac97_lpc(struct pci_dev *dev)
pci_write_config_byte(dev, 0x50, val & (~0xc0)); pci_write_config_byte(dev, 0x50, val & (~0xc0));
pci_read_config_byte(dev, 0x50, &val); pci_read_config_byte(dev, 0x50, &val);
if (val & 0xc0) if (val & 0xc0)
dev_info(&dev->dev, "Onboard AC97/MC97 devices continue to play 'hide and seek'! 0x%x\n", val); dev_info(&dev->dev, "Onboard AC97/MC97 devices continue to play 'hide and seek'! 0x%x\n",
val);
else else
dev_info(&dev->dev, "Enabled onboard AC97/MC97 devices\n"); dev_info(&dev->dev, "Enabled onboard AC97/MC97 devices\n");
} }
...@@ -1720,8 +1723,8 @@ static void quirk_disable_amd_8111_boot_interrupt(struct pci_dev *dev) ...@@ -1720,8 +1723,8 @@ static void quirk_disable_amd_8111_boot_interrupt(struct pci_dev *dev)
pci_read_config_word(dev, AMD_8111_PCI_IRQ_ROUTING, &pci_config_word); pci_read_config_word(dev, AMD_8111_PCI_IRQ_ROUTING, &pci_config_word);
if (!pci_config_word) { if (!pci_config_word) {
dev_info(&dev->dev, "boot interrupts on device [%04x:%04x] " dev_info(&dev->dev, "boot interrupts on device [%04x:%04x] already disabled\n",
"already disabled\n", dev->vendor, dev->device); dev->vendor, dev->device);
return; return;
} }
pci_write_config_word(dev, AMD_8111_PCI_IRQ_ROUTING, 0); pci_write_config_word(dev, AMD_8111_PCI_IRQ_ROUTING, 0);
...@@ -1769,8 +1772,7 @@ static void quirk_plx_pci9050(struct pci_dev *dev) ...@@ -1769,8 +1772,7 @@ static void quirk_plx_pci9050(struct pci_dev *dev)
if (pci_resource_len(dev, bar) == 0x80 && if (pci_resource_len(dev, bar) == 0x80 &&
(pci_resource_start(dev, bar) & 0x80)) { (pci_resource_start(dev, bar) & 0x80)) {
struct resource *r = &dev->resource[bar]; struct resource *r = &dev->resource[bar];
dev_info(&dev->dev, dev_info(&dev->dev, "Re-allocating PLX PCI 9050 BAR %u to length 256 to avoid bit 7 bug\n",
"Re-allocating PLX PCI 9050 BAR %u to length 256 to avoid bit 7 bug\n",
bar); bar);
r->flags |= IORESOURCE_UNSET; r->flags |= IORESOURCE_UNSET;
r->start = 0; r->start = 0;
...@@ -1817,9 +1819,7 @@ static void quirk_netmos(struct pci_dev *dev) ...@@ -1817,9 +1819,7 @@ static void quirk_netmos(struct pci_dev *dev)
case PCI_DEVICE_ID_NETMOS_9845: case PCI_DEVICE_ID_NETMOS_9845:
case PCI_DEVICE_ID_NETMOS_9855: case PCI_DEVICE_ID_NETMOS_9855:
if (num_parallel) { if (num_parallel) {
dev_info(&dev->dev, "Netmos %04x (%u parallel, " dev_info(&dev->dev, "Netmos %04x (%u parallel, %u serial); changing class SERIAL to OTHER (use parport_serial)\n",
"%u serial); changing class SERIAL to OTHER "
"(use parport_serial)\n",
dev->device, num_parallel, num_serial); dev->device, num_parallel, num_serial);
dev->class = (PCI_CLASS_COMMUNICATION_OTHER << 8) | dev->class = (PCI_CLASS_COMMUNICATION_OTHER << 8) |
(dev->class & 0xff); (dev->class & 0xff);
...@@ -1886,8 +1886,7 @@ static void quirk_e100_interrupt(struct pci_dev *dev) ...@@ -1886,8 +1886,7 @@ static void quirk_e100_interrupt(struct pci_dev *dev)
cmd_hi = readb(csr + 3); cmd_hi = readb(csr + 3);
if (cmd_hi == 0) { if (cmd_hi == 0) {
dev_warn(&dev->dev, "Firmware left e100 interrupts enabled; " dev_warn(&dev->dev, "Firmware left e100 interrupts enabled; disabling\n");
"disabling\n");
writeb(1, csr + 3); writeb(1, csr + 3);
} }
...@@ -1957,8 +1956,7 @@ static void quirk_nvidia_ck804_pcie_aer_ext_cap(struct pci_dev *dev) ...@@ -1957,8 +1956,7 @@ static void quirk_nvidia_ck804_pcie_aer_ext_cap(struct pci_dev *dev)
if (pci_read_config_byte(dev, 0xf41, &b) == 0) { if (pci_read_config_byte(dev, 0xf41, &b) == 0) {
if (!(b & 0x20)) { if (!(b & 0x20)) {
pci_write_config_byte(dev, 0xf41, b | 0x20); pci_write_config_byte(dev, 0xf41, b | 0x20);
dev_info(&dev->dev, dev_info(&dev->dev, "Linking AER extended capability\n");
"Linking AER extended capability\n");
} }
} }
} }
...@@ -1996,8 +1994,7 @@ static void quirk_via_cx700_pci_parking_caching(struct pci_dev *dev) ...@@ -1996,8 +1994,7 @@ static void quirk_via_cx700_pci_parking_caching(struct pci_dev *dev)
/* Turn off PCI Bus Parking */ /* Turn off PCI Bus Parking */
pci_write_config_byte(dev, 0x76, b ^ 0x40); pci_write_config_byte(dev, 0x76, b ^ 0x40);
dev_info(&dev->dev, dev_info(&dev->dev, "Disabling VIA CX700 PCI parking\n");
"Disabling VIA CX700 PCI parking\n");
} }
} }
...@@ -2012,8 +2009,7 @@ static void quirk_via_cx700_pci_parking_caching(struct pci_dev *dev) ...@@ -2012,8 +2009,7 @@ static void quirk_via_cx700_pci_parking_caching(struct pci_dev *dev)
/* Disable "Read FIFO Timer" */ /* Disable "Read FIFO Timer" */
pci_write_config_byte(dev, 0x77, 0x0); pci_write_config_byte(dev, 0x77, 0x0);
dev_info(&dev->dev, dev_info(&dev->dev, "Disabling VIA CX700 PCI caching\n");
"Disabling VIA CX700 PCI caching\n");
} }
} }
} }
...@@ -2148,8 +2144,7 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_8380_0, quirk_disab ...@@ -2148,8 +2144,7 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_8380_0, quirk_disab
static void quirk_disable_msi(struct pci_dev *dev) static void quirk_disable_msi(struct pci_dev *dev)
{ {
if (dev->subordinate) { if (dev->subordinate) {
dev_warn(&dev->dev, "MSI quirk detected; " dev_warn(&dev->dev, "MSI quirk detected; subordinate MSI disabled\n");
"subordinate MSI disabled\n");
dev->subordinate->bus_flags |= PCI_BUS_FLAGS_NO_MSI; dev->subordinate->bus_flags |= PCI_BUS_FLAGS_NO_MSI;
} }
} }
...@@ -2205,8 +2200,7 @@ static int msi_ht_cap_enabled(struct pci_dev *dev) ...@@ -2205,8 +2200,7 @@ static int msi_ht_cap_enabled(struct pci_dev *dev)
static void quirk_msi_ht_cap(struct pci_dev *dev) static void quirk_msi_ht_cap(struct pci_dev *dev)
{ {
if (dev->subordinate && !msi_ht_cap_enabled(dev)) { if (dev->subordinate && !msi_ht_cap_enabled(dev)) {
dev_warn(&dev->dev, "MSI quirk detected; " dev_warn(&dev->dev, "MSI quirk detected; subordinate MSI disabled\n");
"subordinate MSI disabled\n");
dev->subordinate->bus_flags |= PCI_BUS_FLAGS_NO_MSI; dev->subordinate->bus_flags |= PCI_BUS_FLAGS_NO_MSI;
} }
} }
...@@ -2230,8 +2224,7 @@ static void quirk_nvidia_ck804_msi_ht_cap(struct pci_dev *dev) ...@@ -2230,8 +2224,7 @@ static void quirk_nvidia_ck804_msi_ht_cap(struct pci_dev *dev)
if (!pdev) if (!pdev)
return; return;
if (!msi_ht_cap_enabled(dev) && !msi_ht_cap_enabled(pdev)) { if (!msi_ht_cap_enabled(dev) && !msi_ht_cap_enabled(pdev)) {
dev_warn(&dev->dev, "MSI quirk detected; " dev_warn(&dev->dev, "MSI quirk detected; subordinate MSI disabled\n");
"subordinate MSI disabled\n");
dev->subordinate->bus_flags |= PCI_BUS_FLAGS_NO_MSI; dev->subordinate->bus_flags |= PCI_BUS_FLAGS_NO_MSI;
} }
pci_dev_put(pdev); pci_dev_put(pdev);
...@@ -2277,8 +2270,7 @@ static void nvenet_msi_disable(struct pci_dev *dev) ...@@ -2277,8 +2270,7 @@ static void nvenet_msi_disable(struct pci_dev *dev)
if (board_name && if (board_name &&
(strstr(board_name, "P5N32-SLI PREMIUM") || (strstr(board_name, "P5N32-SLI PREMIUM") ||
strstr(board_name, "P5N32-E SLI"))) { strstr(board_name, "P5N32-E SLI"))) {
dev_info(&dev->dev, dev_info(&dev->dev, "Disabling msi for MCP55 NIC on P5N32-SLI\n");
"Disabling msi for MCP55 NIC on P5N32-SLI\n");
dev->no_msi = 1; dev->no_msi = 1;
} }
} }
...@@ -2487,8 +2479,7 @@ static void __nv_msi_ht_cap_quirk(struct pci_dev *dev, int all) ...@@ -2487,8 +2479,7 @@ static void __nv_msi_ht_cap_quirk(struct pci_dev *dev, int all)
*/ */
host_bridge = pci_get_bus_and_slot(0, PCI_DEVFN(0, 0)); host_bridge = pci_get_bus_and_slot(0, PCI_DEVFN(0, 0));
if (host_bridge == NULL) { if (host_bridge == NULL) {
dev_warn(&dev->dev, dev_warn(&dev->dev, "nv_msi_ht_cap_quirk didn't locate host bridge\n");
"nv_msi_ht_cap_quirk didn't locate host bridge\n");
return; return;
} }
...@@ -2815,8 +2806,7 @@ static void quirk_intel_mc_errata(struct pci_dev *dev) ...@@ -2815,8 +2806,7 @@ static void quirk_intel_mc_errata(struct pci_dev *dev)
*/ */
err = pci_read_config_word(dev, 0x48, &rcc); err = pci_read_config_word(dev, 0x48, &rcc);
if (err) { if (err) {
dev_err(&dev->dev, "Error attempting to read the read " dev_err(&dev->dev, "Error attempting to read the read completion coalescing register\n");
"completion coalescing register.\n");
return; return;
} }
...@@ -2827,13 +2817,11 @@ static void quirk_intel_mc_errata(struct pci_dev *dev) ...@@ -2827,13 +2817,11 @@ static void quirk_intel_mc_errata(struct pci_dev *dev)
err = pci_write_config_word(dev, 0x48, rcc); err = pci_write_config_word(dev, 0x48, rcc);
if (err) { if (err) {
dev_err(&dev->dev, "Error attempting to write the read " dev_err(&dev->dev, "Error attempting to write the read completion coalescing register\n");
"completion coalescing register.\n");
return; return;
} }
pr_info_once("Read completion coalescing disabled due to hardware " pr_info_once("Read completion coalescing disabled due to hardware errata relating to 256B MPS\n");
"errata relating to 256B MPS.\n");
} }
/* Intel 5000 series memory controllers and ports 2-7 */ /* Intel 5000 series memory controllers and ports 2-7 */
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x25c0, quirk_intel_mc_errata); DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x25c0, quirk_intel_mc_errata);
...@@ -2942,8 +2930,7 @@ static void disable_igfx_irq(struct pci_dev *dev) ...@@ -2942,8 +2930,7 @@ static void disable_igfx_irq(struct pci_dev *dev)
/* Check if any interrupt line is still enabled */ /* Check if any interrupt line is still enabled */
if (readl(regs + I915_DEIER_REG) != 0) { if (readl(regs + I915_DEIER_REG) != 0) {
dev_warn(&dev->dev, "BIOS left Intel GPU interrupts enabled; " dev_warn(&dev->dev, "BIOS left Intel GPU interrupts enabled; disabling\n");
"disabling\n");
writel(0, regs + I915_DEIER_REG); writel(0, regs + I915_DEIER_REG);
} }
...@@ -3110,8 +3097,8 @@ static int __init pci_apply_final_quirks(void) ...@@ -3110,8 +3097,8 @@ static int __init pci_apply_final_quirks(void)
if (!tmp || cls == tmp) if (!tmp || cls == tmp)
continue; continue;
printk(KERN_DEBUG "PCI: CLS mismatch (%u != %u), " printk(KERN_DEBUG "PCI: CLS mismatch (%u != %u), using %u bytes\n",
"using %u bytes\n", cls << 2, tmp << 2, cls << 2, tmp << 2,
pci_dfl_cache_line_size << 2); pci_dfl_cache_line_size << 2);
pci_cache_line_size = pci_dfl_cache_line_size; pci_cache_line_size = pci_dfl_cache_line_size;
} }
......
...@@ -148,8 +148,7 @@ static void pdev_sort_resources(struct pci_dev *dev, struct list_head *head) ...@@ -148,8 +148,7 @@ static void pdev_sort_resources(struct pci_dev *dev, struct list_head *head)
tmp = kzalloc(sizeof(*tmp), GFP_KERNEL); tmp = kzalloc(sizeof(*tmp), GFP_KERNEL);
if (!tmp) if (!tmp)
panic("pdev_sort_resources(): " panic("pdev_sort_resources(): kmalloc() failed!\n");
"kmalloc() failed!\n");
tmp->res = r; tmp->res = r;
tmp->dev = dev; tmp->dev = dev;
...@@ -859,9 +858,8 @@ static void pbus_size_io(struct pci_bus *bus, resource_size_t min_size, ...@@ -859,9 +858,8 @@ static void pbus_size_io(struct pci_bus *bus, resource_size_t min_size,
resource_size(b_res), min_align); resource_size(b_res), min_align);
if (!size0 && !size1) { if (!size0 && !size1) {
if (b_res->start || b_res->end) if (b_res->start || b_res->end)
dev_info(&bus->self->dev, "disabling bridge window " dev_info(&bus->self->dev, "disabling bridge window %pR to %pR (unused)\n",
"%pR to %pR (unused)\n", b_res, b_res, &bus->busn_res);
&bus->busn_res);
b_res->flags = 0; b_res->flags = 0;
return; return;
} }
...@@ -872,9 +870,8 @@ static void pbus_size_io(struct pci_bus *bus, resource_size_t min_size, ...@@ -872,9 +870,8 @@ static void pbus_size_io(struct pci_bus *bus, resource_size_t min_size,
if (size1 > size0 && realloc_head) { if (size1 > size0 && realloc_head) {
add_to_list(realloc_head, bus->self, b_res, size1-size0, add_to_list(realloc_head, bus->self, b_res, size1-size0,
min_align); min_align);
dev_printk(KERN_DEBUG, &bus->self->dev, "bridge window " dev_printk(KERN_DEBUG, &bus->self->dev, "bridge window %pR to %pR add_size %llx\n",
"%pR to %pR add_size %llx\n", b_res, b_res, &bus->busn_res,
&bus->busn_res,
(unsigned long long)size1-size0); (unsigned long long)size1-size0);
} }
} }
...@@ -974,9 +971,8 @@ static int pbus_size_mem(struct pci_bus *bus, unsigned long mask, ...@@ -974,9 +971,8 @@ static int pbus_size_mem(struct pci_bus *bus, unsigned long mask,
if (order < 0) if (order < 0)
order = 0; order = 0;
if (order >= ARRAY_SIZE(aligns)) { if (order >= ARRAY_SIZE(aligns)) {
dev_warn(&dev->dev, "disabling BAR %d: %pR " dev_warn(&dev->dev, "disabling BAR %d: %pR (bad alignment %#llx)\n",
"(bad alignment %#llx)\n", i, r, i, r, (unsigned long long) align);
(unsigned long long) align);
r->flags = 0; r->flags = 0;
continue; continue;
} }
...@@ -1003,9 +999,8 @@ static int pbus_size_mem(struct pci_bus *bus, unsigned long mask, ...@@ -1003,9 +999,8 @@ static int pbus_size_mem(struct pci_bus *bus, unsigned long mask,
resource_size(b_res), min_align); resource_size(b_res), min_align);
if (!size0 && !size1) { if (!size0 && !size1) {
if (b_res->start || b_res->end) if (b_res->start || b_res->end)
dev_info(&bus->self->dev, "disabling bridge window " dev_info(&bus->self->dev, "disabling bridge window %pR to %pR (unused)\n",
"%pR to %pR (unused)\n", b_res, b_res, &bus->busn_res);
&bus->busn_res);
b_res->flags = 0; b_res->flags = 0;
return 0; return 0;
} }
...@@ -1014,9 +1009,9 @@ static int pbus_size_mem(struct pci_bus *bus, unsigned long mask, ...@@ -1014,9 +1009,9 @@ static int pbus_size_mem(struct pci_bus *bus, unsigned long mask,
b_res->flags |= IORESOURCE_STARTALIGN; b_res->flags |= IORESOURCE_STARTALIGN;
if (size1 > size0 && realloc_head) { if (size1 > size0 && realloc_head) {
add_to_list(realloc_head, bus->self, b_res, size1-size0, min_align); add_to_list(realloc_head, bus->self, b_res, size1-size0, min_align);
dev_printk(KERN_DEBUG, &bus->self->dev, "bridge window " dev_printk(KERN_DEBUG, &bus->self->dev, "bridge window %pR to %pR add_size %llx\n",
"%pR to %pR add_size %llx\n", b_res, b_res, &bus->busn_res,
&bus->busn_res, (unsigned long long)size1-size0); (unsigned long long)size1-size0);
} }
return 0; return 0;
} }
...@@ -1274,8 +1269,8 @@ void __pci_bus_assign_resources(const struct pci_bus *bus, ...@@ -1274,8 +1269,8 @@ void __pci_bus_assign_resources(const struct pci_bus *bus,
break; break;
default: default:
dev_info(&dev->dev, "not setting up bridge for bus " dev_info(&dev->dev, "not setting up bridge for bus %04x:%02x\n",
"%04x:%02x\n", pci_domain_nr(b), b->number); pci_domain_nr(b), b->number);
break; break;
} }
} }
...@@ -1312,8 +1307,8 @@ static void __pci_bridge_assign_resources(const struct pci_dev *bridge, ...@@ -1312,8 +1307,8 @@ static void __pci_bridge_assign_resources(const struct pci_dev *bridge,
break; break;
default: default:
dev_info(&bridge->dev, "not setting up bridge for bus " dev_info(&bridge->dev, "not setting up bridge for bus %04x:%02x\n",
"%04x:%02x\n", pci_domain_nr(b), b->number); pci_domain_nr(b), b->number);
break; break;
} }
} }
......
...@@ -96,8 +96,8 @@ void pci_update_resource(struct pci_dev *dev, int resno) ...@@ -96,8 +96,8 @@ void pci_update_resource(struct pci_dev *dev, int resno)
pci_write_config_dword(dev, reg + 4, new); pci_write_config_dword(dev, reg + 4, new);
pci_read_config_dword(dev, reg + 4, &check); pci_read_config_dword(dev, reg + 4, &check);
if (check != new) { if (check != new) {
dev_err(&dev->dev, "BAR %d: error updating " dev_err(&dev->dev, "BAR %d: error updating (high %#08x != %#08x)\n",
"(high %#08x != %#08x)\n", resno, new, check); resno, new, check);
} }
} }
...@@ -289,8 +289,8 @@ int pci_assign_resource(struct pci_dev *dev, int resno) ...@@ -289,8 +289,8 @@ int pci_assign_resource(struct pci_dev *dev, int resno)
res->flags |= IORESOURCE_UNSET; res->flags |= IORESOURCE_UNSET;
align = pci_resource_alignment(dev, res); align = pci_resource_alignment(dev, res);
if (!align) { if (!align) {
dev_info(&dev->dev, "BAR %d: can't assign %pR " dev_info(&dev->dev, "BAR %d: can't assign %pR (bogus alignment)\n",
"(bogus alignment)\n", resno, res); resno, res);
return -EINVAL; return -EINVAL;
} }
...@@ -325,8 +325,8 @@ int pci_reassign_resource(struct pci_dev *dev, int resno, resource_size_t addsiz ...@@ -325,8 +325,8 @@ int pci_reassign_resource(struct pci_dev *dev, int resno, resource_size_t addsiz
res->flags |= IORESOURCE_UNSET; res->flags |= IORESOURCE_UNSET;
if (!res->parent) { if (!res->parent) {
dev_info(&dev->dev, "BAR %d: can't reassign an unassigned resource %pR " dev_info(&dev->dev, "BAR %d: can't reassign an unassigned resource %pR\n",
"\n", resno, res); resno, res);
return -EINVAL; return -EINVAL;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment