Rev 4001 | Rev 4401 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
| Rev 4001 | Rev 4400 | ||
|---|---|---|---|
| Line 35... | Line 35... | ||
| 35 | * @brief |
35 | * @brief |
| 36 | */ |
36 | */ |
| 37 | 37 | ||
| 38 | #include "libblock.h" |
38 | #include "libblock.h" |
| 39 | #include "../../srv/vfs/vfs.h" |
39 | #include "../../srv/vfs/vfs.h" |
| 40 | #include "../../srv/rd/rd.h" |
- | |
| 41 | #include <ipc/devmap.h> |
40 | #include <ipc/devmap.h> |
| - | 41 | #include <ipc/bd.h> |
|
| 42 | #include <ipc/services.h> |
42 | #include <ipc/services.h> |
| 43 | #include <errno.h> |
43 | #include <errno.h> |
| 44 | #include <sys/mman.h> |
44 | #include <sys/mman.h> |
| 45 | #include <async.h> |
45 | #include <async.h> |
| 46 | #include <ipc/ipc.h> |
46 | #include <ipc/ipc.h> |
| Line 475... | Line 475... | ||
| 475 | } |
475 | } |
| 476 | 476 | ||
| 477 | if (*bufpos == *buflen) { |
477 | if (*bufpos == *buflen) { |
| 478 | /* Refill the communication buffer with a new block. */ |
478 | /* Refill the communication buffer with a new block. */ |
| 479 | ipcarg_t retval; |
479 | ipcarg_t retval; |
| 480 | int rc = async_req_2_1(devcon->dev_phone, RD_READ_BLOCK, |
480 | int rc = async_req_2_1(devcon->dev_phone, BD_READ_BLOCK, |
| 481 | *pos / block_size, block_size, &retval); |
481 | *pos / block_size, block_size, &retval); |
| 482 | if ((rc != EOK) || (retval != EOK)) |
482 | if ((rc != EOK) || (retval != EOK)) |
| 483 | return (rc != EOK ? rc : retval); |
483 | return (rc != EOK ? rc : retval); |
| 484 | 484 | ||
| 485 | *bufpos = 0; |
485 | *bufpos = 0; |