On Fri, 24 May 2013, Joe Lawrence wrote: > From 5b26d593807b30f60ed41f6fd5a16a56c3c9a43c Mon Sep 17 00:00:00 2001 > From: Joe Lawrence <joe.lawrence@xxxxxxxxxxx> > Date: Fri, 24 May 2013 13:05:09 -0400 > Subject: [PATCH v5 2/2] block,scsi: convert and handle ERR_PTR from blk_get_request > > The blk_get_request function may fail in low-memory conditions or during > device removal (even if __GFP_WAIT is set). To distinguish between these > errors, modify the blk_get_request call stack to return the appropriate > ERR_PTR. Verify that all callers check the return status and consider > IS_ERR instead of a simple NULL pointer check. > > Signed-off-by: Joe Lawrence <joe.lawrence@xxxxxxxxxxx> > Cc: Jens Axboe <axboe@xxxxxxxxx> > Cc: Jiri Kosina <jkosina@xxxxxxx> > Cc: "James E.J. Bottomley" <JBottomley@xxxxxxxxxxxxx> > Cc: Bart Van Assche <bvanassche@xxxxxxx> > Cc: linux-scsi@xxxxxxxxxxxxxxx > --- > block/blk-core.c | 34 ++++++++++++++--------------- > block/bsg.c | 8 +++---- > block/scsi_ioctl.c | 12 +++++----- > drivers/block/paride/pd.c | 4 ++-- > drivers/block/pktcdvd.c | 4 ++-- Acked-by: Jiri Kosina <jkosina@xxxxxxx> for the pktdvd.c change. Thanks Joe. -- Jiri Kosina SUSE Labs -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html