Removed a number of useless #includes

This commit is contained in:
Kees van Reeuwijk 2010-01-26 10:59:01 +00:00
parent 76f8132545
commit b67f788eea
76 changed files with 9 additions and 101 deletions

View file

@ -21,14 +21,12 @@ char version[]= "2.20";
#include <ibm/bios.h>
#include <minix/config.h>
#include <minix/type.h>
#include <minix/com.h>
#include <minix/dmap.h>
#include <minix/const.h>
#include <minix/minlib.h>
#include <minix/syslib.h>
#if BIOS
#include <kernel/const.h>
#include <kernel/type.h>
#include <sys/video.h>
#endif
#if UNIX

View file

@ -43,10 +43,8 @@
#include "audio_fw.h"
#include <sys/vm.h>
#include <minix/endpoint.h>
#include <minix/ds.h>
#include <sys/vm_i386.h>
FORWARD _PROTOTYPE( int msg_open, (int minor_dev_nr) );

View file

@ -25,7 +25,6 @@
#include "../libdriver/drvlib.h"
#include <minix/sysutil.h>
#include <minix/safecopies.h>
#include <minix/keymap.h>
#include <sys/ioc_disk.h>
#include <ibm/int86.h>
#include <assert.h>

View file

@ -61,7 +61,6 @@
#include <net/gen/ether.h>
#include <net/gen/eth_io.h>
#include <sys/vm_i386.h>
#include <sys/vm.h>
#include "assert.h"
#include "local.h"

View file

@ -13,7 +13,6 @@
#include "drivers.h"
#include <minix/com.h>
#include <net/hton.h>
#include <net/gen/ether.h>
#include <net/gen/eth_io.h>
#include "dp.h"

View file

@ -13,7 +13,6 @@
#include "drivers.h"
#include <minix/com.h>
#include <net/hton.h>
#include <net/gen/ether.h>
#include <net/gen/eth_io.h>

View file

@ -15,7 +15,6 @@
#include "drivers.h"
#include <minix/com.h>
#include <net/hton.h>
#include <net/gen/ether.h>
#include <net/gen/eth_io.h>
#include "dp.h"

View file

@ -55,9 +55,7 @@
*/
#include "drivers.h"
#include <minix/keymap.h>
#include <minix/endpoint.h>
#include <net/hton.h>
#include <net/gen/ether.h>
#include <net/gen/eth_io.h>
@ -283,6 +281,7 @@ static void do_init(message * mp)
dpeth_t *dep;
dp_conf_t *dcp;
message reply_mess;
const char *portname;
port = mp->DL_PORT;
if (port >= 0 && port < DE_PORT_NR) {
@ -291,6 +290,7 @@ static void do_init(message * mp)
dcp = &dp_conf[port];
strcpy(dep->de_name, DevName);
dep->de_name[4] = '0' + port;
portname = dep->de_name;
if (dep->de_mode == DEM_DISABLED) {
@ -341,15 +341,17 @@ static void do_init(message * mp)
}
*(ether_addr_t *) reply_mess.m3_ca1 = dep->de_address;
} else /* Port number is out of range */
} else { /* Port number is out of range */
port = ENXIO;
portname = "(illegal dpeth port)";
}
reply_mess.m_type = DL_CONF_REPLY;
reply_mess.m3_i1 = port;
reply_mess.m3_i2 = DE_PORT_NR;
DEBUG(printf("\t reply %d\n", reply_mess.m_type));
if (send(mp->m_source, &reply_mess) != OK) /* Can't send */
panic(dep->de_name, SendErrMsg, mp->m_source);
panic(portname, SendErrMsg, mp->m_source);
return;
}

View file

@ -55,8 +55,6 @@
#include "lance.h"
#include <sys/ioc_memory.h>
static ether_card_t ec_table[EC_PORT_NR_MAX];
static int eth_tasknr= ANY;
static u16_t eth_ign_proto;

View file

@ -8,7 +8,6 @@
*/
#include <stdio.h>
#include <fcntl.h>
#include <minix/type.h>
#include <minix/safecopies.h>
#include <minix/sys_config.h>

View file

@ -4,8 +4,6 @@
#include "../../kernel.h"
#include <unistd.h>
#include <ibm/cmos.h>
#include <ibm/bios.h>
#include <minix/portio.h>
#include <minix/syslib.h>

View file

@ -6,11 +6,9 @@
#include "../../kernel.h"
#include "proto.h"
#include <signal.h>
#include <stdio.h>
#include <string.h>
#include "../../proc.h"
#include "../../proto.h"
#include "../../vm.h"
extern int vm_copy_in_progress, catch_pagefaults;
extern struct proc *vm_copy_from, *vm_copy_to;

