Subversion Repositories shark

Compare Revisions

Regard whitespace Rev 927 → Rev 926

/shark/trunk/ports/first/modules/grubstar.c
516,7 → 516,7
if ((lev->U - lev->Uf) < 0) {
cprintf("GRUBSTAR Error: Bad Reclaiming Computation\n");
kern_raise(XUNSPECIFIED_EXCEPTION, exec_shadow);
sys_end();
}
 
mul32div32to32(lev->b[lev->tb[exec]].avail,(lev->U-lev->Uf),lev->U,lev->b[lev->tb[exec]].last_reclaiming);
/shark/trunk/ports/first/first-server.c
105,7 → 105,8
if (err) {
cprintf("error creating service task\n");
sys_shutdown_message("Could not create service_task");
exit(1);
sys_end();
return;
}
 
task_activate(server_task);
/shark/trunk/ports/fftw/fftw/malloc.c
21,7 → 21,7
* malloc.c -- memory allocation related functions
*/
 
/* $Id: malloc.c,v 1.3 2005-01-08 15:00:28 pj Exp $ */
/* $Id: malloc.c,v 1.2 2003-03-24 11:14:54 pj Exp $ */
#ifdef FFTW_USING_CILK
#include <cilk.h>
#include <cilk-compat.h>
92,7 → 92,7
// fprintf(stderr, "fftw: %s", s);
 
printk(KERN_ERR "fftw: %s", s);
exit(EXIT_FAILURE);
sys_abort(EXIT_FAILURE);
}
 
/* check for memory leaks when debugging */
113,7 → 113,7
fftw_malloc_cnt,
fftw_node_cnt, fftw_plan_cnt, fftw_twiddle_size,
fftw_malloc_total);
exit(EXIT_FAILURE);
sys_abort(EXIT_FAILURE);
}
#else
if (fftw_node_cnt || fftw_plan_cnt || fftw_twiddle_size) {
123,7 → 123,7
"MEMORY LEAK!!!\n"
" node=%d plan=%d twiddle=%d\n",
fftw_node_cnt, fftw_plan_cnt, fftw_twiddle_size);
exit(EXIT_FAILURE);
sys_abort(EXIT_FAILURE);
}
#endif
}
/shark/trunk/tracer/newtrace/FTrace_udp.c
215,7 → 215,7
udp_task = task_create("UDP_Sender",udp_sender,&st,NULL);
if (udp_task == NIL) {
cprintf("Error creating UDP Sender\n");
exit(1);
sys_end();
}
task_activate(udp_task);
/shark/trunk/drivers/linuxc26/waitqueue.c
105,7 → 105,7
{
printk(KERN_DEBUG "@get_current26 out of memory!!!\n");
//
// exit?
// sys_abort?
//
}
tsp->pid = exec_shadow;
/shark/trunk/drivers/linuxc26/shark_videodev.c
28,7 → 28,7
 
if (videodev_open_inode(num)) {
sys_shutdown_message("VIDEODEV26 ERROR: Cannot open the VideoDev driver\n");
exit(1);
sys_end();
}
 
return 0;
/shark/trunk/drivers/linuxc26/shark_linuxc26.c
53,7 → 53,7
res = shark_interrupt_server();
if (res != 0) {
printk("ERROR: CANNOT REGISTER LINUX COMPATIBILITY LAYER\n");
exit(1);
sys_end();
}
 
return 0;
/shark/trunk/drivers/input/shark/shark_keyb.c
368,7 → 368,7
set_active_page(0);
set_visual_page(0);
//cputs("Ctrl-C pressed!\n");
exit(1);
sys_end();
}
 
/**** Start User Functions ****/
/shark/trunk/drivers/bttv/shark_bttv26.c
46,7 → 46,7
 
if (res != 0) {
sys_shutdown_message("ERROR: Cannot initialize BTTV\n");
exit(1);
sys_end();
}
 
bttv_installed = TRUE;
/shark/trunk/drivers/oldchar/8042.c
20,11 → 20,11
 
/**
------------
CVS : $Id: 8042.c,v 1.6 2005-01-08 14:57:06 pj Exp $
CVS : $Id: 8042.c,v 1.5 2004-03-09 08:49:13 giacomo Exp $
 
File: $File$
Revision: $Revision: 1.6 $
Last update: $Date: 2005-01-08 14:57:06 $
Revision: $Revision: 1.5 $
Last update: $Date: 2004-03-09 08:49:13 $
------------
 
8042.h
83,7 → 83,7
 
//#define __DEBUG_INIT__ 1
 
/* if defined: show messages during exit */
/* if defined: show messages during sys_end() */
//#define __TRACE_EXIT__ 1
 
/* if defined: trace ps/2 enable/disable */
/shark/trunk/drivers/oldchar/keyb.c
20,11 → 20,11
 
