Index: uspace/drv/char/ns8250/ns8250.c
===================================================================
--- uspace/drv/char/ns8250/ns8250.c	(revision cde999aca79219e8751af76502001a86d411d176)
+++ uspace/drv/char/ns8250/ns8250.c	(revision 08d4ea2111e5db01d0a6194bd9da4248ee282dc7)
@@ -251,5 +251,5 @@
  * @return		EOK on success or non-zero error code
  */
-static int ns8250_read(chardev_srv_t *srv, void *buf, size_t count, size_t *nread)
+static errno_t ns8250_read(chardev_srv_t *srv, void *buf, size_t count, size_t *nread)
 {
 	ns8250_t *ns = srv_ns8250(srv);
@@ -295,5 +295,5 @@
  * @return		EOK on success or non-zero error code
  */
-static int ns8250_write(chardev_srv_t *srv, const void *buf, size_t count,
+static errno_t ns8250_write(chardev_srv_t *srv, const void *buf, size_t count,
     size_t *nwritten)
 {
@@ -309,6 +309,6 @@
 }
 
-static int ns8250_open(chardev_srvs_t *, chardev_srv_t *);
-static int ns8250_close(chardev_srv_t *);
+static errno_t ns8250_open(chardev_srvs_t *, chardev_srv_t *);
+static errno_t ns8250_close(chardev_srv_t *);
 static void ns8250_default_handler(chardev_srv_t *, ipc_callid_t, ipc_call_t *);
 
@@ -324,6 +324,6 @@
 static void ns8250_char_conn(ipc_callid_t, ipc_call_t *, void *);
 
-static int ns8250_dev_add(ddf_dev_t *dev);
-static int ns8250_dev_remove(ddf_dev_t *dev);
+static errno_t ns8250_dev_add(ddf_dev_t *dev);
+static errno_t ns8250_dev_remove(ddf_dev_t *dev);
 
 /** The serial port device driver's standard operations. */
@@ -407,7 +407,7 @@
  * @return		Zero on success, error number otherwise
  */
-static int ns8250_dev_initialize(ns8250_t *ns)
-{
-	int ret = EOK;
+static errno_t ns8250_dev_initialize(ns8250_t *ns)
+{
+	errno_t ret = EOK;
 	
 	ddf_msg(LVL_DEBUG, "ns8250_dev_initialize %s", ddf_dev_get_name(ns->dev));
@@ -501,8 +501,8 @@
  * @return		Zero on success, error number otherwise
  */
-static int ns8250_interrupt_enable(ns8250_t *ns)
+static errno_t ns8250_interrupt_enable(ns8250_t *ns)
 {
 	/* Enable interrupt using IRC service. */
-	int rc = hw_res_enable_interrupt(ns->parent_sess, ns->irq);
+	errno_t rc = hw_res_enable_interrupt(ns->parent_sess, ns->irq);
 	if (rc != EOK)
 		return EIO;
@@ -547,5 +547,5 @@
  *			if the specified baud_rate is not valid).
  */
-static int ns8250_port_set_baud_rate(ns8250_regs_t *regs, unsigned int baud_rate)
+static errno_t ns8250_port_set_baud_rate(ns8250_regs_t *regs, unsigned int baud_rate)
 {
 	uint16_t divisor;
@@ -646,5 +646,5 @@
  *			is invalid.
  */
-static int ns8250_port_set_com_props(ns8250_regs_t *regs, unsigned int parity,
+static errno_t ns8250_port_set_com_props(ns8250_regs_t *regs, unsigned int parity,
     unsigned int word_length, unsigned int stop_bits)
 {
@@ -803,5 +803,5 @@
  * @param ns		Serial port device
  */
-static inline int ns8250_register_interrupt_handler(ns8250_t *ns,
+static inline errno_t ns8250_register_interrupt_handler(ns8250_t *ns,
     cap_handle_t *handle)
 {
@@ -814,5 +814,5 @@
  * @param ns		Serial port device
  */
-static inline int ns8250_unregister_interrupt_handler(ns8250_t *ns)
+static inline errno_t ns8250_unregister_interrupt_handler(ns8250_t *ns)
 {
 	return unregister_interrupt_handler(ns->dev, ns->irq_cap);
@@ -825,5 +825,5 @@
  * @param dev		The serial port device.
  */
-static int ns8250_dev_add(ddf_dev_t *dev)
+static errno_t ns8250_dev_add(ddf_dev_t *dev)
 {
 	ns8250_t *ns = NULL;
@@ -831,5 +831,5 @@
 	bool need_cleanup = false;
 	bool need_unreg_intr_handler = false;
-	int rc;
+	errno_t rc;
 	
 	ddf_msg(LVL_DEBUG, "ns8250_dev_add %s (handle = %d)",
@@ -928,8 +928,8 @@
 }
 
-static int ns8250_dev_remove(ddf_dev_t *dev)
+static errno_t ns8250_dev_remove(ddf_dev_t *dev)
 {
 	ns8250_t *ns = dev_ns8250(dev);
-	int rc;
+	errno_t rc;
 	
 	fibril_mutex_lock(&ns->mutex);
@@ -963,8 +963,8 @@
  * @param srv		Server-side connection structure
  */
-static int ns8250_open(chardev_srvs_t *srvs, chardev_srv_t *srv)
+static errno_t ns8250_open(chardev_srvs_t *srvs, chardev_srv_t *srv)
 {
 	ns8250_t *ns = srv_ns8250(srv);
-	int res;
+	errno_t res;
 	
 	fibril_mutex_lock(&ns->mutex);
@@ -987,5 +987,5 @@
  * @param srv		Server-side connection structure
  */
-static int ns8250_close(chardev_srv_t *srv)
+static errno_t ns8250_close(chardev_srv_t *srv)
 {
 	ns8250_t *data = srv_ns8250(srv);
@@ -1040,5 +1040,5 @@
  * @param stop_bits	The number of stop bits to be used.
  */
-static int ns8250_set_props(ddf_dev_t *dev, unsigned int baud_rate,
+static errno_t ns8250_set_props(ddf_dev_t *dev, unsigned int baud_rate,
     unsigned int parity, unsigned int word_length, unsigned int stop_bits)
 {
@@ -1049,5 +1049,5 @@
 	ns8250_t *data = dev_ns8250(dev);
 	ns8250_regs_t *regs = data->regs;
-	int ret;
+	errno_t ret;
 	
 	fibril_mutex_lock(&data->mutex);
@@ -1072,5 +1072,5 @@
 	ns8250_t *ns8250 = srv_ns8250(srv);
 	sysarg_t method = IPC_GET_IMETHOD(*call);
-	int ret;
+	errno_t ret;
 	unsigned int baud_rate, parity, word_length, stop_bits;
 	
