Index: uspace/drv/block/isa-ide/isa-ide_hw.h
===================================================================
--- uspace/drv/block/isa-ide/isa-ide_hw.h	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
+++ uspace/drv/block/isa-ide/isa-ide_hw.h	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -0,0 +1,54 @@
+/*
+ * Copyright (c) 2025 Jiri Svoboda
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * - Redistributions of source code must retain the above copyright
+ *   notice, this list of conditions and the following disclaimer.
+ * - Redistributions in binary form must reproduce the above copyright
+ *   notice, this list of conditions and the following disclaimer in the
+ *   documentation and/or other materials provided with the distribution.
+ * - The name of the author may not be used to endorse or promote products
+ *   derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/** @addtogroup pci-ide
+ * @{
+ */
+/** @file ISA IDE hardware protocol
+ */
+
+#ifndef ISA_IDE_HW_H
+#define ISA_IDE_HW_H
+
+/*
+ * PCI IDE needs to use ATA ports at fixed legacy ISA addresses.
+ * We need to know what those addresses are so that, if we are
+ * asked to attach to those *and* we know that PCI IDE is attached
+ * to legacy IDE ranges, we should not attach.
+ */
+enum {
+	leg_ide_ata_cmd_p = 0x01f0,
+	leg_ide_ata_ctl_p = 0x03f4,
+	leg_ide_ata_cmd_s = 0x0170,
+	leg_ide_ata_ctl_s = 0x0374
+};
+
+#endif
+
+/** @}
+ */
Index: uspace/drv/block/isa-ide/main.c
===================================================================
--- uspace/drv/block/isa-ide/main.c	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/drv/block/isa-ide/main.c	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2024 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * All rights reserved.
  *
@@ -43,4 +43,5 @@
 
 #include "isa-ide.h"
+#include "isa-ide_hw.h"
 #include "main.h"
 
@@ -70,5 +71,5 @@
 	async_sess_t *parent_sess;
 	hw_res_list_parsed_t hw_res;
-	hw_res_flags_t flags;
+	hw_res_claims_t claims;
 	errno_t rc;
 
@@ -77,25 +78,16 @@
 		return ENOMEM;
 
