Bug 154783

Summary: cdrecord[-dvd] no DVD-R-writing possible.
Product: [openSUSE] SUSE LINUX 10.0 Reporter: Thomas Bruecker <tbruecker>
Component: OtherAssignee: Ladislav Michnovic <lmichnovic>
Status: RESOLVED WONTFIX QA Contact: E-mail List <qa-bugs>
Severity: Minor    
Priority: P5 - None    
Version: Final   
Target Milestone: ---   
Hardware: i586   
OS: SuSE Linux 10.0   
Whiteboard:
Found By: Other Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Thomas Bruecker 2006-03-02 18:22:05 UTC
* command: "cdrecord-dvd -dao -dummy a_file". - several messages. I focus on:
"cdrecord-dvd: Found DVD media but DVD-R/DVD-RW support code is missing."
* driver by cdrecord-dvd: "SCSI-3/mmc CD/DVD driver (...) (mmc_cd_dvd) .
* according to "cdrecord-2.01-7.src.rpm/.../cdrecord.spec, line# 10:
"Source10:     cdrtools-%{version}-dvd.patch.bz2", it seems that you
have applied this patch to "binary cdrecord" resulting in
"binary cdrecord-dvd".
these patches contain a patch for"cdrtools-2.01/cdrecord/drv_mmc.c".
in this drv_mmc.c-patch, a driver "generic SCSI-3/mmc DVD-R(W) driver",
"mmc_mdvd" is added.
* " strings /.../cdrecord-dvd | grep mmc_cd_dvd " returns mmc_cd_dvd .
* " strings /.../cdrecord-dvd | grep mmc_mdvd " returns "nothing" .
I suppose that you did not apply the drv_mmc.c-patch ?
I not very carefully applied the patches ...-dvd.patch.bz2 but not
the other patches (I am not an expert) and compiled cdrecord.
* " strings /.../cdrecord-dvd | grep mmc_mdvd " now returns mmc_dvd .
* writing to the DVD-R again with the command at top, now returned
  the acknowledge of a written Track 01. - Guess applyin all the
  other patches would result in working?
PS: in the patched drv_mmc.c "check_writemodes_mdvd" is first  
    declared with the specifier "EXPORT" but at line# 1095 with the
    specifier "LOCAL" resulting in a compilation error.
Comment 1 Michael Gross 2006-03-03 13:19:34 UTC
Please try to format your text more readable, e.g. For output use at least one empty line to seperate it from your description.

