Merge branch 'for-2.6.40/core' of git://git.kernel.dk/linux-2.6-block
authorLinus Torvalds <torvalds@linux-foundation.org>
Wed, 25 May 2011 16:14:07 +0000 (09:14 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 25 May 2011 16:14:07 +0000 (09:14 -0700)
* 'for-2.6.40/core' of git://git.kernel.dk/linux-2.6-block: (40 commits)
  cfq-iosched: free cic_index if cfqd allocation fails
  cfq-iosched: remove unused 'group_changed' in cfq_service_tree_add()
  cfq-iosched: reduce bit operations in cfq_choose_req()
  cfq-iosched: algebraic simplification in cfq_prio_to_maxrq()
  blk-cgroup: Initialize ioc->cgroup_changed at ioc creation time
  block: move bd_set_size() above rescan_partitions() in __blkdev_get()
  block: call elv_bio_merged() when merged
  cfq-iosched: Make IO merge related stats per cpu
  cfq-iosched: Fix a memory leak of per cpu stats for root group
  backing-dev: Kill set but not used var in  bdi_debug_stats_show()
  block: get rid of on-stack plugging debug checks
  blk-throttle: Make no throttling rule group processing lockless
  blk-cgroup: Make cgroup stat reset path blkg->lock free for dispatch stats
  blk-cgroup: Make 64bit per cpu stats safe on 32bit arch
  blk-throttle: Make dispatch stats per cpu
  blk-throttle: Free up a group only after one rcu grace period
  blk-throttle: Use helper function to add root throtl group to lists
  blk-throttle: Introduce a helper function to fill in device details
  blk-throttle: Dynamically allocate root group
  blk-cgroup: Allow sleeping while dynamically allocating a group
  ...

1  2 
drivers/ata/libata-scsi.c

@@@ -1089,21 -1089,21 +1089,21 @@@ static int atapi_drain_needed(struct re
  static int ata_scsi_dev_config(struct scsi_device *sdev,
                               struct ata_device *dev)
  {
+       struct request_queue *q = sdev->request_queue;
        if (!ata_id_has_unload(dev->id))
                dev->flags |= ATA_DFLAG_NO_UNLOAD;
  
        /* configure max sectors */
-       blk_queue_max_hw_sectors(sdev->request_queue, dev->max_sectors);
+       blk_queue_max_hw_sectors(q, dev->max_sectors);
  
        if (dev->class == ATA_DEV_ATAPI) {
-               struct request_queue *q = sdev->request_queue;
                void *buf;
  
                sdev->sector_size = ATA_SECT_SIZE;
  
                /* set DMA padding */
-               blk_queue_update_dma_pad(sdev->request_queue,
-                                        ATA_DMA_PAD_SZ - 1);
+               blk_queue_update_dma_pad(q, ATA_DMA_PAD_SZ - 1);
  
                /* configure draining */
                buf = kmalloc(ATAPI_MAX_DRAIN, q->bounce_gfp | GFP_KERNEL);
                        "sector_size=%u > PAGE_SIZE, PIO may malfunction\n",
                        sdev->sector_size);
  
-       blk_queue_update_dma_alignment(sdev->request_queue,
-                                      sdev->sector_size - 1);
+       blk_queue_update_dma_alignment(q, sdev->sector_size - 1);
  
        if (dev->flags & ATA_DFLAG_AN)
                set_bit(SDEV_EVT_MEDIA_CHANGE, sdev->supported_events);
                scsi_adjust_queue_depth(sdev, MSG_SIMPLE_TAG, depth);
        }
  
+       blk_queue_flush_queueable(q, false);
        dev->sdev = sdev;
        return 0;
  }
@@@ -2138,7 -2139,7 +2139,7 @@@ static unsigned int ata_scsiop_inq_b0(s
         * with the unmap bit set.
         */
        if (ata_id_has_trim(args->id)) {
 -              put_unaligned_be32(65535 * 512 / 8, &rbuf[20]);
 +              put_unaligned_be64(65535 * 512 / 8, &rbuf[36]);
                put_unaligned_be32(1, &rbuf[28]);
        }