diff options
Diffstat (limited to 'drivers/block/pktcdvd.c')
-rw-r--r-- | drivers/block/pktcdvd.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/block/pktcdvd.c b/drivers/block/pktcdvd.c index 293f5858921d..d57f11759480 100644 --- a/drivers/block/pktcdvd.c +++ b/drivers/block/pktcdvd.c | |||
@@ -991,13 +991,15 @@ static void pkt_iosched_process_queue(struct pktcdvd_device *pd) | |||
991 | */ | 991 | */ |
992 | static int pkt_set_segment_merging(struct pktcdvd_device *pd, struct request_queue *q) | 992 | static int pkt_set_segment_merging(struct pktcdvd_device *pd, struct request_queue *q) |
993 | { | 993 | { |
994 | if ((pd->settings.size << 9) / CD_FRAMESIZE <= q->max_phys_segments) { | 994 | if ((pd->settings.size << 9) / CD_FRAMESIZE |
995 | <= queue_max_phys_segments(q)) { | ||
995 | /* | 996 | /* |
996 | * The cdrom device can handle one segment/frame | 997 | * The cdrom device can handle one segment/frame |
997 | */ | 998 | */ |
998 | clear_bit(PACKET_MERGE_SEGS, &pd->flags); | 999 | clear_bit(PACKET_MERGE_SEGS, &pd->flags); |
999 | return 0; | 1000 | return 0; |
1000 | } else if ((pd->settings.size << 9) / PAGE_SIZE <= q->max_phys_segments) { | 1001 | } else if ((pd->settings.size << 9) / PAGE_SIZE |
1002 | <= queue_max_phys_segments(q)) { | ||
1001 | /* | 1003 | /* |
1002 | * We can handle this case at the expense of some extra memory | 1004 | * We can handle this case at the expense of some extra memory |
1003 | * copies during write operations | 1005 | * copies during write operations |