[BACK]Return to kern_devconfig.c CVS log [TXT][DIR] Up to [local] / funnyos / kern

Diff for /funnyos/kern/kern_devconfig.c between version 1.6 and 1.8

version 1.6, 2007/11/01 13:19:27 version 1.8, 2007/11/02 13:17:39
Line 5 
Line 5 
 #include <sys/device.h>  #include <sys/device.h>
 #include <sys/kern_devconfig.h>  #include <sys/kern_devconfig.h>
 #include <sys/mem.h>  #include <sys/mem.h>
   #include <sys/kern_irq.h>
 #include <libkern/string.h>  #include <libkern/string.h>
 #include <libkern/printf.h>  #include <libkern/printf.h>
   
Line 103 
Line 104 
 {  {
         /*          /*
          * Attach device childs, if any.           * Attach device childs, if any.
          * XXX Allocate space for struct device and its xxx_dd           * Allocate space for struct device and its xxx_dd
          */           */
         int retval;          int retval;
         struct device *cdevp;          struct device *cdevp;
Line 146 
Line 147 
                         cdevp->dv_name = dip->di_dname;                          cdevp->dv_name = dip->di_dname;
                         cdevp->dv_minor = dip->di_ninstances;                          cdevp->dv_minor = dip->di_ninstances;
   
                         /* XXX what about locator (aip->ai_locator)? */  
   
                         printf("%s/%d at %s/%d loc 0x%x flags 0x%x: ", cdevp->dv_name, cdevp->dv_minor,                          printf("%s/%d at %s/%d loc 0x%x flags 0x%x: ", cdevp->dv_name, cdevp->dv_minor,
                                                                         pdevp->dv_name, pdevp->dv_minor, aip->ai_locator, aip->ai_flags);                                                                          pdevp->dv_name, pdevp->dv_minor, aip->ai_locator, aip->ai_flags);
   
Line 163 
Line 162 
   
                                 /* TODO kfree devdata and device */                                  /* TODO kfree devdata and device */
   
                                 /* XXX next aip */                                  /* next aip */
                                 aip++;                                  aip++;
   
                                 continue;                                  continue;
Line 177 
Line 176 
                         /* activate device */                          /* activate device */
                         cdevp->dv_active = 1;                          cdevp->dv_active = 1;
   
                         /* XXX think about recursion */                          /* if device has interrupt handler, establish it */
                           if (drp->dr_interrupt != NULL && aip->ai_intrno != 0) {
                                   DPRINTF("devconfig_attach_childs: establishing interrupt %d for %s/%d\n",
                                                           aip->ai_intrno, cdevp->dv_name, cdevp->dv_minor);
                                   intr_establish(aip->ai_intrno, cdevp, drp->dr_interrupt);
                           }
   
                         /* recursive attach this child's children */                          /* recursive attach this child's children */
                         devconfig_attach_childs(cdevp);                          devconfig_attach_childs(cdevp);

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.8

CVSweb