-	rc = hw_res_get_flags(parent_sess, &flags);
-	if (rc != EOK)
-		return rc;
-
-	/*
-	 * Prevent attaching to the legacy ISA IDE register block
-	 * on a system with PCI not to conflict with PCI IDE.
-	 *
-	 * XXX This is a simplification. If we had a PCI-based system without
-	 * PCI-IDE or with PCI-IDE disabled and would still like to use
-	 * an ISA IDE controller, this would prevent us from doing so.
-	 */
-	if (flags & hwf_isa_bridge) {
-		ddf_msg(LVL_NOTE, "Will not attach to PCI/ISA bridge.");
-		return EIO;
+	rc = hw_res_query_legacy_io(parent_sess, &claims);
+	if (rc != EOK) {
+		ddf_msg(LVL_NOTE, "Error getting HW resource flags.");
+		return rc;
 	}
 
 	hw_res_list_parsed_init(&hw_res);
 	rc = hw_res_get_list_parsed(parent_sess, &hw_res, 0);
-	if (rc != EOK)
-		return rc;
+	if (rc != EOK) {
+		ddf_msg(LVL_NOTE, "Error getting HW resource list.");
+		return rc;
+	}
 
 	if (hw_res.io_ranges.count != 4) {
@@ -148,4 +140,16 @@
 	}
 
+	/*
+	 * Only attach to legacy ISA IDE register block if it
+	 * is not claimed by PCI IDE driver.
+	 */
+	if (res->cmd1 == leg_ide_ata_cmd_p &&
+	    res->cmd2 == leg_ide_ata_cmd_s &&
+	    (claims & hwc_isa_ide) != 0) {
+		ddf_msg(LVL_NOTE, "Will not attach to ISA legacy ports "
+		    "since they are already handled by PCI.");
+		return EBUSY;
+	}
+
 	return EOK;
 error:
@@ -167,5 +171,6 @@
 	rc = isa_ide_get_res(dev, &res);
 	if (rc != EOK) {
-		ddf_msg(LVL_ERROR, "Invalid HW resource configuration.");
+		if (rc == EINVAL)
+			ddf_msg(LVL_ERROR, "Invalid HW resource configuration.");
 		return EINVAL;
 	}
Index: uspace/drv/block/pc-floppy/main.c
===================================================================
--- uspace/drv/block/pc-floppy/main.c	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/drv/block/pc-floppy/main.c	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2024 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * All rights reserved.
  *
@@ -73,5 +73,4 @@
 	async_sess_t *parent_sess;
 	hw_res_list_parsed_t hw_res;
-	hw_res_flags_t flags;
 	errno_t rc;
 
@@ -79,8 +78,4 @@
 	if (parent_sess == NULL)
 		return ENOMEM;
-
-	rc = hw_res_get_flags(parent_sess, &flags);
-	if (rc != EOK)
-		return rc;
 
 	hw_res_list_parsed_init(&hw_res);
Index: uspace/drv/block/pci-ide/main.c
===================================================================
--- uspace/drv/block/pci-ide/main.c	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/drv/block/pci-ide/main.c	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2024 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * All rights reserved.
  *
@@ -133,4 +133,5 @@
 	pci_ide_ctrl_t *ctrl;
 	pci_ide_hwres_t res;
+	async_sess_t *parent_sess;
 	errno_t rc;
 
@@ -164,4 +165,18 @@
 	if (rc != EOK) {
 		ddf_msg(LVL_ERROR, "Failed initializing ATA controller.");
+		rc = EIO;
+		goto error;
+	}
+
+	parent_sess = ddf_dev_parent_sess_get(dev);
+	if (parent_sess == NULL) {
+		rc = ENOMEM;
+		goto error;
+	}
+
+	/* Claim legacy I/O range to prevent ISA IDE from attaching there. */
+	rc = hw_res_claim_legacy_io(parent_sess, hwc_isa_ide);
+	if (rc != EOK) {
+		ddf_msg(LVL_ERROR, "Failed claiming legacy I/O range.");
 		rc = EIO;
 		goto error;
Index: uspace/drv/block/pci-ide/pci-ide.c
===================================================================
--- uspace/drv/block/pci-ide/pci-ide.c	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/drv/block/pci-ide/pci-ide.c	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2024 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * All rights reserved.
  *
@@ -189,4 +189,6 @@
 
 	ddf_msg(LVL_DEBUG, "pci_ide_channel_init()");
+
+	memset(&params, 0, sizeof(params));
 
 	chan->ctrl = ctrl;
Index: uspace/drv/bus/isa/isa.c
===================================================================
--- uspace/drv/bus/isa/isa.c	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/drv/bus/isa/isa.c	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2024 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
  * Copyright (c) 2011 Jan Vesely
@@ -206,15 +206,44 @@
 }
 
-static errno_t isa_fun_get_flags(ddf_fun_t *fnode, hw_res_flags_t *rflags)
+/** Handle legacy IO availability query from function.
+ *
+ * @param fnode Function performing the query
+ * @param rclaims Place to store the legacy IO claims bitmask
+ * @return EOK on success or an error code
+ */
+static errno_t isa_fun_query_legacy_io(ddf_fun_t *fnode,
+    hw_res_claims_t *rclaims)
 {
 	isa_fun_t *fun = isa_fun(fnode);
-	hw_res_flags_t flags;
-
-	flags = 0;
-	if (fun->bus->pci_isa_bridge)
-		flags |= hwf_isa_bridge;
-
-	ddf_msg(LVL_NOTE, "isa_fun_get_flags: returning 0x%x", flags);
-	*rflags = flags;
+	hw_res_claims_t claims;
+	async_sess_t *sess;
+	errno_t rc;
+
+	ddf_msg(LVL_DEBUG, "isa_fun_query_legacy_io()");
+
+	sess = ddf_dev_parent_sess_get(fun->bus->dev);
+	if (sess == NULL) {
+		ddf_msg(LVL_ERROR, "isa_dev_add failed to connect to the "
+		    "parent driver.");
+		return ENOENT;
+	}
+
+	if (!fun->bus->pci_isa_bridge) {
+		ddf_msg(LVL_NOTE, "isa_fun_query_legacy_io: classic ISA - "
+		    "legacy IDE range is available");
+		/* Classic ISA, we can be sure IDE is unclaimed by PCI */
+		claims = 0;
+	} else {
+		ddf_msg(LVL_NOTE, "isa_fun_query_legacy_io: ISA bridge - "
+		    "determine legacy IDE availability from PCI bus driver");
+		rc = hw_res_query_legacy_io(sess, &claims);
+		if (rc != EOK) {
+			ddf_msg(LVL_NOTE, "Error querying legacy IO claims.");
+			return rc;
+		}
+	}
+
+	ddf_msg(LVL_DEBUG, "isa_fun_query_legacy_io: returning 0x%x", claims);
+	*rclaims = claims;
 	return EOK;
 }
@@ -227,5 +256,5 @@
 	.dma_channel_setup = isa_fun_setup_dma,
 	.dma_channel_remain = isa_fun_remain_dma,
-	.get_flags = isa_fun_get_flags
+	.query_legacy_io = isa_fun_query_legacy_io
 };
 
