Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 8 Apr 1995 10:23:12 +0930 (CST)
From:      Lucas James <jj@ldjpc.apana.org.au>
To:        Doug Rabson <dfr@render.com>
Cc:        freebsd-bugs@freefall.cdrom.com
Subject:   Re: i386/297: matcd does not play audio CDs from cdplay
Message-ID:  <Pine.BSF.3.91.950408101342.201F-100000@ldjpc.apana.org.au>
In-Reply-To: <199504041450.HAA13780@freefall.cdrom.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 4 Apr 1995, Doug Rabson wrote:
> >Number:         297
> >Category:       i386
> >Synopsis:       matcd does not play audio CDs from cdplay
> >Confidential:   no
> >Severity:       non-critical
> >Priority:       low
> >Responsible:    freebsd-bugs (FreeBSD bugs mailing list)
> >State:          open
> >Class:          sw-bug
> >Submitter-Id:   current-users
> >Arrival-Date:   Tue Apr  4 07:50:01 1995
> >Originator:     Doug Rabson
> >Organization:
> RenderMorphics Ltd.
> >Release:        FreeBSD 2.1.0-Development i386
> >Environment:
> 
> 
> >Description:
> 
> 	When I try to play an audio CD from cdplay with the matcd0 driver,
> 	it prints "cdplay: Bad file descriptor"
> 	I believe that this is because matcd does not implement all the
> 	audio CD ioctls.
> 
> >How-To-Repeat:
> 
> 
> >Fix:

	Patch cdplay.c with the following.
	(it would appear that the status() call doesn't work)

	the 'play' command doesn't work (still) but I can get msfplay to 
work (sortof - does anyone have docs to this command?

@@@@@@@@@@@@@@@@@@@@@@@@cdplay.c.diff@@@@@@@@@@@@@@@@@@@@@@@@@
*** cdplay.c.orig	Sat Apr  8 10:15:36 1995
--- cdplay.c	Fri Apr  7 11:08:11 1995
*************** input ()
*** 249,262 ****
  void
  open_cd ()
  {
!     int trk, m, s, f;
      extern int errno;
      char devbuf[20];
  
      if (cd_fd > -1)
  	return;
      sprintf(devbuf, "/dev/r%sc", cdname);
      cd_fd = open (devbuf, O_RDONLY);
      if (cd_fd < 0) {
  	if (errno == ENXIO) {
  	    /* open says 'Device not configured if there is no cd in */
--- 249,265 ----
  void
  open_cd ()
  {
!     int trk, m, s, f, stat;
      extern int errno;
      char devbuf[20];
  
+     printf("open(); called, cd_fd=%d\n", cd_fd);
      if (cd_fd > -1)
  	return;
      sprintf(devbuf, "/dev/r%sc", cdname);
+     printf("device: %s\n",cdname);
      cd_fd = open (devbuf, O_RDONLY);
+     printf("open returned: %d\n", cd_fd);
      if (cd_fd < 0) {
  	if (errno == ENXIO) {
  	    /* open says 'Device not configured if there is no cd in */
*************** open_cd ()
*** 266,273 ****
  	perror(devbuf);
  	exit (1);
      }
!     if (status (&trk, &m, &s, &f) < 0 ) {
  	close (cd_fd);
  	cd_fd = -1;
      }
  }
--- 269,280 ----
  	perror(devbuf);
  	exit (1);
      }
!     /*
!     trk = m = s = f = 0;
!     if ((stat = status (&trk, &m, &s, &f)) < 0 ) {
! 	printf("status( %d, %d, %d, %d ) returned: %d\n", trk,m,s,f,stat);
  	close (cd_fd);
  	cd_fd = -1;
      }
+     */
  }
@@@@@@@@@@@@@@@@@@@@@@@@cdplay.c.diff@@@@@@@@@@@@@@@@@@@@@@@@@


--
Lucas James
jj@ldjpc.apana.org.au




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.91.950408101342.201F-100000>