static void pcie_cap_slot_hotplug_common(PCIDevice *hotplug_dev,

                                         DeviceState *dev,

                                         uint8_t **exp_cap, Error **errp)

{

    *exp_cap = hotplug_dev->config + hotplug_dev->exp.exp_cap;

    uint16_t sltsta = pci_get_word(*exp_cap + PCI_EXP_SLTSTA);



    PCIE_DEV_PRINTF(PCI_DEVICE(dev), "hotplug state: 0x%x\n", sltsta);

    if (sltsta & PCI_EXP_SLTSTA_EIS) {

        /* the slot is electromechanically locked.

         * This error is propagated up to qdev and then to HMP/QMP.

         */

        error_setg_errno(errp, -EBUSY, "slot is electromechanically locked");

    }

}

static void pcie_cap_slot_hotplug_common(PCIDevice *hotplug_dev,

                                         DeviceState *dev,

                                         uint8_t **exp_cap, Error **errp)

{

    *exp_cap = hotplug_dev->config + hotplug_dev->exp.exp_cap;

    uint16_t sltsta = pci_get_word(*exp_cap + PCI_EXP_SLTSTA);



    PCIE_DEV_PRINTF(PCI_DEVICE(dev), "hotplug state: 0x%x\n", sltsta);

    if (sltsta & PCI_EXP_SLTSTA_EIS) {

        





        error_setg_errno(errp, -EBUSY, "slot is electromechanically locked");

    }

}

        error_setg_errno(errp, -EBUSY, "slot is electromechanically locked");
static void FUNC_0(PCIDevice *VAR_0,

                                         DeviceState *VAR_1,

                                         uint8_t **VAR_2, Error **VAR_3)

{

    *VAR_2 = VAR_0->config + VAR_0->exp.VAR_2;

    uint16_t sltsta = pci_get_word(*VAR_2 + PCI_EXP_SLTSTA);



    PCIE_DEV_PRINTF(PCI_DEVICE(VAR_1), "hotplug state: 0x%x\n", sltsta);

    if (sltsta & PCI_EXP_SLTSTA_EIS) {

        





        error_setg_errno(VAR_3, -EBUSY, "slot is electromechanically locked");

    }

}

static void FUNC_0(PCIDevice *VAR_0,
DeviceState *VAR_1,
uint8_t **VAR_2, Error **VAR_3)
{ *VAR_2 = VAR_0->config + VAR_0->exp.VAR_2; uint16_t sltsta = pci_get_word(*VAR_2 + PCI_EXP_SLTSTA); PCIE_DEV_PRINTF(PCI_DEVICE(VAR_1), "hotplug state: 0x%x\n", sltsta); if (sltsta & PCI_EXP_SLTSTA_EIS) { error_setg_errno(VAR_3, -EBUSY, "slot is electromechanically locked"); } }