Index: uspace/drv/bus/pci/pciintel/pci.c
===================================================================
--- uspace/drv/bus/pci/pciintel/pci.c	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/drv/bus/pci/pciintel/pci.c	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2019 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
  * All rights reserved.
@@ -143,4 +143,76 @@
 }
 
+/** Handle legacy IO availability query from function.
+ *
+ * @param fnode Function performing the query
+ * @param rclaims Place to store the legacy IO claims bitmask
+ * @return EOK on success or an error code
+ */
+static errno_t pciintel_query_legacy_io(ddf_fun_t *fnode,
+    hw_res_claims_t *rclaims)
+{
+	pci_fun_t *fun = pci_fun(fnode);
+	pci_bus_t *bus = fun->busptr;
+	pci_fun_t *f;
+	hw_res_claims_t claims;
+
+	/*
+	 * We need to wait for enumeration to complete so that we give
+	 * the PCI IDE driver a chance to claim the legacy ISA IDE
+	 * ranges.
+	 */
+	ddf_msg(LVL_DEBUG, "pciintel_query_legacy_io");
+
+	fun->querying = true;
+
+	fibril_mutex_lock(&bus->enum_done_lock);
+	while (!bus->enum_done)
+		fibril_condvar_wait(&bus->enum_done_cv, &bus->enum_done_lock);
+	fibril_mutex_unlock(&bus->enum_done_lock);
+
+	ddf_msg(LVL_DEBUG, "Wait for PCI devices to stabilize");
+
+	f = pci_fun_first(bus);
+	while (f != NULL) {
+		if (!f->querying)
+			ddf_fun_wait_stable(f->fnode);
+		f = pci_fun_next(f);
+	}
+
+	/* Devices are stable. Now we can determine if ISA IDE was claimed. */
+
+	claims = 0;
+
+	ddf_msg(LVL_DEBUG, "PCI devices stabilized, leg_ide_claimed=%d\n",
+	    (int)bus->leg_ide_claimed);
+	if (bus->leg_ide_claimed != false) {
+		ddf_msg(LVL_NOTE, "Legacy IDE I/O ports claimed by PCI driver.");
+		claims |= hwc_isa_ide;
+	}
+
+	fun->querying = false;
+	*rclaims = claims;
+	return EOK;
+}
+
+/** Handle legacy IO claim from function.
+ *
+ * @param fnode Function claiming the legacy I/O ports
+ * @param claims Bitmask of claimed I/O
+ * @return EOK on success or an error code
+ */
+static errno_t pciintel_claim_legacy_io(ddf_fun_t *fnode,
+    hw_res_claims_t claims)
+{
+	pci_fun_t *fun = pci_fun(fnode);
+	pci_bus_t *bus = fun->busptr;
+
+	ddf_msg(LVL_DEBUG, "pciintel_claim_legacy_io() claims=%x", claims);
+	if ((claims & hwc_isa_ide) != 0)
+		bus->leg_ide_claimed = true;
+
+	return EOK;
+}
+
 static pio_window_t *pciintel_get_pio_window(ddf_fun_t *fnode)
 {
@@ -211,4 +283,6 @@
 	.disable_interrupt = &pciintel_disable_interrupt,
 	.clear_interrupt = &pciintel_clear_interrupt,
+	.query_legacy_io = &pciintel_query_legacy_io,
+	.claim_legacy_io = &pciintel_claim_legacy_io
 };
 
