Lines Matching refs:slot
80 static inline int is_slot64bit(struct slot *slot) in is_slot64bit() argument
82 return (readb(slot->p_sm_slot + SMBIOS_SLOT_WIDTH) == 0x06) ? 1 : 0; in is_slot64bit()
85 static inline int is_slot66mhz(struct slot *slot) in is_slot66mhz() argument
87 return (readb(slot->p_sm_slot + SMBIOS_SLOT_TYPE) == 0x0E) ? 1 : 0; in is_slot66mhz()
188 tslot = cpqhp_routing_table->slots[loop].slot; in pci_print_IRQ_route()
285 struct slot *slot = hotplug_slot->private; in release_slot() local
287 dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); in release_slot()
289 kfree(slot->hotplug_slot->info); in release_slot()
290 kfree(slot->hotplug_slot); in release_slot()
291 kfree(slot); in release_slot()
296 struct slot *old_slot, *next_slot; in ctrl_slot_cleanup()
298 old_slot = ctrl->slot; in ctrl_slot_cleanup()
299 ctrl->slot = NULL; in ctrl_slot_cleanup()
334 get_slot_mapping(struct pci_bus *bus, u8 bus_num, u8 dev_num, u8 *slot) in get_slot_mapping() argument
342 dbg("%s: %p, %d, %d, %p\n", __func__, bus, bus_num, dev_num, slot); in get_slot_mapping()
350 tslot = cpqhp_routing_table->slots[loop].slot; in get_slot_mapping()
353 *slot = tslot; in get_slot_mapping()
387 *slot = bridgeSlot; in get_slot_mapping()
445 struct slot *slot = hotplug_slot->private; in set_attention_status() local
446 struct controller *ctrl = slot->ctrl; in set_attention_status()
452 dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); in set_attention_status()
454 if (cpqhp_get_bus_dev(ctrl, &bus, &devfn, slot->number) == -1) in set_attention_status()
472 struct slot *slot = hotplug_slot->private; in process_SI() local
473 struct controller *ctrl = slot->ctrl; in process_SI()
479 dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); in process_SI()
481 if (cpqhp_get_bus_dev(ctrl, &bus, &devfn, slot->number) == -1) in process_SI()
504 struct slot *slot = hotplug_slot->private; in process_SS() local
505 struct controller *ctrl = slot->ctrl; in process_SS()
511 dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); in process_SS()
513 if (cpqhp_get_bus_dev(ctrl, &bus, &devfn, slot->number) == -1) in process_SS()
531 struct slot *slot = hotplug_slot->private; in hardware_test() local
532 struct controller *ctrl = slot->ctrl; in hardware_test()
534 dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); in hardware_test()
542 struct slot *slot = hotplug_slot->private; in get_power_status() local
543 struct controller *ctrl = slot->ctrl; in get_power_status()
545 dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); in get_power_status()
547 *value = get_slot_enabled(ctrl, slot); in get_power_status()
553 struct slot *slot = hotplug_slot->private; in get_attention_status() local
554 struct controller *ctrl = slot->ctrl; in get_attention_status()
556 dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); in get_attention_status()
558 *value = cpq_get_attention_status(ctrl, slot); in get_attention_status()
564 struct slot *slot = hotplug_slot->private; in get_latch_status() local
565 struct controller *ctrl = slot->ctrl; in get_latch_status()
567 dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); in get_latch_status()
569 *value = cpq_get_latch_status(ctrl, slot); in get_latch_status()
576 struct slot *slot = hotplug_slot->private; in get_adapter_status() local
577 struct controller *ctrl = slot->ctrl; in get_adapter_status()
579 dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); in get_adapter_status()
581 *value = get_presence_status(ctrl, slot); in get_adapter_status()
603 struct slot *slot; in ctrl_slot_setup() local
625 slot = kzalloc(sizeof(*slot), GFP_KERNEL); in ctrl_slot_setup()
626 if (!slot) { in ctrl_slot_setup()
631 slot->hotplug_slot = kzalloc(sizeof(*(slot->hotplug_slot)), in ctrl_slot_setup()
633 if (!slot->hotplug_slot) { in ctrl_slot_setup()
637 hotplug_slot = slot->hotplug_slot; in ctrl_slot_setup()
647 slot->ctrl = ctrl; in ctrl_slot_setup()
648 slot->bus = ctrl->bus; in ctrl_slot_setup()
649 slot->device = slot_device; in ctrl_slot_setup()
650 slot->number = slot_number; in ctrl_slot_setup()
651 dbg("slot->number = %u\n", slot->number); in ctrl_slot_setup()
657 slot->number)) { in ctrl_slot_setup()
662 slot->p_sm_slot = slot_entry; in ctrl_slot_setup()
664 init_timer(&slot->task_event); in ctrl_slot_setup()
665 slot->task_event.expires = jiffies + 5 * HZ; in ctrl_slot_setup()
666 slot->task_event.function = cpqhp_pushbutton_thread; in ctrl_slot_setup()
671 slot->capabilities |= PCISLOT_REPLACE_SUPPORTED; in ctrl_slot_setup()
672 slot->capabilities |= PCISLOT_INTERLOCK_SUPPORTED; in ctrl_slot_setup()
674 if (is_slot64bit(slot)) in ctrl_slot_setup()
675 slot->capabilities |= PCISLOT_64_BIT_SUPPORTED; in ctrl_slot_setup()
676 if (is_slot66mhz(slot)) in ctrl_slot_setup()
677 slot->capabilities |= PCISLOT_66_MHZ_SUPPORTED; in ctrl_slot_setup()
679 slot->capabilities |= PCISLOT_66_MHZ_OPERATION; in ctrl_slot_setup()
685 slot->capabilities |= in ctrl_slot_setup()
689 slot->capabilities |= in ctrl_slot_setup()
692 slot->capabilities |= in ctrl_slot_setup()
697 hotplug_slot->private = slot; in ctrl_slot_setup()
698 snprintf(name, SLOT_NAME_SIZE, "%u", slot->number); in ctrl_slot_setup()
701 hotplug_slot_info->power_status = get_slot_enabled(ctrl, slot); in ctrl_slot_setup()
703 cpq_get_attention_status(ctrl, slot); in ctrl_slot_setup()
705 cpq_get_latch_status(ctrl, slot); in ctrl_slot_setup()
707 get_presence_status(ctrl, slot); in ctrl_slot_setup()
710 slot->bus, slot->device, in ctrl_slot_setup()
711 slot->number, ctrl->slot_device_offset, in ctrl_slot_setup()
715 slot->device, in ctrl_slot_setup()
722 slot->next = ctrl->slot; in ctrl_slot_setup()
723 ctrl->slot = slot; in ctrl_slot_setup()
736 kfree(slot); in ctrl_slot_setup()