View file

@ -8,7 +8,6 @@
#include "../../kernel.h"
#include "../../proc.h"
#include "proto.h"
#include <minix/com.h>
#include <minix/portio.h>
#include <ibm/cpu.h>

View file

@ -8,7 +8,6 @@
#include <ibm/cmos.h>
#include <ibm/bios.h>
#include <minix/portio.h>
#include <minix/u64.h>
#include <minix/cpufeature.h>
#include <a.out.h>
#include <archconst.h>

View file

@ -31,10 +31,8 @@
#include "kernel.h"
#include "proc.h"
#include <signal.h>
#include <minix/com.h>
#include <minix/endpoint.h>
#include <minix/portio.h>
#include "clock.h"

View file

@ -15,7 +15,6 @@
#include "kernel.h"
#include "proc.h"
#include <minix/com.h>
#include <archconst.h>
#include "arch/i386/hw_intr.h"

View file

@ -9,14 +9,11 @@
* prepare_shutdown: prepare to take MINIX down
*/
#include "kernel.h"
#include <signal.h>
#include <string.h>
#include <unistd.h>
#include <a.out.h>
#include <minix/callnr.h>
#include <minix/com.h>
#include <minix/endpoint.h>
#include <minix/u64.h>
#include "proc.h"
#include "debug.h"
#include "clock.h"

View file

@ -34,12 +34,10 @@
*/
#include <minix/com.h>
#include <minix/callnr.h>
#include <minix/endpoint.h>
#include <stddef.h>
#include <signal.h>
#include <minix/portio.h>
#include <minix/u64.h>
#include <minix/syslib.h>
#include "debug.h"

View file

@ -5,7 +5,6 @@
#include "proc.h"
#include <stdlib.h>
#include <string.h>
#include <archconst.h>
#include "proto.h"
#ifdef CONFIG_WATCHDOG

View file

@ -12,7 +12,6 @@
*/
#include "../system.h"
#include "../vm.h"
#include <minix/type.h>
#if (USE_VIRCOPY || USE_PHYSCOPY)

View file

@ -7,7 +7,6 @@
#include "../system.h"
#include <signal.h>
#include <sys/sigcontext.h>
#if USE_ENDKSIG

View file

@ -9,7 +9,6 @@
*/
#include "../system.h"
#include <string.h>
#include <signal.h>
#include <minix/endpoint.h>
#if USE_EXEC

View file

@ -13,7 +13,6 @@
#include <minix/endpoint.h>
#include "../system.h"
#include "../vm.h"
#if USE_GETINFO

View file

@ -8,7 +8,6 @@
#include "../system.h"
#include <signal.h>
#include <sys/sigcontext.h>
#include <minix/endpoint.h>
#if USE_GETKSIG

View file

@ -8,7 +8,6 @@
#include "../system.h"
#include <signal.h>
#include <sys/sigcontext.h>
#if USE_KILL

View file

@ -8,7 +8,6 @@
*/
#include "../system.h"
#include "../vm.h"
#if USE_MEMSET

View file

@ -7,7 +7,6 @@
*/
#include "../system.h"
#include <minix/type.h>
#include <sys/resource.h>
#if USE_NICE

View file

@ -8,7 +8,6 @@
*/
#include "../system.h"
#include <minix/type.h>
#if USE_RUNCTL

View file

@ -18,7 +18,6 @@
#include <minix/safecopies.h>
#include "../system.h"
#include "../vm.h"
#define MAX_INDIRECT_DEPTH 5 /* up to how many indirect grants to follow? */

View file