/**
------------
CVS : $Id: keyb.c,v 1.3 2005-01-08 14:57:06 pj Exp $
CVS : $Id: keyb.c,v 1.2 2004-01-17 13:17:52 giacomo Exp $
 
File: $File$
Revision: $Revision: 1.3 $
Last update: $Date: 2005-01-08 14:57:06 $
Revision: $Revision: 1.2 $
Last update: $Date: 2004-01-17 13:17:52 $
------------
 
Author: Giuseppe Lipari
508,7 → 508,8
set_active_page(0);
set_visual_page(0);
cputs("Ctrl-C pressed!\n");
exit(1);
sys_end();
// exit(1);
}
 
/* This is the interface to application */
/shark/trunk/drivers/oldsnd/sound.c
167,7 → 167,7
p_pl = task_create("sb_Player",proc_play, &m, NULL);
if (p_pl == NIL) {
cprintf("Sound.c: Cannot create sb_Player\n");
exit(1);
sys_end();
return ESRCH;
}
task_activate(p_pl);
250,7 → 250,7
p_sample = task_create("sb_Sampler",proc_sample, &m, NULL);
if (p_sample == NIL) {
cprintf("Sound.c: Cannot create sb_Sampler\n");
exit(1);
sys_end();
return ESRCH;
}
task_activate(p_sample);
325,7 → 325,7
if (p_sb == NIL) {
cprintf("Sound.c: Cannot create sb_EndDMA\n");
cprintf("errno=%d\n",errno);
exit(1);
sys_end();
return ESRCH;
}
//sb_dev.period = period;
/shark/trunk/drivers/oldsnd/dma.c
86,7 → 86,7
len_port = 0x07;
break;
default: cprintf("dma_setbuff channel error!!!\n");
exit(1);
sys_end();
return;
}
ph_addr = appl2linear(addr);
121,7 → 121,7
break;
/* It does not seem too much clean */
default: cprintf("16 bit DMA?????\n");
exit(1);
sys_end();
return;
}
ph_addr = appl2linear(addr);
/shark/trunk/drivers/net/include/linux/compatib.h
138,7 → 138,7
extern __inline__ void panic(const char *c)
{
cputs((char *)c);
exit(1);
sys_end();
}
 
/* below tuff added for rtl8139 net driver
/shark/trunk/drivers/net/eth.c
20,11 → 20,11
 
/**
------------
CVS : $Id: eth.c,v 1.11 2005-01-08 14:57:06 pj Exp $
CVS : $Id: eth.c,v 1.10 2004-05-11 16:03:40 giacomo Exp $
 
File: $File$
Revision: $Revision: 1.11 $
Last update: $Date: 2005-01-08 14:57:06 $
Revision: $Revision: 1.10 $
Last update: $Date: 2004-05-11 16:03:40 $
------------
**/
 
131,7 → 131,7
void dev_tint(struct device *dev)
{
printk(KERN_WARNING "Warning! dev_tint called. (Why?)\n");
exit(201);
sys_abort(201);
}
 
/*
145,7 → 145,7
// cprintf("DENTRO netif_rx, skbuf=%p\n",skb->data);
if (nettask_pid == NIL) {
printk(KERN_CRIT "Net receives packets, but the driver doesn't exist.\n");
exit(300);
sys_abort(300);
}
 
port_send(NetRxPort,skb,NON_BLOCK);
/shark/trunk/drivers/net/arp.c
20,11 → 20,11
 
/**
------------
CVS : $Id: arp.c,v 1.5 2005-01-08 14:57:06 pj Exp $
CVS : $Id: arp.c,v 1.4 2004-05-11 14:30:48 giacomo Exp $
 
File: $File$
Revision: $Revision: 1.5 $
Last update: $Date: 2005-01-08 14:57:06 $
Revision: $Revision: 1.4 $
Last update: $Date: 2004-05-11 14:30:48 $
------------
**/
 
140,7 → 140,7
}
if (j == -1) {
cprintf("ARP table overflow.\n");
exit(AARPFULL);
sys_abort(AARPFULL);
}
arpTable[j].valid = FALSE;
}
430,7 → 430,8
s = task_create("ArpRetry",arp_retry,&m,NULL);
if (s == NIL) {
kern_printf("Cannot create ArpRetry\n");
exit(1);
sys_end();
l1_exit(-1);
}
 
eth_setProtocol(ETH_ARP_TYPE,arp_server_recv);
445,7 → 446,7
 
if (sigaction(SIGARPFULL, &action, NULL) == -1) {
perror("Error initializing ARP signal...");
exit(AARPFULL);
sys_abort(AARPFULL);
}
 
