libcdio-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Libcdio-devel] Re: libcdio-0.83git on Solaris snv134 sees no drives


From: Thomas Schmitt
Subject: [Libcdio-devel] Re: libcdio-0.83git on Solaris snv134 sees no drives
Date: Wed, 02 Jun 2010 20:25:21 +0200

Hi,

Dagobert Michelsen wrote:
> I wrote an (unfinished) cd access library a long time ago and used
>    error = di_walk_minor( rootnode, DDI_NT_CD_CHAN, 0, &result, 
> &devtToNodepathCallback );
> to find cd/dvd drives. di_walk_minor is a function from libdevinfo(3lib)
> where di_walk_minor(3devinfo) is used to select all nodes with a minor
> device nodetype of DDI_NT_CD_CHAN which happens to be exactly the
> wanted devices.

The man page of libdevinfo on my system looks
indeed very promising.

  ldd /usr/bin/cdrecord.bin
shows that it rather uses libvolmgt which by its
function
   media_findname()
probably could be used to enumerate "cdrom0"
... "cdromN" for getting their device paths.
This function is declared obsolete in its man
page. (One shall use HAL. (shudder))


To Rocky:

Will a dependency on libdevinfo be acceptable ?

How is such a dependency introduced properly ?

Shall i keep my current (stinky) device lister
as fallback ?
(It is used if no /vol directory exists.)


------------------------------------------------

I found man page uscsi(7I) 
  http://docs.sun.com/app/docs/doc/816-5177/uscsi-7i?a=view
which explains a lot of what growisofs does on
Solaris.
It also brings clarity about the last component
"Slice" of the device name (...s2 ? ...s0 ?):
  "the block numbers are absolute block numbers
   on the drive regardless of which slice number
   is used"

I prepared access modes MMC_RDWR and
MMC_RDWR_EXCL (which both seem to need no
w-permission) and also prepared receiving of
SCSI sense reply.

Currently xorriso is a bit too smart-assed when
dealing with the drive addresses provided by
libcdio. Nevertheless it begins to work:

  $ pfexec xorriso/xorriso -devices
  ... waiting ... waiting ... waiting ...
  Full drive scan done
  -----------------------------------------------------------------------------
  0  -dev 
'/dev/rdsk/../../devices/address@hidden,0/pci1458,address@hidden/address@hidden,0:c,raw'
 r----- :  'TSSTcorp' 'CDDVDW SH-S223B' 
  1  -dev 
'/dev/rdsk/../../devices/address@hidden,0/address@hidden,1/address@hidden/address@hidden,0:c,raw'
 r----- :  'TSSTcorp' 'DVD-ROM SH-D162C' 
  -----------------------------------------------------------------------------

  $ pfexec xorriso/xorriso \
    -dev 
'/dev/rdsk/../../devices/address@hidden,0/pci1458,address@hidden/address@hidden,0:c,raw'
 \
    -toc
  ... cooking a simple meal in the meantime ...
  Drive current: -outdev 
'/dev/rdsk/../../devices/address@hidden,0/pci1458,address@hidden/address@hidden,0:c,raw'
  Drive type   : vendor 'TSSTcorp' product 'CDDVDW SH-S223B' revision 'SB02'
  Media current: CD-RW
  Media product: 97m15s35f/79m59s74f , Nan-Ya Plastics Corporation
  Media status : is written , is appendable
  TOC layout   : Idx ,  sbsector ,       Size , Volume Id
  ISO session  :   1 ,         0 ,     79476s , FREEBSD1_HOME_2010_05_08_212407
  ISO session  :   2 ,     91026 ,      9896s , FREEBSD1_HOME_2010_05_08_221606
  ISO session  :   3 ,    107974 ,      2850s , FREEBSD1_HOME_2010_05_08_221929
  ISO session  :   4 ,    117876 ,      2851s , FREEBSD1_HOME_2010_05_08_225714
  ISO session  :   5 ,    127779 ,      1989s , FREEBSD1_HOME_2010_05_08_230413
  ISO session  :   6 ,    136820 ,      5890s , FREEBSD1_HOME_2010_05_09_133322
  Media summary: 6 sessions, 103862 data blocks,  203m data,  410m free
  Media nwa    : 149762s
  $

------------------------------------------------

Now i need to salvage the speed of getting the
device list and teach libburn/sg-libcdio.c not
to resolve the /dev/cXtXd0s2 softlinks to the
ugly actual device paths.


Have a nice day :)

Thomas




reply via email to

[Prev in Thread] Current Thread [Next in Thread]