summaryrefslogtreecommitdiffstats
path: root/c/src/lib (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Patch from Ian Lance Taylor <ian@airs.com>:Joel Sherrill1999-06-114-2/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The select function is not particularly efficient when dealing with a large number of sockets. The application has to build a big set of bits and pass it in. RTEMS has to look through all those bits and see what is ready. Then the application has to look through all the bits again. On the other hand, when using RTEMS, the select function is needed exactly when you have a large number of sockets, because that is when it becomes prohibitive to use a separate thread for each socket. I think it would make more sense for RTEMS to support callback functions which could be invoked when there is data available to read from a socket, or when there is space available to write to a socket. Accordingly, I implemented them. This patch adds two new SOL_SOCKET options to setsockopt and getsockopt: SO_SNDWAKEUP and SO_RCVWAKEUP. They take arguments of type struct sockwakeup: struct sockwakeup { void (*sw_pfn) __P((struct socket *, caddr_t)); caddr_t sw_arg; }; They are used to add or remove a function which will be called when something happens for the socket. Getting a callback doesn't imply that a read or write will succeed, but it does imply that it is worth trying. This adds functionality to RTEMS which is somewhat like interrupt driven socket I/O on Unix. After the patch to RTEMS, I have appended a patch to netdemos-19990407/select/test.c to test the new functionality and demonstrate one way it might be used. To run the new test instead of the select test, change doSocket to call echoServer2 instead of echoServer.
* Patch from Eric Norum <eric@cls.usask.ca> to fix bug reported byJoel Sherrill1999-06-111-0/+2
| | | | | | | | | | | | | | | | | | Ian Lance Taylor <ian@airs.com>: Ian Lance Taylor wrote: > > In rtems-19990528, sbwait sets SB_WAIT in sb_flags. sowakeup checks > it. Why doesn't socket_select set it? > > I don't know that this is a bug--I haven't tried to create a test > case. However, it certainly looks odd. > > Ian Yes, there's a bug there. Sorry about that. It was introduced when I did some cleanup on the sleep/wakeup handling in rtems_glue.c.
* Do not use the RTEMS simpleioctl.h if networking is enabled sinceJoel Sherrill1999-06-091-1/+4
| | | | that subsystem provides a more robust version of ioctl.h.
* Switched to using strcasecmp() since it is more portable.Joel Sherrill1999-06-091-2/+2
| | | | D. V. Henkel-Wallace <gumby@zembu.com> spotted this one.
* Removed "NO CTOR" from list of objects to be picked up. It now comes inJoel Sherrill1999-06-021-2/+1
| | | | via libbsp.a. Reported by Ian Lance Taylor <ian@airs.com>.
* Changes from Eric Norum to add a loop and limit on the length of timeJoel Sherrill1999-05-281-22/+32
| | | | the stack will wait for mbufs.
* Use fgrep instead of grep to avoid treating filenames as regular expressions.Joel Sherrill1999-05-281-1/+1
| | | | | grep found debugio.o when looking for debug.o and said there was a filename conflict incorrectly.
* Alignment corrected per Eric Norum's suggestion.Joel Sherrill1999-05-281-1/+2
|
* Corrected to include shared console driver.Joel Sherrill1999-05-281-1/+1
|
* Renamed config.c to conscfg.c to avoid naming conflicts.Joel Sherrill1999-05-282-284/+1
|
* Renamed config.s to todcfg.c to avoid naming conflicts.Joel Sherrill1999-05-282-80/+1
|
* Renamed fatal.c to bspfatal.c to avoid name conflicts withJoel Sherrill1999-05-282-128/+1
| | | | Fatal Error handler in SuperCore.
* Switched from picking up the .rel for each subdirectory in theJoel Sherrill1999-05-2733-33/+33
| | | | | BSP (BSP_PIECES) to picking up the .o files. This should help reduce the minimum size of an application.
* Patch from Eric Norum <eric@pollux.usask.ca> to eliminate a panic when theJoel Sherrill1999-05-273-147/+88
| | | | network stack runs out of mbufs.
* Split out the routine rtems_assoc_name_bad().Joel Sherrill1999-05-275-29/+83
|
* Removed usage of printf.Joel Sherrill1999-05-272-2/+2
|
* Split initialization and reserve resources from termios to reduceJoel Sherrill1999-05-274-60/+95
| | | | size of mininum application.
* Split out polled io, debug puts, and console reserve resources toJoel Sherrill1999-05-274-83/+146
| | | | reduce dependencies and shrink minimum executable size.
* Regenerated.Joel Sherrill1999-05-278-621/+1107
|
* Removed all post 4.0 changes.Joel Sherrill1999-05-201-81/+78
|
* Regenerated.Joel Sherrill1999-05-188-1107/+621
|
* Spacing correction.Joel Sherrill1999-05-181-1/+0
|
* Patch from D. V. Henkel-Wallace <gumby@zembu.com> to remove compilerJoel Sherrill1999-05-173-4/+4
| | | | warnings.
* Added 3COM 3C509 driver from Rosimildo DaSilva <rdasilva@connecttel.com>.Joel Sherrill1999-05-147-2/+2247
|
* Enabled compilation of rtems_servers at request of Jake JanovetzJoel Sherrill1999-05-144-6/+8
| | | | <janovetz@tempest.ece.uiuc.edu>.
* Fix based on bug report from Jay Kulpinski <jskulpin@eng01.gdds.com>Joel Sherrill1999-05-111-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | that the per task reentrancy structure was not being processed properly during exit(). joel@oarcorp.com wrote: > > > This is always an ugly place to poke around. :( > > The code in newlib/libc/stdlib/exit.c walks the atexit chain for the > reentrancy structure for JUST the current task. The code in libc_wrapup() > does it for both the current task and the global reentrancy structure > (which tends to be where driver atexit()'s were registered. > > So I think the _wrapup_reent(0) in libc_wrapup() should be commented out. > > If you concur, then I will make the change and improve the comment on this > line of code to explain things: > > libc_wrapup(); /* Why? XXX */ > > --joel That does the job. cdtest.exe works correctly now.
* Patch from Erik Ivanenko <erik.ivanenko@utoronto.ca> to correct 32 bitJoel Sherrill1999-05-111-0/+2
| | | | jmp relative offset from .reset section.
* Error reporting fixed by Jennifer.Joel Sherrill1999-05-071-15/+15
|
* Bug fix from Gunter Magin <magin@@skil.camelot.de>:Joel Sherrill1999-05-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | in libcpu/powerpc/mpc860/clock/clock.c:InstallClock() the reload value for the PIT is defined as: pit_value = (BSP_Configuration.microseconds_per_tick * Cpu_table.clicks_per_usec) - 1 ; What exactly is a tick, and what is a click? My confusion stems from the fact, that Jay defines clicks_per_usec to 1 which is correct for his configuration, where a 4MHz clock is predivided by 4 and then fed to the PIT. So I assume a "click" is just the period of the PIT input frequency. However, our HW config seems to have 32.768 kHz crystal input for PIT. Mandatory division by 4 means 8.196kHz (122usec) at the PIT. I think, the above assignment should read: pit_value = (BSP_Configuration.microseconds_per_tick / Cpu_table.clicks_per_usec) - 1; where I can define Cpu_table.clicks_per_usec in bspstart.c to 122 (clicks_per_usec). That would lead to a PIT reload value of 10000/122 - 1 = 81 to reach a 10ms "tick" period.
* Bug fix from Gunter Magin <magin@skil.camelot.de>:Joel Sherrill1999-05-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | in libcpu/powerpc/mpc860/clock/clock.c:InstallClock() the reload value for the PIT is defined as: pit_value = (BSP_Configuration.microseconds_per_tick * Cpu_table.clicks_per_usec) - 1 ; What exactly is a tick, and what is a click? My confusion stems from the fact, that Jay defines clicks_per_usec to 1 which is correct for his configuration, where a 4MHz clock is predivided by 4 and then fed to the PIT. So I assume a "click" is just the period of the PIT input frequency. However, our HW config seems to have 32.768 kHz crystal input for PIT. Mandatory division by 4 means 8.196kHz (122usec) at the PIT. I think, the above assignment should read: pit_value = (BSP_Configuration.microseconds_per_tick / Cpu_table.clicks_per_usec) - 1; where I can define Cpu_table.clicks_per_usec in bspstart.c to 122 (clicks_per_usec). That would lead to a PIT reload value of 10000/122 - 1 = 81 to reach a 10ms "tick" period.
* Patch from Emmanuel Raguet <raguet@crf.canon.fr>:Joel Sherrill1999-04-281-1/+3
| | | | | | | | | | I have made test with the Dec21140 driver and it appears that all works fine even if the cache is enabled for the memory space in which the incoming and outcoming Ethernet frames are stored. I have had #ifdef to "comment" the code. If you want to disable cache, you only have to #define the name. It could be mandatory for some BSPs.
* Patch from Eric Norum <eric@cls.usask.ca> to corrent a miscount in lengthJoel Sherrill1999-04-271-1/+1
| | | | that results in an error in parsing network unit names/numbers.
* New BSP from Tony R. Ambardar <tonya@ece.ubc.ca> from theJoel Sherrill1999-04-2348-0/+5933
| | | | | | | | University of British Columbia. The BSP is for: Yes, this is the "entry model" of a series of boards from Technologic Systems. Costs <$200 I believe. They have a WWW page at www.t-systems.com. I am letting them know about the availability of this BSP too.
* Added lstat().Joel Sherrill1999-04-223-7/+40
|
* Changed ioctl() prototype to be more like Linux/POSIX than BSD to easeJoel Sherrill1999-04-192-2/+2
| | | | porting of ACE to RTEMS.
* Regenerated.Joel Sherrill1999-04-196-60/+72
|
* Direct .gcc_exc section to ram to eliminate the warning Ralf Corsepius isJoel Sherrill1999-04-191-1/+1
| | | | seeing.
* After discussion with Eric Norum <eric@skatter.usask.ca>,Joel Sherrill1999-04-199-16/+30
| | | | | I added __INSIDE_RTEMS_BSD_TCPIP_STACK__ that trips all the needed macro definitions for a network driver.
* Patch from Erik Ivanenko <erik.ivanenko@utoronto.ca> to eliminate aJoel Sherrill1999-04-191-1/+2
| | | | warning.
* New files.Joel Sherrill1999-04-192-0/+128
|
* Patch from Ralf Corsepius <corsepiu@faw.uni-ulm.de> to add scitabs.c toJoel Sherrill1999-04-191-1/+1
| | | | CLEAN_ADDITIONS.
* Patch from Ralf Corsepius <corsepiu@faw.uni-ulm.de>:Joel Sherrill1999-04-19382-387/+387
| | | | | | | | | | | | | | This one is an enhancement to acpolish. It replaces some Makefile variables by others variable in Makefile.ins (tries to use unique name for some variables). It therefore eases parsing Makefile.ins for further automatic Makefile.in conversions in future. To apply: cd <rtems-source-tree> sh <path-to>/rtems-rc-19990407-8.sh ./autogen
* Patch from Ralf Corsepius <corsepiu@faw.uni-ulm.de>:Joel Sherrill1999-04-192-83/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is an attempt to work-around a couple of nasty bugs in librdbg's Makefiles and configuration: Configure and build RTEMS as below: configure --enable-networking --enable-rdbg --target=i386-rtems make RTEMS_BSP=i386ex After a few minutes you will notice that building aborts in librdbg .... Analysis: 1) librdbg is tried to be built, though librdbg is not supported and the required directory hierarchy librdbg/i386/i386ex/ is not existant. The cause for this is incorrect setting of HAS_RDBG in most make/custom/*.cfg files (except pc386.cfg). At the moment all custom/*.cfg files (except pc386.cfg) in general are required to contain HAS_RDBG=no. However, having HAS_NETWORKING=no in most custom/*.cfg files and the toplevel configure script suppress building librdbg for all CPUs except of i386. => The i386ex BSP falls though this scheme and librdbg is tried to be build (CPU=i386 and HAS_NETWORKING=yes). 2) The Makefile.ins below lib/librdbg in general support i386/pc386 only and are not capable to be used for multiple CPUs or BSPs (RPCGEN generates it's target and bsp-specific files into librdbg/, therefore no other CPU or BSP can ever be built afterwards). This problem is hidden until now, because only a single CPU/BSP pair (i386/pc386) is really supported. 3) The Makefile.ins below lib/librdbg can delete source files due to improper handling of source files (make clean removes the *.x files in the source-tree when configuring inside of the source-tree). The patch below tries to work-around these problems for the i386ex and the pc386 BSPs. This work-around is rather fragile (it applies rpcgen -D, I don't know how portable this is) and incomplete (all custom/*.cfg except of pc386.cfg should contain HAS_RDBG=no), nevertheless it should work.
* Fixed some spacing issues.Joel Sherrill1999-04-191-4/+5
|
* Patch from Ralf Corsepius <corsepiu@@faw.uni-ulm.de>:Joel Sherrill1999-04-161-1/+0
| | | | | | | | | | | | | | 2) ./c/src/lib/libbsp/i386/go32/startup > all: ${ARCH} $(SRCS) $(PGM) > $(INSTALL_CHANGE) ${PROJECT_RELEASE}/lib > > This also is very questionable, because it means "install $(PROJECT_RELEASE)/$/lib to the void". I think, removing the INSTALL_CHANGE is the right way to fix it.
* Patch from Ralf Corsepius <corsepiu@faw.uni-ulm.de>:Joel Sherrill1999-04-161-6/+1
| | | | | | | | | | | | | | | | | | | 1) ./c/src/lib/libbsp/i386/i386ex/startup/Makefile.in > preinstall: > $(INSTALL_CHANGE) ${IMPORT_SRC} . > > # ${CP} ${IMPORT_SRC} . > > > This fragment is broken, because IMPORT_SRC is always empty. IMO, the fix would be to remove this fragment or to replace it with test -z "${IMPORT_SRC}" || cp ${IMPORT_SRC} . if an external shell variable IMPORT_SRC shall be supported by this Makefile, which IMO should not be done.
* Corrected to reflect new way of doing mips constructors.Joel Sherrill1999-04-162-12/+94
|
* Added .eh_fram and .gcc_exc sections.Joel Sherrill1999-04-161-0/+11
|
* Added reentrant versions.Joel Sherrill1999-04-152-0/+41
|
* Updated version string.Joel Sherrill1999-04-151-2/+1
|