acpi_install_notify_handler(ap->acpi_handle,
                                                    ACPI_SYSTEM_NOTIFY,
                                                    ata_acpi_ap_notify, ap);
-#if defined(CONFIG_ACPI_DOCK) || defined(CONFIG_ACPI_DOCK_MODULE)
                        /* we might be on a docking station */
                        register_hotplug_dock_device(ap->acpi_handle,
                                                     ata_acpi_ap_notify, ap);
-#endif
                }
 
                for (j = 0; j < ata_link_max_devices(&ap->link); j++) {
                                acpi_install_notify_handler(dev->acpi_handle,
                                                ACPI_SYSTEM_NOTIFY,
                                                ata_acpi_dev_notify, dev);
-#if defined(CONFIG_ACPI_DOCK) || defined(CONFIG_ACPI_DOCK_MODULE)
                                /* we might be on a docking station */
                                register_hotplug_dock_device(dev->acpi_handle,
                                                ata_acpi_dev_notify, dev);
-#endif
                        }
                }
        }