@@ -755,4 +829,6 @@
 	list_initialize(&bus->funs);
 	fibril_mutex_initialize(&bus->conf_mutex);
+	fibril_mutex_initialize(&bus->enum_done_lock);
+	fibril_condvar_initialize(&bus->enum_done_cv);
 
 	bus->dnode = dnode;
@@ -863,6 +939,12 @@
 	hw_res_clean_resource_list(&hw_resources);
 
+	ddf_msg(LVL_DEBUG, "Bus enumeration done.");
+
+	fibril_mutex_lock(&bus->enum_done_lock);
+	bus->enum_done = true;
+	fibril_mutex_unlock(&bus->enum_done_lock);
+	fibril_condvar_broadcast(&bus->enum_done_cv);
+
 	return EOK;
-
 fail:
 	if (got_res)
Index: uspace/drv/bus/pci/pciintel/pci.h
===================================================================
--- uspace/drv/bus/pci/pciintel/pci.h	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/drv/bus/pci/pciintel/pci.h	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,5 +1,5 @@
 /*
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
- * Copyright (c) 2011 Jiri Svoboda
  * All rights reserved.
  *
@@ -41,4 +41,5 @@
 #include <ddf/driver.h>
 #include <fibril_synch.h>
+#include <stdbool.h>
 
 #define PCI_MAX_HW_RES 10
@@ -54,4 +55,12 @@
 	/** List of functions (of pci_fun_t) */
 	list_t funs;
+	/** Enumeration is done */
+	bool enum_done;
+	/** Synchronize enum_done */
+	fibril_mutex_t enum_done_lock;
+	/** Signal change to enum_done */
+	fibril_condvar_t enum_done_cv;
+	/** @c true iff legacy IDE range is claimed by PCI IDE driver */
+	bool leg_ide_claimed;
 } pci_bus_t;
 
@@ -72,4 +81,5 @@
 	uint8_t prog_if;
 	uint8_t revision;
+	bool querying;
 	hw_resource_list_t hw_resources;
 	hw_resource_t resources[PCI_MAX_HW_RES];
Index: uspace/lib/c/generic/device/hw_res.c
===================================================================
--- uspace/lib/c/generic/device/hw_res.c	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/lib/c/generic/device/hw_res.c	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2024 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
  * All rights reserved.
@@ -162,24 +162,44 @@
 }
 
