Compare commits
40 Commits
ZeroThreeS
...
ZeroThreeE
Author | SHA1 | Date | |
---|---|---|---|
0d3a31e3f0 | |||
205d5fed7d | |||
19c3d448a8 | |||
89762d91b4 | |||
a6acdc64cc | |||
7d23984220 | |||
aba535d700 | |||
203f158f5b | |||
e274c90f9d | |||
bf25c6edc8 | |||
2c467c8378 | |||
bdadae6ba5 | |||
1087d402f2 | |||
dc97c0d0df | |||
8b8afdd59b | |||
4dd8f098ac | |||
16b6e1905a | |||
22d1d56ebd | |||
0217702b8c | |||
81d68aeb83 | |||
0e23721f2d | |||
3a771b3da2 | |||
bacb815ecc | |||
f34d9efdb2 | |||
8efb863d5d | |||
d7ca1dd333 | |||
ddc2745495 | |||
12c4c73535 | |||
3326fcdb2d | |||
fba8eaef80 | |||
15a70555b2 | |||
83e196d69f | |||
c86f5d7cde | |||
8d7d177ce3 | |||
cd7b4e6de4 | |||
79adcb520b | |||
41f2a40a58 | |||
9b663f15d9 | |||
ed9d3e2545 | |||
ba7cd6d66e |
@ -101,9 +101,9 @@ test_structest_CPPFLAGS = -Ilibburn
|
||||
test_structest_LDADD = $(libburn_libburn_la_OBJECTS) $(THREAD_LIBS)
|
||||
test_structest_SOURCES = test/structest.c
|
||||
|
||||
## cdrskin construction site - ts A60816 - A70312
|
||||
## cdrskin construction site - ts A60816 - A70720
|
||||
cdrskin_cdrskin_CPPFLAGS = -Ilibburn
|
||||
cdrskin_cdrskin_CFLAGS = -DCdrskin_libburn_0_3_6
|
||||
cdrskin_cdrskin_CFLAGS = -DCdrskin_libburn_0_3_8
|
||||
cdrskin_cdrskin_LDADD = $(libburn_libburn_la_OBJECTS) $(THREAD_LIBS)
|
||||
cdrskin_cdrskin_SOURCES = cdrskin/cdrskin.c cdrskin/cdrfifo.c cdrskin/cdrfifo.h cdrskin/cdrskin_timestamp.h
|
||||
##
|
||||
|
9
README
9
README
@ -127,7 +127,7 @@ Project history as far as known to me:
|
||||
It has meanwhile moved to use vanilla libburn.pykix.org , though.
|
||||
Version 0.1.4 constitutes the first release of this kind.
|
||||
|
||||
- In Juli 2006 our team mate Mario Danic announced a revival of libburn
|
||||
- In July 2006 our team mate Mario Danic announced a revival of libburn
|
||||
which by about nearly everybody else was perceived as unfriendly fork.
|
||||
Derek Foreman four days later posted a message which expressed his
|
||||
discontent.
|
||||
@ -197,9 +197,14 @@ Project history as far as known to me:
|
||||
DVD media. Code for double layer DVD+/-R is implemented but awaits a tester
|
||||
yet.
|
||||
|
||||
- 23th April 2000 version 0.3.6 follows the unanimous opinion of Linux kernel
|
||||
- 23th April 2007 version 0.3.6 follows the unanimous opinion of Linux kernel
|
||||
people that one should not use /dev/sg on kernel 2.6.
|
||||
|
||||
- 31st July 2007 version 0.3.8 marks the first anniversary of libburn revival.
|
||||
We look back on improved stability, a substantially extended list of media
|
||||
and write modes, and better protection against typical user mishaps.
|
||||
|
||||
|
||||
------------------------------------------------------------------------------
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
|
@ -26,12 +26,12 @@ following possible.
|
||||
cdrskin. By Thomas Schmitt <scdbackup@gmx.net>
|
||||
Integrated sub project of libburnia.pykix.org but also published via:
|
||||
http://scdbackup.sourceforge.net/cdrskin_eng.html
|
||||
http://scdbackup.sourceforge.net/cdrskin-0.3.6.pl00.tar.gz
|
||||
http://scdbackup.sourceforge.net/cdrskin-0.3.8.tar.gz
|
||||
Copyright (C) 2006-2007 Thomas Schmitt
|
||||
|
||||
------------------------------------------------------------------------------
|
||||
|
||||
On top of libburn there is implemented cdrskin 0.3.6, a limited cdrecord
|
||||
On top of libburn there is implemented cdrskin 0.3.8, a limited cdrecord
|
||||
compatibility wrapper which allows to use some libburn features from
|
||||
the command line.
|
||||
Interested users of cdrecord are invited to participate in the development
|
||||
@ -59,16 +59,16 @@ systems, including 64 bit systems. (Further reports are welcome.)
|
||||
|
||||
Compilation, First Glimpse, Installation
|
||||
|
||||
Obtain cdrskin-0.3.6.pl00.tar.gz, take it to a directory of your choice and do:
|
||||
Obtain cdrskin-0.3.8.tar.gz, take it to a directory of your choice and do:
|
||||
|
||||
tar xzf cdrskin-0.3.6.pl00.tar.gz
|
||||
cd cdrskin-0.3.6
|
||||
tar xzf cdrskin-0.3.8.tar.gz
|
||||
cd cdrskin-0.3.8
|
||||
|
||||
Or obtain a libburnia.pykix.org SVN snapshot,
|
||||
go into the toplevel directory of the snapshot (e.g. cd libburn_pykix ),
|
||||
and execute the autotools script ./bootstrap . Use autools version >= 1.7 .
|
||||
|
||||
Within that toplevel directory of either cdrskin-0.3.6 or libburn then execute:
|
||||
Within that toplevel directory of either cdrskin-0.3.8 or libburn then execute:
|
||||
|
||||
./configure
|
||||
make
|
||||
@ -402,7 +402,7 @@ most recent session. For example put an ISO filesystem at address 1 GB:
|
||||
cdrskin dev=/dev/sr0 -v fs=32m -eject speed=4 write_start_address=524288s -
|
||||
The superuser may then do:
|
||||
mount -t iso9660 -o ro,sbsector=524288 /dev/sr0 /mnt
|
||||
Note: On my linux-2.4.21-215 mount works only with sbsector <= 337920 (660 MB).
|
||||
Note: On my linux-2.4.21-215 mount works only with sbsector <= 337920 (660 MiB)
|
||||
To extend a filesystem already existing at address 0
|
||||
mkisofs -C 0,524288 -M /dev/sr0 ... | cdrskin dev=/dev/sr0 ...
|
||||
Record the number 524288 for usage as first number with -C at the next
|
||||
@ -447,7 +447,7 @@ too on blanking by cdrecord, dvd+rw-format or cdrskin. Perils of DVD-RW.
|
||||
There are three DVD-RW formatting variants with cdrskin currently:
|
||||
|
||||
blank=format_overwrite uses "DVD-RW Quick" formatting (MMC-type 15h)
|
||||
and writes a first session of 128 MB. This leads to media which are expandable
|
||||
and writes a first session of 128 MiB. This leads to media which are expandable
|
||||
and random addressable by cdrskin.
|
||||
|
||||
blank=format_overwrite_quickest uses "DVD-RW Quick" formatting (type 15h) too,
|
||||
|
@ -38,7 +38,7 @@ original="./libburn_svn_release.tgz"
|
||||
# My changes are in $changes , mainly in $changes/cdrskin
|
||||
changes="./libburn-release"
|
||||
|
||||
skin_release="0.3.6"
|
||||
skin_release="0.3.8"
|
||||
patch_level=".pl00"
|
||||
skin_rev="$skin_release""$patch_level"
|
||||
|
||||
@ -138,7 +138,7 @@ do
|
||||
done
|
||||
|
||||
# Remove GIFs of cdrskin_eng.html
|
||||
rm "$cdrskin_target"/doener_*.gif
|
||||
rm "$cdrskin_target"/doener_*.gif "$cdrskin_target"/doener_*.png
|
||||
|
||||
# Remove automatically generated HTML man page
|
||||
rm "$cdrskin_target"/man_1_cdrskin.html
|
@ -38,7 +38,7 @@ original="./libburn_svn.tgz"
|
||||
# My changes are in $changes , mainly in $changes/cdrskin
|
||||
changes="./libburn-develop"
|
||||
|
||||
skin_release="0.3.7"
|
||||
skin_release="0.3.9"
|
||||
patch_level=""
|
||||
skin_rev="$skin_release""$patch_level"
|
||||
|
||||
@ -138,7 +138,7 @@ do
|
||||
done
|
||||
|
||||
# Remove GIFs of cdrskin_eng.html
|
||||
rm "$cdrskin_target"/doener_*.gif
|
||||
rm "$cdrskin_target"/doener_*.gif "$cdrskin_target"/doener_*.png
|
||||
|
||||
# Remove automatically generated HTML man page
|
||||
rm "$cdrskin_target"/man_1_cdrskin.html
|
||||
@ -215,11 +215,11 @@ tar czf "$cdrskin_tarball" "$target"
|
||||
cd "$compile_dir" || exit 1
|
||||
./configure
|
||||
make
|
||||
"$compile_cmd" -O2 -do_strip
|
||||
"$compile_cmd" -libburn_svn -O2 -do_strip
|
||||
cp "$compile_result" "../$bintarget_dynamic"
|
||||
if test -n "$compile_static_opts"
|
||||
then
|
||||
"$compile_cmd" $compile_static_opts -O2 -do_strip
|
||||
"$compile_cmd" $compile_static_opts -libburn_svn -O2 -do_strip
|
||||
cp "$compile_result" "../$bintarget_static"
|
||||
fi
|
||||
"$man_to_html_cmd"
|
@ -2,7 +2,7 @@
|
||||
.\" First parameter, NAME, should be all caps
|
||||
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
|
||||
.\" other parameters are allowed: see man(7), man(1)
|
||||
.TH CDRSKIN 1 "April 22, 2007"
|
||||
.TH CDRSKIN 1 "July 19, 2007"
|
||||
.\" Please adjust this date whenever revising the manpage.
|
||||
.\"
|
||||
.\" Some roff macros, for reference:
|
||||
@ -269,9 +269,9 @@ Announces that the subsequent tracks are to be burned as audio.
|
||||
The source is supposed to be uncompressed headerless PCM, 44100 Hz, 16 bit,
|
||||
stereo. For little-endian byte order (which is usual on PCs) use option
|
||||
-swab. Unless marked explicitely by option -data, input files with suffix
|
||||
.wav are examined wether they have a header in MS-WAVE format confirming
|
||||
".wav" are examined wether they have a header in MS-WAVE format confirming
|
||||
those parameters and eventually raw audio data get extracted and burned as
|
||||
audio track. Same is done for suffix .au and SUN Audio.
|
||||
audio track. Same is done for suffix ".au" and SUN Audio.
|
||||
.br
|
||||
Option -audio may be used only with CD media and not with DVD.
|
||||
.TP
|
||||
@ -298,14 +298,14 @@ Format a DVD-RW to "Restricted Overwrite". The user should bring some patience.
|
||||
(Note: blank=format_overwrite* are not original cdrecord options.)
|
||||
.TP
|
||||
format_overwrite_quickest
|
||||
Like format_overwrite without creating a 128 MB trailblazer session.
|
||||
Like format_overwrite without creating a 128 MiB trailblazer session.
|
||||
Leads to "intermediate" state which only allows sequential write
|
||||
beginning from address 0.
|
||||
The "intermediate" state ends after the first session of writing data.
|
||||
.TP
|
||||
format_overwrite_full
|
||||
For DVD-RW this is like format_overwrite but claims full media size
|
||||
rather than just 128 MB.
|
||||
rather than just 128 MiB.
|
||||
Most traditional formatting is attempted. No data get written.
|
||||
Much patience is required.
|
||||
.br
|
||||
@ -365,8 +365,10 @@ even if attempted explicitely via "driveropts=burnfree".
|
||||
.TP
|
||||
.BI \-dummy
|
||||
Try to perform the drive operations without actually affecting the inserted
|
||||
media. There is no guarantee that this will work with a particular combination
|
||||
media. There is no warranty that this will work with a particular combination
|
||||
of drive, media, and write mode. Blanking is prevented reliably, though.
|
||||
To avoid inadverted real burning, -dummy refuses burn runs on anything but
|
||||
CD-R[W] and DVD-R[W].
|
||||
.TP
|
||||
.BI \-eject
|
||||
Eject the disc after work is done.
|
||||
@ -380,6 +382,9 @@ write modes which libburn believes they are not supported by the drive.
|
||||
Another application is to enforce blanking or re-formatting of media
|
||||
which appear to be in the desired blank or format state already.
|
||||
.br
|
||||
This option enables a burn run with option -dummy even if libburn believes
|
||||
that drive and media will not simulate the write mode but will write for real.
|
||||
.br
|
||||
.B Caution:
|
||||
Use this only when in urgent need.
|
||||
.TP
|
||||
@ -416,7 +421,14 @@ added to each -isosize track. But be advised to rather use padsize=300k.
|
||||
.br
|
||||
This option can be performed on track sources which are regular files or block
|
||||
devices. For the first track of the session it can be performed on any type
|
||||
of source if there is a fifo of at least 64 kB. See option fs= .
|
||||
of source if there is a fifo of at least 64 kiB. See option fs= .
|
||||
.TP
|
||||
.BI minbuf= percentage
|
||||
Equivalent to:
|
||||
.br
|
||||
modesty_on_drive=1:min_percent=<percentage>:max_percent=95
|
||||
.br
|
||||
Percentage is permissible between 25 and 95.
|
||||
.TP
|
||||
.BI msifile= path
|
||||
Run option -msinfo and copy the result line into the file given by path.
|
||||
@ -461,7 +473,7 @@ to be no use for audio tracks with incomplete last sector, this option applies
|
||||
only to data tracks. There it is default.
|
||||
.TP
|
||||
.BI \-pad
|
||||
Add 30 kB of trailing zeros to each data track. (This is not sufficient to
|
||||
Add 30 kiB of trailing zeros to each data track. (This is not sufficient to
|
||||
avoid problems with various CD-ROM read drivers.)
|
||||
.TP
|
||||
.BI padsize= size
|
||||
@ -513,6 +525,9 @@ Set speed of drive. With data CD, 1x speed corresponds to a throughput of
|
||||
150,000 bytes/second. With DVD, 1x = 1,385,000 bytes/second.
|
||||
It is not an error to set a speed higher than is suitable for drive
|
||||
and media. One should stay within a realistic speed range, though.
|
||||
Special speed settings are:
|
||||
.br
|
||||
0 = minimal speed , -1 = maximal speed (default).
|
||||
.TP
|
||||
.BI \-swab
|
||||
Announce that the raw audio data source of subsequent tracks is byte swapped
|
||||
@ -580,6 +595,12 @@ somebody who had a look into the program sourcecode.
|
||||
Alphabetical list of options which are genuine to cdrskin and intended for
|
||||
normal use:
|
||||
.TP
|
||||
.BI \--adjust_speed_to_drive
|
||||
Curb explicitely given speed= values to the maximum which is announced by the
|
||||
drive for the loaded media. By default, such an adjustment is only made with
|
||||
pseudo-speeds 0 and -1 whereas speed settings > 0 are sent unchanged to the
|
||||
drive which will then choose an appropriate speed on its own.
|
||||
.TP
|
||||
.BI \--allow_setuid
|
||||
Disable the loud warning about insecure discrepance between login user and
|
||||
effective user which indicates application of chmod u+s to the program binary.
|
||||
@ -688,8 +709,8 @@ string and eventual output of -msinfo.
|
||||
.TP
|
||||
.BI write_start_address= byte_offset
|
||||
Set the address on media where to start writing the track. With DVD+RW or
|
||||
DVD-RAM byte_offset must be aligned to 2 KB blocks, but better is 32 kB.
|
||||
With DVD-RW 32 kB alignment is mandatory.
|
||||
DVD-RAM byte_offset must be aligned to 2 kiB blocks, but better is 32 kiB.
|
||||
With DVD-RW 32 kiB alignment is mandatory.
|
||||
.br
|
||||
Other media are not suitable for this option yet.
|
||||
.PP
|
||||
@ -791,6 +812,30 @@ Try to ignore any signals rather than to abort the program. This is not a
|
||||
very good idea. You might end up waiting a very long time for cdrskin
|
||||
to finish.
|
||||
.TP
|
||||
.BI modesty_on_drive= <mode>[:min_percent=<num>][:max_percent=<num>]
|
||||
Mode 1 keeps the program from trying to write to the burner drive while its
|
||||
buffer is in danger to be filled by more than max_percent. If this filling is
|
||||
exceeded then the program will wait until the filling is at most min_percent.
|
||||
.br
|
||||
This can ease the load on operating system and drive controller and thus help
|
||||
with achieving better input bandwidth if disk and burner are not on independent
|
||||
controllers (like hda and hdb). Unsufficient input bandwidth is indicated by
|
||||
output "(fifo xy%)" of option -v if xy is lower than 90 for some time.
|
||||
modesty_on_drive= might hamper output bandwidth and cause buffer underruns.
|
||||
.br
|
||||
To have max_percent larger than the burner's best actual
|
||||
buffer fill has the same effect as min_percent==max_percent. Some burners
|
||||
do not use their full buffer with all media types. Watch output "[buf xy%]"
|
||||
of option -v to get an impression of the actual buffer usage. Some burners
|
||||
are not suitable because they report buffer fill with granularity too large
|
||||
in size or time.
|
||||
.br
|
||||
Mode 0 disables this feature. Mode -1 keeps it unchanged. Default is:
|
||||
.br
|
||||
modesty_on_drive=0:min_percent=65:max_percent=95
|
||||
.br
|
||||
Percentages are permissible in the range of 25 to 100.
|
||||
.TP
|
||||
.BI \--no_abort_handler
|
||||
On signals exit even if the drive is in busy state. This is not a very good
|
||||
idea. You might end up with a stuck drive that refuses to hand out the media.
|
||||
|
@ -86,7 +86,7 @@ or
|
||||
|
||||
/** The official program version */
|
||||
#ifndef Cdrskin_prog_versioN
|
||||
#define Cdrskin_prog_versioN "0.3.6"
|
||||
#define Cdrskin_prog_versioN "0.3.8"
|
||||
#endif
|
||||
|
||||
/** The source code release timestamp */
|
||||
@ -119,24 +119,25 @@ or
|
||||
#endif /* Cdrskin_libburn_cvs_A60220_tS */
|
||||
|
||||
|
||||
#ifdef Cdrskin_libburn_0_3_6
|
||||
#define Cdrskin_libburn_versioN "0.3.6"
|
||||
#ifdef Cdrskin_libburn_0_3_8
|
||||
#define Cdrskin_libburn_versioN "0.3.8"
|
||||
#define Cdrskin_libburn_from_pykix_svN 1
|
||||
#endif /* Cdrskin_libburn_0_3_6 */
|
||||
#endif /* Cdrskin_libburn_0_3_8 */
|
||||
|
||||
#ifdef Cdrskin_libburn_0_3_7
|
||||
#define Cdrskin_libburn_versioN "0.3.7"
|
||||
#ifdef Cdrskin_libburn_0_3_9
|
||||
#define Cdrskin_libburn_versioN "0.3.9"
|
||||
#define Cdrskin_libburn_from_pykix_svN 1
|
||||
|
||||
/* Place novelty switch macros here.
|
||||
Move them down to Cdrskin_libburn_from_pykix_svN on version leap
|
||||
*/
|
||||
/* - no novelty switches currently - */
|
||||
|
||||
#endif /* Cdrskin_libburn_0_3_7 */
|
||||
/* - no novelty switch macros yet - */
|
||||
|
||||
#endif /* Cdrskin_libburn_0_3_9 */
|
||||
|
||||
#ifndef Cdrskin_libburn_versioN
|
||||
#define Cdrskin_libburn_versioN "0.3.6"
|
||||
#define Cdrskin_libburn_versioN "0.3.8"
|
||||
#define Cdrskin_libburn_from_pykix_svN 1
|
||||
#endif
|
||||
|
||||
@ -193,6 +194,10 @@ or
|
||||
#define Cdrskin_libburn_preset_device_familY 1
|
||||
#define Cdrskin_libburn_has_track_set_sizE 1
|
||||
|
||||
/* 0.3.8 */
|
||||
#define Cdrskin_libburn_has_set_waitinG 1
|
||||
#define Cdrskin_libburn_has_get_best_speeD 1
|
||||
|
||||
#ifdef Cdrskin_new_api_tesT
|
||||
|
||||
/* put macros under test caveat here */
|
||||
@ -1161,6 +1166,44 @@ int Cdrtrack_open_source_path(struct CdrtracK *track, int *fd, int flag)
|
||||
*fd= atoi(track->source_path+1);
|
||||
else {
|
||||
*fd= -1;
|
||||
|
||||
#ifdef Cdrskin_libburn_has_convert_fs_adR
|
||||
if(1) {
|
||||
char adr[BURN_DRIVE_ADR_LEN],*device_adr,*raw_adr;
|
||||
int no_convert_fs_adr;
|
||||
int Cdrskin_get_device_adr(struct CdrskiN *skin,
|
||||
char **device_adr, char **raw_adr, int *no_convert_fs_adr,int flag);
|
||||
|
||||
Cdrskin_get_device_adr(track->boss,&device_adr,&raw_adr,
|
||||
&no_convert_fs_adr,0);
|
||||
/*
|
||||
fprintf(stderr,
|
||||
"cdrskin: DEBUG : device_adr='%s' , raw_adr='%s' , ncfs=%d\n",
|
||||
device_adr, raw_adr, no_convert_fs_adr);
|
||||
*/
|
||||
if(!no_convert_fs_adr) {
|
||||
if(burn_drive_convert_fs_adr(track->source_path,adr)>0) {
|
||||
/*
|
||||
fprintf(stderr,"cdrskin: DEBUG : track source '%s' -> adr='%s'\n",
|
||||
track->source_path,adr);
|
||||
*/
|
||||
if(strcmp(device_adr,adr)==0) {
|
||||
fprintf(stderr,
|
||||
"cdrskin: FATAL : track source address leads to burner drive\n");
|
||||
fprintf(stderr,
|
||||
"cdrskin: : dev='%s' -> '%s' <- track source '%s'\n",
|
||||
raw_adr, device_adr, track->source_path);
|
||||
return(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
/*
|
||||
fprintf(stderr,"cdrskin: EXPERIMENTAL : Deliberate abort\n");
|
||||
return(0);
|
||||
*/
|
||||
}
|
||||
#endif
|
||||
|
||||
is_wav= Cdrtrack_extract_audio(track,fd,&xtr_size,0);
|
||||
if(is_wav==-1)
|
||||
return(-1);
|
||||
@ -1716,11 +1759,12 @@ int Cdrpreskin_initialize_lib(struct CdrpreskiN *preskin, int flag)
|
||||
int Cdrpreskin_queue_msgs(struct CdrpreskiN *o, int flag)
|
||||
{
|
||||
#ifdef Cdrskin_libburn_has_burn_msgS
|
||||
/* In cdrskin there is not much sense in queueing library messages.
|
||||
#ifndef Cdrskin_extra_leaN
|
||||
#define Cdrskin_debug_libdax_msgS 1
|
||||
#endif
|
||||
/* <<< In cdrskin there is not much sense in queueing library messages.
|
||||
It is done here only for debugging */
|
||||
It would be done here only for debugging
|
||||
*/
|
||||
#ifdef Cdrskin_debug_libdax_msgS
|
||||
|
||||
int ret;
|
||||
@ -2160,6 +2204,10 @@ set_dev:;
|
||||
"blanking and burning see output of option -help rather than --help.\n");
|
||||
printf("Non-cdrecord options:\n");
|
||||
printf(" --abort_handler do not leave the drive in busy state\n");
|
||||
#ifdef Cdrskin_libburn_has_get_best_speeD
|
||||
printf(
|
||||
" --adjust_speed_to_drive set only speeds offered by drive and media\n");
|
||||
#endif
|
||||
printf(
|
||||
" --allow_setuid disable setuid warning (setuid is insecure !)\n");
|
||||
printf(
|
||||
@ -2208,6 +2256,9 @@ set_dev:;
|
||||
printf(
|
||||
" --ignore_signals try to ignore any signals rather than to abort\n");
|
||||
printf(" --list_ignored_options list all ignored cdrecord options.\n");
|
||||
#ifdef Cdrskin_libburn_has_set_waitinG
|
||||
printf(" modesty_on_drive=<options> no writing into full drive buffer\n");
|
||||
#endif
|
||||
printf(" --no_abort_handler exit even if the drive is in busy state\n");
|
||||
printf(" --no_blank_appendable refuse to blank appendable CD-RW\n");
|
||||
printf(" --no_convert_fs_adr only literal translations of dev=\n");
|
||||
@ -2303,6 +2354,10 @@ see_cdrskin_eng_html:;
|
||||
fprintf(stderr,"\t-toc\t\tretrieve and print TOC/PMA data\n");
|
||||
fprintf(stderr,
|
||||
"\t-atip\t\tretrieve media state, print \"Is *erasable\"\n");
|
||||
#ifdef Cdrskin_libburn_has_set_waitinG
|
||||
fprintf(stderr,
|
||||
"\tminbuf=percent\tset lower limit for drive buffer modesty\n");
|
||||
#endif
|
||||
#ifdef Cdrskin_libburn_has_multI
|
||||
fprintf(stderr,
|
||||
"\t-multi\t\tgenerate a TOC that allows multi session\n");
|
||||
@ -2575,6 +2630,7 @@ struct CdrskiN {
|
||||
/** Job: what to do, plus some parameters. */
|
||||
int verbosity;
|
||||
double x_speed;
|
||||
int adjust_speed_to_drive;
|
||||
int gracetime;
|
||||
int dummy_mode;
|
||||
int force_is_set;
|
||||
@ -2615,6 +2671,9 @@ struct CdrskiN {
|
||||
enum burn_write_types write_type;
|
||||
int block_type;
|
||||
int multi;
|
||||
int modesty_on_drive;
|
||||
int min_buffer_percent;
|
||||
int max_buffer_percent;
|
||||
|
||||
double write_start_address;
|
||||
int assert_write_lba;
|
||||
@ -2671,6 +2730,8 @@ struct CdrskiN {
|
||||
unsigned int n_drives;
|
||||
/** The drive selected for operation by CdrskiN */
|
||||
int driveno;
|
||||
/** The persistent drive address of that drive */
|
||||
char device_adr[Cdrskin_adrleN];
|
||||
|
||||
|
||||
/** Progress state info: wether libburn is actually processing payload data */
|
||||
@ -2725,6 +2786,7 @@ int Cdrskin_new(struct CdrskiN **skin, struct CdrpreskiN *preskin, int flag)
|
||||
o->preskin= preskin;
|
||||
o->verbosity= preskin->verbosity;
|
||||
o->x_speed= -1.0;
|
||||
o->adjust_speed_to_drive= 0;
|
||||
o->gracetime= 0;
|
||||
o->dummy_mode= 0;
|
||||
o->force_is_set= 0;
|
||||
@ -2747,6 +2809,9 @@ int Cdrskin_new(struct CdrskiN **skin, struct CdrpreskiN *preskin, int flag)
|
||||
o->write_type= BURN_WRITE_SAO;
|
||||
o->block_type= BURN_BLOCK_SAO;
|
||||
o->multi= 0;
|
||||
o->modesty_on_drive= 0;
|
||||
o->min_buffer_percent= 65;
|
||||
o->max_buffer_percent= 95;
|
||||
o->write_start_address= -1.0;
|
||||
o->assert_write_lba= -1;
|
||||
o->burnfree= 1;
|
||||
@ -2776,6 +2841,7 @@ int Cdrskin_new(struct CdrskiN **skin, struct CdrpreskiN *preskin, int flag)
|
||||
o->drives= NULL;
|
||||
o->n_drives= 0;
|
||||
o->driveno= 0;
|
||||
o->device_adr[0]= 0;
|
||||
o->is_writing= 0;
|
||||
o->previous_drive_status = BURN_DRIVE_IDLE;
|
||||
o->abort_max_wait= 74*60;
|
||||
@ -2840,6 +2906,20 @@ int Cdrskin_set_msinfo_fd(struct CdrskiN *skin, int result_fd, int flag)
|
||||
}
|
||||
|
||||
|
||||
/** Return the addresses of the drive. device_adr is the libburn persistent
|
||||
address of the drive, raw_adr is the address as given by the user.
|
||||
*/
|
||||
int Cdrskin_get_device_adr(struct CdrskiN *skin,
|
||||
char **device_adr, char **raw_adr, int *no_convert_fs_adr, int flag)
|
||||
{
|
||||
burn_drive_get_adr(&skin->drives[skin->driveno],skin->device_adr);
|
||||
*device_adr= skin->device_adr;
|
||||
*raw_adr= skin->preskin->raw_device_adr;
|
||||
*no_convert_fs_adr= skin->preskin->no_convert_fs_adr;
|
||||
return(1);
|
||||
}
|
||||
|
||||
|
||||
/** Return information about current track source */
|
||||
int Cdrskin_get_source(struct CdrskiN *skin, char *source_path,
|
||||
double *fixed_size, double *tao_to_sao_tsize,
|
||||
@ -2937,20 +3017,44 @@ int Cdrskin_fill_fifo(struct CdrskiN *skin, int flag)
|
||||
/** Inform libburn about the consumer x-speed factor of skin */
|
||||
int Cdrskin_adjust_speed(struct CdrskiN *skin, int flag)
|
||||
{
|
||||
int k_speed;
|
||||
int k_speed, modesty= 0;
|
||||
|
||||
if(skin->x_speed<0)
|
||||
k_speed= 0; /* libburn.h promises 0 to be max speed. */
|
||||
else if(skin->x_speed==0) /* cdrecord specifies 0 as minimum speed. */
|
||||
else if(skin->x_speed==0) { /* cdrecord specifies 0 as minimum speed. */
|
||||
#ifdef Cdrskin_libburn_has_get_best_speeD
|
||||
k_speed= -1;
|
||||
#else
|
||||
k_speed= Cdrskin_libburn_speed_factoR+Cdrskin_libburn_speed_addoN;
|
||||
else
|
||||
#endif
|
||||
} else
|
||||
k_speed= skin->x_speed*Cdrskin_libburn_speed_factoR +
|
||||
Cdrskin_libburn_speed_addoN;
|
||||
|
||||
if(skin->verbosity>=Cdrskin_verbose_debuG)
|
||||
ClN(fprintf(stderr,"cdrskin_debug: k_speed= %d\n",k_speed));
|
||||
|
||||
#ifdef Cdrskin_libburn_has_get_best_speeD
|
||||
if(skin->adjust_speed_to_drive && !skin->force_is_set) {
|
||||
struct burn_speed_descriptor *best_descr;
|
||||
burn_drive_get_best_speed(skin->drives[skin->driveno].drive,k_speed,
|
||||
&best_descr,0);
|
||||
if(best_descr!=NULL) {
|
||||
k_speed= best_descr->write_speed;
|
||||
skin->x_speed = ((double) k_speed) / Cdrskin_libburn_speed_factoR;
|
||||
}
|
||||
}
|
||||
#endif /* Cdrskin_libburn_has_get_best_speeD */
|
||||
|
||||
burn_drive_set_speed(skin->drives[skin->driveno].drive,k_speed,k_speed);
|
||||
|
||||
#ifdef Cdrskin_libburn_has_set_waitinG
|
||||
modesty= skin->modesty_on_drive;
|
||||
burn_drive_set_buffer_waiting(skin->drives[skin->driveno].drive,
|
||||
modesty, -1, -1, -1,
|
||||
skin->min_buffer_percent,
|
||||
skin->max_buffer_percent);
|
||||
#endif
|
||||
return(1);
|
||||
}
|
||||
|
||||
@ -5236,6 +5340,8 @@ burn_failed:;
|
||||
{ret= 1; goto ex;}
|
||||
}
|
||||
|
||||
Cdrskin_adjust_speed(skin,0);
|
||||
|
||||
#ifndef Cdrskin_extra_leaN
|
||||
Cdrskin_wait_before_action(skin,0);
|
||||
if(needs_early_fifo_fill==1)
|
||||
@ -5250,8 +5356,6 @@ fifo_filling_failed:;
|
||||
|
||||
#endif /* ! Cdrskin_extra_leaN */
|
||||
|
||||
Cdrskin_adjust_speed(skin,0);
|
||||
|
||||
if(skin->verbosity>=Cdrskin_verbose_progresS && nwa>=0)
|
||||
printf("Starting new track at sector: %d\n",nwa);
|
||||
skin->drive_is_busy= 1;
|
||||
@ -5789,6 +5893,10 @@ set_abort_max_wait:;
|
||||
skin->abort_max_wait);
|
||||
}
|
||||
|
||||
#ifdef Cdrskin_libburn_has_get_best_speeD
|
||||
} else if(strcmp(argv[i],"--adjust_speed_to_drive")==0) {
|
||||
skin->adjust_speed_to_drive= 1;
|
||||
#endif
|
||||
|
||||
} else if(strcmp(argv[i],"--allow_setuid")==0) {
|
||||
/* is handled in Cdrpreskin_setup() */;
|
||||
@ -6096,6 +6204,90 @@ gracetime_equals:;
|
||||
printf("%s\n",ignored_full_options[k]);
|
||||
printf("\n");
|
||||
|
||||
} else if(strncmp(argv[i],"-minbuf=",8)==0) {
|
||||
value_pt= argv[i]+8;
|
||||
goto minbuf_equals;
|
||||
} else if(strncmp(argv[i],"minbuf=",7)==0) {
|
||||
value_pt= argv[i]+7;
|
||||
minbuf_equals:;
|
||||
#ifdef Cdrskin_libburn_has_set_waitinG
|
||||
skin->modesty_on_drive= 1;
|
||||
sscanf(value_pt,"%lf",&value);
|
||||
if (value<25 || value>95) {
|
||||
fprintf(stderr,
|
||||
"cdrskin: FATAL : minbuf= value must be between 25 and 95\n");
|
||||
return(0);
|
||||
}
|
||||
skin->min_buffer_percent= value;
|
||||
skin->max_buffer_percent= 95;
|
||||
ClN(printf("cdrskin: minbuf=%d percent desired buffer fill\n",
|
||||
skin->min_buffer_percent));
|
||||
#else
|
||||
fprintf(stderr,
|
||||
"cdrskin: SORRY : Option minbuf= is not available yet.\n");
|
||||
return(0);
|
||||
#endif
|
||||
|
||||
} else if(strncmp(argv[i],"modesty_on_drive=",17)==0) {
|
||||
#ifdef Cdrskin_libburn_has_set_waitinG
|
||||
value_pt= argv[i]+17;
|
||||
if(*value_pt=='0') {
|
||||
skin->modesty_on_drive= 0;
|
||||
if(skin->verbosity>=Cdrskin_verbose_cmD)
|
||||
ClN(printf(
|
||||
"cdrskin: modesty_on_drive=0 : buffer waiting by os driver\n"));
|
||||
} else if(*value_pt=='1') {
|
||||
skin->modesty_on_drive= 1;
|
||||
if(skin->verbosity>=Cdrskin_verbose_cmD)
|
||||
ClN(printf(
|
||||
"cdrskin: modesty_on_drive=1 : buffer waiting by libburn\n"));
|
||||
} else if(*value_pt=='-' && argv[i][18]=='1') {
|
||||
skin->modesty_on_drive= -1;
|
||||
if(skin->verbosity>=Cdrskin_verbose_cmD)
|
||||
ClN(printf(
|
||||
"cdrskin: modesty_on_drive=-1 : buffer waiting as libburn defaults\n"));
|
||||
} else {
|
||||
fprintf(stderr,
|
||||
"cdrskin: FATAL : modesty_on_drive= must be -1, 0 or 1\n");
|
||||
return(0);
|
||||
}
|
||||
while(1) {
|
||||
value_pt= strchr(value_pt,':');
|
||||
if(value_pt==NULL)
|
||||
break;
|
||||
value_pt++;
|
||||
if(strncmp(value_pt,"min_percent=",12)==0) {
|
||||
sscanf(value_pt+12,"%lf",&value);
|
||||
if (value<25 || value>100) {
|
||||
fprintf(stderr,
|
||||
"cdrskin: FATAL : modest_on_drive= min_percent value must be between 25 and 100\n");
|
||||
return(0);
|
||||
}
|
||||
skin->min_buffer_percent= value;
|
||||
ClN(printf("cdrskin: modesty_on_drive : %d percent min buffer fill\n",
|
||||
skin->min_buffer_percent));
|
||||
} else if(strncmp(value_pt,"max_percent=",12)==0) {
|
||||
sscanf(value_pt+12,"%lf",&value);
|
||||
if (value<25 || value>100) {
|
||||
fprintf(stderr,
|
||||
"cdrskin: FATAL : modest_on_drive= max_percent value must be between 25 and 100\n");
|
||||
return(0);
|
||||
}
|
||||
skin->max_buffer_percent= value;
|
||||
ClN(printf("cdrskin: modesty_on_drive : %d percent max buffer fill\n",
|
||||
skin->max_buffer_percent));
|
||||
} else {
|
||||
fprintf(stderr,
|
||||
"cdrskin: SORRY : modest_on_drive= unknown option code : %s\n",
|
||||
value_pt);
|
||||
}
|
||||
}
|
||||
#else
|
||||
fprintf(stderr,
|
||||
"cdrskin: SORRY : Option modesty_on_drive= is not available yet.\n");
|
||||
return(0);
|
||||
#endif
|
||||
|
||||
} else if(strcmp(argv[i],"-multi")==0) {
|
||||
#ifdef Cdrskin_libburn_has_multI
|
||||
skin->multi= 1;
|
||||
|
@ -12,7 +12,7 @@
|
||||
|
||||
<CENTER>
|
||||
<A HREF="http://en.wikipedia.org/wiki/D%C3%B6ner_kebab">
|
||||
<IMG SRC="doener_150x200_tr_octx.gif" BORDER=0
|
||||
<IMG SRC="doener_150x200_tr_octx.png" BORDER=0
|
||||
ALT="cdrskin logo: Doener mit Scharf">
|
||||
</A>
|
||||
<P><H2> Homepage of </H2>
|
||||
@ -56,7 +56,7 @@ and to MMC-5 for DVD).
|
||||
GPL software included:<BR>
|
||||
</H2>
|
||||
<DL>
|
||||
<DT>libburn-0.3.6</DT>
|
||||
<DT>libburn-0.3.8</DT>
|
||||
<DD>(by Derek Foreman, Ben Jansens, and team of libburnia.pykix.org)</DD>
|
||||
<DD>transfers data to CD and DVD</DD>
|
||||
</DL>
|
||||
@ -81,18 +81,13 @@ Ports to other usable systems are appreciated. Reports are welcome.
|
||||
<P>
|
||||
<H2>Commands:</H2>
|
||||
<DL>
|
||||
<DT>The goal is to provide some of cdrecord's options in a compatible way.
|
||||
This has been achieved quite sufficiently for the needs of backup tool
|
||||
<A HREF="http://scdbackup.sourceforge.net/main_eng.html">scdbackup</A>
|
||||
and for data CD projects of <A HREF="http://www.k3b.org">K3b</A>
|
||||
(see <A HREF="#examples">examples</A>).
|
||||
Suitability for audio CD frontends has been improved much and is now being
|
||||
evaluated.<BR>
|
||||
Most DVD types are written in pseudo -tao modes which are very different
|
||||
from the write mode DAO used by cdrecord(-ProDVD). With DVD-R[W] cdrskin
|
||||
can use this write mode, too.<BR>
|
||||
Further enhancements depend on people who can describe and discuss their
|
||||
wishes as well as on the development of libburn.</DT>
|
||||
<DT>The most common options of cdrecord for data and audio on CD media
|
||||
are provided in a compatible way.<BR>
|
||||
On single layer DVD media cdrskin is able to perform any recording job
|
||||
which is possible with cdrecord.
|
||||
Other than with cdrecord, options -multi and -tao are supported with
|
||||
certain DVD types.
|
||||
</DT>
|
||||
<BR><BR>
|
||||
<DT>Get an overview of drives and their addresses</DT>
|
||||
<DD>#<KBD> cdrskin -scanbus</KBD></DD>
|
||||
@ -160,7 +155,6 @@ as listed by option --devices.</DT>
|
||||
<DT>Read the detailed manual page:</DT>
|
||||
<DD>$<KBD> <A HREF="man_1_cdrskin.html">man cdrskin</A></KBD></DD>
|
||||
</DL>
|
||||
|
||||
<DL>
|
||||
<DT>Read about the standard for which cdrskin is striving:</DT>
|
||||
<DD>$<KBD>
|
||||
@ -171,6 +165,9 @@ man cdrecord</A></KBD></DD>
|
||||
this "don't bother Joerg" demand.)
|
||||
</DD>
|
||||
</DL>
|
||||
|
||||
Testers wanted who are willing to risk some double layer DVD media.
|
||||
|
||||
</P>
|
||||
|
||||
<HR>
|
||||
@ -178,8 +175,8 @@ man cdrecord</A></KBD></DD>
|
||||
<P>
|
||||
<DL>
|
||||
<DT>Download as source code (see README):</DT>
|
||||
<DD><A HREF="cdrskin-0.3.6.pl00.tar.gz">cdrskin-0.3.6.pl00.tar.gz</A>
|
||||
(605 KB).
|
||||
<DD><A HREF="cdrskin-0.3.8.pl00.tar.gz">cdrskin-0.3.8.pl00.tar.gz</A>
|
||||
(615 KB).
|
||||
</DD>
|
||||
<DD>
|
||||
The "stable" cdrskin tarballs are source code identical with "stable"
|
||||
@ -189,14 +186,14 @@ cdrskin is part of libburn - full libburn is provided with cdrskin releases.
|
||||
</DD>
|
||||
<DD> </DD>
|
||||
<DT>Download as single x86 binaries (untar and move to /usr/bin/cdrskin):</DT>
|
||||
<DD><A HREF="cdrskin_0.3.6.pl00-x86-suse9_0.tar.gz">
|
||||
cdrskin_0.3.6.pl00-x86-suse9_0.tar.gz</A>, (90 KB),
|
||||
<DD><A HREF="cdrskin_0.3.8.pl00-x86-suse9_0.tar.gz">
|
||||
cdrskin_0.3.8.pl00-x86-suse9_0.tar.gz</A>, (90 KB),
|
||||
<DL>
|
||||
<DD>runs on SuSE 9.0 (2.4.21) , RIP-14.4 (2.6.14) ,
|
||||
Gentoo (2.6.15 x86_64 Athlon).</DD>
|
||||
</DL>
|
||||
<DD><A HREF="cdrskin_0.3.6.pl00-x86-suse9_0-static.tar.gz">
|
||||
cdrskin_0.3.6.pl00-x86-suse9_0-static.tar.gz</A>, (290 KB), -static compiled,
|
||||
<DD><A HREF="cdrskin_0.3.8.pl00-x86-suse9_0-static.tar.gz">
|
||||
cdrskin_0.3.8.pl00-x86-suse9_0-static.tar.gz</A>, (290 KB), -static compiled,
|
||||
<DL>
|
||||
<DD>runs on SuSE 7.2 (2.4.4), and on the systems above.</DD>
|
||||
</DL>
|
||||
@ -225,14 +222,16 @@ cdrskin_0.3.6.pl00-x86-suse9_0-static.tar.gz</A>, (290 KB), -static compiled,
|
||||
<P>
|
||||
Enhancements towards previous stable version cdrskin-0.3.4:
|
||||
<UL>
|
||||
<LI>Use of /dev/srN rather than /dev/sgN on Linux >= 2.6</LI>
|
||||
<LI>Option drive_scsi_dev_family=sr|scd|sg to select explicitely</LI>
|
||||
<LI>Option -isosize is supported now</LI>
|
||||
<LI>DVD+R now get finalized (if not -multi is given)</LI>
|
||||
<LI>Now able to cope with the peculiarities of Linux 2.4 USB</LI>
|
||||
<LI>Refusal to perform -dummy runs on media which cannot simulate burning</LI>
|
||||
<LI>Precautions against using the burner drive as track source</LI>
|
||||
<LI>New option modesty_on_drive= may help with hda -> hdb burns</LI>
|
||||
<LI>New option minbuf= , cdrecord compatible frontend of modesty_on_drive=</LI>
|
||||
<LI>New option --adjust_speed_to_drive</LI>
|
||||
</UL>
|
||||
|
||||
<!--
|
||||
Bug fixes towards cdrskin-0.3.6.pl00:
|
||||
Bug fixes towards cdrskin-0.3.8.pl00:
|
||||
<UL>
|
||||
<LI>none yet</LI>
|
||||
</UL>
|
||||
@ -244,17 +243,17 @@ Enhancements towards previous stable version cdrskin-0.3.4:
|
||||
|
||||
<P>
|
||||
<DL>
|
||||
<DT><H3>Development snapshot, version 0.3.7 :</H3></DT>
|
||||
<DD>Enhancements towards stable version 0.3.6.pl00:
|
||||
<DT><H3>Development snapshot, version 0.3.9 :</H3></DT>
|
||||
<DD>Enhancements towards stable version 0.3.8.pl00:
|
||||
<UL>
|
||||
<LI>-none yet-</LI>
|
||||
<LI>none yet</LI>
|
||||
</UL>
|
||||
</DD>
|
||||
<DD> </DD>
|
||||
<DD><A HREF="README_cdrskin_devel">README 0.3.7</A>
|
||||
<DD><A HREF="cdrskin__help_devel">cdrskin_0.3.7 --help</A></DD>
|
||||
<DD><A HREF="cdrskin_help_devel">cdrskin_0.3.7 -help</A></DD>
|
||||
<DD><A HREF="man_1_cdrskin_devel.html">man cdrskin (as of 0.3.7)</A></DD>
|
||||
<DD><A HREF="README_cdrskin_devel">README 0.3.9</A>
|
||||
<DD><A HREF="cdrskin__help_devel">cdrskin_0.3.9 --help</A></DD>
|
||||
<DD><A HREF="cdrskin_help_devel">cdrskin_0.3.9 -help</A></DD>
|
||||
<DD><A HREF="man_1_cdrskin_devel.html">man cdrskin (as of 0.3.9)</A></DD>
|
||||
<DD> </DD>
|
||||
<DT>Maintainers of cdrskin unstable packages please use SVN of
|
||||
<A HREF="http://libburnia.pykix.org"> libburnia.pykix.org</A></DT>
|
||||
@ -274,15 +273,15 @@ admins with full system souvereignty.</DT>
|
||||
<A HREF="README_cdrskin_devel">upcoming README</A> ):
|
||||
</DD>
|
||||
<DD>
|
||||
<A HREF="cdrskin-0.3.7.tar.gz">cdrskin-0.3.7.tar.gz</A>
|
||||
(605 KB).
|
||||
<A HREF="cdrskin-0.3.9.tar.gz">cdrskin-0.3.9.tar.gz</A>
|
||||
(615 KB).
|
||||
</DD>
|
||||
<DD>Binary (untar and move to /usr/bin/cdrskin):</DD>
|
||||
<DD><A HREF="cdrskin_0.3.7-x86-suse9_0.tar.gz">
|
||||
cdrskin_0.3.7-x86-suse9_0.tar.gz</A>, (90 KB).
|
||||
<DD><A HREF="cdrskin_0.3.9-x86-suse9_0.tar.gz">
|
||||
cdrskin_0.3.9-x86-suse9_0.tar.gz</A>, (90 KB).
|
||||
</DD>
|
||||
<DD><A HREF="cdrskin_0.3.7-x86-suse9_0-static.tar.gz">
|
||||
cdrskin_0.3.7-x86-suse9_0-static.tar.gz</A>, (285 KB)
|
||||
<DD><A HREF="cdrskin_0.3.9-x86-suse9_0-static.tar.gz">
|
||||
cdrskin_0.3.9-x86-suse9_0-static.tar.gz</A>, (290 KB)
|
||||
</DD>
|
||||
</DL>
|
||||
</P>
|
||||
@ -353,7 +352,7 @@ is a GUI frontend which uses cdrecord for CD burning.)
|
||||
<DD>$ <KBD><B>export SCDBACKUP_USE_CDRSKIN=1</B></KBD></DD>
|
||||
<DD>$ <KBD><B>./CONFIGURE_CD</B></KBD></DD>
|
||||
<DD><KBD>...</KBD></DD>
|
||||
<DD><KBD>cdrskin 0.3.6 : limited cdrecord compatibility wrapper for libburn</KBD></DD>
|
||||
<DD><KBD>cdrskin 0.3.8 : limited cdrecord compatibility wrapper for libburn</KBD></DD>
|
||||
</DL>
|
||||
If your system is stricken with some ill CD device then this can stall
|
||||
and you will have to press <KBD>Ctrl+C</KBD> to abort.
|
||||
@ -430,7 +429,7 @@ I owe him much. For cdrecord, for mkisofs, for star. Chapeau.
|
||||
<BR><BR>
|
||||
-->
|
||||
<A HREF="http://en.wikipedia.org/wiki/D%C3%B6ner_kebab">
|
||||
<IMG SRC="doener_150x200_tr.gif" BORDER=0
|
||||
<IMG SRC="doener_150x200_tr.png" BORDER=0
|
||||
ALT="cdrskin logo: Doener mit Scharf"></A>
|
||||
<BR><BR>
|
||||
<FONT SIZE=+0>Enjoying free Open Source hosting by <A HREF="http://www.webframe.org">www.webframe.org</A><BR>
|
||||
|
@ -1 +1 @@
|
||||
#define Cdrskin_timestamP "2007.04.23.130001"
|
||||
#define Cdrskin_timestamP "2007.07.20.120001"
|
||||
|
@ -3627,36 +3627,298 @@ Declared failure of DDLP to entirely solve the concurrency problem
|
||||
|
||||
------------------------------------ cycle - cdrskin-0.3.5 - 2007.04.22.112236
|
||||
|
||||
22 Apr 2007 []
|
||||
22 Apr 2007 [836]
|
||||
cdrskin/changelog.txt
|
||||
Next cdrskin-0.3.5 cycle
|
||||
|
||||
[]
|
||||
22 Apr 2007 [837]
|
||||
cdrskin/add_ts_changes_to_libburn_0_3_5
|
||||
cdrskin/add_ts_changes_to_libburn_0_3_4
|
||||
Repaired autotools bootstrap bug by help of sed
|
||||
|
||||
22 Apr 2007 [838]
|
||||
cdrskin/cdrskin.1
|
||||
Changed many /dev/sg to /dev/sr
|
||||
|
||||
|
||||
2007.04.23.130001 [tag 841]
|
||||
Makefile.am
|
||||
configure.ac
|
||||
README
|
||||
cdrskin/cdrskin.c
|
||||
cdrskin/README
|
||||
cdrskin/compile_cdrskin.sh
|
||||
cdrskin/cdrskin_timestamp.h
|
||||
cdrskin/wiki_plain.txt
|
||||
cdrskin/cdrskin_eng.html
|
||||
doc/comments
|
||||
Made number transition and activated development documentation
|
||||
|
||||
23 Apr 2007 [tag 842]
|
||||
- cdrskin/add_ts_changes_to_libburn_0_3_4
|
||||
- cdrskin/add_ts_changes_to_libburn_0_3_5
|
||||
+ cdrskin/add_ts_changes_to_libburn_0_3_6
|
||||
+ cdrskin/add_ts_changes_to_libburn_0_3_7
|
||||
Updated cdrskin tarball generator
|
||||
|
||||
23 Apr 2007 [tag 844]
|
||||
cdrskin/README
|
||||
Corrected false info about outdated addressing method
|
||||
|
||||
2007.04.23.154600 [843]
|
||||
Makefile.am
|
||||
configure.ac
|
||||
README
|
||||
cdrskin/cdrskin.c
|
||||
cdrskin/README
|
||||
cdrskin/compile_cdrskin.sh
|
||||
cdrskin/wiki_plain.txt
|
||||
cdrskin/cdrskin_eng.html
|
||||
doc/comments
|
||||
Made number transition and activated development documentation
|
||||
|
||||
23 Apr 2007 [845]
|
||||
- cdrskin/add_ts_changes_to_libburn_0_3_4
|
||||
- cdrskin/add_ts_changes_to_libburn_0_3_5
|
||||
+ cdrskin/add_ts_changes_to_libburn_0_3_6
|
||||
+ cdrskin/add_ts_changes_to_libburn_0_3_7
|
||||
Updated cdrskin tarball generator
|
||||
|
||||
|
||||
----------------------------- release - cdrskin-0.3.6.pl00 - 2007.04.23.130001
|
||||
* Usage of /dev/srN rather than /dev/sgN on Linux >= 2.6
|
||||
* New option drive_scsi_dev_family=sr|scd|sg
|
||||
* Option -isosize is supported now
|
||||
* DVD+R now get finalized (if not -multi is given)
|
||||
|
||||
|
||||
2007.04.23.171735 [846]
|
||||
cdrskin/changelog.txt
|
||||
Next cdrskin-0.3.7 cycle
|
||||
|
||||
|
||||
------------------------------------ cycle - cdrskin-0.3.7 - 2007.04.24.113310
|
||||
|
||||
2007.05.21.184334 [853]
|
||||
libburn/sg-linux.c
|
||||
Prepared fflushing and stderr output of SCSI command log
|
||||
|
||||
2007.05.21.185450 [854]
|
||||
libburn/sbc.c
|
||||
libburn/spc.h
|
||||
libburn/spc.c
|
||||
libburn/mmc.c
|
||||
libburn/toc.c
|
||||
libburn/transport.h
|
||||
For Linux 2.4, USB : Carefully avoided to inquire more data than available
|
||||
|
||||
2007.05.21.185644 [855]
|
||||
libburn/sector.c
|
||||
libburn/write.c
|
||||
For Linux 2.4, USB audio : Reduced CD output buffer size to 32 kiB
|
||||
|
||||
21 May 2007 [856]
|
||||
cdrskin/cdrskin_eng.html
|
||||
cdrskin/changelog.txt
|
||||
Next cdrskin-0.3.7 cycle
|
||||
|
||||
|
||||
------------------------------------ cycle - cdrskin-0.3.7 - 2007.05.21.201501
|
||||
* Now able to cope with the peculiarities of Linux 2.4 USB
|
||||
|
||||
|
||||
2007.05.22.154407 [857]
|
||||
libburn/sg-linux.c
|
||||
Report eventual sg_io_hdr_t host_status,driver_status as debug messages
|
||||
|
||||
2007.05.22.154504 [858]
|
||||
cdrskin/cdrskin.c
|
||||
Disabled macro Cdrskin_debug_libdax_msgS. Thus getting unqueued error messages.
|
||||
|
||||
2007.05.22.164850 [859]
|
||||
libburn/sg-linux.c
|
||||
Added SCSI opcode to output of revision 857
|
||||
|
||||
2007.05.28.132412 [860]
|
||||
libburn/os-linux.h
|
||||
libburn/write.c
|
||||
Moved general 32 kiB buffer restriction from write.c to os-linux.h
|
||||
|
||||
2007.05.28.165630 [861]
|
||||
libburn/libburn.h
|
||||
libburn/drive.c
|
||||
test/telltoc.c
|
||||
Extended struct burn_multi_caps by .might_simulate
|
||||
|
||||
28 May 2007 [862]
|
||||
libburn/libdax_msgs.h
|
||||
Forgotten update of error list with revison 857
|
||||
|
||||
2007.05.28.170243 [863]
|
||||
libburn/options.c
|
||||
cdrskin/cdrskin.1
|
||||
Added check for .might_simulate to burn_write_opts_auto_write_type()
|
||||
|
||||
2007.05.28.192421 [864]
|
||||
libburn/sector.c
|
||||
Fixed low transaction size introduced by cooperation of revisions 855 and 860
|
||||
|
||||
|
||||
------------------------------------ cycle - cdrskin-0.3.7 - 2007.05.28.192853
|
||||
* Refusal to perform -dummy runs on media which cannot simulate burning
|
||||
|
||||
29 May 2007 [865]
|
||||
cdrskin/cdrskin_eng.html
|
||||
cdrskin/changelog.txt
|
||||
Next cdrskin-0.3.7 cycle
|
||||
|
||||
8 Jun 2007 [873]
|
||||
- cdrskin/doener_150x200_tr.gif
|
||||
- cdrskin/doener_150x200_tr_octx.gif
|
||||
+ cdrskin/doener_150x200_tr.png
|
||||
+ cdrskin/doener_150x200_tr_octx.png
|
||||
cdrskin/cdrskin_eng.html
|
||||
Changed logo graphics format from GIF to PNG
|
||||
|
||||
8 Jun 2007 [874]
|
||||
cdrskin/wiki_plain.txt
|
||||
cdrskin/add_ts_changes_to_libburn_0_3_6
|
||||
cdrskin/add_ts_changes_to_libburn_0_3_7
|
||||
Took into respect change of logo graphics format
|
||||
|
||||
8 Jun 2007 [875]
|
||||
cdrskin/cdrskin.1
|
||||
Prevented macro interpretation of text snippet ".wav"
|
||||
|
||||
10 Jun 2007 [876]
|
||||
cdrskin/README
|
||||
cdrskin/cdrskin.1
|
||||
Clarified MB to MiB if compatibility allows it (ticket 100)
|
||||
|
||||
10 Jun 2007 [877]
|
||||
cdrskin/cdrskin.1
|
||||
doc/cookbook.txt
|
||||
test/libburner.c
|
||||
Changed "KB" to "kiB"
|
||||
|
||||
------------------------------------ cycle - cdrskin-0.3.7 - 2007.06.10.081025
|
||||
|
||||
|
||||
2007.07.12.162856 [882]
|
||||
libburn/transport.h
|
||||
libburn/mmc.c
|
||||
libburn/write.c
|
||||
libburn/libdax_msgs.h
|
||||
Preparations to avoid writing which will not fit in drive buffer
|
||||
|
||||
2007.07.12.171727 [883]
|
||||
libburn/libburn.h
|
||||
libburn/drive.c
|
||||
New API-Function burn_drive_set_buffer_waiting()
|
||||
|
||||
2007.07.12.171832 [884]
|
||||
cdrskin/cdrskin.c
|
||||
cdrskin/cdrskin.1
|
||||
New options modesty_on_drive= and minbuf=
|
||||
|
||||
2007.07.14.111614 [885]
|
||||
libburn/libburn.h
|
||||
libburn/drive.c
|
||||
New API function burn_drive_get_best_speed()
|
||||
|
||||
2007.07.14.112029 [886]
|
||||
libburn/mmc.c
|
||||
Only set realistic maximum DVD speeds (for my LG GSA which fails otherwise)
|
||||
|
||||
2007.07.14.112326 [887]
|
||||
cdrskin/cdrskin.c
|
||||
Experimental option --adjust_speed_to_drive. Caution: May vanish soon.
|
||||
|
||||
17 Jul 2007 [888]
|
||||
cdrskin/cdrskin.1
|
||||
Clarification on option speed=
|
||||
|
||||
2007.07.17.085823 [889]
|
||||
libburn/libburn.h
|
||||
libburn/drive.c
|
||||
libburn/mmc.c
|
||||
cdrskin/cdrskin.c
|
||||
Implemented minimum speed in burn_drive_set_speed()
|
||||
|
||||
2007.07.19.072434 [890]
|
||||
libburn/libburn.h
|
||||
cdrskin/cdrskin.c
|
||||
cdrskin/cdrskin.1
|
||||
Removed ban against speed 0 with burn_drive_set_buffer_waiting()
|
||||
|
||||
2007.07.19.143139 [891]
|
||||
cdrskin/cdrskin.c
|
||||
Trying to prevent usage of burn drive as track source
|
||||
|
||||
2007.07.19.171947 [892]
|
||||
cdrskin/cdrskin.c
|
||||
Avoided new track-drive test with option --no_convert_fs_adr
|
||||
|
||||
19 Jul 2007 [893]
|
||||
cdrskin/cdrskin.1
|
||||
Documented option --adjust_speed_to_drive (i.e. it will stay)
|
||||
|
||||
19 Jul 2007 [894]
|
||||
cdrskin/changelog.txt
|
||||
Next cdrskin-0.3.7 cycle
|
||||
|
||||
19 Jul 2007 [895]
|
||||
cdrskin/cdrskin_eng.html
|
||||
Next cdrskin-0.3.7 cycle
|
||||
|
||||
------------------------------------ cycle - cdrskin-0.3.7 - 2007.07.19.174859
|
||||
* New option modesty_on_drive= may help with hda -> hdb burns
|
||||
* New option minbuf= , cdrecord compatible frontend of modesty_on_drive=
|
||||
* New option --adjust_speed_to_drive
|
||||
* Precautions against using the burner drive as track source
|
||||
|
||||
|
||||
2007.07.20.120001 [branch 897]
|
||||
Makefile.am
|
||||
configure.ac
|
||||
README
|
||||
cdrskin/cdrskin.c
|
||||
cdrskin/README
|
||||
cdrskin/compile_cdrskin.sh
|
||||
cdrskin/cdrskin_timestamp.h
|
||||
cdrskin/cdrskin_eng.html
|
||||
Made number transition to 0.3.8
|
||||
|
||||
20 Jul 2007 [branch 898]
|
||||
- cdrskin/add_ts_changes_to_libburn_0_3_6
|
||||
- cdrskin/add_ts_changes_to_libburn_0_3_7
|
||||
+ cdrskin/add_ts_changes_to_libburn_0_3_8
|
||||
+ cdrskin/add_ts_changes_to_libburn_0_3_9
|
||||
Updated cdrskin tarball generators
|
||||
|
||||
|
||||
----------------------------- release - cdrskin-0.3.8.pl00 - 2007.07.
|
||||
* Now able to cope with the peculiarities of Linux 2.4 USB
|
||||
* Refusal to perform -dummy runs on media which cannot simulate burning
|
||||
* New option modesty_on_drive= may help with hda -> hdb burns
|
||||
* New option minbuf= , cdrecord compatible frontend of modesty_on_drive=
|
||||
* New option --adjust_speed_to_drive
|
||||
* Precautions against using the burner drive as track source
|
||||
|
||||
|
||||
===============================================================================
|
||||
TODO
|
||||
===============================================================================
|
||||
|
||||
------------------------------------ cycle - cdrskin-0.3.5 -
|
||||
------------------------------------ cycle - cdrskin-0.3.7 -
|
||||
cdrskin/changelog.txt
|
||||
Next cdrskin-0.3.5 cycle
|
||||
Next cdrskin-0.3.7 cycle
|
||||
|
||||
|
||||
|
||||
cdrskin: prevent usage of burn drive as track source
|
||||
|
||||
Think about cdrecord option minbuf= for simultaneous operation on hdc and hdd
|
||||
|
||||
|
||||
What about minimum track sizes ? (POWER OFF/ON , BUS RESET ?)
|
||||
|
||||
How to handle finalizing ?
|
||||
growisofs does not finalize multi-session DVD[+-]R unless padding up. Why ?
|
||||
|
||||
|
||||
After cooking: review of -do_diet ?
|
||||
|
||||
@ -3673,23 +3935,14 @@ Disable error checking with DVD-RAM.
|
||||
|
||||
Rectify mmc_read_atip speed interpretation. 12x media are reported as 10x. I never heard of 6x media.
|
||||
|
||||
Sequentially check option list for DVD compliance
|
||||
|
||||
|
||||
----------------------------------------- long term intentions:
|
||||
|
||||
[]
|
||||
Ticket 90: failure on USB
|
||||
|
||||
[]
|
||||
-reset: ioctl(fd,CDROMRESET) ioctl(fd,SG_SCSI_RESET,SG_SCSI_RESET_DEVICE)
|
||||
http://developer.osdl.org/dev/robustmutexes/src/fusyn.hg/Documentation/ioctl/cdrom.txt
|
||||
|
||||
|
||||
[]
|
||||
Open O_EXCL all devices in address resolution chain
|
||||
(Might help with non-standard hdX device siblings)
|
||||
|
||||
[]
|
||||
Convert burn_print() into libdax_msgs_submit()
|
||||
|
||||
@ -3703,5 +3956,5 @@ Clear outdated persistent read buffer after small CD image was read (ticket 57)
|
||||
|
||||
===============================================================================
|
||||
This is the dirty end of the todo list.
|
||||
For most recent changelog entries scroll up about 100 lines.
|
||||
The recent changelog entries are above the headline "TODO".
|
||||
===============================================================================
|
||||
|
@ -7,7 +7,7 @@
|
||||
debug_opts=
|
||||
def_opts=
|
||||
largefile_opts="-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE=1"
|
||||
libvers="-DCdrskin_libburn_0_3_6"
|
||||
libvers="-DCdrskin_libburn_0_3_8"
|
||||
cleanup_src_or_obj="libburn/cleanup.o"
|
||||
libdax_msgs_o="libburn/libdax_msgs.o"
|
||||
libdax_audioxtr_o="libburn/libdax_audioxtr.o"
|
||||
@ -33,15 +33,15 @@ do
|
||||
libdax_audioxtr_o=
|
||||
libdax_msgs_o="libburn/message.o"
|
||||
cleanup_src_or_obj="-DCleanup_has_no_libburn_os_H cdrskin/cleanup.c"
|
||||
elif test "$i" = "-libburn_0_3_6"
|
||||
elif test "$i" = "-libburn_0_3_8"
|
||||
then
|
||||
libvers="-DCdrskin_libburn_0_3_6"
|
||||
libvers="-DCdrskin_libburn_0_3_8"
|
||||
libdax_audioxtr_o="libburn/libdax_audioxtr.o"
|
||||
libdax_msgs_o="libburn/libdax_msgs.o"
|
||||
cleanup_src_or_obj="libburn/cleanup.o"
|
||||
elif test "$i" = "-libburn_svn"
|
||||
then
|
||||
libvers="-DCdrskin_libburn_0_3_7"
|
||||
libvers="-DCdrskin_libburn_0_3_9"
|
||||
libdax_audioxtr_o="libburn/libdax_audioxtr.o"
|
||||
libdax_msgs_o="libburn/libdax_msgs.o"
|
||||
cleanup_src_or_obj="libburn/cleanup.o"
|
||||
@ -79,7 +79,7 @@ do
|
||||
echo " -compile_cdrfifo compile program cdrskin/cdrfifo."
|
||||
echo " -compile_dewav compile program test/dewav without libburn."
|
||||
echo " -cvs_A60220 set macro to match libburn-CVS of 20 Feb 2006."
|
||||
echo " -libburn_0_3_6 set macro to match libburn-0.3.6 (default)."
|
||||
echo " -libburn_0_3_8 set macro to match libburn-0.3.8."
|
||||
echo " -libburn_svn set macro to match current libburn-SVN."
|
||||
echo " -no_largefile do not use 64 bit off_t (must match libburn)."
|
||||
echo " -do_not_compile_cdrskin omit compilation of cdrskin/cdrskin."
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 34 KiB |
BIN
cdrskin/doener_150x200_tr.png
Normal file
BIN
cdrskin/doener_150x200_tr.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 10 KiB |
Binary file not shown.
Before Width: | Height: | Size: 29 KiB |
BIN
cdrskin/doener_150x200_tr_octx.png
Normal file
BIN
cdrskin/doener_150x200_tr_octx.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 9.2 KiB |
@ -1,7 +1,7 @@
|
||||
--------------------------------------------------------------------------
|
||||
cdrskin Wiki - plain text copy
|
||||
--------------------------------------------------------------------------
|
||||
[[Image(source:/libburn/trunk/cdrskin/doener_150x200_tr.gif)]] [http://en.wikipedia.org/wiki/D%C3%B6ner_kebab Doener]
|
||||
[[Image(source:/libburn/trunk/cdrskin/doener_150x200_tr.png)]] [http://en.wikipedia.org/wiki/D%C3%B6ner_kebab Doener]
|
||||
|
||||
'''cdrskin is the cdrecord compatibility middleware of libburn.'''
|
||||
|
||||
@ -127,7 +127,7 @@ E.g. cdrskin aborts with an error message if
|
||||
{{{
|
||||
assert_write_lba=0
|
||||
}}}
|
||||
is given but an appendable media is to be burned which would start ati
|
||||
is given but an appendable media is to be burned which would start at
|
||||
block 68432.
|
||||
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
AC_INIT([libburn], [0.3.6], [http://libburnia.pykix.org])
|
||||
AC_INIT([libburn], [0.3.8], [http://libburnia.pykix.org])
|
||||
AC_PREREQ([2.50])
|
||||
dnl AC_CONFIG_HEADER([config.h])
|
||||
|
||||
@ -19,7 +19,7 @@ dnl if MAJOR or MINOR version changes, be sure to change AC_INIT above to match
|
||||
dnl
|
||||
BURN_MAJOR_VERSION=0
|
||||
BURN_MINOR_VERSION=3
|
||||
BURN_MICRO_VERSION=6
|
||||
BURN_MICRO_VERSION=8
|
||||
BURN_INTERFACE_AGE=0
|
||||
BURN_BINARY_AGE=0
|
||||
BURN_VERSION=$BURN_MAJOR_VERSION.$BURN_MINOR_VERSION.$BURN_MICRO_VERSION
|
||||
@ -33,7 +33,7 @@ AC_SUBST(BURN_VERSION)
|
||||
|
||||
dnl Libtool versioning
|
||||
LT_RELEASE=$BURN_MAJOR_VERSION.$BURN_MINOR_VERSION
|
||||
LT_CURRENT=`expr $BURN_MICRO_VERSION - $BURN_INTERFACE_AGE`
|
||||
LT_CURRENT=4
|
||||
LT_REVISION=$BURN_INTERFACE_AGE
|
||||
LT_AGE=`expr $BURN_BINARY_AGE - $BURN_INTERFACE_AGE`
|
||||
LT_CURRENT_MINUS_AGE=`expr $LT_CURRENT - $LT_AGE`
|
||||
|
@ -788,12 +788,12 @@ growisofs (transport.hxx) sets Link Size to 16 for profiles 0011h and 0014h.
|
||||
libburn now records the first link size from feature 0021h in its burn_drive
|
||||
structure. If another link size item is 16, then 16 is used.
|
||||
[*4:]
|
||||
growisofs takes Packet Size from 52h. Specs predict it will be 16 (= 32 kB).
|
||||
growisofs takes Packet Size from 52h. Specs predict it will be 16 (= 32 kiB).
|
||||
(mmc5r03.pdf 7.5.4.16)
|
||||
|
||||
The writing process is much like in "Writing a session to CD in TAO mode" :
|
||||
Next Writeable Address is fetched from the reply of 52h READ TRACK INFORMATION.
|
||||
libburn writes full 32 kB buffers via 2Ah WRITE.
|
||||
libburn writes full 32 kiB buffers via 2Ah WRITE.
|
||||
(mmc5r03c.pdf, 6.27 READ TRACK INFORMATION, 6.44 WRITE)
|
||||
When writing is done, it is mandatory to force the drive's buffer to media by
|
||||
35h SYNCHRONIZE CACHE.
|
||||
@ -860,7 +860,8 @@ tested yet, what happens if not enough data get written.
|
||||
(mmc5r03c.pdf 6.31)
|
||||
|
||||
Next Writeable Address is fetched from the reply of 52h READ TRACK INFORMATION.
|
||||
The reply is supposed to be 0. libburn writes full 32 kB buffers via 2Ah WRITE.
|
||||
The reply is supposed to be 0. libburn writes full 32 kiB buffers via
|
||||
2Ah WRITE.
|
||||
(mmc5r03c.pdf, 6.27 READ TRACK INFORMATION, 6.44 WRITE)
|
||||
If the track source delivers less than the announced size then libburn pads up
|
||||
by zeros.
|
||||
@ -1063,7 +1064,7 @@ The specs promise to pad up the track if not enough data get written.
|
||||
Next Writeable Address is fetched from the reply of 52h READ TRACK INFORMATION
|
||||
with track number FFh.
|
||||
(mmc5r03c.pdf 6.27)
|
||||
Since the fixely set write type is 16-block packet, full 32 kB buffers have
|
||||
Since the fixely set write type is 16-block packet, full 32 kiB buffers have
|
||||
to be transmitted via 2Ah WRITE.
|
||||
(mmc5r03c.pdf 4.3.6.2.2)
|
||||
|
||||
|
@ -857,6 +857,35 @@ void burn_drive_set_speed(struct burn_drive *d, int r, int w)
|
||||
d->set_speed(d, r, w);
|
||||
}
|
||||
|
||||
|
||||
/* ts A70711 API function */
|
||||
int burn_drive_set_buffer_waiting(struct burn_drive *d, int enable,
|
||||
int min_usec, int max_usec, int timeout_sec,
|
||||
int min_percent, int max_percent)
|
||||
{
|
||||
|
||||
if (enable >= 0)
|
||||
d->wait_for_buffer_free = !!enable;
|
||||
if (min_usec >= 0)
|
||||
d->wfb_min_usec = min_usec;
|
||||
if (max_usec >= 0)
|
||||
d->wfb_max_usec = max_usec;
|
||||
if (timeout_sec >= 0)
|
||||
d->wfb_timeout_sec = timeout_sec;
|
||||
if (min_percent >= 0) {
|
||||
if (min_percent < 25 || min_percent > 100)
|
||||
return 0;
|
||||
d->wfb_min_percent = min_percent;
|
||||
}
|
||||
if (max_percent >= 0) {
|
||||
if (max_percent < 25 || max_percent > 100)
|
||||
return 0;
|
||||
d->wfb_max_percent = max_percent;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
int burn_msf_to_sectors(int m, int s, int f)
|
||||
{
|
||||
return (m * 60 + s) * 75 + f;
|
||||
@ -1022,7 +1051,6 @@ int burn_drive_is_enumerable_adr(char *adr)
|
||||
#define BURN_DRIVE_MAX_LINK_DEPTH 20
|
||||
|
||||
/* ts A60922 ticket 33 */
|
||||
/* Try to find an enumerated address with the given stat.st_rdev number */
|
||||
int burn_drive_resolve_link(char *path, char adr[], int *recursion_count)
|
||||
{
|
||||
int ret;
|
||||
@ -1586,6 +1614,55 @@ int burn_drive_get_speedlist(struct burn_drive *d,
|
||||
}
|
||||
|
||||
|
||||
/* ts A70713 : API function */
|
||||
int burn_drive_get_best_speed(struct burn_drive *d, int speed_goal,
|
||||
struct burn_speed_descriptor **best_descr, int flag)
|
||||
{
|
||||
struct burn_speed_descriptor *sd;
|
||||
int best_speed = 0, best_lba = 0, source= 2, speed;
|
||||
|
||||
if (flag & 2)
|
||||
source = -1;
|
||||
if (speed_goal < 0)
|
||||
best_speed = 2000000000;
|
||||
*best_descr = NULL;
|
||||
for (sd = d->mdata->speed_descriptors; sd != NULL; sd = sd->next) {
|
||||
if (flag & 1)
|
||||
speed = sd->read_speed;
|
||||
else
|
||||
speed = sd->write_speed;
|
||||
if ((source >= 0 && sd->source != source) ||
|
||||
speed <= 0)
|
||||
continue;
|
||||
if (speed_goal < 0) {
|
||||
if (speed < best_speed) {
|
||||
best_speed = speed;
|
||||
*best_descr = sd;
|
||||
}
|
||||
} else if (speed_goal == 0) {
|
||||
if ((source == 2 && sd->end_lba > best_lba) ||
|
||||
((source !=2 || sd->end_lba == best_lba) &&
|
||||
speed > best_speed)) {
|
||||
best_lba = sd->end_lba;
|
||||
best_speed = speed;
|
||||
*best_descr = sd;
|
||||
}
|
||||
} else if (speed <= speed_goal) {
|
||||
if (speed > best_speed) {
|
||||
best_speed = speed;
|
||||
*best_descr = sd;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (d->current_is_cd_profile && *best_descr == NULL && ! (flag & 2))
|
||||
/* Mode page 2Ah is deprecated in MMC-5 although all known
|
||||
burners still support it with CD media. */
|
||||
return burn_drive_get_best_speed(d, speed_goal, best_descr,
|
||||
flag | 2);
|
||||
return (*best_descr != NULL);
|
||||
}
|
||||
|
||||
|
||||
/* ts A61226 : API function */
|
||||
int burn_drive_free_speedlist(struct burn_speed_descriptor **speed_list)
|
||||
{
|
||||
@ -1620,6 +1697,7 @@ int burn_disc_get_multi_caps(struct burn_drive *d, enum burn_write_types wt,
|
||||
o->selected_write_mode = wt;
|
||||
o->current_profile = d->current_profile;
|
||||
o->current_is_cd_profile = d->current_is_cd_profile;
|
||||
o->might_simulate = 0;
|
||||
|
||||
if (s != BURN_DISC_BLANK && s != BURN_DISC_APPENDABLE) {
|
||||
return 0;
|
||||
@ -1649,6 +1727,9 @@ int burn_disc_get_multi_caps(struct burn_drive *d, enum burn_write_types wt,
|
||||
}
|
||||
if (wt == BURN_WRITE_RAW)
|
||||
o->multi_session = o->multi_track = 0;
|
||||
else if(wt == BURN_WRITE_NONE || wt == BURN_WRITE_SAO ||
|
||||
wt == BURN_WRITE_TAO)
|
||||
o->might_simulate = !!d->mdata->simulate;
|
||||
} else if (d->current_profile == 0x11 || d->current_profile == 0x14 ||
|
||||
d->current_profile == 0x15) {
|
||||
/* DVD-R , sequential DVD-RW , DVD-R/DL Sequential */
|
||||
@ -1667,6 +1748,9 @@ int burn_disc_get_multi_caps(struct burn_drive *d, enum burn_write_types wt,
|
||||
}
|
||||
if (wt == BURN_WRITE_SAO)
|
||||
o->multi_session = o->multi_track = 0;
|
||||
if (wt == BURN_WRITE_NONE || wt == BURN_WRITE_SAO ||
|
||||
wt == BURN_WRITE_TAO)
|
||||
o->might_simulate = 1;
|
||||
} else if (d->current_profile == 0x12 || d->current_profile == 0x13 ||
|
||||
d->current_profile == 0x1a) {
|
||||
/* DVD-RAM, overwriteable DVD-RW, DVD+RW */
|
||||
|
@ -455,8 +455,9 @@ struct burn_progress {
|
||||
/* ts A61119 */
|
||||
/** The number of bytes sent to the drive buffer */
|
||||
off_t buffered_bytes;
|
||||
/** The minimum number of buffered bytes. (Caution: Before surely
|
||||
one buffer size of bytes was processed, this value is 0xffffffff.)
|
||||
/** The minimum number of bytes stored in buffer during write.
|
||||
(Caution: Before surely one buffer size of bytes was processed,
|
||||
this value is 0xffffffff.)
|
||||
*/
|
||||
unsigned buffer_min_fill;
|
||||
};
|
||||
@ -1288,12 +1289,51 @@ int burn_track_get_counters(struct burn_track *t,
|
||||
|
||||
|
||||
/** Sets drive read and write speed
|
||||
Note: "k" is 1000, not 1024. 1xCD = 176.4 k/s, 1xDVD = 1385 k/s.
|
||||
Fractional speeds should be rounded up. Like 4xCD = 706.
|
||||
@param d The drive to set speed for
|
||||
@param read Read speed in k/s (0 is max)
|
||||
@param write Write speed in k/s (0 is max)
|
||||
@param read Read speed in k/s (0 is max, -1 is min).
|
||||
@param write Write speed in k/s (0 is max, -1 is min).
|
||||
*/
|
||||
void burn_drive_set_speed(struct burn_drive *d, int read, int write);
|
||||
|
||||
|
||||
/* ts A70711 */
|
||||
/** Controls the behavior with writing when the drive buffer is suspected to
|
||||
be full. To check and wait for enough free buffer space before writing
|
||||
will move the task of waiting from the operating system's device driver
|
||||
to libburn. While writing is going on and waiting is enabled, any write
|
||||
operation will be checked wether it will fill the drive buffer up to
|
||||
more than max_percent. If so, then waiting will happen until the buffer
|
||||
fill is predicted with at most min_percent.
|
||||
Thus: if min_percent < max_percent then transfer rate will oscillate.
|
||||
This may allow the driver to operate on other devices, e.g. a disk from
|
||||
which to read the input for writing. On the other hand, this checking might
|
||||
reduce maximum throughput to the drive or even get misled by faulty buffer
|
||||
fill replies from the drive.
|
||||
If a setting parameter is < 0, then this setting will stay unchanged
|
||||
by the call.
|
||||
Known burner or media specific pitfalls:
|
||||
To have max_percent larger than the burner's best reported buffer fill has
|
||||
the same effect as min_percent==max_percent. Some burners do not report
|
||||
their full buffer with all media types. Some are not suitable because
|
||||
they report their buffer fill with delay.
|
||||
@param d The drive to control
|
||||
@param enable 0= disable , 1= enable waiting , (-1 = do not change setting)
|
||||
@param min_usec Shortest possible sleeping period (given in micro seconds)
|
||||
@param max_usec Longest possible sleeping period (given in micro seconds)
|
||||
@param timeout_sec If a single write has to wait longer than this number
|
||||
of seconds, then waiting gets disabled and mindless
|
||||
writing starts. A value of 0 disables this timeout.
|
||||
@param min_percent Minimum of desired buffer oscillation: 25 to 100
|
||||
@param max_percent Maximum of desired buffer oscillation: 25 to 100
|
||||
@return 1=success , 0=failure
|
||||
*/
|
||||
int burn_drive_set_buffer_waiting(struct burn_drive *d, int enable,
|
||||
int min_usec, int max_usec, int timeout_sec,
|
||||
int min_percent, int max_percent);
|
||||
|
||||
|
||||
/* these are for my debugging, they will disappear */
|
||||
void burn_structure_print_disc(struct burn_disc *d);
|
||||
void burn_structure_print_session(struct burn_session *s);
|
||||
@ -1411,6 +1451,7 @@ void burn_write_opts_set_fillup(struct burn_write_opts *opts,
|
||||
/* ts A70303 */
|
||||
/** Eventually makes libburn ignore the failure of some conformance checks:
|
||||
- the check wether CD write+block type is supported by the drive
|
||||
- the check wether the media profile supports simulated burning
|
||||
@param opts The write opts to change
|
||||
@param use_force 1=ignore above checks, 0=refuse work on failed check
|
||||
*/
|
||||
@ -1513,6 +1554,26 @@ int burn_drive_get_read_speed(struct burn_drive *d);
|
||||
int burn_drive_get_speedlist(struct burn_drive *d,
|
||||
struct burn_speed_descriptor **speed_list);
|
||||
|
||||
/* ts A70713 */
|
||||
/** Look up the fastest speed descriptor which is not faster than the given
|
||||
speed_goal. If it is 0, then the fastest one is chosen among the
|
||||
descriptors with the highest end_lba. If it is -1 then the slowest speed
|
||||
descriptor is chosen regardless of end_lba. Parameter flag decides wether
|
||||
the speed goal means write speed or read speed.
|
||||
@param d Drive to query
|
||||
@param speed_goal Upper limit for speed,
|
||||
0=search for maximum speed , -1 search for minimum speed
|
||||
@param best_descr Result of the search, NULL if no match
|
||||
@param flag Bitfield for control purposes
|
||||
bit0= look for best read speed rather than write speed
|
||||
bit1= look for any source type (else look for source==2 first
|
||||
and for any other source type only with CD media)
|
||||
@return >0 indicates a valid best_descr, 0 = no valid best_descr
|
||||
*/
|
||||
int burn_drive_get_best_speed(struct burn_drive *d, int speed_goal,
|
||||
struct burn_speed_descriptor **best_descr, int flag);
|
||||
|
||||
|
||||
/* ts A61226 */
|
||||
/** Dispose a speed descriptor list copy which was obtained by
|
||||
burn_drive_get_speedlist().
|
||||
@ -1599,6 +1660,10 @@ struct burn_multi_caps {
|
||||
|
||||
/** Wether the current profile indicates CD media. 1=yes, 0=no */
|
||||
int current_is_cd_profile;
|
||||
|
||||
/* ts A70528, added to version 0.3.7 */
|
||||
/** Wether the current profile is able to perform simulated write */
|
||||
int might_simulate;
|
||||
};
|
||||
|
||||
/** Allocates a struct burn_multi_caps (see above) and fills it with values
|
||||
|
@ -366,8 +366,12 @@ Range "scdbackup" : 0x00020000 to 0x0002ffff
|
||||
0x00020138 (FATAL,HIGH) = Cannot reserve track
|
||||
0x00020139 (SORRY,HIGH) = Write job parameters are unsuitable
|
||||
0x0002013a (FATAL,HIGH) = No suitable media detected
|
||||
0x0002013b
|
||||
0x0002013b (DEBUG,HIGH) = SCSI command indicates host or driver error
|
||||
0x0002013c (SORRY,HIGH) = Malformed capabilities page 2Ah received
|
||||
0x0002013d (DEBUG,LOW) = Waiting for free buffer space takes long time
|
||||
0x0002013e (SORRY,HIGH) = Timeout with waiting for free buffer. Now disabled
|
||||
0x0002013f (DEBUG,LOW) = Reporting total time spent with waiting for buffer
|
||||
|
||||
|
||||
libdax_audioxtr:
|
||||
0x00020200 (SORRY,HIGH) = Cannot open audio source file
|
||||
|
741
libburn/mmc.c
741
libburn/mmc.c
File diff suppressed because it is too large
Load Diff
@ -124,11 +124,19 @@ void burn_write_opts_set_format(struct burn_write_opts *opts, int format)
|
||||
|
||||
int burn_write_opts_set_simulate(struct burn_write_opts *opts, int sim)
|
||||
{
|
||||
/* <<< ts A70529 :
|
||||
One cannot predict the ability to simulate from page 05h
|
||||
information alone. This check is now done later in
|
||||
function burn_write_opts_auto_write_type().
|
||||
|
||||
if (opts->drive->mdata->simulate) {
|
||||
opts->simulate = sim;
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
*/
|
||||
opts->simulate = !!sim;
|
||||
return 1;
|
||||
}
|
||||
|
||||
int burn_write_opts_set_underrun_proof(struct burn_write_opts *opts,
|
||||
@ -265,6 +273,8 @@ no_caps:;
|
||||
} else if (caps->might_do_sao >= 3 && !(flag & 1))
|
||||
goto try_tao;
|
||||
do_sao:;
|
||||
if (caps->might_simulate == 0 && opts->simulate && !opts->force_is_set)
|
||||
goto no_simulate;
|
||||
if (!(flag & 1))
|
||||
burn_write_opts_set_write_type(
|
||||
opts, BURN_WRITE_SAO, BURN_BLOCK_SAO);
|
||||
@ -296,6 +306,8 @@ try_tao:;
|
||||
if (strcmp(reason_pt, "TAO: ") != 0)
|
||||
goto no_tao;
|
||||
/* ( TAO data/audio block size will be handled automatically ) */
|
||||
if (caps->might_simulate == 0 && opts->simulate && !opts->force_is_set)
|
||||
goto no_simulate;
|
||||
if (!(flag & 1))
|
||||
burn_write_opts_set_write_type(
|
||||
opts, BURN_WRITE_TAO, BURN_BLOCK_MODE1);
|
||||
@ -323,13 +335,21 @@ try_raw:;
|
||||
strcat(reasons, "drive dislikes block type, ");
|
||||
if (strcmp(reason_pt, "RAW: ") != 0)
|
||||
goto no_write_mode;
|
||||
if (!opts->force_is_set)
|
||||
goto no_simulate;
|
||||
|
||||
/* For now: no setting of raw write modes */
|
||||
|
||||
{wt = BURN_WRITE_RAW; goto ex;}
|
||||
|
||||
no_write_mode:;
|
||||
wt = BURN_WRITE_NONE;
|
||||
{wt = BURN_WRITE_NONE; goto ex;}
|
||||
|
||||
no_simulate:;
|
||||
strcat(reasons,
|
||||
"simulation of write job not supported by drive and media, ");
|
||||
{wt = BURN_WRITE_NONE; goto ex;}
|
||||
|
||||
ex:;
|
||||
burn_disc_free_multi_caps(&caps);
|
||||
if (wt == BURN_WRITE_NONE && !(flag & 3)) {
|
||||
|
@ -42,7 +42,10 @@ SIGKILL, SIGCHLD, SIGSTOP, SIGURG, SIGWINCH
|
||||
|
||||
/* The maximum size for a (SCSI) i/o transaction */
|
||||
/* Important : MUST be at least 32768 ! */
|
||||
/* ts A70523 : >32k seems not good with kernel 2.4 USB drivers and audio
|
||||
#define BURN_OS_TRANSPORT_BUFFER_SIZE 65536
|
||||
*/
|
||||
#define BURN_OS_TRANSPORT_BUFFER_SIZE 32768
|
||||
|
||||
|
||||
/* To hold the index number of the most recently delivered address from
|
||||
|
@ -11,19 +11,22 @@
|
||||
#include "options.h"
|
||||
|
||||
/* spc command set */
|
||||
static char SBC_LOAD[] = { 0x1b, 0, 0, 0, 3, 0 };
|
||||
static char SBC_UNLOAD[] = { 0x1b, 0, 0, 0, 2, 0 };
|
||||
static char SBC_START_UNIT[] = { 0x1b, 0, 0, 0, 1, 0 };
|
||||
static unsigned char SBC_LOAD[] = { 0x1b, 0, 0, 0, 3, 0 };
|
||||
static unsigned char SBC_UNLOAD[] = { 0x1b, 0, 0, 0, 2, 0 };
|
||||
static unsigned char SBC_START_UNIT[] = { 0x1b, 0, 0, 0, 1, 0 };
|
||||
|
||||
void sbc_load(struct burn_drive *d)
|
||||
{
|
||||
struct command c;
|
||||
|
||||
scsi_init_command(&c, SBC_LOAD, sizeof(SBC_LOAD));
|
||||
/*
|
||||
memcpy(c.opcode, SBC_LOAD, sizeof(SBC_LOAD));
|
||||
c.retry = 1;
|
||||
c.oplen = sizeof(SBC_LOAD);
|
||||
c.dir = NO_TRANSFER;
|
||||
c.page = NULL;
|
||||
*/
|
||||
c.retry = 1;
|
||||
c.dir = NO_TRANSFER;
|
||||
d->issue_command(d, &c);
|
||||
spc_wait_unit_attention(d, 60);
|
||||
}
|
||||
@ -32,11 +35,13 @@ void sbc_eject(struct burn_drive *d)
|
||||
{
|
||||
struct command c;
|
||||
|
||||
c.page = NULL;
|
||||
scsi_init_command(&c, SBC_UNLOAD, sizeof(SBC_UNLOAD));
|
||||
/*
|
||||
memcpy(c.opcode, SBC_UNLOAD, sizeof(SBC_UNLOAD));
|
||||
c.oplen = 1;
|
||||
c.oplen = sizeof(SBC_UNLOAD);
|
||||
c.page = NULL;
|
||||
*/
|
||||
c.page = NULL;
|
||||
c.dir = NO_TRANSFER;
|
||||
d->issue_command(d, &c);
|
||||
}
|
||||
@ -46,11 +51,14 @@ int sbc_start_unit(struct burn_drive *d)
|
||||
{
|
||||
struct command c;
|
||||
|
||||
scsi_init_command(&c, SBC_START_UNIT, sizeof(SBC_START_UNIT));
|
||||
/*
|
||||
memcpy(c.opcode, SBC_START_UNIT, sizeof(SBC_START_UNIT));
|
||||
c.retry = 1;
|
||||
c.oplen = sizeof(SBC_START_UNIT);
|
||||
c.dir = NO_TRANSFER;
|
||||
c.page = NULL;
|
||||
*/
|
||||
c.retry = 1;
|
||||
c.dir = NO_TRANSFER;
|
||||
d->issue_command(d, &c);
|
||||
return (c.error==0);
|
||||
}
|
||||
|
@ -218,7 +218,8 @@ static unsigned char *get_sector(struct burn_write_opts *opts,
|
||||
seclen += burn_subcode_length(outmode);
|
||||
|
||||
/* ts A61219 : opts->obs is eventually a 32k trigger for DVD */
|
||||
if (out->bytes + (seclen) > BUFFER_SIZE || out->bytes == opts->obs) {
|
||||
if (out->bytes + seclen > BUFFER_SIZE ||
|
||||
(opts->obs > 0 && out->bytes + seclen > opts->obs)) {
|
||||
int err;
|
||||
err = d->write(d, d->nwa, out);
|
||||
if (err == BE_CANCELLED)
|
||||
|
@ -72,9 +72,16 @@ Hint: You should also look into sg-freebsd-port.c, which is a younger and
|
||||
#include <linux/hdreg.h>
|
||||
#include <stdlib.h>
|
||||
#include <sys/utsname.h>
|
||||
#include <scsi/sg.h>
|
||||
#include <scsi/scsi.h>
|
||||
|
||||
#include <scsi/sg.h>
|
||||
/* Values within sg_io_hdr_t indicating success after ioctl(SG_IO) : */
|
||||
/* .host_status : from http://tldp.org/HOWTO/SCSI-Generic-HOWTO/x291.html */
|
||||
#define Libburn_sg_host_oK 0
|
||||
/* .driver_status : from http://tldp.org/HOWTO/SCSI-Generic-HOWTO/x322.html */
|
||||
#define Libburn_sg_driver_oK 0
|
||||
|
||||
|
||||
/* ts A61211 : to eventually recognize CD devices on /dev/sr* */
|
||||
#include <linux/cdrom.h>
|
||||
|
||||
@ -1027,6 +1034,71 @@ int sg_release(struct burn_drive *d)
|
||||
}
|
||||
|
||||
|
||||
/** ts A70518:
|
||||
Debugging log facility. Controlled by existence of macros:
|
||||
Libburn_log_sg_commandS enables logging to file
|
||||
/tmp/libburn_sg_command_log
|
||||
Libburn_fflush_log_sg_commandS enables fflush after each output line
|
||||
Libburn_log_sg_command_stderR enables additional log to stderr
|
||||
*/
|
||||
/*
|
||||
#define Libburn_log_sg_commandS 1
|
||||
#define Libburn_fflush_log_sg_commandS 1
|
||||
#define Libburn_log_sg_command_stderR 1
|
||||
*/
|
||||
|
||||
#ifdef Libburn_log_sg_commandS
|
||||
|
||||
/** Logs command (before execution) */
|
||||
static int sg_log_cmd(struct command *c, FILE *fp, int flag)
|
||||
{
|
||||
int i;
|
||||
|
||||
if (fp != NULL) {
|
||||
for(i = 0; i < 16 && i < c->oplen; i++)
|
||||
fprintf(fp,"%2.2x ", c->opcode[i]);
|
||||
fprintf(fp, "\n");
|
||||
#ifdef Libburn_fflush_log_sg_commandS
|
||||
fflush(fp);
|
||||
#endif
|
||||
}
|
||||
if (fp == stderr)
|
||||
return 1;
|
||||
#ifdef Libburn_log_sg_command_stderR
|
||||
sg_log_cmd(c, stderr, flag);
|
||||
#endif
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
/** logs outcome of a sg command. flag&1 causes an error message */
|
||||
static int sg_log_err(struct command *c, FILE *fp,
|
||||
sg_io_hdr_t *s,
|
||||
int flag)
|
||||
{
|
||||
if(fp!=NULL) {
|
||||
if(flag & 1)
|
||||
fprintf(fp,
|
||||
"+++ key=%X asc=%2.2Xh ascq=%2.2Xh (%6d ms)\n",
|
||||
s->sbp[2], s->sbp[12], s->sbp[13],s->duration);
|
||||
else
|
||||
fprintf(fp,"%6d ms\n", s->duration);
|
||||
#ifdef Libburn_fflush_log_sg_commandS
|
||||
fflush(fp);
|
||||
#endif
|
||||
}
|
||||
if (fp == stderr)
|
||||
return 1;
|
||||
#ifdef Libburn_log_sg_command_stderR
|
||||
sg_log_err(c, stderr, s, flag);
|
||||
#endif
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
#endif /* Libburn_log_sg_commandS */
|
||||
|
||||
|
||||
/** Sends a SCSI command to the drive, receives reply and evaluates wether
|
||||
the command succeeded or shall be retried or finally failed.
|
||||
Returned SCSI errors shall not lead to a return value indicating failure.
|
||||
@ -1041,15 +1113,10 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
|
||||
int done = 0, no_c_page = 0;
|
||||
int err;
|
||||
sg_io_hdr_t s;
|
||||
/*
|
||||
#define Libburn_log_sg_commandS 1
|
||||
*/
|
||||
|
||||
#ifdef Libburn_log_sg_commandS
|
||||
/* ts A61030 */
|
||||
static FILE *fp= NULL;
|
||||
static int fpcount= 0;
|
||||
int i;
|
||||
#endif /* Libburn_log_sg_commandS */
|
||||
|
||||
/* <<< ts A60821
|
||||
@ -1065,12 +1132,7 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
|
||||
fp= fopen("/tmp/libburn_sg_command_log","a");
|
||||
fprintf(fp,"\n-----------------------------------------\n");
|
||||
}
|
||||
if(fp!=NULL) {
|
||||
for(i=0;i<10;i++)
|
||||
fprintf(fp,"%2.2x ", c->opcode[i]);
|
||||
fprintf(fp,"\n");
|
||||
fpcount++;
|
||||
}
|
||||
sg_log_cmd(c,fp,0);
|
||||
#endif /* Libburn_log_sg_commandS */
|
||||
|
||||
|
||||
@ -1105,7 +1167,15 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
|
||||
if (c->page && !no_c_page) {
|
||||
s.dxferp = c->page->data;
|
||||
if (c->dir == FROM_DRIVE) {
|
||||
s.dxfer_len = BUFFER_SIZE;
|
||||
|
||||
/* ts A70519 : kernel 2.4 usb-storage seems to
|
||||
expect exact dxfer_len for data
|
||||
fetching commands.
|
||||
*/
|
||||
if (c->dxfer_len >= 0)
|
||||
s.dxfer_len = c->dxfer_len;
|
||||
else
|
||||
s.dxfer_len = BUFFER_SIZE;
|
||||
/* touch page so we can use valgrind */
|
||||
memset(c->page->data, 0, BUFFER_SIZE);
|
||||
} else {
|
||||
@ -1168,16 +1238,27 @@ int sg_issue_command(struct burn_drive *d, struct command *c)
|
||||
ex:;
|
||||
if (c->error) {
|
||||
scsi_notify_error(d, c, s.sbp, s.sb_len_wr, 0);
|
||||
} else if (s.host_status != Libburn_sg_host_oK ||
|
||||
s.driver_status != Libburn_sg_driver_oK) {
|
||||
char msg[161];
|
||||
|
||||
sprintf(msg,
|
||||
"SCSI command %2.2Xh indicates host or driver error:",
|
||||
(unsigned int) c->opcode[0]);
|
||||
sprintf(msg+strlen(msg),
|
||||
" host_status= %xh , driver_status= %xh",
|
||||
(unsigned int) s.host_status,
|
||||
(unsigned int) s.driver_status);
|
||||
libdax_msgs_submit(libdax_messenger, d->global_index,
|
||||
0x0002013b,
|
||||
LIBDAX_MSGS_SEV_DEBUG, LIBDAX_MSGS_PRIO_HIGH,
|
||||
msg, 0, 0);
|
||||
}
|
||||
|
||||
#ifdef Libburn_log_sg_commandS
|
||||
if(fp!=NULL) {
|
||||
fprintf(fp,"+++ key=%X asc=%2.2Xh ascq=%2.2Xh\n",
|
||||
s.sbp[2], s.sbp[12], s.sbp[13]);
|
||||
fpcount++;
|
||||
}
|
||||
sg_log_err(c, fp, &s, c->error != 0);
|
||||
#endif /* Libburn_log_sg_commandS */
|
||||
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
148
libburn/spc.c
148
libburn/spc.c
@ -29,7 +29,8 @@ extern struct libdax_msgs *libdax_messenger;
|
||||
|
||||
|
||||
/* spc command set */
|
||||
static unsigned char SPC_INQUIRY[] = { 0x12, 0, 0, 0, 255, 0 };
|
||||
/* ts A70519 : allocation length byte 3+4 was 0,255 */
|
||||
static unsigned char SPC_INQUIRY[] = { 0x12, 0, 0, 0, 36, 0 };
|
||||
|
||||
/*static char SPC_TEST[]={0,0,0,0,0,0};*/
|
||||
static unsigned char SPC_PREVENT[] = { 0x1e, 0, 0, 0, 1, 0 };
|
||||
@ -40,14 +41,35 @@ static unsigned char SPC_MODE_SELECT[] =
|
||||
static unsigned char SPC_REQUEST_SENSE[] = { 0x03, 0, 0, 0, 18, 0 };
|
||||
static unsigned char SPC_TEST_UNIT_READY[] = { 0x00, 0, 0, 0, 0, 0 };
|
||||
|
||||
|
||||
/* ts A70519 : An initializer for the abstract SCSI command structure */
|
||||
int scsi_init_command(struct command *c, unsigned char *opcode, int oplen)
|
||||
{
|
||||
if (oplen > 16)
|
||||
return 0;
|
||||
memcpy(c->opcode, opcode, oplen);
|
||||
c->oplen = oplen;
|
||||
c->dir = NO_TRANSFER;
|
||||
c->dxfer_len = -1;
|
||||
memset(c->sense, 0, sizeof(c->sense));
|
||||
c->error = 0;
|
||||
c->retry = 0;
|
||||
c->page = NULL;
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
int spc_test_unit_ready_r(struct burn_drive *d, int *key, int *asc, int *ascq)
|
||||
{
|
||||
struct command c;
|
||||
|
||||
c.retry = 0;
|
||||
scsi_init_command(&c, SPC_TEST_UNIT_READY,sizeof(SPC_TEST_UNIT_READY));
|
||||
/*
|
||||
c.oplen = sizeof(SPC_TEST_UNIT_READY);
|
||||
memcpy(c.opcode, SPC_TEST_UNIT_READY, sizeof(SPC_TEST_UNIT_READY));
|
||||
c.page = NULL;
|
||||
*/
|
||||
c.retry = 0;
|
||||
c.dir = NO_TRANSFER;
|
||||
d->issue_command(d, &c);
|
||||
if (c.error) {
|
||||
@ -68,7 +90,7 @@ int spc_test_unit_ready(struct burn_drive *d)
|
||||
|
||||
|
||||
/* ts A70315 */
|
||||
/** Wait until the drive state becomes clear in or until max_usec elapsed */
|
||||
/** Wait until the drive state becomes clear or until max_usec elapsed */
|
||||
int spc_wait_unit_attention(struct burn_drive *d, int max_sec)
|
||||
{
|
||||
int i, ret, key, asc, ascq;
|
||||
@ -89,9 +111,14 @@ void spc_request_sense(struct burn_drive *d, struct buffer *buf)
|
||||
{
|
||||
struct command c;
|
||||
|
||||
scsi_init_command(&c, SPC_REQUEST_SENSE, sizeof(SPC_REQUEST_SENSE));
|
||||
c.retry = 0;
|
||||
/*
|
||||
c.oplen = sizeof(SPC_REQUEST_SENSE);
|
||||
memcpy(c.opcode, SPC_REQUEST_SENSE, sizeof(SPC_REQUEST_SENSE));
|
||||
*/
|
||||
c.dxfer_len= c.opcode[4];
|
||||
c.retry = 0;
|
||||
c.page = buf;
|
||||
c.page->sectors = 0;
|
||||
c.page->bytes = 0;
|
||||
@ -113,24 +140,29 @@ void spc_inquiry(struct burn_drive *d)
|
||||
struct burn_scsi_inquiry_data *id;
|
||||
struct command c;
|
||||
|
||||
scsi_init_command(&c, SPC_INQUIRY, sizeof(SPC_INQUIRY));
|
||||
/*
|
||||
memcpy(c.opcode, SPC_INQUIRY, sizeof(SPC_INQUIRY));
|
||||
c.retry = 1;
|
||||
c.oplen = sizeof(SPC_INQUIRY);
|
||||
*/
|
||||
c.dxfer_len= (c.opcode[3] << 8) | c.opcode[4];
|
||||
c.retry = 1;
|
||||
c.page = &buf;
|
||||
c.page->bytes = 0;
|
||||
c.page->sectors = 0;
|
||||
c.dir = FROM_DRIVE;
|
||||
d->issue_command(d, &c);
|
||||
|
||||
id = (struct burn_scsi_inquiry_data *)d->idata;
|
||||
id->vendor[8] = 0;
|
||||
id->product[16] = 0;
|
||||
id->revision[4] = 0;
|
||||
|
||||
memset(id->vendor, 0, 9);
|
||||
memset(id->product, 0, 17);
|
||||
memset(id->revision, 0, 5);
|
||||
if (c.error) {
|
||||
id->valid = -1;
|
||||
return;
|
||||
}
|
||||
memcpy(id->vendor, c.page->data + 8, 8);
|
||||
memcpy(id->product, c.page->data + 16, 16);
|
||||
memcpy(id->revision, c.page->data + 32, 4);
|
||||
|
||||
id->valid = 1;
|
||||
return;
|
||||
}
|
||||
@ -139,10 +171,13 @@ void spc_prevent(struct burn_drive *d)
|
||||
{
|
||||
struct command c;
|
||||
|
||||
scsi_init_command(&c, SPC_PREVENT, sizeof(SPC_PREVENT));
|
||||
/*
|
||||
memcpy(c.opcode, SPC_PREVENT, sizeof(SPC_PREVENT));
|
||||
c.retry = 1;
|
||||
c.oplen = sizeof(SPC_PREVENT);
|
||||
c.page = NULL;
|
||||
*/
|
||||
c.retry = 1;
|
||||
c.dir = NO_TRANSFER;
|
||||
d->issue_command(d, &c);
|
||||
}
|
||||
@ -151,19 +186,27 @@ void spc_allow(struct burn_drive *d)
|
||||
{
|
||||
struct command c;
|
||||
|
||||
scsi_init_command(&c, SPC_ALLOW, sizeof(SPC_ALLOW));
|
||||
/*
|
||||
memcpy(c.opcode, SPC_ALLOW, sizeof(SPC_ALLOW));
|
||||
c.retry = 1;
|
||||
c.oplen = sizeof(SPC_ALLOW);
|
||||
c.page = NULL;
|
||||
*/
|
||||
c.retry = 1;
|
||||
c.dir = NO_TRANSFER;
|
||||
d->issue_command(d, &c);
|
||||
}
|
||||
|
||||
void spc_sense_caps(struct burn_drive *d)
|
||||
/*
|
||||
ts A70518 : Do not call with *alloc_len < 8
|
||||
*/
|
||||
/** flag&1= do only inquire alloc_len */
|
||||
static int spc_sense_caps_al(struct burn_drive *d, int *alloc_len, int flag)
|
||||
{
|
||||
struct buffer buf;
|
||||
struct scsi_mode_data *m;
|
||||
int size, page_length, num_write_speeds = 0, i, speed, ret;
|
||||
int old_alloc_len, was_error = 0;
|
||||
unsigned char *page;
|
||||
struct command c;
|
||||
struct burn_speed_descriptor *sd;
|
||||
@ -171,18 +214,30 @@ void spc_sense_caps(struct burn_drive *d)
|
||||
/* ts A61225 : 1 = report about post-MMC-1 speed descriptors */
|
||||
static int speed_debug = 0;
|
||||
|
||||
if (*alloc_len < 8)
|
||||
return 0;
|
||||
|
||||
memset(&buf, 0, sizeof(buf));
|
||||
scsi_init_command(&c, SPC_MODE_SENSE, sizeof(SPC_MODE_SENSE));
|
||||
/*
|
||||
memcpy(c.opcode, SPC_MODE_SENSE, sizeof(SPC_MODE_SENSE));
|
||||
c.retry = 1;
|
||||
c.oplen = sizeof(SPC_MODE_SENSE);
|
||||
*/
|
||||
c.dxfer_len = *alloc_len;
|
||||
c.opcode[7] = (c.dxfer_len >> 8) & 0xff;
|
||||
c.opcode[8] = c.dxfer_len & 0xff;
|
||||
c.retry = 1;
|
||||
c.opcode[2] = 0x2A;
|
||||
c.page = &buf;
|
||||
c.page->bytes = 0;
|
||||
c.page->sectors = 0;
|
||||
c.dir = FROM_DRIVE;
|
||||
d->issue_command(d, &c);
|
||||
if (c.error)
|
||||
if (c.error) {
|
||||
memset(&buf, 0, sizeof(buf));
|
||||
d->mdata->valid = -1;
|
||||
was_error = 1;
|
||||
}
|
||||
|
||||
size = c.page->data[0] * 256 + c.page->data[1];
|
||||
m = d->mdata;
|
||||
@ -195,6 +250,14 @@ void spc_sense_caps(struct burn_drive *d)
|
||||
set of speed descriptors. In MMC-5 E.11 it is declared "legacy".
|
||||
*/
|
||||
page_length = page[1];
|
||||
old_alloc_len = *alloc_len;
|
||||
*alloc_len = page_length + 8;
|
||||
if (flag & 1)
|
||||
return !was_error;
|
||||
if (page_length + 8 > old_alloc_len)
|
||||
page_length = old_alloc_len - 8;
|
||||
if (page_length < 22)
|
||||
return 0;
|
||||
|
||||
m->valid = 0;
|
||||
burn_mdata_free_subs(m);
|
||||
@ -253,7 +316,7 @@ void spc_sense_caps(struct burn_drive *d)
|
||||
0x0002013c,
|
||||
LIBDAX_MSGS_SEV_SORRY, LIBDAX_MSGS_PRIO_HIGH,
|
||||
msg, 0, 0);
|
||||
return;
|
||||
return 0;
|
||||
}
|
||||
|
||||
for (i = 0; i < num_write_speeds; i++) {
|
||||
@ -297,6 +360,24 @@ try_mmc_get_performance:;
|
||||
fprintf(stderr,
|
||||
"LIBBURN_DEBUG: ACh min_write_speed = %d , max_write_speed = %d\n",
|
||||
m->min_write_speed, m->max_write_speed);
|
||||
return !was_error;
|
||||
}
|
||||
|
||||
|
||||
void spc_sense_caps(struct burn_drive *d)
|
||||
{
|
||||
int alloc_len, start_len = 22, ret;
|
||||
|
||||
/* first command execution to learn Allocation Length */
|
||||
alloc_len = start_len;
|
||||
ret = spc_sense_caps_al(d, &alloc_len, 1);
|
||||
/*
|
||||
fprintf(stderr,"LIBBURN_DEBUG: 5Ah alloc_len = %d , ret = %d\n",
|
||||
alloc_len, ret);
|
||||
*/
|
||||
if (alloc_len >= start_len && ret > 0)
|
||||
/* second execution with announced length */
|
||||
spc_sense_caps_al(d, &alloc_len, 0);
|
||||
}
|
||||
|
||||
|
||||
@ -304,13 +385,19 @@ void spc_sense_error_params(struct burn_drive *d)
|
||||
{
|
||||
struct buffer buf;
|
||||
struct scsi_mode_data *m;
|
||||
int size;
|
||||
int size, alloc_len = 12 ;
|
||||
unsigned char *page;
|
||||
struct command c;
|
||||
|
||||
scsi_init_command(&c, SPC_MODE_SENSE, sizeof(SPC_MODE_SENSE));
|
||||
/*
|
||||
memcpy(c.opcode, SPC_MODE_SENSE, sizeof(SPC_MODE_SENSE));
|
||||
c.retry = 1;
|
||||
c.oplen = sizeof(SPC_MODE_SENSE);
|
||||
*/
|
||||
c.dxfer_len = alloc_len;
|
||||
c.opcode[7] = (c.dxfer_len >> 8) & 0xff;
|
||||
c.opcode[8] = c.dxfer_len & 0xff;
|
||||
c.retry = 1;
|
||||
c.opcode[2] = 0x01;
|
||||
c.page = &buf;
|
||||
c.page->bytes = 0;
|
||||
@ -332,9 +419,12 @@ void spc_select_error_params(struct burn_drive *d,
|
||||
struct buffer buf;
|
||||
struct command c;
|
||||
|
||||
scsi_init_command(&c, SPC_MODE_SELECT, sizeof(SPC_MODE_SELECT));
|
||||
/*
|
||||
memcpy(c.opcode, SPC_MODE_SELECT, sizeof(SPC_MODE_SELECT));
|
||||
c.retry = 1;
|
||||
c.oplen = sizeof(SPC_MODE_SELECT);
|
||||
*/
|
||||
c.retry = 1;
|
||||
c.opcode[8] = 8 + 2 + d->mdata->retry_page_length;
|
||||
c.page = &buf;
|
||||
c.page->bytes = 0;
|
||||
@ -363,7 +453,7 @@ void spc_sense_write_params(struct burn_drive *d)
|
||||
{
|
||||
struct buffer buf;
|
||||
struct scsi_mode_data *m;
|
||||
int size, dummy;
|
||||
int size, dummy, alloc_len = 10;
|
||||
unsigned char *page;
|
||||
struct command c;
|
||||
|
||||
@ -371,9 +461,15 @@ void spc_sense_write_params(struct burn_drive *d)
|
||||
/* a ssert(d->mdata->cdr_write || d->mdata->cdrw_write ||
|
||||
d->mdata->dvdr_write || d->mdata->dvdram_write); */
|
||||
|
||||
scsi_init_command(&c, SPC_MODE_SENSE, sizeof(SPC_MODE_SENSE));
|
||||
/*
|
||||
memcpy(c.opcode, SPC_MODE_SENSE, sizeof(SPC_MODE_SENSE));
|
||||
c.retry = 1;
|
||||
c.oplen = sizeof(SPC_MODE_SENSE);
|
||||
*/
|
||||
c.dxfer_len = alloc_len;
|
||||
c.opcode[7] = (c.dxfer_len >> 8) & 0xff;
|
||||
c.opcode[8] = c.dxfer_len & 0xff;
|
||||
c.retry = 1;
|
||||
c.opcode[2] = 0x05;
|
||||
c.page = &buf;
|
||||
c.page->bytes = 0;
|
||||
@ -428,9 +524,12 @@ void spc_select_write_params(struct burn_drive *d,
|
||||
o->block_type,spc_block_type(o->block_type));
|
||||
*/
|
||||
|
||||
scsi_init_command(&c, SPC_MODE_SELECT, sizeof(SPC_MODE_SELECT));
|
||||
/*
|
||||
memcpy(c.opcode, SPC_MODE_SELECT, sizeof(SPC_MODE_SELECT));
|
||||
c.retry = 1;
|
||||
c.oplen = sizeof(SPC_MODE_SELECT);
|
||||
*/
|
||||
c.retry = 1;
|
||||
c.opcode[8] = 8 + 2 + d->mdata->write_page_length;
|
||||
c.page = &buf;
|
||||
c.page->bytes = 0;
|
||||
@ -488,9 +587,12 @@ void spc_probe_write_modes(struct burn_drive *d)
|
||||
try_block_type = useable_block_type;
|
||||
last_try= 1;
|
||||
}
|
||||
scsi_init_command(&c, SPC_MODE_SELECT,sizeof(SPC_MODE_SELECT));
|
||||
/*
|
||||
memcpy(c.opcode, SPC_MODE_SELECT, sizeof(SPC_MODE_SELECT));
|
||||
c.retry = 1;
|
||||
c.oplen = sizeof(SPC_MODE_SELECT);
|
||||
*/
|
||||
c.retry = 1;
|
||||
c.opcode[8] = 8 + 2 + 0x32;
|
||||
c.page = &buf;
|
||||
|
||||
|
@ -55,4 +55,7 @@ enum response scsi_error_msg(struct burn_drive *d, unsigned char *sense,
|
||||
int scsi_notify_error(struct burn_drive *, struct command *c,
|
||||
unsigned char *sense, int senselen, int flag);
|
||||
|
||||
/* ts A70519 */
|
||||
int scsi_init_command(struct command *c, unsigned char *opcode, int oplen);
|
||||
|
||||
#endif /*__SPC*/
|
||||
|
@ -128,9 +128,14 @@ void toc_find_modes(struct burn_drive *d)
|
||||
if (e && !(e->control & 4)) {
|
||||
t->mode = BURN_AUDIO;
|
||||
} else {
|
||||
|
||||
t->mode = BURN_MODE1;
|
||||
/* ts A70519 : this does not work with Linux 2.4 USB because one cannot
|
||||
predict the exact dxfer_size without knowing the sector type.
|
||||
mem.sectors = 1;
|
||||
d->read_sectors(d, lba, mem.sectors, &o, &mem);
|
||||
t->mode = sector_identify(mem.data);
|
||||
*/
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -51,6 +51,7 @@ struct command
|
||||
unsigned char opcode[16];
|
||||
int oplen;
|
||||
int dir;
|
||||
int dxfer_len;
|
||||
unsigned char sense[128];
|
||||
int error;
|
||||
int retry;
|
||||
@ -223,6 +224,21 @@ struct burn_drive
|
||||
struct buffer *buffer;
|
||||
struct burn_progress progress;
|
||||
|
||||
/* ts A70711 : keeping an eye on the drive buffer */
|
||||
off_t pessimistic_buffer_free;
|
||||
int pbf_altered;
|
||||
int wait_for_buffer_free;
|
||||
int nominal_write_speed;
|
||||
unsigned wfb_min_usec;
|
||||
unsigned wfb_max_usec;
|
||||
unsigned wfb_timeout_sec;
|
||||
unsigned wfb_min_percent;
|
||||
unsigned wfb_max_percent;
|
||||
unsigned pessimistic_writes;
|
||||
unsigned waited_writes;
|
||||
unsigned waited_tries;
|
||||
unsigned waited_usec;
|
||||
|
||||
volatile int cancel;
|
||||
volatile enum burn_drive_status busy;
|
||||
/* transport functions */
|
||||
|
@ -875,6 +875,14 @@ int burn_disc_init_write_status(struct burn_write_opts *o,
|
||||
d->progress.buffered_bytes = 0;
|
||||
d->progress.buffer_min_fill = 0xffffffff;
|
||||
|
||||
/* ts A70711 */
|
||||
d->pessimistic_buffer_free = 0;
|
||||
d->pbf_altered = 0;
|
||||
d->pessimistic_writes = 0;
|
||||
d->waited_writes = 0;
|
||||
d->waited_tries = 0;
|
||||
d->waited_usec = 0;
|
||||
|
||||
/* Set eventual media fill up for last track only */
|
||||
for (sx = 0; sx < disc->sessions; sx++)
|
||||
for (tx = 0 ; tx < disc->session[sx]->tracks; tx++) {
|
||||
|
@ -350,7 +350,7 @@ int libburner_format_row(struct burn_drive *drive)
|
||||
|
||||
/** Brings preformatted track images (ISO 9660, audio, ...) onto media.
|
||||
To make sure a data image is fully readable on any Linux machine, this
|
||||
function adds 300 kB of padding to the (usualy single) track.
|
||||
function adds 300 kiB of padding to the (usualy single) track.
|
||||
Audio tracks get padded to complete their last sector.
|
||||
|
||||
In case of external signals expect abort handling of an ongoing burn to
|
||||
@ -378,7 +378,7 @@ int libburner_payload(struct burn_drive *drive,
|
||||
|
||||
if (all_tracks_type != BURN_AUDIO) {
|
||||
all_tracks_type = BURN_MODE1;
|
||||
/* a padding of 300 kB helps to avoid the read-ahead bug */
|
||||
/* a padding of 300 kiB helps to avoid the read-ahead bug */
|
||||
padding = 300*1024;
|
||||
}
|
||||
|
||||
|
@ -312,6 +312,11 @@ int telltoc_media(struct burn_drive *drive)
|
||||
caps->advised_write_mode == BURN_WRITE_RAW ?
|
||||
" (advised)" : "");
|
||||
printf("\n");
|
||||
printf("Write dummy : ");
|
||||
if (caps->might_simulate)
|
||||
printf("supposed to work with non-RAW modes\n");
|
||||
else
|
||||
printf("will not work\n");
|
||||
o= burn_write_opts_new(drive);
|
||||
if (o != NULL) {
|
||||
burn_write_opts_set_perform_opc(o, 0);
|
||||
|
Reference in New Issue
Block a user