[interface] Provide intf_insert() to insert a filter interface

Generalise the filter interface insertion logic from block_translate()
and expose as intf_insert(), allowing a filter interface to be
inserted on any existing interface.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown
2020-12-07 13:49:47 +00:00
parent cb0ba2f825
commit 09fe2bbd34
3 changed files with 20 additions and 3 deletions

View File

@@ -169,6 +169,8 @@ extern void intfs_shutdown ( int rc, ... ) __attribute__ (( sentinel ));
extern void intf_restart ( struct interface *intf, int rc );
extern void intfs_vrestart ( va_list intfs, int rc );
extern void intfs_restart ( int rc, ... ) __attribute__ (( sentinel ));
extern void intf_insert ( struct interface *intf, struct interface *upper,
struct interface *lower );
extern void intf_poke ( struct interface *intf,
void ( type ) ( struct interface *intf ) );