-/** Get bus flags.
+/** Query legacy IO claims.
  *
  * @param sess HW res session
- * @param rflags Place to store the flags
- *
- * @return Error code.
- *
- */
-errno_t hw_res_get_flags(async_sess_t *sess, hw_res_flags_t *rflags)
-{
-	async_exch_t *exch = async_exchange_begin(sess);
-
-	sysarg_t flags;
+ * @param rclaims Place to store the claims
+ *
+ * @return Error code.
+ *
+ */
+errno_t hw_res_query_legacy_io(async_sess_t *sess, hw_res_claims_t *rclaims)
+{
+	async_exch_t *exch = async_exchange_begin(sess);
+
+	sysarg_t claims;
 	const errno_t ret = async_req_1_1(exch, DEV_IFACE_ID(HW_RES_DEV_IFACE),
-	    HW_RES_GET_FLAGS, &flags);
+	    HW_RES_QUERY_LEGACY_IO, &claims);
 
 	async_exchange_end(exch);
 
 	if (ret == EOK)
-		*rflags = flags;
+		*rclaims = claims;
+
+	return ret;
+}
+
+/** Claim legacy IO devices.
+ *
+ * @param sess HW res session
+ * @param claims Claims
+ *
+ * @return Error code.
+ *
+ */
+errno_t hw_res_claim_legacy_io(async_sess_t *sess, hw_res_claims_t claims)
+{
+	async_exch_t *exch = async_exchange_begin(sess);
+
+	const errno_t ret = async_req_2_0(exch, DEV_IFACE_ID(HW_RES_DEV_IFACE),
+	    HW_RES_CLAIM_LEGACY_IO, claims);
+
+	async_exchange_end(exch);
 
 	return ret;
Index: uspace/lib/c/include/device/hw_res.h
===================================================================
--- uspace/lib/c/include/device/hw_res.h	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/lib/c/include/device/hw_res.h	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2024 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
  * All rights reserved.
@@ -57,5 +57,6 @@
 	HW_RES_DMA_CHANNEL_SETUP,
 	HW_RES_DMA_CHANNEL_REMAIN,
-	HW_RES_GET_FLAGS
+	HW_RES_QUERY_LEGACY_IO,
+	HW_RES_CLAIM_LEGACY_IO
 } hw_res_method_t;
 
@@ -118,8 +119,9 @@
 }
 
+/** Claims to legacy devices */
 typedef enum {
-	/** This is an PCI/ISA bridge, not 'classic' ISA bus */
-	hwf_isa_bridge = 0x1
-} hw_res_flags_t;
+	/** 'Legacy' ISA IDE I/O ranges */
+	hwc_isa_ide = 0x1
+} hw_res_claims_t;
 
 extern errno_t hw_res_get_resource_list(async_sess_t *, hw_resource_list_t *);
@@ -131,5 +133,6 @@
     uint32_t, uint8_t);
 extern errno_t hw_res_dma_channel_remain(async_sess_t *, unsigned, size_t *);
-extern errno_t hw_res_get_flags(async_sess_t *, hw_res_flags_t *);
+extern errno_t hw_res_query_legacy_io(async_sess_t *, hw_res_claims_t *);
+extern errno_t hw_res_claim_legacy_io(async_sess_t *, hw_res_claims_t);
 
 #endif
Index: uspace/lib/device/include/devman.h
===================================================================
--- uspace/lib/device/include/devman.h	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/lib/device/include/devman.h	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2009 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
  * All rights reserved.
@@ -52,4 +52,5 @@
 extern errno_t devman_drv_fun_online(devman_handle_t);
 extern errno_t devman_drv_fun_offline(devman_handle_t);
+extern errno_t devman_drv_fun_wait_stable(devman_handle_t);
 
 extern async_sess_t *devman_device_connect(devman_handle_t, unsigned int);
