--- trunk/src/devices/dev_igsfb.c 2007/10/08 16:22:20 41 +++ trunk/src/devices/dev_igsfb.c 2007/10/08 16:22:32 42 @@ -25,10 +25,11 @@ * SUCH DAMAGE. * * - * $Id: dev_igsfb.c,v 1.5 2006/12/30 13:30:58 debug Exp $ + * $Id: dev_igsfb.c,v 1.6 2007/06/15 19:11:15 debug Exp $ * - * Integraphics Systems "igsfb" Framebuffer (graphics) card, used in at - * least the NetWinder. + * COMMENT: Integraphics Systems "igsfb" Framebuffer graphics card + * + * Used in at least the NetWinder. * * TODO: This is hardcoded to 1024x768x8 right now, and only supports the * two acceleration commands used by NetBSD for scrolling the @@ -158,8 +159,8 @@ DEVICE_ACCESS(igsfb) { - uint64_t idata = 0, odata = 0; struct dev_igsfb_data *d = extra; + uint64_t idata = 0, odata = 0; if (writeflag == MEM_WRITE) idata = memory_readmax64(cpu, data, len); @@ -404,11 +405,8 @@ DEVINIT(igsfb) { struct dev_igsfb_data *d; - d = malloc(sizeof(struct dev_igsfb_data)); - if (d == NULL) { - fprintf(stderr, "out of memory\n"); - exit(1); - } + + CHECK_ALLOCATION(d = malloc(sizeof(struct dev_igsfb_data))); memset(d, 0, sizeof(struct dev_igsfb_data)); d->xres = 1024;