Subversion Repositories HelenOS

Rev

Rev 3598 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3598 Rev 4345
Line 25... Line 25...
25
 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25
 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
27
 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27
 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28
 */
28
 */
29
 
29
 
30
/** @addtogroup libblock
30
/** @addtogroup libblock
31
 * @{
31
 * @{
32
 */
32
 */
33
/**
33
/**
34
 * @file
34
 * @file
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"
40
#include "../../srv/rd/rd.h"
41
#include <ipc/devmap.h>
41
#include <ipc/devmap.h>
42
#include <ipc/services.h>
42
#include <ipc/services.h>
43
#include <errno.h>
43
#include <errno.h>
Line 144... Line 144...
144
    com_area = mmap(NULL, com_size, PROTO_READ | PROTO_WRITE,
144
    com_area = mmap(NULL, com_size, PROTO_READ | PROTO_WRITE,
145
        MAP_ANONYMOUS | MAP_PRIVATE, 0, 0);
145
        MAP_ANONYMOUS | MAP_PRIVATE, 0, 0);
146
    if (!com_area) {
146
    if (!com_area) {
147
        return ENOMEM;
147
        return ENOMEM;
148
    }
148
    }
149
    dev_phone = ipc_connect_me_to(PHONE_NS, SERVICE_DEVMAP,
149
    dev_phone = ipc_connect_me_to_blocking(PHONE_NS, SERVICE_DEVMAP,
150
        DEVMAP_CONNECT_TO_DEVICE, dev_handle);
150
        DEVMAP_CONNECT_TO_DEVICE, dev_handle);
151
 
151
 
152
    if (dev_phone < 0) {
152
    if (dev_phone < 0) {
153
        munmap(com_area, com_size);
153
        munmap(com_area, com_size);
154
        return dev_phone;
154
        return dev_phone;