size of a char devices

hi
i want to write a simple io-benchmark for raw devices, especially for
harddisks, vx-volumes and md-volumes on solaris.
is there a unix system call to get the size of the device? the 'stat' system call
reports the size for regaular files but not for block or devices. On Solaris the Unix-command to get this information is devinfo -p [device] (or
prtvtoc [device].
if I 'truss' the devinfo command i can see that the program gets the information calling
open("/dev/vx/rdsk/perfdg/perfvol01", O_RDONLY) = 3
ioctl(3, 0x0401, 0xFFBEFB64) = 0
ioctl(3, 0x040B, 0xFFBEF9B8) = 0
ioctl(3, 0x0403, 0xFFBEF824) = 0
stat("/dev/vx/rdsk/perfdg/perfvol01", 0xFFBEF930) = 0
...
close(3) = 0

but i dont know nothing about ioctl-parameters. has someone a hint?
guenter

See this link:

http://bama.ua.edu/cgi-bin/man-cgi?ioctl

thanks, but this is the manual page for ioctl(29 that I knew already.
in the meantime I found the answer: the intergace is documented in
/usr/include/sys/dkio.h. the ioctl-calls are
#define DKIOCGGEOM (DKIOC|1) /* Get geometry /
#define DKIOCINFO (DKIOC|3) /
Get info /
#define DKIOCGVTOC (DKIOC|11) /
Get VTOC */
guenter