lkml.org 
[lkml]   [1998]   [May]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subjectsr_ioctl.c error logging patch
The following diff modifies drivers/scsi/sr_ioctl.c so that illegal IOCTLs
to the CDROM can be diverted away from the console by syslog. This should
be an appropriate severity level, feel free to change it if it's
inappropriate. Relative to 2.1.99, but probably will apply much earlier.

--- clean-linux-2.1.99/drivers/scsi/sr_ioctl.c Mon Feb 9 18:12:55 1998
+++ linux/drivers/scsi/sr_ioctl.c Sat May 2 23:25:21 1998
@@ -106,8 +106,8 @@
break;
case ILLEGAL_REQUEST:
if (!quiet)
- printk("sr%d: CDROM (ioctl) reports ILLEGAL REQUEST.\n",
- target);
+ printk(KERN_ERR "sr%d: CDROM (ioctl) reports ILLEGAL "
+ "REQUEST.\n", target);
if (SCpnt->sense_buffer[12] == 0x20 &&
SCpnt->sense_buffer[13] == 0x00) {
/* sense: Invalid command operation code */
@@ -121,7 +121,7 @@
#endif
break;
default:
- printk("sr%d: CDROM (ioctl) error, command: ", target);
+ printk(KERN_ERR "sr%d: CDROM (ioctl) error, command: ", target);
print_command(sr_cmd);
print_sense("sr", SCpnt);
err = -EIO;

Chris
--
=============================================================================
| Chris Lawrence | My home page: |
| <quango@ix.netcom.com> | http://www.clark.net/pub/lawrencc/ |
| | |
| Amiga A4000/040 and | Visit the Lurker's Guide to Babylon 5: |
| Linux/m68k 2.1.29 | <*> http://www.midwinter.com/lurk/ <*> |
=============================================================================
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu

\
 
 \ /
  Last update: 2005-03-22 13:42    [from the cache]
©2003-2011 Jasper Spaans. Advertise on this site