From bd017a108e47e7006c02e69399bd8a615a9b1670 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Fri, 12 Feb 2010 21:26:46 +0000 Subject: [PATCH] Changed docs and comments to "GNU/Linux" where appropriate --- cdrskin/cdrskin_timestamp.h | 2 +- libburn/cleanup.c | 3 ++- libburn/drive.c | 2 +- libburn/init.c | 8 +++++--- libburn/libburn.h | 14 ++++++-------- libburn/mmc.c | 2 +- libburn/os-libcdio.h | 2 +- libburn/os-linux.h | 2 +- libburn/os.h | 4 ++-- libburn/read.c | 2 +- libburn/sg-libcdio.c | 2 +- libburn/sg-linux.c | 6 +++--- libburn/sg.c | 4 ++-- libburn/toc.c | 2 +- libburn/write.c | 6 +++--- 15 files changed, 31 insertions(+), 30 deletions(-) diff --git a/cdrskin/cdrskin_timestamp.h b/cdrskin/cdrskin_timestamp.h index 5f90e0b..0889100 100644 --- a/cdrskin/cdrskin_timestamp.h +++ b/cdrskin/cdrskin_timestamp.h @@ -1 +1 @@ -#define Cdrskin_timestamP "2010.02.12.173236" +#define Cdrskin_timestamP "2010.02.12.212818" diff --git a/libburn/cleanup.c b/libburn/cleanup.c index 1701c17..708bc26 100644 --- a/libburn/cleanup.c +++ b/libburn/cleanup.c @@ -40,7 +40,8 @@ static int non_signal_list_count= BURN_OS_NON_SIGNAL_COUNT; #else /* ! Cleanup_has_no_libburn_os_H */ -/* Outdated. Linux only. For backward compatibility with pre-libburn-0.2.3 */ +/* Outdated. GNU/Linux only. + For backward compatibility with pre-libburn-0.2.3 */ /* Signals to be caught */ static int signal_list[]= { diff --git a/libburn/drive.c b/libburn/drive.c index 698f1ef..45804a1 100644 --- a/libburn/drive.c +++ b/libburn/drive.c @@ -3,7 +3,7 @@ #include #include -/* #include ts A61013 : not in Linux man 3 malloc */ +/* #include ts A61013 : not in GNU/Linux man 3 malloc */ #include #include diff --git a/libburn/init.c b/libburn/init.c index 91eefed..f452a73 100644 --- a/libburn/init.c +++ b/libburn/init.c @@ -32,14 +32,16 @@ struct libdax_msgs *libdax_messenger= NULL; int burn_running = 0; -/* ts A60813 : Linux: wether to use O_EXCL on open() of device files */ +/* ts A60813 : GNU/Linux: whether to use O_EXCL on open() of device files + ts B00212 : FreeBSD: whether to use flock(LOCK_EX) after open() +*/ int burn_sg_open_o_excl = 1; -/* ts A70403 : Linux: wether to use fcntl(,F_SETLK,) +/* ts A70403 : GNU/Linux: wether to use fcntl(,F_SETLK,) after open() of device files */ int burn_sg_fcntl_f_setlk = 1; -/* ts A70314 : Linux: what device family to use : +/* ts A70314 : GNU/Linux: what device family to use : 0= default family 1= sr 2= scd diff --git a/libburn/libburn.h b/libburn/libburn.h index bcd3e24..605bb55 100644 --- a/libburn/libburn.h +++ b/libburn/libburn.h @@ -765,7 +765,7 @@ int burn_abort_pacifier(void *handle, int patience, int elapsed); void burn_set_verbosity(int level); /* ts A91111 */ -/** Enable resp. disable logging of SCSI commands (currently Linux only). +/** Enable resp. disable logging of SCSI commands (currently GNU/Linux only). This call can be made at any time - even before burn_initialize(). It is in effect for all active drives and currently not very thread safe for multiple drives. @@ -782,12 +782,11 @@ void burn_set_scsi_logging(int flag); after burn_initialize() and before any bus scan. But not mandatory at all. Parameter value 1 enables a feature, 0 disables. Default is (1,0,0). Have a good reason before you change it. - @param exclusive Linux only: + @param exclusive 0 = no attempt to make drive access exclusive. 1 = Try to open only devices which are not marked as busy - and try to mark them busy if opened sucessfully. (O_EXCL) - There are kernels which simply don't care about O_EXCL. - Some have it off, some have it on, some are switchable. + and try to mark them busy if opened sucessfully. (O_EXCL + on GNU/Linux , flock(LOCK_EX) on FreeBSD.) 2 = in case of a SCSI device, also try to open exclusively the matching /dev/sr, /dev/scd and /dev/st . One may select a device SCSI file family by adding @@ -796,8 +795,8 @@ void burn_set_scsi_logging(int flag); 8 = /dev/scd%d 16 = /dev/sg%d Do not use other values ! - Add 32 to demand an exclusive lock by fcntl(,F_SETLK,) - after open() has succeeded. + Add 32 to demand on GNU/Linux an exclusive lock by + fcntl(,F_SETLK,) after open() has succeeded. @param blocking Try to wait for drives which do not open immediately but also do not return an error as well. (O_NONBLOCK) This might stall indefinitely with /dev/hdX hard disks. @@ -1097,7 +1096,6 @@ int burn_drive_snooze(struct burn_drive *d, int flag); /** Release a drive. This should not be done until the drive is no longer busy (see burn_drive_get_status). - Linux: The drive device file is not reserved afterwards. (O_EXCL, F_SETLK). @param drive The drive to release. @param eject Nonzero to make the drive eject the disc in it. */ diff --git a/libburn/mmc.c b/libburn/mmc.c index 7069acf..168d045 100644 --- a/libburn/mmc.c +++ b/libburn/mmc.c @@ -4078,7 +4078,7 @@ int mmc_read_disc_structure(struct burn_drive *d, desired payload bytes. The drive then returns 35 bytes as requested and the media id is "RITEKF1". Nevertheless this is not a generally usable gesture - because older Linux USB dislikes requests to fetch + because older GNU/Linux USB dislikes requests to fetch more bytes than the drive will deliver. # define Libburn_enforce_structure_code_0x0E 1 diff --git a/libburn/os-libcdio.h b/libburn/os-libcdio.h index 5dd4c94..3426d4a 100644 --- a/libburn/os-libcdio.h +++ b/libburn/os-libcdio.h @@ -41,7 +41,7 @@ SIGKILL, SIGCHLD, SIGSTOP /* Important : MUST be at least 32768 ! */ /* My Blu-ray burner LG GGW-H20 writes junk if stream recording is combined with buffer size 32 kB. So stream recording is allowed only with size 64k. - This makes it worth to have a special case for Linux buffer size here. + This makes it worth to have a special case for GNU/Linux buffer size here. */ #ifdef __linux #define BURN_OS_TRANSPORT_BUFFER_SIZE 65536 diff --git a/libburn/os-linux.h b/libburn/os-linux.h index 0208a78..217e009 100644 --- a/libburn/os-linux.h +++ b/libburn/os-linux.h @@ -2,7 +2,7 @@ /* os-linux.h Operating system specific libburn definitions and declarations. Included by os.h in case of compilation for - GNU/Linux kernels 2.4 and 2.6 with Linux SCSI Generic (sg) + Linux kernels 2.4 and 2.6, GNU/Linux SCSI Generic (sg) Copyright (C) 2006 Thomas Schmitt , provided under GPLv2+ */ diff --git a/libburn/os.h b/libburn/os.h index 441ce80..376650a 100644 --- a/libburn/os.h +++ b/libburn/os.h @@ -3,7 +3,7 @@ Operating system specific libburn definitions and declarations. The macros defined here are used by libburn modules in order to avoid own system dependent case distinctions. - Copyright (C) 2009 Thomas Schmitt , provided under GPL + Copyright (C) 2009 Thomas Schmitt , provided under GPLv2+ */ #ifndef BURN_OS_H_INCLUDED @@ -41,7 +41,7 @@ #ifdef __linux -/* --------- Linux kernels 2.4 and 2.6 with Linux SCSI Generic (sg) -------- */ +/* ------- Linux kernels 2.4 and 2.6 with GNU/Linux SCSI Generic (sg) ------ */ #include "os-linux.h" diff --git a/libburn/read.c b/libburn/read.c index fa13dc0..2c80bc7 100644 --- a/libburn/read.c +++ b/libburn/read.c @@ -1,6 +1,6 @@ /* -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 8; -*- */ -/* #include ts A61013 : not in Linux man 3 malloc */ +/* #include ts A61013 : not in GNU/Linux man 3 malloc */ #include #include diff --git a/libburn/sg-libcdio.c b/libburn/sg-libcdio.c index a812cbc..b2789d6 100644 --- a/libburn/sg-libcdio.c +++ b/libburn/sg-libcdio.c @@ -834,7 +834,7 @@ int burn_os_stdio_capacity(char *path, off_t *bytes) #ifdef __linux - /* Linux specific determination of block device size */ + /* GNU/Linux specific determination of block device size */ } else if(S_ISBLK(stbuf.st_mode)) { int open_mode = O_RDONLY, fd, ret; diff --git a/libburn/sg-linux.c b/libburn/sg-linux.c index 6e76e0d..613a206 100644 --- a/libburn/sg-linux.c +++ b/libburn/sg-linux.c @@ -143,7 +143,7 @@ Hint: You should also look into sg-freebsd-port.c, which is a younger and #include -/** Indication of the GNU/Linux kernel this software is running on */ +/** Indication of the Linux kernel this software is running on */ /* -1 = not evaluated , 0 = unrecognizable , 1 = 2.4 , 2 = 2.6 */ static int sg_kernel_age = -1; @@ -543,7 +543,7 @@ static int sg_open_drive_fd(char *fname, int scan_mode) /* ts A60813 - A60927 O_EXCL with devices is a non-POSIX feature - of GNU/Linux kernels. Possibly introduced 2002. + of Linux kernels. Possibly introduced 2002. Mentioned in "The Linux SCSI Generic (sg) HOWTO" */ if(burn_sg_open_o_excl) open_mode |= O_EXCL; @@ -1657,7 +1657,7 @@ int sg_grab(struct burn_drive *d) /* ts A60813 - A60927 O_EXCL with devices is a non-POSIX feature - of GNU/Linux kernels. Possibly introduced 2002. + of Linux kernels. Possibly introduced 2002. Mentioned in "The Linux SCSI Generic (sg) HOWTO". */ if(burn_sg_open_o_excl) diff --git a/libburn/sg.c b/libburn/sg.c index 258856a..e7aa20f 100644 --- a/libburn/sg.c +++ b/libburn/sg.c @@ -34,11 +34,11 @@ static int intentional_compiler_warning(void) { int INTENTIONAL_COMPILER_WARNING_; - int Cannot_recognize_Linux_nor_FreeBSD_; + int Cannot_recognize_GNU_Linux_nor_FreeBSD_; int Have_to_use_dummy_MMC_transport_adapter_; int This_libburn_will_not_be_able_to_operate_on_real_CD_drives; int Have_to_use_dummy_MMC_transport_adapter; - int Cannot_recognize_Linux_nor_FreeBSD; + int Cannot_recognize_GNU_Linux_nor_FreeBSD; int INTENTIONAL_COMPILER_WARNING; return(0); diff --git a/libburn/toc.c b/libburn/toc.c index 7a9bbbc..c732104 100644 --- a/libburn/toc.c +++ b/libburn/toc.c @@ -130,7 +130,7 @@ void toc_find_modes(struct burn_drive *d) } else { t->mode = BURN_MODE1; -/* ts A70519 : this does not work with Linux 2.4 USB because one cannot +/* ts A70519 : this does not work with GNU/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); diff --git a/libburn/write.c b/libburn/write.c index 43f6f00..502db82 100644 --- a/libburn/write.c +++ b/libburn/write.c @@ -1263,8 +1263,8 @@ int burn_disc_close_track_dvd_plus_r(struct burn_write_opts *o, /* ts A91114 : EXPERIMENTAL, NOT COMPLETELY IMPLEMENTED - Simplified data transmission for DVD. libburn via Linux USB is 30 % slower - than growisofs or cdrecord when transmitting 32 KB chunks. + Simplified data transmission for DVD. libburn via GNU/Linux USB is 30 % + slower than growisofs or cdrecord when transmitting 32 KB chunks. With 64 KB chunks it is 20% faster than the competitors. No heavy CPU load is visible but there might be subtle race conditions in the USB driver which work better with shorter time gaps between WRITE @@ -2397,7 +2397,7 @@ calloc() seems not to have the desired effect. valgrind warns: goto ex; } - /* ts A70521 : Linux 2.4 USB audio fails with 64 kiB */ + /* ts A70521 : GNU/Linux 2.4 USB audio fails with 64 kiB */ /* ts A80414 : might need 64 kiB for BD-RE streaming */ /* buffer flush trigger for sector.c:get_sector() */ o->obs = Libburn_cd_obS;