@ -15,7 +15,6 @@
#include <minix/safecopies.h>
#include "../system.h"
#include "../vm.h"
struct map_info_s {

View file

@ -9,7 +9,6 @@
#include "../system.h"
#include <string.h>
#include <signal.h>
#include <ibm/cpu.h>
#include <sys/sigcontext.h>

View file

@ -9,7 +9,6 @@
*/
#include "../system.h"
#include "../vm.h"
#include <signal.h>
#include <string.h>
#include <sys/sigcontext.h>

View file

@ -10,7 +10,6 @@
*/
#include "../system.h"
#include "../vm.h"
#if USE_UMAP

View file

@ -9,7 +9,6 @@
#include <unistd.h>
#include <signal.h>
#include <string.h>
#include <minix/sys_config.h>

View file

@ -19,7 +19,6 @@
/* Author: J.W. Stevenson */
#include <pc_file.h>
#include <pc_err.h>
extern (*_sig())();
extern _catch();

View file

@ -7,7 +7,6 @@
/* $Header$ */
#define __NO_DEFS
#include <math.h>
#include <pc_err.h>
extern _trp();

View file

@ -4,8 +4,6 @@
*/
/* $Header$ */
#include <errno.h>
static const char unknown[] = "Unknown error";
const char *_sys_errlist[] = {

View file

@ -5,7 +5,6 @@
/* $Header$ */
#include <stdlib.h>
#include <limits.h>
#define CHAR_SHIFT 8

View file

@ -5,7 +5,6 @@
/* $Header$ */
#include <stdlib.h>
#include <limits.h>
int
mbtowc(wchar_t *pwc, register const char *s, size_t n)

View file

@ -5,7 +5,6 @@
/* $Header$ */
#include <string.h>
#include <locale.h>
int
strcoll(register const char *s1, register const char *s2)

View file

@ -6,7 +6,6 @@
#include <stdlib.h>
#include <locale.h>
#include <limits.h>
size_t
wcstombs(register char *s, register const wchar_t *pwcs, size_t n)

View file

@ -5,7 +5,6 @@
/* $Header$ */
#include <stdlib.h>
#include <limits.h>
int
/* was: wctomb(char *s, wchar_t wchar)

View file

@ -9,7 +9,6 @@ Implementation of isnan that directly tests the bits in an ieee float
#define _MINIX_SOURCE
#include <sys/types.h>
#include <math.h>
#include "ieee_float.h"

View file

@ -1,4 +1,3 @@
#include <errno.h>
#include <fenv.h>
#include "fpu_cw.h"

View file

@ -5,7 +5,6 @@
#include <string.h>
#include <sys/ioctl.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <net/netlib.h>
#include <net/gen/in.h>

View file

@ -5,7 +5,6 @@ domainname.c
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <net/netlib.h>
int getdomainname(domain, size)
char *domain;

View file

@ -8,7 +8,6 @@ Created: Nov 17, 1992 by Philip Homburg
#include <sys/types.h>
#include <stdlib.h>
#include <net/netlib.h>
#include <net/gen/ether.h>
#include <net/gen/if_ether.h>

View file

@ -3,7 +3,6 @@
*/
#define nil 0
#include <sys/types.h>
#include <sys/utsname.h>
#include <unistd.h>
#include <string.h>

View file

@ -24,7 +24,6 @@ static char sccsid[] = "@(#)gethostnamadr.c 6.41 (Berkeley) 6/1/90";
#ifdef _MINIX
#include <sys/types.h>
#include <ctype.h>
#include <errno.h>
#include <stdio.h>
#include <string.h>
@ -42,7 +41,6 @@ static char sccsid[] = "@(#)gethostnamadr.c 6.41 (Berkeley) 6/1/90";
#include <ctype.h>
#include <netdb.h>
#include <stdio.h>
#include <errno.h>
#include <arpa/inet.h>
#include <arpa/nameser.h>
#include <resolv.h>

View file

@ -1,4 +1,3 @@
#include <errno.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
@ -12,9 +11,7 @@
#include <net/gen/in.h>
#include <net/gen/ip_io.h>
#include <net/gen/tcp.h>
#include <net/gen/tcp_io.h>
#include <net/gen/udp.h>
#include <net/gen/udp_io.h>
int
getifaddrs(struct ifaddrs **ifap)

View file

@ -9,7 +9,6 @@
#include <net/gen/tcp.h>
#include <net/gen/tcp_io.h>
#include <net/gen/udp.h>
#include <net/gen/udp_io.h>
#define DEBUG 0

View file

@ -22,7 +22,6 @@ static char sccsid[] = "@(#)getservent.c 5.8 (Berkeley) 6/1/90";
#endif /* LIBC_SCCS and not lint */
#include <sys/types.h>
#include <ctype.h>
#include <stdio.h>
#include <stdlib.h>

View file

@ -18,7 +18,6 @@
#include <net/gen/tcp.h>
#include <net/gen/tcp_io.h>
#include <net/gen/udp.h>
#include <net/gen/udp_io.h>
/*

View file

@ -4,7 +4,6 @@
#include <lib.h>
#define nanosleep _nanosleep
#include <signal.h>
#include <unistd.h>
#include <errno.h>
#include <time.h>

View file

@ -5,13 +5,10 @@
#define readdir _readdir
#define getdents _getdents
#include <sys/types.h>
#include <sys/stat.h>
#include <dirent.h>
#include <unistd.h>
#include <stddef.h>
#include <stdlib.h>
#include <fcntl.h>
#include <limits.h>
#include <errno.h>
#include <string.h>

View file

@ -1,6 +1,5 @@
#include <lib.h>
#define sigaction _sigaction
#include <sys/sigcontext.h>
#include <signal.h>
_PROTOTYPE(int __sigreturn, (void));

View file

@ -5,7 +5,6 @@
#include <lib.h>
#define sleep _sleep
#include <signal.h>
#include <unistd.h>
#include <errno.h>
#include <time.h>

View file

@ -1,6 +1,5 @@
#include <lib.h>
#define stime _stime
#include <minix/minlib.h>
#include <time.h>
PUBLIC int stime(top)

View file

@ -9,7 +9,6 @@ Created: June 11, 1993 by Philip Homburg
#include <errno.h>
#include <termios.h>
#include <sys/ioctl.h>
#include <sys/types.h>
int tcsetattr(fd, opt_actions, termios_p)
int fd;

View file

@ -1,7 +1,6 @@
#include <lib.h>
#define times _times
#include <sys/times.h>
#include <time.h>
PUBLIC clock_t times(buf)
struct tms *buf;

View file

@ -4,7 +4,6 @@ gettimeofday.c
#include <sys/time.h>
#include <lib.h>
#include <time.h>
int gettimeofday(struct timeval *_RESTRICT tp, void *_RESTRICT tzp)
{

View file

@ -55,10 +55,8 @@
* Number of matches in the current invocation of glob.
*/
#include <sys/param.h>
#include <sys/stat.h>
#include <ctype.h>
#include <dirent.h>
#include <errno.h>
#include <glob.h>

View file

@ -49,7 +49,6 @@ static char sccsid[] = "@(#)regerror.c 8.4 (Berkeley) 3/20/94";
#else
#include <ctype.h>
#endif
#include <limits.h>
#include <stdlib.h>
#include <regex.h>

View file

@ -3,7 +3,6 @@ pci_init.c
*/
#include "syslib.h"
#include <minix/sysutil.h>
/*===========================================================================*
* pci_init *

View file

@ -1,7 +1,5 @@
#include "syslib.h"
#include <minix/config.h>
/*===========================================================================*
* sys_profbuf *
*===========================================================================*/

View file

@ -9,7 +9,6 @@
#include <minix/const.h>
#include <minix/type.h>
#include <fcntl.h>
#include <stdlib.h>
#include <unistd.h>
#include <minix/syslib.h>

View file

@ -1,5 +1,4 @@
#include "sysutil.h"
#include <minix/config.h>
#include <string.h>
PUBLIC int env_argc = 0;

View file

@ -1,6 +1,5 @@
#include <lib.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <minix/profile.h>

View file

@ -1,5 +1,4 @@
#include "sysutil.h"
#include <timers.h>
#define COM1_BASE 0x3F8
#define COM1_THR (COM1_BASE + 0)

View file

@ -1,8 +1,6 @@
#include <stdio.h>
#include <time.h>
#include <sys/time.h>
#include <sys/times.h>
#include <sys/types.h>
#include <minix/u64.h>
#include <minix/config.h>

View file

@ -1,7 +1,6 @@
#include <stdio.h>
#include <time.h>
#include <sys/time.h>
#include <sys/times.h>
#include <sys/types.h>
#include <minix/u64.h>

View file

@ -15,8 +15,6 @@
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/sem.h>
#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
#include <errno.h>

View file

@ -1,7 +1,6 @@
#define _SYSTEM 1
#define _MINIX 1
#include <minix/callnr.h>
#include <minix/com.h>
#include <minix/config.h>
#include <minix/ipc.h>
@ -15,8 +14,6 @@
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/shm.h>
#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>

View file

@ -31,7 +31,6 @@ _PROTOTYPE( int do_shmat, (message *) );
_PROTOTYPE( int do_shmdt, (message *) );
_PROTOTYPE( int do_shmctl, (message *) );
_PROTOTYPE( int check_perm, (struct ipc_perm *, endpoint_t, int) );
_PROTOTYPE( void list_shm_ds, (void) );
_PROTOTYPE( void update_refcount_and_destroy, (void) );
_PROTOTYPE( int do_semget, (message *) );
_PROTOTYPE( int do_semctl, (message *) );

View file

@ -5,7 +5,7 @@ PUBLIC endpoint_t who_e;
PUBLIC int call_type;
PUBLIC endpoint_t SELF_E;
struct {
PRIVATE struct {
int type;
int (*func)(message *);
int reply; /* whether the reply action is passed through */
@ -21,7 +21,7 @@ struct {
#define SIZE(a) (sizeof(a)/sizeof(a[0]))
int verbose = 0;
PRIVATE int verbose = 0;
/* SEF functions and variables. */
FORWARD _PROTOTYPE( void sef_local_startup, (void) );

View file

@ -328,7 +328,7 @@ PUBLIC int do_shmctl(message *m)
return OK;
}
PUBLIC void list_shm_ds(void)
PRIVATE void list_shm_ds(void)
{
int i;
printf("key\tid\tpage\n");