diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/serdev.h | 7 | ||||
| -rw-r--r-- | include/linux/tty.h | 9 |
2 files changed, 14 insertions, 2 deletions
diff --git a/include/linux/serdev.h b/include/linux/serdev.h index e2a225bf716d..e69402d4a8ae 100644 --- a/include/linux/serdev.h +++ b/include/linux/serdev.h | |||
| @@ -308,7 +308,7 @@ struct tty_driver; | |||
| 308 | struct device *serdev_tty_port_register(struct tty_port *port, | 308 | struct device *serdev_tty_port_register(struct tty_port *port, |
| 309 | struct device *parent, | 309 | struct device *parent, |
| 310 | struct tty_driver *drv, int idx); | 310 | struct tty_driver *drv, int idx); |
| 311 | void serdev_tty_port_unregister(struct tty_port *port); | 311 | int serdev_tty_port_unregister(struct tty_port *port); |
| 312 | #else | 312 | #else |
| 313 | static inline struct device *serdev_tty_port_register(struct tty_port *port, | 313 | static inline struct device *serdev_tty_port_register(struct tty_port *port, |
| 314 | struct device *parent, | 314 | struct device *parent, |
| @@ -316,7 +316,10 @@ static inline struct device *serdev_tty_port_register(struct tty_port *port, | |||
| 316 | { | 316 | { |
| 317 | return ERR_PTR(-ENODEV); | 317 | return ERR_PTR(-ENODEV); |
| 318 | } | 318 | } |
| 319 | static inline void serdev_tty_port_unregister(struct tty_port *port) {} | 319 | static inline int serdev_tty_port_unregister(struct tty_port *port) |
| 320 | { | ||
| 321 | return -ENODEV; | ||
| 322 | } | ||
| 320 | #endif /* CONFIG_SERIAL_DEV_CTRL_TTYPORT */ | 323 | #endif /* CONFIG_SERIAL_DEV_CTRL_TTYPORT */ |
| 321 | 324 | ||
| 322 | #endif /*_LINUX_SERDEV_H */ | 325 | #endif /*_LINUX_SERDEV_H */ |
diff --git a/include/linux/tty.h b/include/linux/tty.h index d07cd2105a6c..eccb4ec30a8a 100644 --- a/include/linux/tty.h +++ b/include/linux/tty.h | |||
| @@ -558,6 +558,15 @@ extern struct device *tty_port_register_device_attr(struct tty_port *port, | |||
| 558 | struct tty_driver *driver, unsigned index, | 558 | struct tty_driver *driver, unsigned index, |
| 559 | struct device *device, void *drvdata, | 559 | struct device *device, void *drvdata, |
| 560 | const struct attribute_group **attr_grp); | 560 | const struct attribute_group **attr_grp); |
| 561 | extern struct device *tty_port_register_device_serdev(struct tty_port *port, | ||
| 562 | struct tty_driver *driver, unsigned index, | ||
| 563 | struct device *device); | ||
| 564 | extern struct device *tty_port_register_device_attr_serdev(struct tty_port *port, | ||
| 565 | struct tty_driver *driver, unsigned index, | ||
| 566 | struct device *device, void *drvdata, | ||
| 567 | const struct attribute_group **attr_grp); | ||
| 568 | extern void tty_port_unregister_device(struct tty_port *port, | ||
| 569 | struct tty_driver *driver, unsigned index); | ||
| 561 | extern int tty_port_alloc_xmit_buf(struct tty_port *port); | 570 | extern int tty_port_alloc_xmit_buf(struct tty_port *port); |
| 562 | extern void tty_port_free_xmit_buf(struct tty_port *port); | 571 | extern void tty_port_free_xmit_buf(struct tty_port *port); |
| 563 | extern void tty_port_destroy(struct tty_port *port); | 572 | extern void tty_port_destroy(struct tty_port *port); |
