3 #include <minix/vfsif.h>
4 #include <minix/bdev.h>
7 /*===========================================================================*
9 *===========================================================================*/
12 /* Always mounted read only, so nothing to sync */
13 return(OK
); /* sync() can't fail */
17 /*===========================================================================*
19 *===========================================================================*/
20 int fs_new_driver(void)
22 /* Set a new driver endpoint for this device. */
24 cp_grant_id_t label_gid
;
26 char label
[sizeof(fs_dev_label
)];
29 dev
= fs_m_in
.m_vfs_fs_new_driver
.device
;
30 label_gid
= fs_m_in
.m_vfs_fs_new_driver
.grant
;
31 label_len
= fs_m_in
.m_vfs_fs_new_driver
.path_len
;
33 if (label_len
> sizeof(label
))
36 r
= sys_safecopyfrom(fs_m_in
.m_source
, label_gid
, (vir_bytes
) 0,
37 (vir_bytes
) label
, label_len
);
40 printf("ISOFS: fs_new_driver safecopyfrom failed (%d)\n", r
);
44 bdev_driver(dev
, label
);