summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorheinz <heinz>2007-10-09 21:26:11 +0000
committerheinz <heinz>2007-10-09 21:26:11 +0000
commit5df3f16647196a92339b00711f681ab21e02ce87 (patch)
treee8d16f378e58ceb584d1300052897c659b66fed2
parent5dfa53dc42012d0a2b9b4e78e0abc1ba4928fc69 (diff)
downloadpkgsrc-5df3f16647196a92339b00711f681ab21e02ce87.tar.gz
Added missing copyright notices for Simon 'corecode' Schubert.
This should fix PR pkg/34017.
-rw-r--r--audio/cdparanoia/distinfo8
-rw-r--r--audio/cdparanoia/patches/patch-ce29
-rw-r--r--audio/cdparanoia/patches/patch-cf65
-rw-r--r--audio/cdparanoia/patches/patch-cg45
4 files changed, 87 insertions, 60 deletions
diff --git a/audio/cdparanoia/distinfo b/audio/cdparanoia/distinfo
index ee8cfd720c0..548085474b7 100644
--- a/audio/cdparanoia/distinfo
+++ b/audio/cdparanoia/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.19 2007/03/08 19:24:24 rillig Exp $
+$NetBSD: distinfo,v 1.20 2007/10/09 21:26:11 heinz Exp $
SHA1 (cdparanoia-III-alpha9.8.src.tgz) = 04cc33a7d22d6255f6239e3e74195506b3bdde06
RMD160 (cdparanoia-III-alpha9.8.src.tgz) = d9225165f83b5386c58db263d6918a7006df1481
@@ -13,9 +13,9 @@ SHA1 (patch-ca) = 9c35254c09a96b622cac44198443f66f7bc0e428
SHA1 (patch-cb) = c19ee04017b836842bb0f2d2c77e8f35aad0f9bb
SHA1 (patch-cc) = adea4fd9682c0543e5749c6f3fe73697d8663c6c
SHA1 (patch-cd) = 81d31fb55db0f982959395cdecc3da826bf23bfb
-SHA1 (patch-ce) = efbdd8b7f8908c9c4916f2356f9ff14658c27c15
-SHA1 (patch-cf) = 650de2a80235e42acd5670a06bd1e5bcf346100d
-SHA1 (patch-cg) = b9786ee81dcb7bd2f6572a20f424dd5291a8720d
+SHA1 (patch-ce) = 3a4e9a83753e2eb6595bcb4e7a47c42b72ef5702
+SHA1 (patch-cf) = d8cde95f9efa9c1941768468c30b1152c083830f
+SHA1 (patch-cg) = c962cbc84f021e399b6f210d0e7a140fd7004222
SHA1 (patch-ch) = 8d16dd8c80e8f1ee35ccc299ba927d685adde01c
SHA1 (patch-ci) = 60db1d1d2e8ec9c6d446543762218b22c597d986
SHA1 (patch-cj) = e2420e2ccadd2d6ea30d6bf48af9c141dc395afc
diff --git a/audio/cdparanoia/patches/patch-ce b/audio/cdparanoia/patches/patch-ce
index ae5820d2f17..4dfaa24cc42 100644
--- a/audio/cdparanoia/patches/patch-ce
+++ b/audio/cdparanoia/patches/patch-ce
@@ -1,8 +1,17 @@
-$NetBSD: patch-ce,v 1.4 2006/11/05 13:45:37 wiz Exp $
+$NetBSD: patch-ce,v 1.5 2007/10/09 21:26:11 heinz Exp $
---- interface/cooked_interface.c.orig Thu Apr 20 00:41:04 2000
+--- interface/cooked_interface.c.orig 2000-04-20 00:41:04.000000000 +0200
+++ interface/cooked_interface.c
-@@ -10,9 +10,11 @@
+@@ -1,6 +1,8 @@
+ /******************************************************************
+ * CopyPolicy: GNU Public License 2 applies
+ * Copyright (C) Monty xiphmont@mit.edu
++ * FreeBSD porting (c) 2003
++ * Simon 'corecode' Schubert <corecode@corecode.ath.cx>
+ *
+ * CDROM code specific to the cooked ioctl interface
+ *
+@@ -10,9 +12,11 @@
#include "common_interface.h"
#include "utils.h"
@@ -14,7 +23,7 @@ $NetBSD: patch-ce,v 1.4 2006/11/05 13:45:37 wiz Exp $
struct cdrom_tochdr hdr;
struct cdrom_tocentry entry;
-@@ -52,6 +54,45 @@ static int cooked_readtoc (cdrom_drive *
+@@ -52,6 +56,45 @@ static int cooked_readtoc (cdrom_drive *
d->disc_toc[i].dwStartSector = entry.cdte_addr.lba;
tracks=hdr.cdth_trk1+1;
@@ -60,7 +69,7 @@ $NetBSD: patch-ce,v 1.4 2006/11/05 13:45:37 wiz Exp $
d->cd_extra=FixupTOC(d,tracks);
return(--tracks); /* without lead-out */
}
-@@ -60,10 +101,15 @@ static int cooked_readtoc (cdrom_drive *
+@@ -60,10 +103,15 @@ static int cooked_readtoc (cdrom_drive *
/* Set operating speed */
static int cooked_setspeed(cdrom_drive *d, int speed)
{
@@ -76,7 +85,7 @@ $NetBSD: patch-ce,v 1.4 2006/11/05 13:45:37 wiz Exp $
}
-@@ -72,6 +118,7 @@ static int cooked_setspeed(cdrom_drive *
+@@ -72,6 +120,7 @@ static int cooked_setspeed(cdrom_drive *
*/
static long cooked_read (cdrom_drive *d, void *p, long begin, long sectors){
@@ -84,7 +93,7 @@ $NetBSD: patch-ce,v 1.4 2006/11/05 13:45:37 wiz Exp $
int retry_count,err;
struct cdrom_read_audio arg;
char *buffer=(char *)p;
-@@ -127,7 +174,147 @@ static long cooked_read (cdrom_drive *d,
+@@ -127,7 +176,147 @@ static long cooked_read (cdrom_drive *d,
} while (err);
return(sectors);
@@ -232,7 +241,7 @@ $NetBSD: patch-ce,v 1.4 2006/11/05 13:45:37 wiz Exp $
/* hook */
static int Dummy (cdrom_drive *d,int Switch){
-@@ -191,8 +378,11 @@ static void check_exceptions(cdrom_drive
+@@ -191,8 +380,11 @@ static void check_exceptions(cdrom_drive
/* set function pointers to use the ioctl routines */
int cooked_init_drive (cdrom_drive *d){
@@ -245,7 +254,7 @@ $NetBSD: patch-ce,v 1.4 2006/11/05 13:45:37 wiz Exp $
switch(d->drive_type){
case MATSUSHITA_CDROM_MAJOR: /* sbpcd 1 */
case MATSUSHITA_CDROM2_MAJOR: /* sbpcd 2 */
-@@ -243,6 +433,9 @@ int cooked_init_drive (cdrom_drive *d){
+@@ -243,6 +435,9 @@ int cooked_init_drive (cdrom_drive *d){
default:
d->nsectors=40;
}
@@ -255,7 +264,7 @@ $NetBSD: patch-ce,v 1.4 2006/11/05 13:45:37 wiz Exp $
d->enable_cdda = Dummy;
d->read_audio = cooked_read;
d->set_speed = cooked_setspeed;
-@@ -255,5 +448,6 @@ int cooked_init_drive (cdrom_drive *d){
+@@ -255,5 +450,6 @@ int cooked_init_drive (cdrom_drive *d){
if((ret=verify_read_command(d)))return(ret);
d->error_retry=1;
return(0);
diff --git a/audio/cdparanoia/patches/patch-cf b/audio/cdparanoia/patches/patch-cf
index 5aba4a64f1f..981adcb6940 100644
--- a/audio/cdparanoia/patches/patch-cf
+++ b/audio/cdparanoia/patches/patch-cf
@@ -1,8 +1,17 @@
-$NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
+$NetBSD: patch-cf,v 1.8 2007/10/09 21:26:11 heinz Exp $
---- interface/scan_devices.c.orig 2001-03-25 21:44:01.000000000 -0800
+--- interface/scan_devices.c.orig 2001-03-26 07:44:01.000000000 +0200
+++ interface/scan_devices.c
-@@ -19,6 +19,8 @@
+@@ -1,6 +1,8 @@
+ /******************************************************************
+ * CopyPolicy: GNU Public License 2 applies
+ * Copyright (C) 1998 Monty xiphmont@mit.edu
++ * FreeBSD porting (c) 2003
++ * Simon 'corecode' Schubert <corecode@corecode.ath.cx>
+ *
+ * Autoscan for or verify presence of a cdrom device
+ *
+@@ -19,6 +21,8 @@
#include "common_interface.h"
#include "utils.h"
@@ -11,7 +20,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
#define MAX_DEV_LEN 20 /* Safe because strings only come from below */
/* must be absolute paths! */
static char *scsi_cdrom_prefixes[]={
-@@ -49,11 +51,24 @@ static char *cdrom_devices[]={
+@@ -49,11 +53,24 @@ static char *cdrom_devices[]={
"/dev/cm206cd",
"/dev/gscd",
"/dev/optcd",NULL};
@@ -36,7 +45,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
/* Brute force... */
int i=0;
-@@ -75,10 +90,12 @@ cdrom_drive *cdda_find_a_cdrom(int messa
+@@ -75,10 +92,12 @@ cdrom_drive *cdda_find_a_cdrom(int messa
if((d=cdda_identify(buffer,messagedest,messages)))
return(d);
idmessage(messagedest,messages,"",NULL);
@@ -49,7 +58,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
}
}else{
/* Name. Go for it. */
-@@ -97,8 +114,20 @@ cdrom_drive *cdda_find_a_cdrom(int messa
+@@ -97,8 +116,20 @@ cdrom_drive *cdda_find_a_cdrom(int messa
temp->pw_name);
}
return(NULL);
@@ -70,7 +79,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
cdrom_drive *cdda_identify(const char *device, int messagedest,char **messages){
struct stat st;
cdrom_drive *d=NULL;
-@@ -117,8 +146,14 @@ cdrom_drive *cdda_identify(const char *d
+@@ -117,8 +148,14 @@ cdrom_drive *cdda_identify(const char *d
}
#endif
@@ -85,7 +94,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
#ifdef CDDA_TEST
if(!d)d=cdda_identify_test(device,messagedest,messages);
-@@ -146,6 +181,7 @@ char *test_resolve_symlink(const char *f
+@@ -146,6 +183,7 @@ char *test_resolve_symlink(const char *f
cdrom_drive *cdda_identify_cooked(const char *dev, int messagedest,
char **messages){
@@ -93,7 +102,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
cdrom_drive *d=NULL;
struct stat st;
int fd=-1;
-@@ -273,8 +309,60 @@ cdrom_drive *cdda_identify_cooked(const
+@@ -273,8 +311,60 @@ cdrom_drive *cdda_identify_cooked(const
idmessage(messagedest,messages,"\t\tCDROM sensed: %s\n",description);
return(d);
@@ -154,7 +163,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
struct sg_id {
long l1; /* target | lun << 8 | channel << 16 | low_ino << 24 */
long l2; /* Unique id */
-@@ -289,12 +377,18 @@ typedef struct scsiid{
+@@ -289,12 +379,18 @@ typedef struct scsiid{
/* Even *this* isn't as simple as it bloody well should be :-P */
/* SG has an easy interface, but SCSI overall does not */
static int get_scsi_id(int fd, scsiid *id){
@@ -173,7 +182,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
if(ioctl(fd,SCSI_IOCTL_GET_IDLUN,&argid))return(-1);
id->bus=argid.l2; /* for now */
id->id=argid.l1&0xff;
-@@ -302,6 +396,13 @@ static int get_scsi_id(int fd, scsiid *i
+@@ -302,6 +398,13 @@ static int get_scsi_id(int fd, scsiid *i
if(ioctl(fd,SCSI_IOCTL_GET_BUS_NUMBER,&busarg)==0)
id->bus=busarg;
@@ -187,7 +196,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
return(0);
}
-@@ -390,6 +491,7 @@ matchfail:
+@@ -390,6 +493,7 @@ matchfail:
if(dev!=-1)close(dev);
return(NULL);
}
@@ -195,7 +204,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
void strscat(char *a,char *b,int n){
int i;
-@@ -401,6 +503,7 @@ void strscat(char *a,char *b,int n){
+@@ -401,6 +505,7 @@ void strscat(char *a,char *b,int n){
strcat(a," ");
}
@@ -203,7 +212,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
/* At this point, we're going to punt compatability before SG2, and
allow only SG2 and SG3 */
static int verify_SG_version(cdrom_drive *d,int messagedest,
-@@ -430,7 +533,9 @@ static int verify_SG_version(cdrom_drive
+@@ -430,7 +535,9 @@ static int verify_SG_version(cdrom_drive
idmessage(messagedest,messages,buffer,"");
return(major);
}
@@ -213,7 +222,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
cdrom_drive *cdda_identify_scsi(const char *generic_device,
const char *ioctl_device, int messagedest,
char **messages){
-@@ -460,6 +565,7 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -460,6 +567,7 @@ cdrom_drive *cdda_identify_scsi(const ch
generic_device);
return(NULL);
}
@@ -221,7 +230,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
if((int)(g_st.st_rdev>>8)!=SCSI_GENERIC_MAJOR){
if((int)(g_st.st_rdev>>8)!=SCSI_CDROM_MAJOR){
idmessage(messagedest,messages,"\t\t%s is not a SCSI device",
-@@ -471,6 +577,7 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -471,6 +579,7 @@ cdrom_drive *cdda_identify_scsi(const ch
ioctl_device=temp;
}
}
@@ -229,7 +238,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
}
if(ioctl_device){
if(stat(ioctl_device,&i_st)){
-@@ -478,6 +585,7 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -478,6 +587,7 @@ cdrom_drive *cdda_identify_scsi(const ch
ioctl_device);
return(NULL);
}
@@ -237,7 +246,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
if((int)(i_st.st_rdev>>8)!=SCSI_CDROM_MAJOR){
if((int)(i_st.st_rdev>>8)!=SCSI_GENERIC_MAJOR){
idmessage(messagedest,messages,"\t\t%s is not a SCSI device",
-@@ -489,6 +597,7 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -489,6 +599,7 @@ cdrom_drive *cdda_identify_scsi(const ch
ioctl_device=temp;
}
}
@@ -245,7 +254,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
}
/* we need to resolve any symlinks for the lookup code to work */
-@@ -505,6 +614,7 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -505,6 +616,7 @@ cdrom_drive *cdda_identify_scsi(const ch
}
if(!generic_device || !ioctl_device){
@@ -253,7 +262,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
if(generic_device){
ioctl_device=
scsi_match(generic_device,scsi_cdrom_prefixes,
-@@ -520,6 +630,12 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -520,6 +632,12 @@ cdrom_drive *cdda_identify_scsi(const ch
if(!generic_device)
goto cdda_identify_scsi_fail;
}
@@ -266,7 +275,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
}
idmessage(messagedest,messages,"\t\tgeneric device: %s",generic_device);
-@@ -556,6 +672,7 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -556,6 +674,7 @@ cdrom_drive *cdda_identify_scsi(const ch
type=(int)(i_st.st_rdev>>8);
@@ -274,7 +283,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
if(type==SCSI_CDROM_MAJOR){
if (!S_ISBLK(i_st.st_mode)) {
idmessage(messagedest,messages,"\t\tSCSI CDROM device %s not a "
-@@ -567,8 +684,10 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -567,8 +686,10 @@ cdrom_drive *cdda_identify_scsi(const ch
"major number",ioctl_device);
goto cdda_identify_scsi_fail;
}
@@ -285,7 +294,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
if((int)(g_st.st_rdev>>8)==SCSI_GENERIC_MAJOR){
if (!S_ISCHR(g_st.st_mode)) {
idmessage(messagedest,messages,"\t\tGeneric SCSI device %s not a "
-@@ -580,6 +699,7 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -580,6 +701,7 @@ cdrom_drive *cdda_identify_scsi(const ch
"major number",generic_device);
goto cdda_identify_scsi_fail;
}
@@ -293,7 +302,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
d=calloc(1,sizeof(cdrom_drive));
-@@ -590,6 +710,7 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -590,6 +712,7 @@ cdrom_drive *cdda_identify_scsi(const ch
d->bigendianp=-1; /* We don't know yet... */
d->nsectors=-1;
@@ -301,7 +310,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
version=verify_SG_version(d,messagedest,messages);
switch(version){
case -1:case 0:case 1:
-@@ -599,6 +720,9 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -599,6 +722,9 @@ cdrom_drive *cdda_identify_scsi(const ch
d->interface=GENERIC_SCSI;
break;
}
@@ -311,7 +320,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
/* malloc our big buffer for scsi commands */
d->sg=malloc(MAX_BIG_BUFF_SIZE);
-@@ -617,7 +741,16 @@ cdrom_drive *cdda_identify_scsi(const ch
+@@ -617,7 +743,16 @@ cdrom_drive *cdda_identify_scsi(const ch
/* It would seem some TOSHIBA CDROMs gets things wrong */
@@ -329,7 +338,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
!strncmp (p + 16, "CD-ROM", 6) &&
p[0] == TYPE_DISK) {
p[0] = TYPE_ROM;
-@@ -653,6 +786,88 @@ cdda_identify_scsi_fail:
+@@ -653,6 +788,88 @@ cdda_identify_scsi_fail:
if(g_fd!=-1)close(g_fd);
return(NULL);
}
@@ -418,7 +427,7 @@ $NetBSD: patch-cf,v 1.7 2006/09/03 17:13:30 ben Exp $
#ifdef CDDA_TEST
-@@ -702,3 +917,4 @@ cdrom_drive *cdda_identify_test(const ch
+@@ -702,3 +919,4 @@ cdrom_drive *cdda_identify_test(const ch
}
#endif
diff --git a/audio/cdparanoia/patches/patch-cg b/audio/cdparanoia/patches/patch-cg
index 0f5f0aacc8b..d3d9ed114ba 100644
--- a/audio/cdparanoia/patches/patch-cg
+++ b/audio/cdparanoia/patches/patch-cg
@@ -1,8 +1,17 @@
-$NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
+$NetBSD: patch-cg,v 1.9 2007/10/09 21:26:11 heinz Exp $
---- interface/scsi_interface.c.orig 2001-03-24 12:15:46.000000000 +1100
+--- interface/scsi_interface.c.orig 2001-03-24 02:15:46.000000000 +0100
+++ interface/scsi_interface.c
-@@ -23,6 +23,8 @@ static void tweak_SG_buffer(cdrom_drive
+@@ -3,6 +3,8 @@
+ * Original interface.c Copyright (C) 1994-1997
+ * Eissfeldt heiko@colossus.escape.de
+ * Current blenderization Copyright (C) 1998-1999 Monty xiphmont@mit.edu
++ * FreeBSD porting (c) 2003
++ * Simon 'corecode' Schubert <corecode@corecode.ath.cx>
+ *
+ * Generic SCSI interface specific code.
+ *
+@@ -23,6 +25,8 @@ static void tweak_SG_buffer(cdrom_drive
int table,reserved;
char buffer[256];
@@ -11,7 +20,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
/* maximum transfer size? */
if(ioctl(d->cdda_fd,SG_GET_RESERVED_SIZE,&reserved)){
/* Up, guess not. */
-@@ -31,6 +33,10 @@ static void tweak_SG_buffer(cdrom_drive
+@@ -31,6 +35,10 @@ static void tweak_SG_buffer(cdrom_drive
}
if(ioctl(d->cdda_fd,SG_GET_SG_TABLESIZE,&table))table=1;
@@ -22,7 +31,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
{
int cur;
-@@ -53,14 +59,24 @@ static void tweak_SG_buffer(cdrom_drive
+@@ -53,14 +61,24 @@ static void tweak_SG_buffer(cdrom_drive
cdmessage(d,buffer);
}
@@ -48,7 +57,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
static void reset_scsi(cdrom_drive *d){
int arg;
d->enable_cdda(d,0);
-@@ -74,6 +90,44 @@ static void reset_scsi(cdrom_drive *d){
+@@ -74,6 +92,44 @@ static void reset_scsi(cdrom_drive *d){
d->enable_cdda(d,1);
}
@@ -93,7 +102,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
static void clear_garbage(cdrom_drive *d){
fd_set fdset;
struct timeval tv;
-@@ -104,21 +158,30 @@ static void clear_garbage(cdrom_drive *d
+@@ -104,21 +160,30 @@ static void clear_garbage(cdrom_drive *d
flag=1;
}
}
@@ -125,7 +134,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
/* clear out any possibly preexisting garbage */
clear_garbage(d);
-@@ -224,11 +287,53 @@ static int handle_scsi_cmd(cdrom_drive *
+@@ -224,11 +289,53 @@ static int handle_scsi_cmd(cdrom_drive *
if(errno==0)errno=EIO;
return(TR_EREAD);
}
@@ -180,7 +189,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
switch(key){
case 0:
if(errno==0)errno=EIO;
-@@ -266,9 +371,20 @@ static int handle_scsi_cmd(cdrom_drive *
+@@ -266,9 +373,20 @@ static int handle_scsi_cmd(cdrom_drive *
commands still get through. Perhaps no data comes back even
though the target reports success? */
@@ -202,7 +211,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
if(d->sg_buffer[i]!=bytefill){
flag=1;
break;
-@@ -284,6 +400,83 @@ static int handle_scsi_cmd(cdrom_drive *
+@@ -284,6 +402,83 @@ static int handle_scsi_cmd(cdrom_drive *
return(0);
}
@@ -286,7 +295,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
/* Group 1 (10b) command */
static int mode_sense_atapi(cdrom_drive *d,int size,int page){
-@@ -600,6 +793,23 @@ static int scsi_read_toc2 (cdrom_drive *
+@@ -600,6 +795,23 @@ static int scsi_read_toc2 (cdrom_drive *
return(tracks);
}
@@ -310,7 +319,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
/* These do one 'extra' copy in the name of clean code */
static int i_read_28 (cdrom_drive *d, void *p, long begin, long sectors){
-@@ -833,30 +1043,59 @@ static long scsi_read_map (cdrom_drive *
+@@ -833,30 +1045,59 @@ static long scsi_read_map (cdrom_drive *
while(1) {
if((err=map(d,(p?buffer:NULL),begin,sectors))){
if(d->report_all){
@@ -371,7 +380,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
}
if(!d->error_retry)return(-7);
-@@ -1307,22 +1546,45 @@ static void check_fua_bit(cdrom_drive *d
+@@ -1307,22 +1548,45 @@ static void check_fua_bit(cdrom_drive *d
return;
}
@@ -419,7 +428,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
d->is_atapi=1;
}else{
cdmessage(d,"\tDrive is SCSI\n");
-@@ -1332,6 +1594,46 @@ static int check_atapi(cdrom_drive *d){
+@@ -1332,6 +1596,46 @@ static int check_atapi(cdrom_drive *d){
return(d->is_atapi);
}
}
@@ -466,7 +475,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
static int check_mmc(cdrom_drive *d){
char *b;
-@@ -1379,6 +1681,7 @@ static void check_exceptions(cdrom_drive
+@@ -1379,6 +1683,7 @@ static void check_exceptions(cdrom_drive
}
}
@@ -474,7 +483,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
/* request vendor brand and model */
unsigned char *scsi_inquiry(cdrom_drive *d){
memcpy(d->sg_buffer,(char[]){ 0x12,0,0,0,56,0},6);
-@@ -1389,6 +1692,7 @@ unsigned char *scsi_inquiry(cdrom_drive
+@@ -1389,6 +1694,7 @@ unsigned char *scsi_inquiry(cdrom_drive
}
return (d->sg_buffer);
}
@@ -482,7 +491,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
int scsi_init_drive(cdrom_drive *d){
-@@ -1434,7 +1738,7 @@ int scsi_init_drive(cdrom_drive *d){
+@@ -1434,7 +1740,7 @@ int scsi_init_drive(cdrom_drive *d){
d->read_toc = (!memcmp(d->drive_model, "IMS", 3) && !d->is_atapi) ? scsi_read_toc2 :
scsi_read_toc;
@@ -491,7 +500,7 @@ $NetBSD: patch-cg,v 1.8 2006/03/07 06:29:04 joerg Exp $
if(!d->is_atapi){
-@@ -1458,8 +1762,12 @@ int scsi_init_drive(cdrom_drive *d){
+@@ -1458,8 +1764,12 @@ int scsi_init_drive(cdrom_drive *d){
check_fua_bit(d);
d->error_retry=1;