However the problem is not clear. Most drives should be supported with the MMC driver, though there might be some models which require another driver or are unsupported. Which drive do you own (`hwininfo --cdrom'). Please be more verbose about the problem.
Comment 2 Thomas Bruecker 2006-03-03 16:14:14 UTC
* installed package:            cdrecord-2.01-7.i586.rpm
* corresponding source package: cdrecord-2.01-7.src.rpm
  i call this source package further: "cdrSP" .
* cdrom-drive:                  _NEC DVD+/-RW ND-6650A

* i add to the bug summary: writing to DVD-RW and DVD+RW is not possible.

* using cdrecord-dvd from the installed package, i have wanted to write to a
  DVD and i have entered the command line:
    cdrecord-dvd -dao -dummy a_file

* after this command, cdrecord-dvd says many things, i think important is:
  ...
  Device seems to be: Generic mmc2 DVD-R/DVD-RW.
  cdrecord-dvd: Found DVD media but DVD-R/DVD-RW support code is missing.
  ...
  Using generic SCSI-3/mmc CD/DVD driver (checks media) (mmc_cd_dvd).
  ...
  cdrecord-dvd: A write error ocurred.

* proposition: my NEC-cdrom-device needs the driver 
  "generic SCSI-3/mmc DVD-R(W) driver (mmc_mdvd)" .

* to verify my proposition i have done the following:
 
  * the cdrSP provides (somehow) the driver:
                               "generic SCSI-3/mmc DVD-R(W) driver (mmc_mdvd)" .
    i call this driver further "mmc_mdvd" .

  * i have compiled, taking source from cdrSP, a binary named "cdrecord.new".
    this cdrecord.new contains the driver mmc_mdvd. besides this, cdrecord.new
    is nearly identical to cdrecord-dvd from the installed package.

  * with cdrecord.new, writing to either DVD-RW and DVD+RW works ok.
  * during writing to eg. DVD-RW, cdrecord.new says many things. i think
    important is:
    ...
    Device seems to be: Generic mmc2 DVD-R/DVD-RW.
    cdrecord.neu: Found DVD media: using cdr_mdvd.
    Using generic SCSI-3/mmc DVD-R(W) driver (mmc_mdvd).
    ...

* after this, i think, my propostion holds.

* next propostion: the cdrecord-dvd of the installed package does not contain
  the driver mmc_mdvd .

* verification of this propostion:

  * from the test with the cdrecord-dvd from the installed package, i think
    it is obvious, that cdrecord-dvd contains the driver
    "generic SCSI-3/mmc CD/DVD driver (checks media) (mmc_cd_dvd)".

  * assume cdrecord-dvd has the full path "/usr/bin/cdrecord-dvd".

  * the command-line
      strings /usr/bin/cdrecord-dvd | grep mmc_cd_dvd
    returns mmc_cd_dvd .
    i think, this corresponds to the fact that cdrecord-dvd contains the driver
    "generic SCSI-3/mmc CD/DVD driver (checks media) (mmc_cd_dvd)".

  * the command-line
      strings /usr/bin/cdrecord-dvd | grep mmc_mdvd
    returns "nothing".

  * assuming cdrecord.new is in the current directory, the command-line
      strings cdrecord.new | grep mmc_mdvd
    returns mmc_mdvd .

  * conclusion: if a binary contains the driver mmc_mdvd you get mmc_mdvd with
    grep.

* i think my propostion holds.    
    
* the cdrSP contains the file "cdrecord-2.01-dvd.patch.bz2" .

* the cdrSP contains the file "cdrecord.spec" .

  * line # 28 ... of cdrecord.spec:
    # DVD patches, applied later during build
    ...
    Source10:     cdrtools-%{version}-dvd.patch.bz2

  * line # 253 of cdrecord.spec:
    - DVD patch is applied to separate binary cdrecord-dvd

* the cdrSP contains the file "cdrtools-2.01/cdrecord/drv_mmc.c"
  * this file contains the driver mmc_cd_dvd.
  * this file does not contain the driver mmc_mdvd.

* after patching drv_mmc.c with "cdrecord-2.01-dvd.patch.bz2", drv_mmc.c
  contains the driver mmc_mdvd.

* i compiled my cdrecord.new with the patched drv_mmc.c and cdrecord.new con-
  tains therefore the driver mmc_mdvd.

* according to the file cdrecord.spec, especially lines 28 ... and 253, you
  should have applied the patch cdrecord-2.01-dvd.patch.bz2 to drv_mmc.c, and
  the resulting binary cdrecord-dvd should contain the driver mmc_mdvd .

* because cdrecord-dvd does not contain the driver mmc_mdvd, i assume that you
  did not apply the patch cdrecord-2.01-dvd.patch.bz2 completly.

i am sorry for some wrong line#s and some typing-mistakes in my first report;
i hope these additional comments will help.
    
    
Comment 3 Thomas Bruecker 2006-03-04 20:37:36 UTC
* more to comment #2 : more (less) to the proposition:
  "the cdrecord-dvd of the installed package does not contain
  the driver mmc_mdvd ."

  * verification of this proposition, ok, i admit, you can have it simpler and
    more mainstream-like:

    * with the command-line
        cdrecord-dvd driver=help
      you get a list with the available drivers. the driver
      "generic SCSI-3/mmc DVD-R(W) driver" is not in this list.

    * with the command-line
        cdrecord.new driver=help
      you get a similar list and it contains the line:
      "mmc_mdvd [...] generic SCSI-3/mmc DVD-R(W) driver" .
      "[...]" stands for several white spaces.
Comment 4 Michael Gross 2006-03-06 13:15:50 UTC
So to sum this up: The package should contain the mentioned driver ``generic SCSI-3/mmc DVD-R(W) driver (mmc_mdvd)''. Vladimir, please take care about that.
Comment 5 Ladislav Michnovic 2006-03-07 17:39:47 UTC
I'll take care of it.
Comment 6 Ladislav Michnovic 2006-03-09 10:33:25 UTC
This seems to be fixed in SL 10.1 Beta. Should this be fixed  for 10.0?
Comment 7 Andreas Jaeger 2006-03-09 15:01:28 UTC
Leave it as it is.
Comment 8 Ladislav Michnovic 2006-03-09 15:11:44 UTC
OK. 
Comment 9 Thomas Bruecker 2006-03-09 15:55:48 UTC
i have downloaded "cdrecord-2.01-16.i586.rpm" from suse linux
ver. 10.1 and installed it on ver. 10.0.
cdrecord-dvd seems now to work with the _NEC DVD+/-RW ND-6650A-drive.
i thank you for your information in Comment #6 .
Comment 10 Ladislav Michnovic 2006-03-09 16:02:51 UTC
(In reply to comment #9)
> i thank you for your information in Comment #6 .
 Not at all.