Linux Sparc & Sun Disklabel Issue
Doug Goldstein
cardoe at gentoo.org
Thu Apr 26 12:55:08 PDT 2007
Artem Kachitchkine wrote:
>
>> I'm hoping some of our Sun guys can peek at this and confirm if it's an
>> issue with HAL processing Sun disklabels.
>
> I don't know much about how Linux represents partitioned disks, but
> looking at probe-storage.c and probe-volume.c, HAL on Linux appears to
> rely on partutil. In particular, part_get_scheme_name(). Looking at
> partutil.h:
>
> /* Partition schemes understood by this library */
> typedef enum {
> PART_TYPE_MSDOS = 0,
> PART_TYPE_MSDOS_EXTENDED = 1,
> PART_TYPE_APPLE = 2,
> PART_TYPE_GPT = 3
> } PartitionScheme;
>
> I'd say you want to add VTOC type here, some code to recognize it, and
> yet some more code to probe-{storage,volume} (and keep in mind that on
> x86, VTOC can be embedded in a DOS partition).
>
> -Artem.
>
I think it is being contained within a DOS partition.... since partition
type 5 is a DOS partition type..
/sys/block/sda
|-- dev
|-- device -> ../../devices/platform/host0/target0:0:1/0:0:1:0
|-- queue
| |-- iosched
| | |-- antic_expire
| | |-- est_time
| | |-- read_batch_expire
| | |-- read_expire
| | |-- write_batch_expire
| | `-- write_expire
| |-- max_hw_sectors_kb
| |-- max_sectors_kb
| |-- nr_requests
| |-- read_ahead_kb
| `-- scheduler
|-- range
|-- removable
|-- sda1
| |-- dev
| |-- size
| |-- start
| |-- stat
| `-- uevent
|-- sda2
| |-- dev
| |-- size
| |-- start
| |-- stat
| `-- uevent
|-- sda3
| |-- dev
| |-- size
| |-- start
| |-- stat
| `-- uevent
|-- sda4
| |-- dev
| |-- size
| |-- start
| |-- stat
| `-- uevent
|-- sda5
| |-- dev
| |-- size
| |-- start
| |-- stat
| `-- uevent
|-- size
|-- stat
`-- uevent
===================================
polylepis ~ # fdisk /dev/sda
Command (m for help): p
Disk /dev/sda (Sun disk label): 27 heads, 107 sectors, 49242 cylinders
Units = cylinders of 2889 * 512 bytes
Device Flag Start End Blocks Id System
/dev/sda1 0 43 62113+ 83 Linux native
/dev/sda2 u 43 44 1444+ 82 Linux swap
/dev/sda3 0 49242 71130069 5 Whole disk
/dev/sda4 44 26410 38085687 83 Linux native
/dev/sda5 26410 49242 32980824 83 Linux native
====================================
Expert command (m for help): p
Disk /dev/sda (Sun disk label): 27 heads, 107 sectors, 15000 rpm
49242 cylinders, 2 alternate cylinders, 49244 physical cylinders
0 extra sects/cyl, interleave 1:1
Linux custom cyl 49242 alt 2 hd 27 sec 107
Units = cylinders of 2889 * 512 bytes
Device Flag Start End Blocks Id System
/dev/sda1 0 43 62113+ 83 Linux native
/dev/sda2 u 43 44 1444+ 82 Linux swap
/dev/sda3 0 49242 71130069 5 Whole disk
/dev/sda4 44 26410 38085687 83 Linux native
/dev/sda5 26410 49242 32980824 83 Linux native
======================================
More information about the hal
mailing list