1 /*
2  * Copyright (c) 2013 Corey Tabaka
3  *
4  * Use of this source code is governed by a MIT-style
5  * license that can be found in the LICENSE file or at
6  * https://opensource.org/licenses/MIT
7  */
8 #pragma once
9 
10 #include <dev/driver.h>
11 
12 /* uart interface */
13 struct uart_ops {
14     struct driver_ops std;
15 
16     ssize_t (*read)(struct device *dev, void *buf, size_t len);
17     ssize_t (*write)(struct device *dev, const void *buf, size_t len);
18 };
19 
20 
21 ssize_t class_uart_read(struct device *dev, void *buf, size_t len);
22 ssize_t class_uart_write(struct device *dev, const void *buf, size_t len);
23 
24