diff options
| author | iabdalkader <i.abdalkader@gmail.com> | 2023-11-02 09:10:38 +0100 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2023-12-06 17:32:00 +1100 |
| commit | 50f31cc902d284db9f6ddbd60101608cfdbdbe7b (patch) | |
| tree | 4ef3f2e20d26c8da21b4ecc4346cba44603a3dbe /extmod/modnetwork.h | |
| parent | d30d5c99afba705e8286e9177768e0e38db59fff (diff) | |
extmod/modnetwork: Add deinit function to NIC protocol.
This is usually called on soft-reboot, a NIC can implement this to do any
necessary cleaning up (such as invalidating root pointers).
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
Diffstat (limited to 'extmod/modnetwork.h')
| -rw-r--r-- | extmod/modnetwork.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/extmod/modnetwork.h b/extmod/modnetwork.h index e3239c2a0..0a7897faa 100644 --- a/extmod/modnetwork.h +++ b/extmod/modnetwork.h @@ -80,6 +80,7 @@ struct _mod_network_socket_obj_t; typedef struct _mod_network_nic_protocol_t { // API for non-socket operations int (*gethostbyname)(mp_obj_t nic, const char *name, mp_uint_t len, uint8_t *ip_out); + void (*deinit)(void); // API for socket operations; return -1 on error int (*socket)(struct _mod_network_socket_obj_t *socket, int *_errno); |