task_activate(s);
/shark/trunk/drivers/net/misc.c
5,6 → 5,6
{
cprintf("Panic: stub called!!!\n");
 
exit(200); /* Just a number... */
sys_abort(200); /* Just a number... */
}
 
/shark/trunk/fs/msdos/msdos_s.c
34,11 → 34,11
*/
 
/*
* CVS : $Id: msdos_s.c,v 1.2 2005-01-08 14:59:23 pj Exp $
* CVS : $Id: msdos_s.c,v 1.1.1.1 2002-03-29 14:12:50 pj Exp $
*
* File: $File$
* Revision: $Revision: 1.2 $
* Last update: $Date: 2005-01-08 14:59:23 $
* Revision: $Revision: 1.1.1.1 $
* Last update: $Date: 2002-03-29 14:12:50 $
*/
 
#include <fs/types.h>
555,7 → 555,7
d=get_dentry();
if (d!=NULL) {
exit(1234);
sys_abort(1234);
}
strcpy(d->d_name.name,"BC45");
d->d_name.nameptr=NULL;
/shark/trunk/fs/fs.h
34,11 → 34,11
*/
 
/*
* CVS : $Id: fs.h,v 1.3 2005-01-08 14:59:23 pj Exp $
* CVS : $Id: fs.h,v 1.2 2002-11-11 08:40:44 pj Exp $
*
* File: $File$
* Revision: $Revision: 1.3 $
* Last update: $Date: 2005-01-08 14:59:23 $
* Revision: $Revision: 1.2 $
* Last update: $Date: 2002-11-11 08:40:44 $
*/
 
/***
233,7 → 233,7
}
if (counter>=SHUTDOWNCOUNTER) {
printk(KERN_NOTICE "filesystem shutdown timeout... aborting!");
exit(371);
sys_abort(371);
}
}
#else
/shark/trunk/libc/stdlib/abort.c
20,11 → 20,11
 
/**
------------
CVS : $Id: abort.c,v 1.2 2005-01-08 14:59:45 pj Exp $
CVS : $Id: abort.c,v 1.1.1.1 2002-03-29 14:12:53 pj Exp $
 
File: $File$
Revision: $Revision: 1.2 $
Last update: $Date: 2005-01-08 14:59:45 $
Revision: $Revision: 1.1.1.1 $
Last update: $Date: 2002-03-29 14:12:53 $
------------
 
abort, inspired on OsKit one...
106,6 → 106,6
(void)sigprocmask(SIG_SETMASK, &mask, (sigset_t *)NULL);
 
kill(0,SIGABRT);
exit(0);
sys_end();
}
 
/shark/trunk/libc/stdlib/exit.c
0,0 → 1,72
/*
* Project: S.Ha.R.K.
*
* Coordinators:
* Giorgio Buttazzo <giorgio@sssup.it>
* Paolo Gai <pj@gandalf.sssup.it>
*
* Authors :
* Paolo Gai <pj@gandalf.sssup.it>
* Massimiliano Giorgi <massy@gandalf.sssup.it>
* Luca Abeni <luca@gandalf.sssup.it>
* (see the web pages for full authors list)
*
* ReTiS Lab (Scuola Superiore S.Anna - Pisa - Italy)
*
* http://www.sssup.it
* http://retis.sssup.it
* http://shark.sssup.it
*/
 
/**
------------
CVS : $Id: exit.c,v 1.1.1.1 2002-03-29 14:12:53 pj Exp $
 
File: $File$
Revision: $Revision: 1.1.1.1 $
Last update: $Date: 2002-03-29 14:12:53 $
------------
 
**/
 
/*
* Copyright (C) 2000 Paolo Gai
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
 
#include <kernel/kern.h>
 
 
// the code of this function is equal to sys_end!!!! (kernel/kern.c)
void _exit(int status)
{
SYS_FLAGS f;
 
/* the sys_end change the context to the global context.
when the first time is called, it simply kills all the users tasks
and waits the system tasks to end... */
 
f = kern_fsave();
if (runlevel != RUNLEVEL_INIT && system_counter) {
kern_frestore(f);
return;
}
 
internal_sys_end(status);
kern_frestore(f);
}
 
/shark/trunk/libc/libio/old/abort.c
20,11 → 20,11
 
/**
------------
CVS : $Id: abort.c,v 1.2 2005-01-08 14:59:45 pj Exp $
CVS : $Id: abort.c,v 1.1.1.1 2002-03-29 14:12:53 pj Exp $
 
File: $File$
Revision: $Revision: 1.2 $
Last update: $Date: 2005-01-08 14:59:45 $
Revision: $Revision: 1.1.1.1 $
Last update: $Date: 2002-03-29 14:12:53 $
------------
**/
 
55,6 → 55,6
void abort(void)
{
cprintf("ABORT CALLED\n");
exit(999);
sys_abort(999);
}