PATCH: 2.6.10 - scsi ioctls warnings

From: Alan Cox
Date: Sun Dec 26 2004 - 19:57:14 EST


SCSI ioctls can ask for a lot of memory and fail. We don't need to vomit
in the log file for this case. Again taken from the Red Hat minor
patches applied for FC3.

Signed-off-by: Alan Cox <alan@xxxxxxxxxx>
Original-patch: Arjan van de Ven <arjanv@xxxxxxxxxx>

diff -u --new-file --recursive --exclude-from /usr/src/exclude linux.vanilla-2.6.10/drivers/block/scsi_ioctl.c linux-2.6.10/drivers/block/scsi_ioctl.c
--- linux.vanilla-2.6.10/drivers/block/scsi_ioctl.c 2004-12-25 21:15:34.000000000 +0000
+++ linux-2.6.10/drivers/block/scsi_ioctl.c 2004-12-26 17:27:50.889059496 +0000
@@ -356,7 +356,7 @@

bytes = max(in_len, out_len);
if (bytes) {
- buffer = kmalloc(bytes, q->bounce_gfp | GFP_USER);
+ buffer = kmalloc(bytes, q->bounce_gfp | GFP_USER| __GFP_NOWARN);
if (!buffer)
return -ENOMEM;


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/