Lines Matching full:partition
96 * As the GPT backup partition is located at the end of the disk, in ptblread()
234 int rc, slice, partition; in disk_open() local
262 partition = dev->d_partition; in disk_open()
264 DPRINTF("%s unit %d, slice %d, partition %d => %p", disk_fmtdev(dev), in disk_open()
271 DPRINTF("Can't read partition table"); in disk_open()
283 partition >= 0) { in disk_open()
285 rc = ptable_getpart(od->table, &part, partition); in disk_open()
294 /* Try to get information about partition */ in disk_open()
299 if (rc != 0) /* Partition doesn't exist */ in disk_open()
305 partition = D_PARTISGPT; in disk_open()
307 } else if (partition == D_PARTISGPT) { in disk_open()
309 * When we try to open GPT partition, but partition in disk_open()
310 * table isn't GPT, reset partition value to in disk_open()
313 partition = D_PARTWILD; in disk_open()
317 * If partition is D_PARTNONE, then disk_open() was called in disk_open()
320 if (partition == D_PARTNONE) in disk_open()
324 * If partition is D_PARTWILD and we are looking at a BSD slice, in disk_open()
328 if (partition == D_PARTWILD && in disk_open()
340 * If slice contains BSD label and partition < 0, then in disk_open()
341 * assume the 'a' partition. Otherwise just return the in disk_open()
344 if (partition < 0) { in disk_open()
347 partition = 0; in disk_open()
349 rc = ptable_getpart(table, &part, partition); in disk_open()
365 /* Save the slice and partition number to the dev */ in disk_open()
367 dev->d_partition = partition; in disk_open()
415 int unit, slice, partition; in disk_parsedev() local
424 * slice or partition info should be considered a request to search for in disk_parsedev()
425 * an appropriate partition. Otherwise we want to open the raw device in disk_parsedev()
430 partition = D_PARTWILD; in disk_parsedev()
433 partition = D_PARTNONE; in disk_parsedev()
449 partition = D_PARTISGPT; in disk_parsedev()
461 partition = *cp - 'a'; in disk_parsedev()
462 if (partition < 0) in disk_parsedev()
476 dev->d_partition = partition; in disk_parsedev()