PERFORCE change 35675 for review
Marcel Moolenaar
marcel at FreeBSD.org
Thu Aug 7 01:15:09 PDT 2003
http://perforce.freebsd.org/chv.cgi?CH=35675
Change 35675 by marcel at marcel_nfs on 2003/08/07 01:14:05
IFC @35674
Affected files ...
.. //depot/projects/ia64/Makefile#30 integrate
.. //depot/projects/ia64/contrib/isc-dhcp/client/dhclient.c#9 integrate
.. //depot/projects/ia64/contrib/isc-dhcp/includes/dhcpd.h#7 integrate
.. //depot/projects/ia64/etc/defaults/pccard.conf#23 integrate
.. //depot/projects/ia64/etc/services#9 integrate
.. //depot/projects/ia64/lib/libc/sys/connect.2#6 integrate
.. //depot/projects/ia64/lib/libpthread/arch/ia64/ia64/pthread_md.c#2 integrate
.. //depot/projects/ia64/lib/libpthread/arch/ia64/include/pthread_md.h#5 integrate
.. //depot/projects/ia64/release/Makefile#66 integrate
.. //depot/projects/ia64/sbin/ip6fw/ip6fw.c#6 integrate
.. //depot/projects/ia64/sbin/mount/mount.c#11 integrate
.. //depot/projects/ia64/sbin/mount_hpfs/mount_hpfs.c#4 integrate
.. //depot/projects/ia64/sbin/quotacheck/quotacheck.c#11 integrate
.. //depot/projects/ia64/sbin/restore/interactive.c#5 integrate
.. //depot/projects/ia64/sbin/restore/main.c#8 integrate
.. //depot/projects/ia64/sbin/routed/defs.h#2 integrate
.. //depot/projects/ia64/sbin/routed/trace.c#3 integrate
.. //depot/projects/ia64/share/examples/ppi/ppilcd.c#2 integrate
.. //depot/projects/ia64/share/man/man4/acpi.4#12 integrate
.. //depot/projects/ia64/sys/cam/scsi/scsi_da.c#48 integrate
.. //depot/projects/ia64/sys/compat/svr4/svr4_misc.c#21 integrate
.. //depot/projects/ia64/sys/contrib/dev/acpica/acfreebsd.h#11 integrate
.. //depot/projects/ia64/sys/contrib/dev/oltr/if_oltr.c#7 integrate
.. //depot/projects/ia64/sys/dev/ed/if_ed_cbus.c#7 integrate
.. //depot/projects/ia64/sys/dev/en/midway.c#21 integrate
.. //depot/projects/ia64/sys/dev/en/midwayvar.h#8 integrate
.. //depot/projects/ia64/sys/dev/fatm/if_fatm.c#6 integrate
.. //depot/projects/ia64/sys/dev/hatm/if_hatm_ioctl.c#5 integrate
.. //depot/projects/ia64/sys/dev/hatm/if_hatm_rx.c#3 integrate
.. //depot/projects/ia64/sys/dev/hatm/if_hatm_tx.c#4 integrate
.. //depot/projects/ia64/sys/dev/hatm/if_hatmvar.h#4 integrate
.. //depot/projects/ia64/sys/dev/ie/if_ievar.h#2 integrate
.. //depot/projects/ia64/sys/dev/patm/if_patm_ioctl.c#3 integrate
.. //depot/projects/ia64/sys/dev/patm/if_patm_rx.c#3 integrate
.. //depot/projects/ia64/sys/dev/patm/if_patm_tx.c#4 integrate
.. //depot/projects/ia64/sys/dev/patm/if_patmvar.h#2 integrate
.. //depot/projects/ia64/sys/dev/usb/umass.c#31 integrate
.. //depot/projects/ia64/sys/fs/specfs/spec_vnops.c#21 integrate
.. //depot/projects/ia64/sys/i386/i386/i686_mem.c#8 integrate
.. //depot/projects/ia64/sys/i386/i386/identcpu.c#23 integrate
.. //depot/projects/ia64/sys/i386/i386/pmap.c#54 integrate
.. //depot/projects/ia64/sys/i386/i386/tsc.c#6 integrate
.. //depot/projects/ia64/sys/i386/include/clock.h#5 integrate
.. //depot/projects/ia64/sys/i386/include/cpufunc.h#15 integrate
.. //depot/projects/ia64/sys/i386/isa/clock.c#19 integrate
.. //depot/projects/ia64/sys/i386/isa/cxreg.h#2 integrate
.. //depot/projects/ia64/sys/ia64/ia64/exception.S#5 integrate
.. //depot/projects/ia64/sys/ia64/ia64/machdep.c#87 integrate
.. //depot/projects/ia64/sys/ia64/ia64/syscall.S#3 integrate
.. //depot/projects/ia64/sys/ia64/ia64/vm_machdep.c#32 integrate
.. //depot/projects/ia64/sys/ia64/include/ucontext.h#4 integrate
.. //depot/projects/ia64/sys/kern/sys_pipe.c#36 integrate
.. //depot/projects/ia64/sys/kern/uipc_syscalls.c#37 integrate
.. //depot/projects/ia64/sys/modules/en/Makefile#3 integrate
.. //depot/projects/ia64/sys/net/if_atm.h#11 integrate
.. //depot/projects/ia64/sys/netinet/if_atm.c#4 integrate
.. //depot/projects/ia64/sys/netnatm/natm.c#14 integrate
.. //depot/projects/ia64/sys/netnatm/natm.h#4 integrate
.. //depot/projects/ia64/sys/netnatm/natm_pcb.c#6 integrate
.. //depot/projects/ia64/sys/netnatm/natm_proto.c#8 integrate
.. //depot/projects/ia64/sys/pci/if_rl.c#39 integrate
.. //depot/projects/ia64/sys/pci/if_rlreg.h#11 integrate
.. //depot/projects/ia64/sys/sys/buf.h#24 integrate
.. //depot/projects/ia64/sys/sys/pipe.h#6 integrate
.. //depot/projects/ia64/sys/vm/default_pager.c#7 integrate
.. //depot/projects/ia64/sys/vm/swap_pager.c#38 integrate
.. //depot/projects/ia64/sys/vm/swap_pager.h#14 integrate
.. //depot/projects/ia64/sys/vm/vm_object.c#64 integrate
.. //depot/projects/ia64/sys/vm/vm_pager.h#10 integrate
.. //depot/projects/ia64/usr.bin/calendar/calendars/calendar.birthday#9 integrate
.. //depot/projects/ia64/usr.sbin/config/config.8#8 integrate
.. //depot/projects/ia64/usr.sbin/ctm/mkCTM/mkctm.c#2 integrate
Differences ...
==== //depot/projects/ia64/Makefile#30 (text+ko) ====
@@ -1,5 +1,5 @@
#
-# $FreeBSD: src/Makefile,v 1.286 2003/07/20 12:38:29 ru Exp $
+# $FreeBSD: src/Makefile,v 1.287 2003/08/06 11:06:38 ru Exp $
#
# The user-driven targets are:
#
@@ -105,7 +105,7 @@
#
world: upgrade_checks
@echo "--------------------------------------------------------------"
- @echo ">>> elf make world started on ${STARTTIME}"
+ @echo ">>> make world started on ${STARTTIME}"
@echo "--------------------------------------------------------------"
.if target(pre-world)
@echo
@@ -125,7 +125,8 @@
.endif
@echo
@echo "--------------------------------------------------------------"
- @printf ">>> elf make world completed on `LC_ALL=C date`\n (started ${STARTTIME})\n"
+ @echo ">>> make world completed on `LC_ALL=C date`"
+ @echo " (started ${STARTTIME})"
@echo "--------------------------------------------------------------"
#
@@ -198,7 +199,8 @@
.endfor
.endfor
@echo "--------------------------------------------------------------"
- @printf ">>> make universe completed on `LC_ALL=C date`\n (started ${STARTTIME})\n"
+ @echo ">>> make universe completed on `LC_ALL=C date`"
+ @echo " (started ${STARTTIME})"
@echo "--------------------------------------------------------------"
KERNCONFS!= cd ${.CURDIR}/sys/${TARGET}/conf && \
==== //depot/projects/ia64/contrib/isc-dhcp/client/dhclient.c#9 (text+ko) ====
@@ -42,7 +42,7 @@
#ifndef lint
static char ocopyright[] =
"$Id: dhclient.c,v 1.129.2.12 2002/11/07 23:26:38 dhankins Exp $ Copyright (c) 1995-2002 Internet Software Consortium. All rights reserved.\n"
-"$FreeBSD: src/contrib/isc-dhcp/client/dhclient.c,v 1.27 2003/07/28 13:25:04 mbr Exp $\n";
+"$FreeBSD: src/contrib/isc-dhcp/client/dhclient.c,v 1.29 2003/08/07 07:27:14 mbr Exp $\n";
#endif /* not lint */
#include "dhcpd.h"
@@ -217,7 +217,7 @@
} else if (!strcmp (argv [i], "-i")) {
if (++i == argc)
usage ();
- polling_interval = (int)strtol(argv [i],
+ polling_interval = (int)strtol (argv [i],
(char **)NULL, 10);
if (polling_interval <= 0) {
log_info ("Incorrect polling interval %d",
@@ -257,8 +257,11 @@
log_fatal ("%s: interface name too long (max %ld)",
argv [i], (long)strlen (argv [i]));
strlcpy (tmp -> name, argv [i], IFNAMSIZ);
- set_ieee802(tmp);
- tmp->linkstatus = interface_active(tmp);
+#ifdef __FreeBSD__
+ set_ieee80211 (tmp);
+#endif
+ tmp -> forcediscover = 0;
+ tmp -> linkstate = 0;
if (interfaces) {
interface_reference (&tmp -> next,
interfaces, MDL);
@@ -286,16 +289,16 @@
/* first kill of any currently running client */
if (release_mode) {
- if ((pidfd = fopen(path_dhclient_pid, "r")) != NULL) {
- e = fscanf(pidfd, "%d", &oldpid);
+ if ((pidfd = fopen (path_dhclient_pid, "r")) != NULL) {
+ e = fscanf (pidfd, "%d", &oldpid);
if (e != 0 && e != EOF) {
if (oldpid) {
- if (kill(oldpid, SIGKILL) == 0)
- unlink(path_dhclient_pid);
+ if (kill (oldpid, SIGKILL) == 0)
+ unlink (path_dhclient_pid);
}
}
- fclose(pidfd);
+ fclose (pidfd);
}
}
@@ -412,7 +415,15 @@
INTERFACE_AUTOMATIC)) !=
INTERFACE_REQUESTED))
continue;
- set_ieee802(ip);
+#ifdef __FreeBSD__
+ set_ieee80211 (ip);
+#endif
+ ip -> forcediscover = 0;
+ if (ip -> client -> config -> media != NULL)
+ ip -> havemedia = 1;
+ else
+ ip -> havemedia = 0;
+
script_init (ip -> client,
"PREINIT", (struct string_list *)0);
if (ip -> client -> alias)
@@ -459,7 +470,7 @@
add_timeout (cur_time + random () % 5,
state_link, client, 0, 0);
#else
- add_timeout(cur_time + random () % 5,
+ add_timeout (cur_time + random () % 5,
state_reboot, client, 0, 0);
#endif
}
@@ -909,6 +920,15 @@
/* Write out the new lease. */
write_client_lease (client, client -> new, 0, 0);
+ /*
+ * It's now possible that state_reboot can be called
+ * after a interface link went down and is up again.
+ * To prevent tons of equal leases saved on disk, we rewrite
+ * them.
+ */
+ read_client_leases ();
+ rewrite_client_leases ();
+
/* Replace the old active lease with the new one. */
if (client -> active)
destroy_client_lease (client -> active);
@@ -923,6 +943,10 @@
piaddr (client -> active -> address),
(long)(client -> active -> renewal - cur_time));
client -> state = S_BOUND;
+#ifdef ENABLE_POLLING_MODE
+ client -> interface -> linkstate = HAVELINK;
+ client -> interface -> forcediscover = 0;
+#endif /* ifdef ENABLE_POLLING_MODE */
reinitialize_interfaces ();
go_daemon ();
if (client -> config -> do_forward_update) {
@@ -1385,9 +1409,6 @@
int interval;
int increase = 1;
- if (interface_active(client -> interface) == 0)
- return;
-
/* Figure out how long it's been since we started transmitting. */
interval = cur_time - client -> first_sending;
@@ -1427,6 +1448,9 @@
}
}
+ if (interface_active (client -> interface) == NOLINK)
+ return;
+
/* If we're supposed to increase the interval, do so. If it's
currently zero (i.e., we haven't sent any packets yet), set
it to one; otherwise, add to it a random number between
@@ -1493,7 +1517,7 @@
struct client_lease *loop;
struct client_lease *lp;
- if (interface_active(client -> interface) == 0)
+ if (interface_active (client -> interface) == NOLINK)
return;
loop = lp = client -> active;
@@ -1535,6 +1559,11 @@
log_info ("bound: immediate renewal.");
state_bound (client);
}
+ /*
+ * Set the link status back to nolink, even
+ * if we have media settings.
+ */
+ client -> interface -> linkstate = NOLINK;
reinitialize_interfaces ();
go_daemon ();
return;
@@ -2809,8 +2838,8 @@
break;
}
client -> state = S_INIT;
- if (interface_active(ip))
- state_reboot(client);
+ if (interface_active (ip) == HAVELINK)
+ state_reboot (client);
}
}
}
@@ -2971,8 +3000,8 @@
client -> state = S_INIT;
/* Set up a timeout to start the initialization
process. */
- if (interface_active(ip)) {
- add_timeout(cur_time + random () % 5,
+ if (interface_active (ip) == HAVELINK) {
+ add_timeout (cur_time + random () % 5,
state_reboot, client, 0, 0);
}
}
@@ -3038,8 +3067,8 @@
break;
case server_awaken:
- if (interface_active(ip))
- state_reboot(client);
+ if (interface_active (ip) == HAVELINK)
+ state_reboot (client);
break;
}
}
@@ -3188,50 +3217,81 @@
ifname = ip -> name;
- if ((sock = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP)) < 0)
- log_fatal("Can't create interface_active socket");
+ if ((sock = socket (AF_INET, SOCK_DGRAM, IPPROTO_UDP)) < 0)
+ log_fatal ("Can't create interface_active socket");
- (void) memset(&ifmr, 0, sizeof(ifmr));
- (void) strncpy(ifmr.ifm_name, ifname, sizeof(ifmr.ifm_name));
+ (void) memset (&ifmr, 0, sizeof (ifmr));
+ (void) strncpy (ifmr.ifm_name, ifname, sizeof (ifmr.ifm_name));
- if (ioctl(sock, SIOCGIFMEDIA, (caddr_t)&ifmr) < 0) {
+ if (ioctl (sock, SIOCGIFMEDIA, (caddr_t)&ifmr) < 0) {
/*
* Interface doesn't support SIOCGIFMEDIA, presume okay
*/
- close(sock);
- return (1);
+ close (sock);
+ return (HAVELINK);
}
- close(sock);
+ close (sock);
if (ifmr.ifm_count == 0) {
/*
- * this is unexpected (to me), but we'll just assume
- * that this means interface does not support SIOCGIFMEDIA
+ * Assume that this means interface
+ * does not support SIOCGIFMEDIA
*/
- log_fatal("%s: no media types?", ifname);
- return (1);
+ log_fatal ("%s: no media types?", ifname);
+ return (HAVELINK);
}
if (ifmr.ifm_status & IFM_AVALID) {
- if (ip->ieee802) {
+ if (ip -> ieee80211) {
+ /*
+ * Wavelan devices need to be checked if they are
+ * associated.
+ */
if ((IFM_TYPE(ifmr.ifm_active) == IFM_IEEE80211) &&
- (ifmr.ifm_status & IFM_ACTIVE))
- return (1);
+ (ifmr.ifm_status & IFM_ACTIVE)) {
+ if (ip -> havemedia &&
+ ip -> client -> state != S_BOUND)
+ ip -> forcediscover = 1;
+ return (HAVELINK);
+ }
} else {
- if (ifmr.ifm_status & IFM_ACTIVE)
- return (1);
+ /*
+ * Media settings can also be possible for normal
+ * devices.
+ */
+ if (ifmr.ifm_status & IFM_ACTIVE) {
+ if (ip -> havemedia &&
+ ip -> client -> state != S_BOUND)
+ ip -> forcediscover = 1;
+ return (HAVELINK);
+ }
}
}
- return (0);
+ /*
+ * If dhclient.conf contains media settings, we cannot
+ * abort if the interface is not set to active mode.
+ */
+ if (ip -> havemedia && ip -> client -> state != S_BOUND)
+ return (HAVELINK);
+
+ /*
+ * We really have no link.
+ */
+ return (NOLINK);
#else /* ifdef __FreeBSD__ */
- return (1);
+ /*
+ * Always return a successful link if the OS
+ * is not supported.
+ */
+ return (HAVELINK);
#endif /* Other OSs */
}
#ifdef __FreeBSD__
-set_ieee802 (struct interface_info *ip) {
+void
+set_ieee80211 (struct interface_info *ip) {
struct ieee80211req ireq;
u_int8_t data[32];
@@ -3242,11 +3302,11 @@
ifname = ip -> name;
- if ((sock = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP)) < 0)
- log_fatal("Can't create interface_active socket");
+ if ((sock = socket (AF_INET, SOCK_DGRAM, IPPROTO_UDP)) < 0)
+ log_fatal ("Can't create interface_active socket");
- (void) memset(&ireq, 0, sizeof(ireq));
- (void) strncpy(ireq.i_name, ifname, sizeof(ireq.i_name));
+ (void) memset (&ireq, 0, sizeof (ireq));
+ (void) strncpy (ireq.i_name, ifname, sizeof (ireq.i_name));
ireq.i_data = &data;
ireq.i_type = IEEE80211_IOC_SSID;
ireq.i_val = -1;
@@ -3254,19 +3314,26 @@
* If we can't get the SSID,
* this isn't an 802.11 device.
*/
- if (ioctl(sock, SIOCG80211, &ireq) < 0)
- ip->ieee802 = 0;
+ if (ioctl (sock, SIOCG80211, &ireq) < 0)
+ ip -> ieee80211 = 0;
else {
#ifdef DEBUG
- printf("Device %s has 802.11\n", ifname);
+ printf ("Device %s has 802.11\n", ifname);
#endif
- ip->ieee802 = 1;
+ ip -> ieee80211 = 1;
}
- close(sock);
+ close (sock);
}
#endif /* __FreeBSD__ */
#ifdef ENABLE_POLLING_MODE
+/* Go to background after some time */
+void state_background (cpp)
+ void *cpp;
+{
+ go_daemon ();
+}
+
/* Check the state of the NICs if we have link */
void state_link (cpp)
void *cpp;
@@ -3275,53 +3342,126 @@
struct client_state *client;
#ifdef DEBUG
- printf("Polling interface status\n");
+ printf ("Polling interface status\n");
#endif
for (ip = interfaces; ip; ip = ip -> next) {
- if (ip->linkstatus == 0 || doinitcheck == 0) {
- if (interface_active(ip)) {
+
+#ifdef DEBUG
+ for (client = ip -> client;
+ client; client = client -> next) {
+ printf ("%s: client state of %d\n", ip -> name, ip -> client -> state);
+ printf ("%s: link = %d\n", ip -> name, ip -> linkstate);
+ }
+#endif
+
+ /*
+ * The last status of the interface tells us
+ * the we've got no link ...
+ */
+ if (ip -> linkstate == NOLINK || ! doinitcheck) {
+ /*
+ * ... but we have now link. Let's send
+ * requests.
+ */
+ if (interface_active (ip) == HAVELINK) {
#ifdef DEBUG
- printf("%s: Found Link on interface\n", ip->name);
+ if (ip -> havemedia)
+ printf ("%s: Trying media settings on interface\n",
+ ip -> name);
+ else
+ printf ("%s: Found Link on interface\n", ip -> name);
#endif
+ /*
+ * Set the interface to state_reboot. But of
+ * course we can not be sure that we really got link,
+ * we just assume it.
+ */
for (client = ip -> client;
client; client = client -> next) {
- add_timeout(cur_time + random () % 5,
- state_reboot, client, 0, 0);
+ cancel_timeout (state_init, client);
+ cancel_timeout (state_reboot, client);
+ cancel_timeout (state_selecting, client);
+ add_timeout (cur_time + random () % 5,
+ state_reboot, client, 0, 0);
}
- ip->linkstatus = 1;
+ ip -> linkstate = HAVELINK;
} else {
#ifdef DEBUG
- printf("%s: No Link on interface\n", ip->name);
+ printf ("%s: No Link on interface\n", ip -> name);
#endif
for (client = ip -> client;
client; client = client -> next) {
- cancel_timeout(state_init, client);
- cancel_timeout(send_discover, client);
- cancel_timeout(send_request, client);
/*
- * XXX without this, dhclient does
+ * Without this add_timout(), dhclient does
* not poll on a interface if there
* is no cable plugged in at startup
- * time
+ * time. Because we add one additional second
+ * to the time of a normal timeout, we always
+ * skip and block a running one. This prevents
+ * that polling is done twice at the same time.
*/
if (client -> state == S_INIT) {
- add_timeout(cur_time + polling_interval,
+ add_timeout (cur_time + (polling_interval + 1),
state_link, client, 0, 0);
}
}
- ip->linkstatus = 0;
+ ip -> linkstate = NOLINK;
+ /*
+ * Automatically go into the background after
+ * some time. Do this only if there are no
+ * media options available for a interface.
+ */
+ if (! ip -> havemedia && ! doinitcheck) {
+ add_timeout (cur_time + (polling_interval * 2),
+ state_background, client, 0, 0);
+ }
}
- } else {
- if (interface_active(ip) == 0) {
+ }
+
+ /*
+ * The last status of the interface tells us
+ * the we previously had link.
+ */
+ if (ip -> linkstate == HAVELINK && doinitcheck) {
+ if (interface_active (ip) == NOLINK) {
+ /*
+ * We lost link on the interface, or it isn't
+ * associated anymore.
+ */
#ifdef DEBUG
- printf("%s: Lost Link on interface\n", ip->name);
+ printf ("%s: Lost Link on interface\n", ip -> name);
#endif
- ip->linkstatus = 0;
+ /*
+ * After we lost link, cycle again through the
+ * different media settings if available. Else
+ * set NOLINK.
+ */
+ if (ip -> havemedia)
+ ip -> forcediscover = 1;
+ else
+ ip -> linkstate = NOLINK;
+ }
+ /*
+ * If we happen to have a real link, but no
+ * active lease, force the interface into
+ * state_reboot. Do the same if media settings
+ * are available.
+ */
+ if (ip -> forcediscover) {
+ for (client = ip -> client;
+ client; client = client -> next) {
+ if (client -> state != S_REBOOTING &&
+ client -> state != S_SELECTING) {
+ add_timeout (cur_time + random () % 5,
+ state_reboot, client, 0, 0);
+ }
+ }
+ ip -> forcediscover = 0;
+ ip -> linkstate = HAVELINK;
}
+ /* We still have link, do nothing. */
}
}
- if (doinitcheck)
- go_daemon ();
doinitcheck = 1;
}
#endif /* ifdef ENABLE_POLLING_MODE */
==== //depot/projects/ia64/contrib/isc-dhcp/includes/dhcpd.h#7 (text+ko) ====
@@ -40,7 +40,7 @@
* see ``http://www.vix.com''. To learn more about Nominum, Inc., see
* ``http://www.nominum.com''.
*
- * $FreeBSD: src/contrib/isc-dhcp/includes/dhcpd.h,v 1.3 2003/07/28 11:49:07 mbr Exp $
+ * $FreeBSD: src/contrib/isc-dhcp/includes/dhcpd.h,v 1.5 2003/08/07 07:27:14 mbr Exp $
*/
#ifndef __CYGWIN32__
@@ -101,6 +101,9 @@
(((x) >> OPTION_HASH_EXP) & \
(OPTION_HASH_PTWO - 1))) % OPTION_HASH_SIZE;
+#define NOLINK 0
+#define HAVELINK 1
+
enum dhcp_shutdown_state {
shutdown_listeners,
shutdown_omapi_connections,
@@ -780,8 +783,10 @@
unsigned remote_id_len; /* Length of Remote ID. */
char name [IFNAMSIZ]; /* Its name... */
- int linkstatus; /* Link status */
- int ieee802; /* True if media is ieee802 */
+ int ieee80211; /* True if media is ieee802.11 */
+ int havemedia; /* True if we have a media table */
+ int linkstate; /* True if we have link */
+ int forcediscover; /* True if a discover is needed */
int index; /* Its index. */
int rfdesc; /* Its read file descriptor. */
int wfdesc; /* Its write file descriptor, if
@@ -1859,6 +1864,7 @@
void state_reboot PROTO ((void *));
#ifdef ENABLE_POLLING_MODE
void state_link PROTO (());
+void state_background PROTO ((void *));
#endif
void state_init PROTO ((void *));
void state_selecting PROTO ((void *));
@@ -1867,6 +1873,11 @@
void state_stop PROTO ((void *));
void state_panic PROTO ((void *));
+#ifdef __FreeBSD__
+void set_ieee80211 PROTO ((struct interface_info *));
+#endif
+int interface_active PROTO ((struct interface_info *));
+
void bind_lease PROTO ((struct client_state *));
void make_client_options PROTO ((struct client_state *,
==== //depot/projects/ia64/etc/defaults/pccard.conf#23 (text+ko) ====
@@ -1,7 +1,7 @@
#
# Default PCCARD configuration file
#
-# $FreeBSD: src/etc/defaults/pccard.conf,v 1.262 2003/07/22 21:23:01 dds Exp $
+# $FreeBSD: src/etc/defaults/pccard.conf,v 1.263 2003/08/07 04:38:01 imp Exp $
#
# Please send new entries for this file to imp at freebsd.org. He likes to
# review them before they are committed to make sure they are correct for
@@ -205,6 +205,10 @@
card "KODAK Picture Card" "KODAK"
config default "ata" ?
+# Panasonic KXL-CB10AN (CD-R/RW/DVD)
+card "KME" "KXLC006"
+ config auto "ata" ?
+
# TOSHIBA Portable 24X Speed CD-ROM Drive PA2673UJ
card "LOOKMEET" "/CBIDE2 */"
config default "ata" ?
@@ -691,6 +695,12 @@
insert /etc/pccard_ether $device start
remove /etc/pccard_ether $device stop
+# I/O DATA PCET10-CL
+card "IO DATA" "PCET10CL"
+ config auto "ed0" any 0x10
+ insert /etc/pccard_ether $device
+ remove /etc/pccard_ether_remove $device
+
# I-O DATA PCET/100-CL
card "IO DATA" "PCET100CL"
config auto "ed" ? 0x80000
@@ -2088,6 +2098,12 @@
insert /etc/pccard_ether $device start
remove /etc/pccard_ether $device stop
+# Netgear MA701
+card "NETGEAR" "MA701 Wireless CF Card"
+ config auto "wi" ?
+ insert /etc/pccard_ether $device start
+ remove /etc/pccard_ether $device stop
+
# Nortel eMobility
card "Nortel Networks" "emobility 802.11 Wireless LAN PC Card"
config auto "wi" ?
==== //depot/projects/ia64/etc/services#9 (text+ko) ====
@@ -16,7 +16,7 @@
# Kerberos services are for Kerberos v4, and are unofficial. Sites running
# v5 should uncomment v5 entries and comment v4 entries.
#
-# $FreeBSD: src/etc/services,v 1.93 2003/05/05 22:10:14 dougb Exp $
+# $FreeBSD: src/etc/services,v 1.94 2003/08/06 18:15:10 dcs Exp $
# From: @(#)services 5.8 (Berkeley) 5/9/91
#
# WELL KNOWN PORT NUMBERS
@@ -1093,6 +1093,8 @@
ginad 634/udp
ldaps 636/tcp sldap #ldap protocol over TLS/SSL
ldaps 636/udp sldap
+aodv 654/tdp #Ad-Hoc On-Demand Distance Vector Routing Protocol
+aodv 654/udp #Ad-Hoc On-Demand Distance Vector Routing Protocol
mdqs 666/tcp
mdqs 666/udp
#PROBLEMS!===============================================
==== //depot/projects/ia64/lib/libc/sys/connect.2#6 (text+ko) ====
@@ -30,7 +30,7 @@
.\" SUCH DAMAGE.
.\"
.\" @(#)connect.2 8.1 (Berkeley) 6/4/93
-.\" $FreeBSD: src/lib/libc/sys/connect.2,v 1.24 2003/07/23 22:00:08 dds Exp $
+.\" $FreeBSD: src/lib/libc/sys/connect.2,v 1.25 2003/08/06 14:21:06 yar Exp $
.\"
.Dd June 4, 1993
.Dt CONNECT 2
@@ -117,10 +117,13 @@
It is possible to
.Xr select 2
for completion by selecting the socket for writing.
+.It Bq Er EINTR
+The connection attempt was interrupted by the delivery of a signal.
+The connection will be established in the background,
+as in the case of
+.Er EINPROGRESS .
.It Bq Er EALREADY
-The socket is non-blocking
-and a previous connection attempt
-has not yet been completed.
+A previous connection attempt has not yet been completed.
.It Bq Er EACCES
An attempt is made to connect to a broadcast address (obtained through the
.Dv INADDR_BROADCAST
==== //depot/projects/ia64/lib/libpthread/arch/ia64/ia64/pthread_md.c#2 (text+ko) ====
@@ -23,7 +23,7 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $FreeBSD: src/lib/libpthread/arch/ia64/ia64/pthread_md.c,v 1.1 2003/08/05 22:46:00 deischen Exp $
+ * $FreeBSD: src/lib/libpthread/arch/ia64/ia64/pthread_md.c,v 1.2 2003/08/06 04:17:42 marcel Exp $
*/
#include <stdlib.h>
@@ -41,7 +41,6 @@
if ((tcb = malloc(sizeof(struct tcb))) != NULL) {
bzero(tcb, sizeof(struct tcb));
tcb->tcb_thread = thread;
- tcb->tcb_tp.tp_self = tcb;
/* Allocate TDV */
}
return (tcb);
@@ -63,7 +62,6 @@
bzero(kcb, sizeof(struct kcb));
kcb->kcb_faketcb.tcb_isfake = 1;
kcb->kcb_faketcb.tcb_tmbx.tm_flags = TMF_NOUPCALL;
- kcb->kcb_faketcb.tcb_tp.tp_self = &kcb->kcb_faketcb;
kcb->kcb_curtcb = &kcb->kcb_faketcb;
kcb->kcb_kse = kse;
}
==== //depot/projects/ia64/lib/libpthread/arch/ia64/include/pthread_md.h#5 (text+ko) ====
@@ -23,13 +23,14 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $FreeBSD: src/lib/libpthread/arch/ia64/include/pthread_md.h,v 1.6 2003/08/06 00:17:15 marcel Exp $
+ * $FreeBSD: src/lib/libpthread/arch/ia64/include/pthread_md.h,v 1.8 2003/08/06 06:12:54 deischen Exp $
*/
#ifndef _PTHREAD_MD_H_
#define _PTHREAD_MD_H_
#include <sys/kse.h>
+#include <stddef.h>
#include <ucontext.h>
#define THR_GETCONTEXT(ucp) _ia64_save_context(&(ucp)->uc_mcontext)
@@ -53,7 +54,7 @@
*/
struct ia64_tp {
struct tdv *tp_tdv; /* dynamic TLS */
- struct tcb *tp_self;
+ uint64_t _reserved_;
long double tp_tls[0]; /* static TLS */
};
@@ -74,6 +75,8 @@
register struct ia64_tp *_tp __asm("%r13");
+#define _tcb ((struct tcb*)((char*)(_tp) - offsetof(struct tcb, tcb_tp)))
+
/*
* The kcb and tcb constructors.
*/
@@ -99,7 +102,7 @@
static __inline struct kcb *
_kcb_get(void)
{
- return (_tp->tp_self->tcb_curkcb);
+ return (_tcb->tcb_curkcb);
}
/*
@@ -111,22 +114,20 @@
_kcb_critical_enter(void)
{
struct kse_thr_mailbox *crit;
- struct tcb *tcb;
uint32_t flags;
- tcb = _tp->tp_self;
- if (tcb->tcb_isfake != 0) {
+ if (_tcb->tcb_isfake != 0) {
/*
* We already are in a critical region since
* there is no current thread.
*/
crit = NULL;
} else {
- flags = tcb->tcb_tmbx.tm_flags;
- tcb->tcb_tmbx.tm_flags |= TMF_NOUPCALL;
- crit = tcb->tcb_curkcb->kcb_kmbx.km_curthread;
- tcb->tcb_curkcb->kcb_kmbx.km_curthread = NULL;
- tcb->tcb_tmbx.tm_flags = flags;
+ flags = _tcb->tcb_tmbx.tm_flags;
+ _tcb->tcb_tmbx.tm_flags |= TMF_NOUPCALL;
+ crit = _tcb->tcb_curkcb->kcb_kmbx.km_curthread;
+ _tcb->tcb_curkcb->kcb_kmbx.km_curthread = NULL;
+ _tcb->tcb_tmbx.tm_flags = flags;
}
return (crit);
}
@@ -134,33 +135,28 @@
static __inline void
_kcb_critical_leave(struct kse_thr_mailbox *crit)
{
- struct tcb *tcb;
-
- tcb = _tp->tp_self;
/* No need to do anything if this is a fake tcb. */
- if (tcb->tcb_isfake == 0)
- tcb->tcb_curkcb->kcb_kmbx.km_curthread = crit;
+ if (_tcb->tcb_isfake == 0)
+ _tcb->tcb_curkcb->kcb_kmbx.km_curthread = crit;
}
static __inline int
_kcb_in_critical(void)
{
- struct tcb *tcb;
uint32_t flags;
int ret;
- tcb = _tp->tp_self;
- if (tcb->tcb_isfake != 0) {
+ if (_tcb->tcb_isfake != 0) {
/*
* We are in a critical region since there is no
* current thread.
*/
ret = 1;
} else {
- flags = tcb->tcb_tmbx.tm_flags;
- tcb->tcb_tmbx.tm_flags |= TMF_NOUPCALL;
- ret = (tcb->tcb_curkcb->kcb_kmbx.km_curthread == NULL);
- tcb->tcb_tmbx.tm_flags = flags;
+ flags = _tcb->tcb_tmbx.tm_flags;
+ _tcb->tcb_tmbx.tm_flags |= TMF_NOUPCALL;
+ ret = (_tcb->tcb_curkcb->kcb_kmbx.km_curthread == NULL);
+ _tcb->tcb_tmbx.tm_flags = flags;
}
return (ret);
}
@@ -168,38 +164,34 @@
static __inline void
_tcb_set(struct kcb *kcb, struct tcb *tcb)
{
- if (tcb == NULL) {
- kcb->kcb_curtcb = &kcb->kcb_faketcb;
- _tp = &kcb->kcb_faketcb.tcb_tp;
- }
- else {
- kcb->kcb_curtcb = tcb;
- tcb->tcb_curkcb = kcb;
- _tp = &tcb->tcb_tp;
- }
+ if (tcb == NULL)
+ tcb = &kcb->kcb_faketcb;
+ kcb->kcb_curtcb = tcb;
+ tcb->tcb_curkcb = kcb;
+ _tp = &tcb->tcb_tp;
}
static __inline struct tcb *
_tcb_get(void)
{
- return (_tp->tp_self);
+ return (_tcb);
}
static __inline struct pthread *
_get_curthread(void)
{
- return (_tp->tp_self->tcb_thread);
+ return (_tcb->tcb_thread);
}
/*
* Get the current kse.
*
- * Line _kcb_get(), this can only be called while in a critical region.
+ * Like _kcb_get(), this can only be called while in a critical region.
*/
static __inline struct kse *
_get_curkse(void)
{
- return (_tp->tp_self->tcb_curkcb->kcb_kse);
+ return (_tcb->tcb_curkcb->kcb_kse);
}
void _ia64_enter_uts(kse_func_t uts, struct kse_mailbox *km, void *stack,
@@ -226,9 +218,7 @@
static __inline int
_thread_switch(struct kcb *kcb, struct tcb *tcb, int setmbox)
{
- kcb->kcb_curtcb = tcb;
- tcb->tcb_curkcb = kcb;
- _tp = &tcb->tcb_tp;
+ _tcb_set(kcb, tcb);
if (setmbox != 0)
_ia64_restore_context(&tcb->tcb_tmbx.tm_context.uc_mcontext,
(intptr_t)&tcb->tcb_tmbx,
==== //depot/projects/ia64/release/Makefile#66 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/release/Makefile,v 1.813 2003/08/05 05:35:56 ache Exp $
+# $FreeBSD: src/release/Makefile,v 1.814 2003/08/06 08:09:40 ru Exp $
#
# make release [BUILDNAME=somename] CHROOTDIR=/some/dir CVSROOT=/cvs/dir \
# [RELEASETAG=tag]
@@ -255,18 +255,14 @@
DOFS_SH= ${.CURDIR}/scripts/doFS.sh ${DISKLABEL} ""
.endif
-.if ${TARGET_ARCH} == "sparc64"
-CRUNCH_TARGETS= boot
-.elif ${TARGET_ARCH} == "ia64"
-CRUNCH_TARGETS= boot
-.elif ${TARGET} == "pc98"
-CRUNCH_TARGETS= boot fixit fixit-small
-.elif ${TARGET_ARCH} == "amd64"
-CRUNCH_TARGETS= boot
+CRUNCH_TARGETS= boot
+.if ${TARGET_ARCH} == "i386"
+CRUNCH_TARGETS+=fixit
+.if ${TARGET} == "pc98"
+CRUNCH_TARGETS+=fixit-small
+.endif
.endif
-CRUNCH_TARGETS?=boot fixit
-
EXTRAS= ftp.1
.if !defined(NOCDROM)
EXTRAS+= cdrom.1
@@ -553,19 +549,17 @@
rm -rf ${RD}/crunch
mkdir -p ${RD}/crunch
.for j in ${CRUNCH_TARGETS}
+.if exists(${.CURDIR}/${TARGET}/${j}_crunch.conf)
rm -rf ${j}_crunch
mkdir ${j}_crunch
-.if exists(${.CURDIR}/${TARGET}/${j}_crunch.conf)
>>> TRUNCATED FOR MAIL (1000 lines) <<<
More information about the p4-projects
mailing list