* Flush any buffered vmcore data. */
| 200 | * Flush any buffered vmcore data. |
| 201 | */ |
| 202 | static int |
| 203 | netdump_flush_buf(void) |
| 204 | { |
| 205 | int error; |
| 206 | |
| 207 | error = 0; |
| 208 | if (nd_conf.nd_buf_len != 0) { |
| 209 | struct debugnet_proto_aux auxdata = { |
| 210 | .dp_offset_start = nd_conf.nd_tx_off, |
| 211 | }; |
| 212 | error = debugnet_send(nd_conf.nd_pcb, DEBUGNET_DATA, nd_buf, |
| 213 | nd_conf.nd_buf_len, &auxdata); |
| 214 | if (error == 0) |
| 215 | nd_conf.nd_buf_len = 0; |
| 216 | } |
| 217 | return (error); |
| 218 | } |
| 219 | |
| 220 | /* |
| 221 | * Callback from dumpsys() to dump a chunk of memory. |
no test coverage detected