Index: uspace/lib/device/include/ipc/devman.h
===================================================================
--- uspace/lib/device/include/ipc/devman.h	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/lib/device/include/ipc/devman.h	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,3 +1,4 @@
 /*
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
  * All rights reserved.
@@ -147,4 +148,5 @@
 	DEVMAN_DRV_FUN_ONLINE,
 	DEVMAN_DRV_FUN_OFFLINE,
+	DEVMAN_DRV_FUN_WAIT_STABLE,
 	DEVMAN_REMOVE_FUNCTION
 } driver_to_devman_t;
Index: uspace/lib/device/src/devman.c
===================================================================
--- uspace/lib/device/src/devman.c	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/lib/device/src/devman.c	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,5 +1,5 @@
 /*
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2007 Josef Cejka
- * Copyright (c) 2013 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
  * All rights reserved.
@@ -343,4 +343,16 @@
 }
 
+errno_t devman_drv_fun_wait_stable(devman_handle_t funh)
+{
+	async_exch_t *exch = devman_exchange_begin(INTERFACE_DDF_DRIVER);
+	if (exch == NULL)
+		return ENOMEM;
+
+	errno_t retval = async_req_1_0(exch, DEVMAN_DRV_FUN_WAIT_STABLE, funh);
+
+	devman_exchange_end(exch);
+	return retval;
+}
+
 async_sess_t *devman_parent_device_connect(devman_handle_t handle,
     unsigned int flags)
Index: uspace/lib/drv/generic/driver.c
===================================================================
--- uspace/lib/drv/generic/driver.c	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/lib/drv/generic/driver.c	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,5 +1,5 @@
 /*
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
- * Copyright (c) 2011 Jiri Svoboda
  * All rights reserved.
  *
@@ -971,4 +971,14 @@
 }
 
+/** Wait for function to enter stable state.
+ *
+ * @param fun Function
+ * @return EOK on success or an error code
+ */
+errno_t ddf_fun_wait_stable(ddf_fun_t *fun)
+{
+	return devman_drv_fun_wait_stable(fun->handle);
+}
+
 errno_t ddf_driver_main(const driver_t *drv)
 {
Index: uspace/lib/drv/generic/remote_hw_res.c
===================================================================
--- uspace/lib/drv/generic/remote_hw_res.c	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/lib/drv/generic/remote_hw_res.c	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2024 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
  * Copyright (c) 2011 Jan Vesely
@@ -48,5 +48,6 @@
 static void remote_hw_res_dma_channel_setup(ddf_fun_t *, void *, ipc_call_t *);
 static void remote_hw_res_dma_channel_remain(ddf_fun_t *, void *, ipc_call_t *);
-static void remote_hw_res_get_flags(ddf_fun_t *, void *, ipc_call_t *);
+static void remote_hw_res_query_legacy_io(ddf_fun_t *, void *, ipc_call_t *);
+static void remote_hw_res_claim_legacy_io(ddf_fun_t *, void *, ipc_call_t *);
 
 static const remote_iface_func_ptr_t remote_hw_res_iface_ops [] = {
@@ -57,5 +58,6 @@
 	[HW_RES_DMA_CHANNEL_SETUP] = &remote_hw_res_dma_channel_setup,
 	[HW_RES_DMA_CHANNEL_REMAIN] = &remote_hw_res_dma_channel_remain,
-	[HW_RES_GET_FLAGS] = &remote_hw_res_get_flags
+	[HW_RES_QUERY_LEGACY_IO] = &remote_hw_res_query_legacy_io,
+	[HW_RES_CLAIM_LEGACY_IO] = &remote_hw_res_claim_legacy_io
 };
 
@@ -174,17 +176,34 @@
 }
 
