1. 20 10月, 2011 2 次提交
  2. 15 9月, 2011 1 次提交
    • K
      xen/irq: Alter the locking to use a mutex instead of a spinlock. · 77365948
      Konrad Rzeszutek Wilk 提交于
      When we allocate/change the IRQ informations, we do not
      need to use spinlocks. We can use a mutex (which is
      what the generic IRQ code does for allocations/changes).
      Fixes a slew of:
      
      BUG: sleeping function called from invalid context at /linux/kernel/mutex.c:271
      in_atomic(): 1, irqs_disabled(): 0, pid: 3216, name: xenstored
      2 locks held by xenstored/3216:
       #0:  (&u->bind_mutex){......}, at: [<ffffffffa02e0920>] evtchn_ioctl+0x30/0x3a0 [xen_evtchn]
       #1:  (irq_mapping_update_lock){......}, at: [<ffffffff8138b274>] bind_evtchn_to_irq+0x24/0x90
      Pid: 3216, comm: xenstored Not tainted 3.1.0-rc6-00021-g437a3d1 #2
      Call Trace:
       [<ffffffff81088d10>] __might_sleep+0x100/0x130
       [<ffffffff81645c2f>] mutex_lock_nested+0x2f/0x50
       [<ffffffff81627529>] __irq_alloc_descs+0x49/0x200
       [<ffffffffa02e0920>] ? evtchn_ioctl+0x30/0x3a0 [xen_evtchn]
       [<ffffffff8138b214>] xen_allocate_irq_dynamic+0x34/0x70
       [<ffffffff8138b2ad>] bind_evtchn_to_irq+0x5d/0x90
       [<ffffffffa02e03c0>] ? evtchn_bind_to_user+0x60/0x60 [xen_evtchn]
       [<ffffffff8138c282>] bind_evtchn_to_irqhandler+0x32/0x80
       [<ffffffffa02e03a9>] evtchn_bind_to_user+0x49/0x60 [xen_evtchn]
       [<ffffffffa02e0a34>] evtchn_ioctl+0x144/0x3a0 [xen_evtchn]
       [<ffffffff811b4070>] ? vfsmount_lock_local_unlock+0x50/0x80
       [<ffffffff811a6a1a>] do_vfs_ioctl+0x9a/0x5e0
       [<ffffffff811b476f>] ? mntput+0x1f/0x30
       [<ffffffff81196259>] ? fput+0x199/0x240
       [<ffffffff811a7001>] sys_ioctl+0xa1/0xb0
       [<ffffffff8164ea82>] system_call_fastpath+0x16/0x1b
      Reported-by: NJim Burns <jim_burn@bellsouth.net>
      Acked-by: NIan Campbell <ian.campbell@citrix.com>
      Signed-off-by: NKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
      77365948
  3. 12 7月, 2011 2 次提交
  4. 16 6月, 2011 1 次提交
  5. 31 5月, 2011 1 次提交
  6. 11 5月, 2011 1 次提交
    • S
      xen: do not clear and mask evtchns in __xen_evtchn_do_upcall · 7e186bdd
      Stefano Stabellini 提交于
      Change the irq handler of evtchns and pirqs that don't need EOI (pirqs
      that correspond to physical edge interrupts) to handle_edge_irq.
      
      Use handle_fasteoi_irq for pirqs that need eoi (they generally
      correspond to level triggered irqs), no risk in loosing interrupts
      because we have to EOI the irq anyway.
      
      This change has the following benefits:
      
      - it uses the very same handlers that Linux would use on native for the
      same irqs (handle_edge_irq for edge irqs and msis, and
      handle_fasteoi_irq for everything else);
      
      - it uses these handlers in the same way native code would use them: it
      let Linux mask\unmask and ack the irq when Linux want to mask\unmask
      and ack the irq;
      
      - it fixes a problem occurring when a driver calls disable_irq() in its
      handler: the old code was unconditionally unmasking the evtchn even if
      the irq is disabled when irq_eoi was called.
      
      See Documentation/DocBook/genericirq.tmpl for more informations.
      Signed-off-by: NStefano Stabellini <stefano.stabellini@eu.citrix.com>
      [v1: Fixed space/tab issues]
      Signed-off-by: NKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
      7e186bdd
  7. 14 4月, 2011 4 次提交
  8. 31 3月, 2011 2 次提交
  9. 29 3月, 2011 4 次提交
  10. 16 3月, 2011 1 次提交
  11. 14 3月, 2011 1 次提交
  12. 11 3月, 2011 20 次提交