/[gxemul]/trunk/src/devices/dev_gc.c
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /trunk/src/devices/dev_gc.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 41 by dpavlin, Mon Oct 8 16:21:17 2007 UTC revision 42 by dpavlin, Mon Oct 8 16:22:32 2007 UTC
# Line 24  Line 24 
24   *  OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF   *  OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
25   *  SUCH DAMAGE.   *  SUCH DAMAGE.
26   *     *  
27   *  $Id: dev_gc.c,v 1.12 2007/02/16 17:17:51 debug Exp $   *  $Id: dev_gc.c,v 1.13 2007/06/15 19:11:15 debug Exp $
28   *     *  
29   *  Grand Central Interrupt controller (used by MacPPC).   *  COMMENT: Grand Central Interrupt controller (used by MacPPC)
30   */   */
31    
32  #include <stdio.h>  #include <stdio.h>
# Line 211  DEVINIT(gc) Line 211  DEVINIT(gc)
211          struct gc_data *d;          struct gc_data *d;
212          int i;          int i;
213    
214          d = malloc(sizeof(struct gc_data));          CHECK_ALLOCATION(d = malloc(sizeof(struct gc_data)));
         if (d == NULL) {  
                 fprintf(stderr, "out of memory\n");  
                 exit(1);  
         }  
215          memset(d, 0, sizeof(struct gc_data));          memset(d, 0, sizeof(struct gc_data));
216    
217          /*  Connect to the CPU:  */          /*  Connect to the CPU interrupt pin:  */
218          INTERRUPT_CONNECT(devinit->interrupt_path, d->cpu_irq);          INTERRUPT_CONNECT(devinit->interrupt_path, d->cpu_irq);
219    
220          /*          /*

Legend:
Removed from v.41  
changed lines
  Added in v.42

  ViewVC Help
Powered by ViewVC 1.1.26