| /dflybsd-src/sys/sys/ |
| H A D | disk.h | 135 struct disk { struct 148 LIST_ENTRY(disk) d_list; argument 163 cdev_t disk_create (int unit, struct disk *disk, struct dev_ops *raw_ops); argument 164 cdev_t disk_create_clone (int unit, struct disk *disk, struct dev_ops *raw_ops); 165 cdev_t disk_create_named(const char *name, int unit, struct disk *dp, struct dev_ops *raw_ops); 166 cdev_t disk_create_named_clone(const char *name, int unit, struct disk *dp, struct dev_ops *raw_ops… 168 void disk_destroy (struct disk *disk); 169 void disk_setdiskinfo (struct disk *disk, struct disk_info *info); 170 int disk_setdisktype(struct disk *disk, const char *type); 171 int disk_getopencount(struct disk *disk); [all …]
|
| /dflybsd-src/usr.sbin/installer/libinstaller/ |
| H A D | diskutil.h | 49 struct disk; 60 struct disk *disk_head; 61 struct disk *disk_tail; 62 struct disk *selected_disk; 67 struct disk { struct 68 struct disk *next; argument 69 struct disk *prev; argument 84 struct disk *parent; argument 123 struct disk *storage_disk_first(const struct storage *); 124 void storage_set_selected_disk(struct storage *, struct disk *); [all …]
|
| H A D | survey.c | 149 char *disk, *disk_ptr; in survey_storage() local 154 struct disk *d = NULL; in survey_storage() 182 while (!failure && (disk = strsep(&disk_ptr, " ")) != NULL) { in survey_storage() 183 if (disk[0] == '\0') in survey_storage() 189 if (strncmp(disk, "md", 2) == 0 || in survey_storage() 190 strncmp(disk, "cd", 2) == 0 || in survey_storage() 191 strncmp(disk, "acd", 3) == 0 || in survey_storage() 192 strncmp(disk, "fd", 2) == 0) in survey_storage() 195 aura_dict_store(di, disk, strlen(disk) + 1, "", 1); in survey_storage() 209 disk = (char *)rk; in survey_storage() [all …]
|
| H A D | diskutil.c | 119 struct disk * 126 storage_set_selected_disk(struct storage *s, struct disk *d) in storage_set_selected_disk() 131 struct disk * 152 struct disk * 155 struct disk *d; in disk_new() 157 AURA_MALLOC(d, disk); in disk_new() 193 disk_get_desc(const struct disk *d) in disk_get_desc() 199 disk_get_capacity(const struct disk *d) in disk_get_capacity() 206 disk_set_desc(struct disk *d, const char *desc) in disk_set_desc() 235 disk_get_device_name(const struct disk *d) in disk_get_device_name() [all …]
|
| /dflybsd-src/sys/dev/disk/nata/ |
| H A D | ata-raid.c | 149 int disk; in ata_raid_attach() local 170 cdev = disk_create(rdp->lun, &rdp->disk, &ar_ops); in ata_raid_attach() 194 for (disk = 0; disk < rdp->total_disks; disk++) { in ata_raid_attach() 195 kprintf("ar%d: disk%d ", rdp->lun, disk); in ata_raid_attach() 196 if (rdp->disks[disk].dev) { in ata_raid_attach() 197 if (rdp->disks[disk].flags & AR_DF_PRESENT) { in ata_raid_attach() 199 if (rdp->disks[disk].flags & AR_DF_ONLINE) in ata_raid_attach() 201 else if (rdp->disks[disk].flags & AR_DF_SPARE) in ata_raid_attach() 210 if (disk < rdp->width) in ata_raid_attach() 218 device_get_nameunit(rdp->disks[disk].dev), in ata_raid_attach() [all …]
|
| /dflybsd-src/sys/kern/ |
| H A D | subr_disk.c | 116 static int disk_probe_slice(struct disk *dp, cdev_t dev, int slice, int reprobe); 117 static void disk_probe(struct disk *dp, int reprobe); 118 static void _setdiskinfo(struct disk *disk, struct disk_info *info); 122 static cdev_t _disk_create_named(const char *name, int unit, struct disk *dp, 132 static LIST_HEAD(, disk) disklist = LIST_HEAD_INITIALIZER(&disklist); 185 disk_probe_slice(struct disk *dp, cdev_t dev, int slice, int reprobe) in disk_probe_slice() 348 disk_probe(struct disk *dp, int reprobe) in disk_probe() 503 struct disk *dp; in disk_msg_core() 521 dp = (struct disk *)msg->load; in disk_msg_core() 529 dp = (struct disk *)msg->load; in disk_msg_core() [all …]
|
| H A D | subr_diskiocom.c | 77 static int disk_iocom_reconnect(struct disk *dp, struct file *fp); 80 static void disk_blk_open(struct disk *dp, kdmsg_msg_t *msg); 81 static void disk_blk_read(struct disk *dp, kdmsg_msg_t *msg); 82 static void disk_blk_write(struct disk *dp, kdmsg_msg_t *msg); 83 static void disk_blk_flush(struct disk *dp, kdmsg_msg_t *msg); 84 static void disk_blk_freeblks(struct disk *dp, kdmsg_msg_t *msg); 88 disk_iocom_init(struct disk *dp) in disk_iocom_init() 98 disk_iocom_update(struct disk *dp) in disk_iocom_update() 103 disk_iocom_uninit(struct disk *dp) in disk_iocom_uninit() 109 disk_iocom_ioctl(struct disk *dp, u_long cmd, void *data) in disk_iocom_ioctl() [all …]
|
| /dflybsd-src/sys/dev/disk/dm/dmirror/ |
| H A D | dm_target_dmirror.c | 122 dmirror_disk_t disk; in dmirror_write_done() local 127 disk = dmirror_get_bio_disk(bio); in dmirror_write_done() 140 dmirror_issue_write(dmirror_disk_t disk, struct bio *bio) in dmirror_issue_write() argument 142 dmirror_set_bio_disk(bio, disk); in dmirror_issue_write() 146 vn_strategy(disk->pdev, bio); in dmirror_issue_write() 152 dmirror_disk_t disk, m_disk; in dmirror_write() local 158 disk = &config->disks[i]; in dmirror_write() 159 segdesc = SEGDESC_FROM_OFFSET(disk, bio->bio_offset); in dmirror_write() 162 m_disk = disk; in dmirror_write() 181 segdesc_set_flag(dmirror_disk_t disk, off_t segno, int flag) in segdesc_set_flag() argument [all …]
|
| /dflybsd-src/share/examples/rconfig/ |
| H A D | hammer_uefi.sh | 16 set disk = "ad6" 27 echo "This program formats disk ${disk}! Hit ^C now or its gone." 54 dd if=/dev/zero of=/dev/${disk} bs=32k count=16 55 gpt destroy ${disk} 56 gpt create -f ${disk} 57 gpt add -i 0 -s 262144 -t efi ${disk} 58 gpt add -i 1 -t dragonfly ${disk} 59 newfs_msdos -F 32 -c 2 -L EFI -m 0xf8 ${disk}s0 60 mount_msdos /dev/${disk}s0 /mnt 64 disklabel64 -r -w ${disk}s1 [all …]
|
| H A D | hammer_lvm_stripe.sh | 115 local disk=$1 118 if [ ! "$disk" = "" ]; then 119 mount | fgrep ${disk} >> ${logfile} 2>&1 122 err 1 "${disk} is already being used, aborting" 127 bootdisk=${disk} 130 dd if=/dev/zero of=/dev/${disk} bs=32k count=16 >> ${logfile} 2>&1 133 fdisk -IB ${disk} >> ${logfile} 2>&1 136 disklabel -r -w ${disk}s1 >> ${logfile} 2>&1 140 disklabel -B ${disk}s1 >> ${logfile} 2>&1 154 local disk=$1 [all …]
|
| H A D | hammer.sh | 16 set disk = "ad6" 27 echo "This program formats disk ${disk}! Hit ^C now or its gone." 54 dd if=/dev/zero of=/dev/${disk} bs=32k count=16 55 fdisk -IB ${disk} 56 disklabel64 -r -w ${disk}s1 57 disklabel64 -B ${disk}s1 58 disklabel64 ${disk}s1 > /tmp/label 65 disklabel64 -R ${disk}s1 /tmp/label 68 newfs /dev/${disk}s1a 69 newfs_hammer -f -L ROOT /dev/${disk}s1d [all …]
|
| H A D | hammer_ccd_mirror.sh | 118 local disk=$1 121 if [ ! "$disk" = "" ]; then 122 mount | fgrep ${disk} >> ${logfile} 2>&1 125 err 1 "${disk} is already being used, aborting" 130 bootdisk=${disk} 133 dd if=/dev/zero of=/dev/${disk} bs=32k count=16 >> ${logfile} 2>&1 136 fdisk -IB ${disk} >> ${logfile} 2>&1 139 disklabel -r -w ${disk}s1 >> ${logfile} 2>&1 143 disklabel -B ${disk}s1 >> ${logfile} 2>&1 157 local disk=$1 [all …]
|
| H A D | encrypted_root.sh | 21 set disk = "ad0" 32 echo "This program formats disk ${disk}! Hit ^C now or its gone." 59 dd if=/dev/zero of=/dev/${disk} bs=32k count=16 60 fdisk -IB ${disk} 61 disklabel64 -r -w ${disk}s1 62 disklabel64 -B ${disk}s1 63 disklabel64 ${disk}s1 > /tmp/label 70 disklabel64 -R ${disk}s1 /tmp/label 72 newfs /dev/${disk}s1a 77 cryptsetup -y luksFormat /dev/${disk}s1d [all …]
|
| /dflybsd-src/usr.sbin/boot0cfg/ |
| H A D | boot0cfg.c | 92 char *disk; in main() local 142 disk = getdevpath(*argv, 0); in main() 143 if (!disk) in main() 144 err(1, "cannot open disk %s", disk); in main() 150 mbr_size = read_mbr(disk, &mbr, !B_flag); in main() 195 write_mbr(disk, 0, boot0, boot0_size); in main() 205 free(disk); in main() 216 read_mbr(const char *disk, u_int8_t **mbr, int check_version) in read_mbr() argument 222 if ((fd = open(disk, O_RDONLY)) == -1) in read_mbr() 223 err(1, "open %s", disk); in read_mbr() [all …]
|
| /dflybsd-src/lib/libefivar/ |
| H A D | efivar-dp-xlate.c | 69 char *disk, *disk_ptr, *s; in find_slice_by_efimedia() local 80 while ((disk = strsep(&disk_ptr, " ")) != NULL) { in find_slice_by_efimedia() 81 if (disk[0] == '\0') in find_slice_by_efimedia() 83 if (strncmp(disk, "md", 2) == 0 || in find_slice_by_efimedia() 84 strncmp(disk, "cd", 2) == 0 || in find_slice_by_efimedia() 85 strncmp(disk, "acd", 3) == 0 || in find_slice_by_efimedia() 86 strncmp(disk, "fd", 2) == 0) in find_slice_by_efimedia() 88 snprintf(dev_path, sizeof(dev_path), "%s%s", _PATH_DEV, disk); in find_slice_by_efimedia() 107 _PATH_DEV, disk, m->map_index); in find_slice_by_efimedia() 429 char *disk, *disk_ptr, *ep, *s; in find_slice_efimedia() local [all …]
|
| /dflybsd-src/contrib/lvm2/dist/lib/format1/ |
| H A D | disk-rep.c | 26 #define xx16(v) disk->v = xlate16(disk->v) 27 #define xx32(v) disk->v = xlate32(disk->v) 28 #define xx64(v) disk->v = xlate64(disk->v) 35 static void _xlate_pvd(struct pv_disk *disk) in _xlate_pvd() argument 62 static void _xlate_lvd(struct lv_disk *disk) in _xlate_lvd() argument 85 static void _xlate_vgd(struct vg_disk *disk) in _xlate_vgd() argument 219 static int _read_lvd(struct device *dev, uint64_t pos, struct lv_disk *disk) in _read_lvd() argument 221 if (!dev_read(dev, pos, sizeof(*disk), disk)) in _read_lvd() 224 _xlate_lvd(disk); in _read_lvd() 554 static int _write_lvd(struct device *dev, uint64_t pos, struct lv_disk *disk) in _write_lvd() argument [all …]
|
| /dflybsd-src/sbin/hammer2/ |
| H A D | cmd_service.c | 62 char *disk; member 94 static void disk_reconnect(const char *disk); 753 char *disk; in udev_check_disks() local 780 for (disk = strtok(buf, WS); disk; disk = strtok(NULL, WS)) { in udev_check_disks() 781 disk_reconnect(disk); in udev_check_disks() 847 disk_reconnect(const char *disk) in disk_reconnect() argument 862 if (strncmp(disk, "md", 2) == 0) in disk_reconnect() 864 if (strncmp(disk, "xa", 2) == 0) in disk_reconnect() 872 if (strcmp(dc->disk, disk) == 0) in disk_reconnect() 883 asprintf(&path, "/dev/%s", disk); in disk_reconnect() [all …]
|
| /dflybsd-src/sbin/fsck/ |
| H A D | preen.c | 55 struct disk { struct 57 struct disk *next; /* forward link for list of disks */ argument 65 static struct disk *finddisk(char *name); argument 66 static int startdisk(struct disk *dk, 74 struct disk *dk, *nextdisk; in checkfstab() 193 static struct disk * 196 struct disk *dk, **dkp; in finddisk() 212 if ((*dkp = (struct disk *)malloc(sizeof(struct disk))) == NULL) { in finddisk() 233 struct disk *dk = finddisk(name); in addpart() 261 startdisk(struct disk *dk, int (*checkit)(char *, char *, long ,int)) in startdisk()
|
| /dflybsd-src/contrib/file/magic/Magdir/ |
| H A D | amigaos | 15 >>48 byte 1 disk icon 106 # Amiga disk types 107 # display information like volume name of root block on Amiga (floppy) disk 139 # https://reposcope.com/mimetype/application/x-amiga-disk-format 140 !:mime application/x-amiga-disk-format 142 >>3 ubyte 0 DOS disk 143 >>3 ubyte 1 FFS disk 144 >>3 ubyte 2 Inter DOS disk 145 >>3 ubyte 3 Inter FFS disk 147 >>3 ubyte 4 Fastdir DOS disk [all …]
|
| /dflybsd-src/sbin/dump/ |
| H A D | main.c | 64 char *disk; /* name of the disk file */ variable 227 disk = *argv++; in main() 307 dt = fstabsearch(disk); in main() 309 disk = rawname(dt->fs_spec); in main() 313 strncpy(spcl.c_dev, disk, NAMELEN); in main() 329 msg("Dumping %s ", disk); in main() 337 if ((diskfd = open(disk, O_RDONLY)) < 0) in main() 338 err(X_STARTUP, "Cannot open %s", disk); in main() 340 err(X_STARTUP, "%s: stat", disk); in main() 342 errx(X_STARTUP, "%s: unknown file system", disk); in main() [all …]
|
| /dflybsd-src/stand/boot/pc32/loader/ |
| H A D | help.i386 | 31 # Tbcachestat DDisplay disk block cache stats 35 Display disk block cache stats. For debugging use only. 52 When booting from a SCSI disk on a system with one or more IDE disks, 55 correctly locate the SCSI disk you are booting from. 58 # Tset Sroot_disk_unit DForce the root disk unit number. 62 If the code which detects the disk unit number for the root disk is
|
| /dflybsd-src/sys/dev/raid/hptmv/ |
| H A D | gui_lib.c | 284 pSataChannel = pVDevice->u.disk.mv; in get_disk_info() 300 if (pVDevice->u.disk.df_user_mode_set) in get_disk_info() 301 pDiskInfo->DeviceModeSetting = pVDevice->u.disk.bDeUserSelectMode; in get_disk_info() 302 else if (((((PIDENTIFY_DATA)pVDevice->u.disk.mv->identifyDevice)->SataCapability) & 3)==2) in get_disk_info() 305 p = (char *)&((PIDENTIFY_DATA)pVDevice->u.disk.mv->identifyDevice)->ModelNumber; in get_disk_info() 310 pDiskInfo->DeviceModeSetting = pVDevice->u.disk.bDeModeSetting; in get_disk_info() 313 pDiskInfo->UsableMode = pVDevice->u.disk.bDeUsable_Mode; in get_disk_info() 320 if(!pVDevice->u.disk.df_on_line) in get_disk_info() 532 pInfo->Capacity = pVDevice->u.disk.dDeRealCapacity; in hpt_get_device_info() 557 pInfo->Capacity.lo32 = pVDevice->u.disk.dDeRealCapacity; in hpt_get_device_info_v2() [all …]
|
| /dflybsd-src/usr.sbin/makefs/cd9660/ |
| H A D | cd9660_eltorito.c | 273 cd9660_boot_setup_default_entry(struct cd9660_boot_image *disk) in cd9660_boot_setup_default_entry() argument 285 ie->boot_indicator[0] = disk->bootable; in cd9660_boot_setup_default_entry() 286 ie->media_type[0] = disk->targetMode; in cd9660_boot_setup_default_entry() 287 cd9660_721(disk->loadSegment, ie->load_segment); in cd9660_boot_setup_default_entry() 288 ie->system_type[0] = disk->system; in cd9660_boot_setup_default_entry() 289 cd9660_721(disk->num_sectors, ie->sector_count); in cd9660_boot_setup_default_entry() 290 cd9660_731(disk->sector, ie->load_rba); in cd9660_boot_setup_default_entry() 295 ie->media_type[0], disk->loadSegment, ie->system_type[0], in cd9660_boot_setup_default_entry() 296 disk->num_sectors, disk->sector)); in cd9660_boot_setup_default_entry() 323 cd9660_boot_setup_section_entry(struct cd9660_boot_image *disk) in cd9660_boot_setup_section_entry() argument [all …]
|
| /dflybsd-src/contrib/lvm2/dist/udev/ |
| H A D | 13-dm-disk.rules | 7 # These rules create symlinks in /dev/disk directory. 17 SYMLINK+="disk/by-id/dm-name-$env{DM_NAME}" 18 ENV{DM_UUID}=="?*", SYMLINK+="disk/by-id/dm-uuid-$env{DM_UUID}" 24 ENV{ID_FS_USAGE}=="filesystem|other|crypto", ENV{ID_FS_UUID_ENC}=="?*", SYMLINK+="disk/by-uuid/$env… 25 ENV{ID_FS_USAGE}=="filesystem|other", ENV{ID_FS_LABEL_ENC}=="?*", SYMLINK+="disk/by-label/$env{ID_F…
|
| /dflybsd-src/sbin/natacontrol/ |
| H A D | natacontrol.c | 338 int disk, fd; in open_dev() local 341 if (!(sscanf(arg, "ad%d", &disk) == 1 || in open_dev() 342 sscanf(arg, "acd%d", &disk) == 1 || in open_dev() 343 sscanf(arg, "afd%d", &disk) == 1 || in open_dev() 344 sscanf(arg, "ast%d", &disk) == 1)) { in open_dev() 515 int disk, dev, offset; in main() local 561 for (disk = 0; disk < 16 && (offset + disk) < argc; disk++) { in main() 562 if (!(sscanf(argv[offset + disk], "ad%d", &dev) == 1)) { in main() 565 argv[offset + disk]); in main() 568 config.disks[disk] = dev; in main() [all …]
|