[BACK]Return to xen_intr.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / arch / xen / x86

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/arch/xen/x86/xen_intr.c between version 1.21.2.5 and 1.21.2.6

version 1.21.2.5, 2020/04/16 08:46:35 version 1.21.2.6, 2020/04/19 11:40:30
Line 138  xen_intr_establish_xname(int legacy_irq,
Line 138  xen_intr_establish_xname(int legacy_irq,
                 intrstr = intr_create_intrid(legacy_irq, pic, pin, intrstr_buf,                  intrstr = intr_create_intrid(legacy_irq, pic, pin, intrstr_buf,
                     sizeof(intrstr_buf));                      sizeof(intrstr_buf));
   
                 event_set_handler(pin, handler, arg, level, intrstr, xname,                  rih = event_set_handler(pin, handler, arg, level,
                     known_mpsafe);                      intrstr, xname, known_mpsafe);
   
                 rih = kmem_zalloc(sizeof(*rih), cold ? KM_NOSLEEP : KM_SLEEP);  
                 if (rih == NULL) {                  if (rih == NULL) {
                         printf("%s: can't allocate handler info\n", __func__);                          printf("%s: can't establish interrupt", __func__);
                         return NULL;                          return NULL;
                 }                  }
   
                 /*  
                  * XXX:  
                  * This is just a copy for API conformance.  
                  * The real ih is lost in the innards of  
                  * event_set_handler(); where the details of  
                  * biglock_wrapper etc are taken care of.  
                  * All that goes away when we nuke event_set_handler()  
                  * et. al. and unify with x86/intr.c  
                  */  
                 rih->ih_pin = pin; /* port */  
                 rih->ih_fun = rih->ih_realfun = handler;  
                 rih->ih_arg = rih->ih_realarg = arg;  
                 rih->pic_type = pic->pic_type;  
                 return rih;                  return rih;
         }       /* Else we assume pintr */          }       /* Else we assume pintr */
   
Line 201  xen_intr_establish_xname(int legacy_irq,
Line 187  xen_intr_establish_xname(int legacy_irq,
   
         pih = pirq_establish(gsi, evtchn, handler, arg, level,          pih = pirq_establish(gsi, evtchn, handler, arg, level,
                              intrstr, xname, known_mpsafe);                               intrstr, xname, known_mpsafe);
         pih->pic_type = pic->pic_type;          pih->pic = pic;
         return pih;          return pih;
 #endif /* NPCI > 0 || NISA > 0 */  #endif /* NPCI > 0 || NISA > 0 */
   
Line 236  void
Line 222  void
 xen_intr_disestablish(struct intrhand *ih)  xen_intr_disestablish(struct intrhand *ih)
 {  {
   
         if (ih->pic_type == PIC_XEN) {          if (ih->ih_pic->pic_type == PIC_XEN) {
                 event_remove_handler(ih->ih_pin, ih->ih_realfun,                  event_remove_handler(ih->ih_pin, ih->ih_realfun,
                     ih->ih_realarg);                      ih->ih_realarg);
                 kmem_free(ih, sizeof(*ih));                  /* event_remove_handler frees ih */
                 return;                  return;
         }          }
 #if defined(DOM0OPS)  #if defined(DOM0OPS)

Legend:
Removed from v.1.21.2.5  
changed lines
  Added in v.1.21.2.6

CVSweb <webmaster@jp.NetBSD.org>