aboutsummaryrefslogtreecommitdiffstats
path: root/com32/sysdump/serial.h
blob: be95f6c48fa1308c9c47166ef408ce65f64ec79f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#ifndef SERIAL_H
#define SERIAL_H

#include <stddef.h>

struct serial_if {
    uint16_t port;
    struct {
	uint8_t dll, dlm, ier, iir, lcr, mcr;
    } old;
};

int serial_init(struct serial_if *sif, const char *argv[]);
void serial_read(struct serial_if *sif, void *data, size_t n);
void serial_write(struct serial_if *sif, const void *data, size_t n);
void serial_cleanup(struct serial_if *sif);

#endif /* SERIAL_H */