diff options
Diffstat (limited to 'arch/um/drivers/ubd_kern.c')
-rw-r--r-- | arch/um/drivers/ubd_kern.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/arch/um/drivers/ubd_kern.c b/arch/um/drivers/ubd_kern.c index 614fe25a31bd..70509ddaac03 100644 --- a/arch/um/drivers/ubd_kern.c +++ b/arch/um/drivers/ubd_kern.c | |||
@@ -511,8 +511,8 @@ static void ubd_handler(void) | |||
511 | int n; | 511 | int n; |
512 | 512 | ||
513 | while(1){ | 513 | while(1){ |
514 | n = os_read_file_k(thread_fd, &req, | 514 | n = os_read_file(thread_fd, &req, |
515 | sizeof(struct io_thread_req *)); | 515 | sizeof(struct io_thread_req *)); |
516 | if(n != sizeof(req)){ | 516 | if(n != sizeof(req)){ |
517 | if(n == -EAGAIN) | 517 | if(n == -EAGAIN) |
518 | break; | 518 | break; |
@@ -1112,8 +1112,8 @@ static void do_ubd_request(request_queue_t *q) | |||
1112 | (unsigned long long) req->sector << 9, | 1112 | (unsigned long long) req->sector << 9, |
1113 | sg->offset, sg->length, sg->page); | 1113 | sg->offset, sg->length, sg->page); |
1114 | 1114 | ||
1115 | n = os_write_file_k(thread_fd, &io_req, | 1115 | n = os_write_file(thread_fd, &io_req, |
1116 | sizeof(struct io_thread_req *)); | 1116 | sizeof(struct io_thread_req *)); |
1117 | if(n != sizeof(struct io_thread_req *)){ | 1117 | if(n != sizeof(struct io_thread_req *)){ |
1118 | if(n != -EAGAIN) | 1118 | if(n != -EAGAIN) |
1119 | printk("write to io thread failed, " | 1119 | printk("write to io thread failed, " |
@@ -1366,8 +1366,8 @@ static int update_bitmap(struct io_thread_req *req) | |||
1366 | return 1; | 1366 | return 1; |
1367 | } | 1367 | } |
1368 | 1368 | ||
1369 | n = os_write_file_k(req->fds[1], &req->bitmap_words, | 1369 | n = os_write_file(req->fds[1], &req->bitmap_words, |
1370 | sizeof(req->bitmap_words)); | 1370 | sizeof(req->bitmap_words)); |
1371 | if(n != sizeof(req->bitmap_words)){ | 1371 | if(n != sizeof(req->bitmap_words)){ |
1372 | printk("do_io - bitmap update failed, err = %d fd = %d\n", -n, | 1372 | printk("do_io - bitmap update failed, err = %d fd = %d\n", -n, |
1373 | req->fds[1]); | 1373 | req->fds[1]); |
@@ -1411,7 +1411,7 @@ void do_io(struct io_thread_req *req) | |||
1411 | do { | 1411 | do { |
1412 | buf = &buf[n]; | 1412 | buf = &buf[n]; |
1413 | len -= n; | 1413 | len -= n; |
1414 | n = os_read_file_k(req->fds[bit], buf, len); | 1414 | n = os_read_file(req->fds[bit], buf, len); |
1415 | if (n < 0) { | 1415 | if (n < 0) { |
1416 | printk("do_io - read failed, err = %d " | 1416 | printk("do_io - read failed, err = %d " |
1417 | "fd = %d\n", -n, req->fds[bit]); | 1417 | "fd = %d\n", -n, req->fds[bit]); |
@@ -1421,7 +1421,7 @@ void do_io(struct io_thread_req *req) | |||
1421 | } while((n < len) && (n != 0)); | 1421 | } while((n < len) && (n != 0)); |
1422 | if (n < len) memset(&buf[n], 0, len - n); | 1422 | if (n < len) memset(&buf[n], 0, len - n); |
1423 | } else { | 1423 | } else { |
1424 | n = os_write_file_k(req->fds[bit], buf, len); | 1424 | n = os_write_file(req->fds[bit], buf, len); |
1425 | if(n != len){ | 1425 | if(n != len){ |
1426 | printk("do_io - write failed err = %d " | 1426 | printk("do_io - write failed err = %d " |
1427 | "fd = %d\n", -n, req->fds[bit]); | 1427 | "fd = %d\n", -n, req->fds[bit]); |
@@ -1451,7 +1451,7 @@ int io_thread(void *arg) | |||
1451 | 1451 | ||
1452 | ignore_sigwinch_sig(); | 1452 | ignore_sigwinch_sig(); |
1453 | while(1){ | 1453 | while(1){ |
1454 | n = os_read_file_k(kernel_fd, &req, | 1454 | n = os_read_file(kernel_fd, &req, |
1455 | sizeof(struct io_thread_req *)); | 1455 | sizeof(struct io_thread_req *)); |
1456 | if(n != sizeof(struct io_thread_req *)){ | 1456 | if(n != sizeof(struct io_thread_req *)){ |
1457 | if(n < 0) | 1457 | if(n < 0) |
@@ -1465,7 +1465,7 @@ int io_thread(void *arg) | |||
1465 | } | 1465 | } |
1466 | io_count++; | 1466 | io_count++; |
1467 | do_io(req); | 1467 | do_io(req); |
1468 | n = os_write_file_k(kernel_fd, &req, | 1468 | n = os_write_file(kernel_fd, &req, |
1469 | sizeof(struct io_thread_req *)); | 1469 | sizeof(struct io_thread_req *)); |
1470 | if(n != sizeof(struct io_thread_req *)) | 1470 | if(n != sizeof(struct io_thread_req *)) |
1471 | printk("io_thread - write failed, fd = %d, err = %d\n", | 1471 | printk("io_thread - write failed, fd = %d, err = %d\n", |