changelog
来自「eCos操作系统源码」· 代码 · 共 1,734 行 · 第 1/5 页
TXT
1,734 行
2000-09-26 Hugo Tyson <hmt@redhat.com>2000-09-25 Andrew Lunn <Andrew.Lunn@ascom.ch> * src/lib/tftp_server.c: Send an ERROR packet when giving up after too many timeouts. This should cause the client to give up as well. Also moved all the replicated code to send an ERROR packet into one function. [Huge] I collected another point where we can use the common function also, and used ETIMEOUT instead of EBADOP for the new error packet returns. Thanks Andrew! 2000-09-14 Hugo Tyson <hmt@redhat.com> * cdl/net.cdl (CYGOPT_NET_DHCP_DHCP_THREAD_PARAM): Set default to 1 so that the DHCP management thread loops forever. This allows it to recover from a DHCP renewal failure. * src/lib/dhcp_prot.c (next_timeout): Harden the DHCP protocol machine against [simulated] failures - otherwise the tests with simulated failures tend just to close down all the interfaces when DHCP packets are lost.2000-09-11 Gary Thomas <gthomas@redhat.com> * src/lib/bootp_support.c (init_net): Set default route correctly.2000-09-01 Hugo Tyson <hmt@cygnus.co.uk> * src/ecos/support.c (cyg_net_init): You can't print things while initializing the network! Well, not if connected to GDB over the network anyway. The printf("Init device '%s'...); removed.2000-09-01 Hugo Tyson <hmt@cygnus.co.uk> * OVERVIEW: This is part of the change to the network stack to greatly reduce latencies both of (other) DSRs and of thread scheduling. All the work that the network stack *and* individual ether drivers used to do in DSRs (including alarm callbacks and data copies to/from the device memory) is moved into a "fast network thread" instead. It calls a device's "deliver" function to do the work that was previously in the DSR. This is a separate thread so that it can be set higher priority than application threads in order to minimize packet loss (depending on the driver), if required (the application threads presumed to be higher priority in turn than the network thread). A crucial consequence of this is that we are no longer locking against DSRs, so a plain mutex can be used rather than the global scheduler lock, thus simplifying all the splfoo/splx() style functions. * src/ecos/timeout.c (alarm_thread): Addition of the "fast network thread" which runs DSR-like activities. (do_timeout): Timeout function morphed for calling from that. (do_alarm, ecos_synch_eth_drv_dsr): new DSR functions to signal to the thread. (timeout): Race condition fixed. splinternal() used for locking instead of scheduler. * src/ecos/support.c (cyg_net_init): Splfoo/splx() functions, together with tsleep/wakeup functions, all removed to separate them from the mixed bag of utilities in this file. What remains is mbuf wrapper routines and the like, plus the network "netisr" thread itself, the caller into the stack that does the slower priority work. * src/ecos/synch.c: New file; implemtation of new splfoo/splx() functions, together with tsleep/wakeup functions, since they are related now. * cdl/net.cdl: Compile new file synch.c; two new options, one for "fast thread" priority, and one for DHCP manager thread priority, as I was adding prio configury. CYGPKG_NET_FAST_THREAD_PRIORITY and CYGPKG_NET_DHCP_THREAD_PRIORITY resp, with suitable default values relative to the CYGPKG_NET_THREAD_PRIORITY. * src/lib/dhcp_support.c (dhcp_start_dhcp_mgt_thread): Use the configured priority rather than just "net thread - 1"2000-08-31 Hugo Tyson <hmt@cygnus.co.uk> * tests/tcp_echo.c: Change the priorities of the main and loading threads to accommodate the network having helper threads around at adjacent priorities to its main thread prio.2000-08-24 Hugo Tyson <hmt@cygnus.co.uk> * src/sys/net/if.c (ifioctl): Support the two new ioctl() keys; at this level, the struct ifreq at the head of the data area must be filled to select an interface. * include/sys/sockio.h (SIOCGIFSTATSUD): Add two new eCos-only ioctl() keys, SIOCGIFSTATSUD and SIOCGIFSTATS, for reading statistical information out of ethernet devices, for SNMP. This should allow SNMP (a) to not explode, (b) to get useful info out of other device implementations than this one.2000-08-17 Hugo Tyson <hmt@cygnus.co.uk> * src/ecos/timeout.c (timeout): Rework the timeout system to record last-time-we-set-the-alarm and whence values, so that new timeouts being added can be set up relative to the correct absolute time. Otherwise adding a new timeout sets them *all* into the future by the expired portion of the previous minimum pending timeout. Also deal better with recursion ie. timeout handlers themselves setting new timeouts as is only natural. Lots of asserts too. * src/ecos/support.c (cyg_splsoftnet): Use the new kernel facility to lock mutex &c atomically, with the scheduler locked already. (cyg_tsleep): Similarly, and reclaim the mutex likewise. Also added lots of asserts to both calls the better to document what's going on.2000-08-17 Hugo Tyson <hmt@cygnus.co.uk> * src/lib/tftp_server.c: Fix contributors field.2000-08-16 Hugo Tyson <hmt@cygnus.co.uk> * src/lib/tftp_server.c: Improvements to server wrt better error messages and detection of filesystem errors eg. on close-file. Contrib from ASCOM. I tidied up some comments and indent to minimize the diff. [CASE 104354]2000-08-15 Hugo Tyson <hmt@cygnus.co.uk> * doc/bridge.html: New file... * doc/bridge.doc: New file... provided by ASCOM from the OpenBSD version.2000-08-15 Hugo Tyson <hmt@cygnus.co.uk> * src/sys/net/if_bridge.c (bridge_ioctl): SIOCBRDGSTO takes argument in seconds not in ticks. So move around some mul/div by hz ops to get this right.2000-08-14 Gary Thomas <gthomas@redhat.com> * src/ecos/support.c: Use new table definition mechanism.2000-07-27 Hugo Tyson <hmt@cygnus.co.uk> * src/lib/dhcp_prot.c (do_dhcp): Use xmit->bp_htype = HTYPE_ETHERNET rather than ifr.ifr_hwaddr.sa_family; sa_family is in a different namespace, despite appearances. * src/lib/bootp_support.c (do_bootp): Use bp_htype = HTYPE_ETHERNET rather than ifr.ifr_hwaddr.sa_family; sa_family is in a different namespace, despite appearances.2000-07-27 Nick Garnett <nickg@cygnus.co.uk> * cdl/net.cdl: Require the C library STDIO package to be present if there is more than one loopback interface. This is because it needs sprintf() to form the interface names. * src/sys/net/if_loop.c (loopattach): Only use sprintf() to form the loopback interface names when there is more than one. The CDL ensures that this will work. * src/lib/network_support.c: Added diag_printf() version of perror() for when STDIO package is absent. Only use sprintf() to form the loopback interface names when there is more than one. The CDL ensures that this will work. * tests/multi_lo_select.c: * tests/ping_lo_test.c: * tests/tcp_lo_test.c: Removed dependence on C library by adding a substitute perror() based on diag_printf() that is enabled when the STDIO package is absent. 2000-07-26 Hugo Tyson <hmt@cygnus.co.uk> * src/lib/dhcp_prot.c (do_dhcp): Set the broadcast flag where necessary, and the client address too. This makes it talk to a greater range of servers OK. 2000-07-25 Nick Garnett <nickg@cygnus.co.uk> * tests/multi_lo_select.c: Changed definition of NLISTENERS to work correctly with FILEIO package. * src/sys/net/if_loop.c (loopattach): Changed initialization of if_xname to "lo0". * src/ecos/support.c (cyg_net_init): Removed redundant code to initialize loop-back interface.2000-07-25 Hugo Tyson <hmt@cygnus.co.uk> * src/lib/getserv.c: Add a list terminator record with NULLs in it so that the search finishes (without throwing asserts about bad strings).2000-07-21 Hugo Tyson <hmt@cygnus.co.uk> * src/sys/net/if_bridge.c: Move the include of stdio.h lower, apparently it confuses local x86 compilers if their host tree is malformed. Or something.2000-07-21 Hugo Tyson <hmt@cygnus.co.uk> * cdl/net.cdl: Add a lot of description about the way the various fields are used in interface initialization: specifically that "server" so-called is just "someone to talk to" in the absence of bootp - and our tests depend on it! * src/lib/bootp_support.c (init_net): Only set up a route if the route address is nonzero - or all manner of confusion occurs with multiple interfaces and route that sends to 0.0.0.0... For setting up the default route, use (SIOCADDRT, 0, 0, TAG_GATEWAY) rather than the bogus (SIOCADDRT, yiaddr & netmask, netmask, TAG_GATEWAY) that we did before. * tests/ftp_test.c (ftp_test): Try it with eth1 if available also. * tests/ping_test.c (ping_host): If a ping fails, reset the packet size to small just in case the huge packet size is what's causing confusion - helps it as a debug tool. * tests/dhcp_test.c (net_test): It didn't compile if DHCP is disabled! Doh. Same change as ping_test also.2000-07-19 Hugo Tyson <hmt@cygnus.co.uk> * src/lib/tftp_server.c (tftpd_read_file): Deal with a) [assumed] timeouts on the select, and b) ACKs for old packets. [CASE 104052 and CASE 104055]2000-07-19 Hugo Tyson <hmt@cygnus.co.uk> * src/lib/select.c (_cyg_select): Return 0 and do not perturb errno when the timeout occurs. That matches the man page! [CASE 104054]2000-07-19 Hugo Tyson <hmt@cygnus.co.uk> * include/machine/param.h: Be more defensive against warnings from external defines such as __linux__/__bsdi__/__FreeBSD__/... [CASE 104090]2000-07-19 Hugo Tyson <hmt@cygnus.co.uk> * tests/multi_lo_select.c: New test program to test for proper broadcast behaviour of select() implementation. Took some fiddling to get it to work, but it really did fail before the select change below. * cdl/net.cdl: Build the new test. * src/lib/select.c (_cyg_select): Don't use the CLR flag in the flag wait because that gives unicast semantics. Flags have producer-does-all-the-work behaviour, so setting a value then clearing it right afterwards does the right thing, with broadcast semantics so long as no waiter has set the CLR part. [CASE 104058]2000-07-18 Hugo Tyson <hmt@cygnus.co.uk> All part of the bridge contribution from Andrew Lunn/ASCOM (andrew.lunn@ascom.ch). Bridginess is controlled by NBRIDGE which is itself controlled by CDL option CYGPKG_NET_NBRIDGE aka "Number of bridge buffers?" * include/machine/param.h: Add proper definition of untimeout(). * include/sys/sockio.h (SIOCBRDGFRL): Add this and the other 2 bridge ioctl() call definitions. * include/sys/param.h (splhigh): Added. * src/ecos/timeout.c (untimeout): Implement this properly, it was never used before. * src/ecos/support.c: implement cyg_splhigh(), call bridgeintr() when it is scheduled and bridgeattach() if configured. * tests/bridge.c: New "test" file - implements an ethernet bridge. Contributed by Andrew Lunn/ASCOM, from the usual OpenBSD external source original. * include/net/if_bridge.h: New file, contributed by Andrew Lunn/ ASCOM, from OpenBSD original. (Actually did exist in eCos source tree but was not released) * src/sys/net/if_bridge.c: New file, contributed by Andrew Lunn/ ASCOM, from OpenBSD original. * cdl/net.cdl: Build the new files.2000-07-18 Gary Thomas <gthomas@redhat.com> * src/lib/tftp_client.c (tftp_get): Fix edge condition when penultimate block is full and end of file which implies that the last block has zero data bytes.2000-07-18 Hugo Tyson <hmt@cygnus.co.uk> * src/lib/dhcp_prot.c: Ignore NAK messages from the wrong server - we get these because the REQUEST for our chosen IP is broadcast, so other servers think we've asked to use the wrong IP.2000-07-14 Hugo Tyson <hmt@cygnus.co.uk> * include/bootp.h: export init_loopback_interface();2000-07-14 Hugo Tyson <hmt@cygnus.co.uk> * cdl/net.cdl: Add option controlling whether to have a separate DHCP lease management thread, and what its parameter is to be - which controls whether it loops or quits if a lease fails. * src/lib/dhcp_support.c (dhcp_start_dhcp_mgt_thread): Provide the DHCP management thread function and code to instantiate and start the thread if so configured. * src/lib/network_support.c (init_all_network_interfaces): Call the function that starts the DHCP management thread function. * include/dhcp.h: Declare the DHCP management thread function &c if so configured. * tests/dhcp_test.c (net_test): Only poll for need to rebind DHCP leases if there is no service thread to do the same.2000-07-14 Hugo Tyson <hmt@cygnus.co.uk> * include/bootp.h (build_bootp_record): Export this, no harm in it, and some folk want to use this rather than configured initialization or bootp/dhcp. Also commented the other APIs somewhat better. * src/lib/network_support.c (build_bootp_record): Unconditionally provide this; selective linking will look after it if unused.2000-07-14 Hugo Tyson <hmt@cygnus.co.uk> * src/lib/network_support.c (build_bootp_record): [Static configuration of interface parameters] Add the gateway into the options section with TAG_GATEWAY so that init_net() will pick it up and set up a route accordingly.
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?