Пример #1
0
int rawimage_open(disk_image_t *image)
{
    char *name;

    image->type = DISK_IMAGE_TYPE_D81;
    image->tracks = 80;

    name = rawimage_name_get(image);

    blockdev_open(name, &(image->read_only));

    return 0;
}
Пример #2
0
void disk_image_detach_log(disk_image_t *image, signed int lognum,
                           unsigned int unit, const char *type)
{
    switch (image->device) {
      case DISK_IMAGE_DEVICE_FS:
        log_message(lognum, "Unit %d: %s disk image detached: %s.",
                    unit, type, fsimage_name_get(image));
        break;
#ifdef HAVE_RAWDRIVE
      case DISK_IMAGE_DEVICE_RAW:
        log_message(lognum, "Unit %d: %s disk detached (drive: %s).",
                    unit, type, rawimage_name_get(image));
        break;
#endif
    }
}
Пример #3
0
void disk_image_detach_log(disk_image_t *image, signed int lognum,
                           unsigned int unit)
{
    const char *type = disk_image_type(image);

    if (type == NULL) {
        return;
    }

    switch (image->device) {
      case DISK_IMAGE_DEVICE_FS:
        log_verbose("Unit %d: %s disk image detached: %s.",
                    unit, type, fsimage_name_get(image));
        break;
#ifdef HAVE_RAWDRIVE
      case DISK_IMAGE_DEVICE_RAW:
        log_verbose("Unit %d: %s disk detached (drive: %s).",
                    unit, type, rawimage_name_get(image));
        break;
#endif
    }
}