fix some warnings
Change-Id: I1f3fa582d8e3ddb3c981784dddb13e740102f4f3
This commit is contained in:
		
							parent
							
								
									1cc6f4295d
								
							
						
					
					
						commit
						4f3b015903
					
				@ -39,7 +39,7 @@ typedef struct {
 | 
				
			|||||||
	u32_t dev;
 | 
						u32_t dev;
 | 
				
			||||||
	u8_t pages;
 | 
						u8_t pages;
 | 
				
			||||||
	u8_t flags;
 | 
						u8_t flags;
 | 
				
			||||||
} mess_vmmcp __packed;
 | 
					} mess_vmmcp;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
typedef struct {
 | 
					typedef struct {
 | 
				
			||||||
	endpoint_t who;
 | 
						endpoint_t who;
 | 
				
			||||||
@ -50,9 +50,9 @@ typedef struct {
 | 
				
			|||||||
	u32_t len;
 | 
						u32_t len;
 | 
				
			||||||
	u16_t fd;
 | 
						u16_t fd;
 | 
				
			||||||
	u16_t clearend_and_flags; /* low 12 bits are clearend, rest flags */
 | 
						u16_t clearend_and_flags; /* low 12 bits are clearend, rest flags */
 | 
				
			||||||
} mess_vm_vfs_mmap __packed;
 | 
					} mess_vm_vfs_mmap;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
typedef struct { u8_t flags; void *addr; } mess_vmmcp_reply __packed;
 | 
					typedef struct { u8_t flags; void *addr; } mess_vmmcp_reply;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
typedef struct {
 | 
					typedef struct {
 | 
				
			||||||
  endpoint_t m_source;		/* who sent the message */
 | 
					  endpoint_t m_source;		/* who sent the message */
 | 
				
			||||||
 | 
				
			|||||||
@ -2,6 +2,7 @@
 | 
				
			|||||||
#include <namespace.h>
 | 
					#include <namespace.h>
 | 
				
			||||||
#include <lib.h>
 | 
					#include <lib.h>
 | 
				
			||||||
#include <machine/stackframe.h>
 | 
					#include <machine/stackframe.h>
 | 
				
			||||||
 | 
					#include <sys/cdefs.h>
 | 
				
			||||||
#include <ucontext.h>
 | 
					#include <ucontext.h>
 | 
				
			||||||
#include <signal.h>
 | 
					#include <signal.h>
 | 
				
			||||||
#include <stdarg.h>
 | 
					#include <stdarg.h>
 | 
				
			||||||
@ -245,6 +246,7 @@ int swapcontext(ucontext_t *oucp, const ucontext_t *ucp)
 | 
				
			|||||||
/*===========================================================================*
 | 
					/*===========================================================================*
 | 
				
			||||||
 *				resumecontext				     *
 | 
					 *				resumecontext				     *
 | 
				
			||||||
 *===========================================================================*/
 | 
					 *===========================================================================*/
 | 
				
			||||||
 | 
					__dead
 | 
				
			||||||
void resumecontext(ucontext_t *ucp)
 | 
					void resumecontext(ucontext_t *ucp)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
  if (ucp->uc_link == NULL) exit(0);
 | 
					  if (ucp->uc_link == NULL) exit(0);
 | 
				
			||||||
 | 
				
			|||||||
@ -5,6 +5,7 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
#include <sys/cdefs.h>
 | 
					#include <sys/cdefs.h>
 | 
				
			||||||
#include <lib.h>
 | 
					#include <lib.h>
 | 
				
			||||||
 | 
					#include <unistd.h>
 | 
				
			||||||
#include "namespace.h"
 | 
					#include "namespace.h"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include <unistd.h>
 | 
					#include <unistd.h>
 | 
				
			||||||
 | 
				
			|||||||
@ -45,13 +45,14 @@ int ip_forward_directed_bcast= 0;	/* Default is off */
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
static int ifdefault= -1;		/* Default network interface. */
 | 
					static int ifdefault= -1;		/* Default network interface. */
 | 
				
			||||||
 | 
					
 | 
				
			||||||
static void fatal(char *label)
 | 
					__dead
 | 
				
			||||||
 | 
					static void fatal(const char *label)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	printf("init: %s: %s\n", label, strerror(errno));
 | 
						printf("init: %s: %s\n", label, strerror(errno));
 | 
				
			||||||
	exit(1);
 | 
						exit(1);
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
static void check_mknod(char *device, mode_t mode, int minor)
 | 
					static void check_mknod(const char *device, mode_t mode, int minor)
 | 
				
			||||||
/* Check if a device exists with the proper device number. */
 | 
					/* Check if a device exists with the proper device number. */
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	dev_t dev;
 | 
						dev_t dev;
 | 
				
			||||||
 | 
				
			|||||||
@ -34,7 +34,7 @@ extern struct sock_ops sock_udp_ops;
 | 
				
			|||||||
extern struct sock_ops sock_tcp_ops;
 | 
					extern struct sock_ops sock_tcp_ops;
 | 
				
			||||||
extern struct sock_ops sock_raw_ip_ops;
 | 
					extern struct sock_ops sock_raw_ip_ops;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void sys_init(void)
 | 
					static void sys_init(void)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -91,7 +91,7 @@ static int sef_cb_init_fresh(__unused int type, __unused sef_init_info_t *info)
 | 
				
			|||||||
	set_timer(&tcp_stmr, tcp_sticks, tcp_swatchdog, 0);
 | 
						set_timer(&tcp_stmr, tcp_sticks, tcp_swatchdog, 0);
 | 
				
			||||||
	
 | 
						
 | 
				
			||||||
	netif_init();
 | 
						netif_init();
 | 
				
			||||||
	netif_lo = netif_find("lo0");
 | 
						netif_lo = netif_find((char *) "lo0");
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	/* Read configuration. */
 | 
						/* Read configuration. */
 | 
				
			||||||
#if 0
 | 
					#if 0
 | 
				
			||||||
@ -160,12 +160,15 @@ static void sef_local_startup()
 | 
				
			|||||||
static void ds_event(void)
 | 
					static void ds_event(void)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	char key[DS_MAX_KEYLEN];
 | 
						char key[DS_MAX_KEYLEN];
 | 
				
			||||||
	char *driver_prefix = "drv.net.";
 | 
						const char *driver_prefix = "drv.net.";
 | 
				
			||||||
	char *label;
 | 
						char *label;
 | 
				
			||||||
	u32_t value;
 | 
						u32_t value;
 | 
				
			||||||
	int type;
 | 
						int type;
 | 
				
			||||||
	endpoint_t owner_endpoint;
 | 
						endpoint_t owner_endpoint;
 | 
				
			||||||
	int r;
 | 
						int r;
 | 
				
			||||||
 | 
					        int prefix_len;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        prefix_len = strlen(driver_prefix);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	/* We may get one notification for multiple updates from DS. Get events
 | 
						/* We may get one notification for multiple updates from DS. Get events
 | 
				
			||||||
	 * and owners from DS, until DS tells us that there are no more.
 | 
						 * and owners from DS, until DS tells us that there are no more.
 | 
				
			||||||
@ -178,9 +181,10 @@ static void ds_event(void)
 | 
				
			|||||||
		}
 | 
							}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		/* Only check for network driver up events. */
 | 
							/* Only check for network driver up events. */
 | 
				
			||||||
		if(strncmp(key, driver_prefix, sizeof(driver_prefix))
 | 
							if(strncmp(key, driver_prefix, prefix_len)
 | 
				
			||||||
				|| value != DS_DRIVER_UP)
 | 
							  || value != DS_DRIVER_UP) {
 | 
				
			||||||
			return;
 | 
								return;
 | 
				
			||||||
 | 
							}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		/* The driver label comes after the prefix. */
 | 
							/* The driver label comes after the prefix. */
 | 
				
			||||||
		label = key + strlen(driver_prefix);
 | 
							label = key + strlen(driver_prefix);
 | 
				
			||||||
 | 
				
			|||||||
@ -23,7 +23,7 @@ int do_get()
 | 
				
			|||||||
 */
 | 
					 */
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  register struct mproc *rmp = mp;
 | 
					  register struct mproc *rmp = mp;
 | 
				
			||||||
  int r, i;
 | 
					  int r;
 | 
				
			||||||
  int ngroups;
 | 
					  int ngroups;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  switch(call_nr) {
 | 
					  switch(call_nr) {
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user