[BACK]Return to config.c CVS log [TXT][DIR] Up to [local] / funnyos / arch / testarm

Diff for /funnyos/arch/testarm/config.c between version 1.1 and 1.12

version 1.1, 2007/10/16 09:41:04 version 1.12, 2007/11/19 11:21:48
Line 11 
Line 11 
 /* device drivers */  /* device drivers */
 extern struct driver root_dr;  extern struct driver root_dr;
 extern struct driver cpu_dr;  extern struct driver cpu_dr;
   extern struct driver obio_dr;
   extern struct driver tacons_dr;
   extern struct driver fcons_dr;
   extern struct driver tartc_dr;
   extern struct driver tairqc_dr;
   
   
 extern void(*putchar)(char);  extern void(*putchar)(char);
Line 19 
Line 24 
 /* amount of physical memory, in Bytes */  /* amount of physical memory, in Bytes */
 uint32_t physmem = 33554432;  uint32_t physmem = 33554432;
   
 #if 0  
 /*  /*
  * Devices present in this system.  
  */  
 struct device devlist[] = {  
 /*        name, minor, active, attach_subr, *devdata, locator, [*parent] */  
 /* 0 */ { "root", 0, 0, root_attach, NULL, 0 },  
 /* 1 */ { "cpu", 0, 0, cpu_attach, NULL, 0 },  
 /* 2 */ { "obio", 0, 0, obio_attach, NULL, 0 },  
 /* 3 */ { "tartc", 0, 0, tartc_attach, NULL, 0x15000000 },  
 /* 4 */ { "tacons", 0, 0, tacons_attach, NULL, 0x10000000 },  
 /* 5 */ { "fcons", 0, 0, fcons_attach, NULL, 0 },  
                 { NULL, 0, 0, NULL, NULL, 0, NULL }  
 };  
   
 void  
 devlist_prepare(void)  
 {  
         /*  
         * Where to attach each device.  
         * XXX kill this ugly macross.  
         */  
         ATTACH(0) AT PARENT(0);  
         ATTACH(1) AT PARENT(0);  
         ATTACH(2) AT PARENT(0);  
         ATTACH(3) AT PARENT(2);  
         ATTACH(4) AT PARENT(2);  
         ATTACH(5) AT PARENT(4);  
   
         /*  
          * Early console putchar hack;  
          */  
         putchar = tacons_early_putc;  
   
 };  
 /*  
  * How many instances of each device will be present in system.  
  * We need it to know (at compile-time) how many of struct xxx_dd (devdata) in device drivers  
  *  should we compile. (sadly, we have no dynamic memory allocations subsystem for now)  
  */  
 /* this all is XXX; btw this've been moved in drivervar.h */  
 // #define NTACONS 1  
   
 uint8_t ndevices = sizeof(devlist) / sizeof(struct device);  
 #endif /* not 0 */  
   
 /*  
  * Where to attach each device.   * Where to attach each device.
  */   */
 struct attachinfo config_attachinfo[] = {  struct attachinfo config_attachinfo[] = {
         /* child,   parent, pminor, loc, flags */          /* child,   parent, pminor, loc,        intrno, flags */
 //      { "obio",       "root",         0, 0,   0 },          { "cpu" ,       "root",         0, 0,                   0,      0 },
         { "cpu" ,       "root",         0, 0,   0 },          { "obio",       "root",         0, 0,                   0,      0 },
 //      { "tacons",     "obio",         0, 0x10000000, 0 },          { "tacons",     "obio",         0, 0x10000000,  0,      0 },
 //      { "tartc",      "obio",         0, 0x15000000, 0x01 },          { "tartc",      "obio",         0, 0x15000000,  4,  0 },
 //      { "fcons",      "tacons",       0, 0,   0},          { "tairqc", "obio",             0, 0x16000000,  0,      0 },
         { NULL,         NULL,           0, 0,   0}          { "fcons",      "tacons",       0, 0,                   0,      0 },
           { NULL,         NULL,           0, 0,                   0,  0 }
 };  };
   
   
Line 83 
Line 43 
  * Link device names with their drivers.   * Link device names with their drivers.
  */   */
 struct driverinfo config_driverinfo[] = {  struct driverinfo config_driverinfo[] = {
   /* name, driverp, ninstances (should be -1) */
         { "root", &root_dr, -1 },          { "root", &root_dr, -1 },
 //      { "obio", &obio_dr, -1 },          { "obio", &obio_dr, -1 },
         { "cpu" , &cpu_dr, -1 },          { "cpu" , &cpu_dr, -1 },
 //      { "tacons", &tacons_dr, -1 },          { "tacons", &tacons_dr, -1 },
 //      { "tartc", &tartc_dr, -1 },          { "tartc", &tartc_dr, -1 },
 //      { "fcons", &fcons_dr, -1 },          { "fcons", &fcons_dr, -1 },
           { "tairqc", &tairqc_dr, -1 },
         { NULL, NULL, 0 }          { NULL, NULL, 0 }
 };  };
   
Line 98 
Line 60 
  */   */
   
 void  void
 config_consinit(void)  config_machineinit(void)
 {  {
         /*          /*
          * Configure putchar, so we can printf messages to the console without fcons.           * Configure putchar, so we can printf messages to the console without fcons.

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.12

CVSweb