1. 02 10月, 2010 2 次提交
  2. 01 10月, 2010 3 次提交
    • V
      blkio-throttle: Fix link failure failure on i386 · 3aad5d3e
      Vivek Goyal 提交于
      o Randy Dunlap reported following linux-next failure. This patch fixes it.
      
      on i386:
      
      blk-throttle.c:(.text+0x1abb8): undefined reference to `__udivdi3'
      blk-throttle.c:(.text+0x1b1dc): undefined reference to `__udivdi3'
      
      o bytes_per_second interface is 64bit and I was continuing to do 64 bit
        division even on 32bit platform without help of special macros/functions
        hence the failure.
      Signed-off-by: NVivek Goyal <vgoyal@redhat.com>
      Reported-by: NRandy Dunlap <randy.dunlap@oracle.com>
      Signed-off-by: NJens Axboe <jaxboe@fusionio.com>
      3aad5d3e
    • V
      blkio: Recalculate the throttled bio dispatch time upon throttle limit change · fe071437
      Vivek Goyal 提交于
      o Currently any cgroup throttle limit changes are processed asynchronousy and
        the change does not take affect till a new bio is dispatched from same group.
      
      o It might happen that a user sets a redicuously low limit on throttling.
        Say 1 bytes per second on reads. In such cases simple operations like mount
        a disk can wait for a very long time.
      
      o Once bio is throttled, there is no easy way to come out of that wait even if
        user increases the read limit later.
      
      o This patch fixes it. Now if a user changes the cgroup limits, we recalculate
        the bio dispatch time according to new limits.
      
      o Can't take queueu lock under blkcg_lock, hence after the change I wake
        up the dispatch thread again which recalculates the time. So there are some
        variables being synchronized across two threads without lock and I had to
        make use of barriers. Hoping I have used barriers correctly. Any review of
        memory barrier code especially will help.
      Signed-off-by: NVivek Goyal <vgoyal@redhat.com>
      Signed-off-by: NJens Axboe <jaxboe@fusionio.com>
      fe071437
    • V
      blkio: Add root group to td->tg_list · 02977e4a
      Vivek Goyal 提交于
      o Currently all the dynamically allocated groups, except root grp is added
        to td->tg_list. This was not a problem so far but in next patch I will
        travel through td->tg_list to process any updates of limits on the group.
        If root group is not in tg_list, then root group's updates are not
        processed.
      
      o It is better to root group also to tg_list instead of doing special
        processing for it during limit updates.
      Signed-off-by: NVivek Goyal <vgoyal@redhat.com>
      Signed-off-by: NJens Axboe <jaxboe@fusionio.com>
      02977e4a
  3. 16 9月, 2010 2 次提交