Skip to content
  • Mikulas Patocka's avatar
    ide: Fix IDE taskfile with cfq scheduler · 720fc22a
    Mikulas Patocka authored
    
    
    When ide taskfile access is being used (for example with hdparm --security
    commands) and cfq scheduler is selected, the scheduler crashes on BUG in
    cfq_put_request.
    
    The reason is that the cfq scheduler is tracking counts of read and write
    requests separately; the ide-taskfile subsystem allocates a read request and
    then flips the flag to make it a write request. The counters in cfq will
    mismatch.
    
    This patch changes ide-taskfile to allocate the READ or WRITE request as
    required and don't change the flag later.
    
    Signed-off-by: default avatarMikulas Patocka <mpatocka@redhat.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    720fc22a