-static void remote_hw_res_get_flags(ddf_fun_t *fun, void *ops,
-    ipc_call_t *call)
-{
-	hw_res_ops_t *hw_res_ops = ops;
-
-	if (hw_res_ops->get_flags == NULL) {
-		async_answer_0(call, ENOTSUP);
-		return;
-	}
-
-	hw_res_flags_t flags = 0;
-	const errno_t ret = hw_res_ops->get_flags(fun, &flags);
-	async_answer_1(call, ret, flags);
+static void remote_hw_res_query_legacy_io(ddf_fun_t *fun, void *ops,
+    ipc_call_t *call)
+{
+	hw_res_ops_t *hw_res_ops = ops;
+
+	if (hw_res_ops->query_legacy_io == NULL) {
+		async_answer_0(call, ENOTSUP);
+		return;
+	}
+
+	hw_res_claims_t claims = 0;
+	const errno_t ret = hw_res_ops->query_legacy_io(fun, &claims);
+	async_answer_1(call, ret, claims);
+}
+
+static void remote_hw_res_claim_legacy_io(ddf_fun_t *fun, void *ops,
+    ipc_call_t *call)
+{
+	hw_res_ops_t *hw_res_ops = ops;
+	hw_res_claims_t claims;
+
+	if (hw_res_ops->claim_legacy_io == NULL) {
+		async_answer_0(call, ENOTSUP);
+		return;
+	}
+
+	claims = DEV_IPC_GET_ARG1(*call);
+
+	const errno_t ret = hw_res_ops->claim_legacy_io(fun, claims);
+	async_answer_0(call, ret);
 }
 
Index: uspace/lib/drv/include/ddf/driver.h
===================================================================
--- uspace/lib/drv/include/ddf/driver.h	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/lib/drv/include/ddf/driver.h	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,5 +1,5 @@
 /*
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
- * Copyright (c) 2011 Jiri Svoboda
  * All rights reserved.
  *
@@ -133,4 +133,5 @@
 extern void ddf_fun_set_conn_handler(ddf_fun_t *, async_port_handler_t);
 extern errno_t ddf_fun_add_to_category(ddf_fun_t *, const char *);
+extern errno_t ddf_fun_wait_stable(ddf_fun_t *);
 
 #endif
Index: uspace/lib/drv/include/ops/hw_res.h
===================================================================
--- uspace/lib/drv/include/ops/hw_res.h	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/lib/drv/include/ops/hw_res.h	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2024 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
  * Copyright (c) 2011 Jan Vesely
@@ -50,5 +50,6 @@
 	errno_t (*dma_channel_setup)(ddf_fun_t *, unsigned, uint32_t, uint32_t, uint8_t);
 	errno_t (*dma_channel_remain)(ddf_fun_t *, unsigned, size_t *);
-	errno_t (*get_flags)(ddf_fun_t *, hw_res_flags_t *);
+	errno_t (*query_legacy_io)(ddf_fun_t *, hw_res_claims_t *);
+	errno_t (*claim_legacy_io)(ddf_fun_t *, hw_res_claims_t);
 } hw_res_ops_t;
 
Index: uspace/srv/devman/drv_conn.c
===================================================================
--- uspace/srv/devman/drv_conn.c	(revision 0dab4850c8601c3ffb2cf910cb99650e1766ff26)
+++ uspace/srv/devman/drv_conn.c	(revision 832cbe7f6539badd99e8e5715f4a59e044c65c44)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2023 Jiri Svoboda
+ * Copyright (c) 2025 Jiri Svoboda
  * Copyright (c) 2010 Lenka Trochtova
  * All rights reserved.
@@ -453,4 +453,39 @@
 	fun_busy_unlock(fun);
 	fun_del_ref(fun);
+	async_answer_0(icall, EOK);
+}
+
+/** Wait for function to become stable.
+ *
+ */
+static void devman_drv_fun_wait_stable(ipc_call_t *icall, driver_t *drv)
+{
+	fun_node_t *fun;
+	dev_node_t *dev;
+
+	fibril_rwlock_read_lock(&device_tree.rwlock);
+
+	fun = find_fun_node(&device_tree, ipc_get_arg1(icall));
+	if (fun == NULL) {
+		fibril_rwlock_read_unlock(&device_tree.rwlock);
+		async_answer_0(icall, ENOENT);
+		return;
+	}
+
+	if (fun->child == NULL) {
+		fibril_rwlock_read_unlock(&device_tree.rwlock);
+		fun_del_ref(fun);
+		async_answer_0(icall, EOK);
+		return;
+	}
+
+	dev = fun->child;
+	dev_add_ref(dev);
+
+	fibril_rwlock_read_unlock(&device_tree.rwlock);
+
+	dev_wait_stable(dev);
+	dev_del_ref(dev);
+
 	async_answer_0(icall, EOK);
 }
@@ -642,4 +677,7 @@
 			devman_drv_fun_offline(&call, driver);
 			break;
+		case DEVMAN_DRV_FUN_WAIT_STABLE:
+			devman_drv_fun_wait_stable(&call, driver);
+			break;
 		case DEVMAN_REMOVE_FUNCTION:
 			devman_remove_function(&call);
