summaryrefslogtreecommitdiffstats
path: root/lib/libstand
Commit message (Collapse)AuthorAgeFilesLines
* o Merge <machine/ansi.h> and <machine/types.h> into a new headermike2002-08-211-2/+2
| | | | | | | | | | | | | | | | | | | | | called <machine/_types.h>. o <machine/ansi.h> will continue to live so it can define MD clock macros, which are only MD because of gratuitous differences between architectures. o Change all headers to make use of this. This mainly involves changing: #ifdef _BSD_FOO_T_ typedef _BSD_FOO_T_ foo_t; #undef _BSD_FOO_T_ #endif to: #ifndef _FOO_T_DECLARED typedef __foo_t foo_t; #define _FOO_T_DECLARED #endif Concept by: bde Reviewed by: jake, obrien
* Fix a typo in #if 0 codescottl2002-08-211-1/+1
|
* Stash various networking paramters in the environment for the kerneljake2002-07-311-1/+15
| | | | to pick up, ala pxe.
* Reimplement malloc/free debugging that includes the offending file:linepeter2002-07-205-40/+73
| | | | | | | | | | | | info. This turned out to be rather useful on ia64 for tracking down malloc/free problems. Detect duplicate free()'s - otherwise these show up as a guard1 failure and it looks like corruption instead of something simple like a second free() where there shouldn't be. Deal with libz using libc headers and not seeing the malloc/free stuff that we provide in libstand. Do similar nastiness to what is done for bzlib. Tested on: i386, ia64 (compile, run)
* Add __printflike() to printf() and sprintf() prototypes. -ffreestandingpeter2002-07-201-2/+2
| | | | | turns off gcc's builtin attributes for these functions and as a result -Wformat does no checking. (argh)
* Add a hack (kludge?) to avoid trying to access files backed by diskjake2002-07-072-0/+8
| | | | devices as though they were backed by network devices.
* Ficl wants _setjmp and _longjmp. No need for weak symbols either.jake2002-07-071-6/+4
|
* To avoid anybody else getting caught out, these two files are reallypeter2002-06-292-278/+0
| | | | in /sys/boot/common and are actually used there.
* Update from NetBSD 1.3 -> 1.6. Most notable, rev 1.6:peter2002-06-291-1/+13
| | | | | | "Make in_cksum work on little endian machines" This would explain a few things. :-)
* This commit adds basic support for the UFS2 filesystem. The UFS2mckusick2002-06-211-95/+90
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | filesystem expands the inode to 256 bytes to make space for 64-bit block pointers. It also adds a file-creation time field, an ability to use jumbo blocks per inode to allow extent like pointer density, and space for extended attributes (up to twice the filesystem block size worth of attributes, e.g., on a 16K filesystem, there is space for 32K of attributes). UFS2 fully supports and runs existing UFS1 filesystems. New filesystems built using newfs can be built in either UFS1 or UFS2 format using the -O option. In this commit UFS1 is the default format, so if you want to build UFS2 format filesystems, you must specify -O 2. This default will be changed to UFS2 when UFS2 proves itself to be stable. In this commit the boot code for reading UFS2 filesystems is not compiled (see /sys/boot/common/ufsread.c) as there is insufficient space in the boot block. Once the size of the boot block is increased, this code can be defined. Things to note: the definition of SBSIZE has changed to SBLOCKSIZE. The header file <ufs/ufs/dinode.h> must be included before <ufs/ffs/fs.h> so as to get the definitions of ufs2_daddr_t and ufs_lbn_t. Still TODO: Verify that the first level bootstraps work for all the architectures. Convert the utility ffsinfo to understand UFS2 and test growfs. Add support for the extended attribute storage. Update soft updates to ensure integrity of extended attribute storage. Switch the current extended attribute interfaces to use the extended attribute storage. Add the extent like functionality (framework is there, but is currently never used). Sponsored by: DARPA & NAI Labs. Reviewed by: Poul-Henning Kamp <phk@freebsd.org>
* Correct bswap64() prototype.sobomax2002-06-031-1/+1
| | | | | | Submitted by: glewis MFC after: 1 day (assuming that there is re's approval)
* Remove a URL from the middle of the BSD copyright (a clicko? a pasto?).schweikh2002-06-021-4/+4
| | | | | | | | | Fix typos: s/evironment/environment s/cont/const s/_lonjmp/_longjmp MFC after: 3 weeks
* Use an explicitly-sized type instead of daddr_t for on-disk blockiedowse2002-05-191-2/+2
| | | | numbers.
* UFS indirect blocks are size u_int32_t, not daddr_tphk2002-05-181-2/+2
|
* Add __divdi3() and __moddi3() to libstand. We will need them for UFS2.phk2002-05-131-0/+48
| | | | Sponsored by: DARPA & NAI Labs.
* #include <sys/disklabel.h> to get BBSIZE.phk2002-05-121-0/+1
|
* Added new bsd.incs.mk which handles installing of header filesru2002-05-121-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | via INCS. Implemented INCSLINKS (equivalent to SYMLINKS) to handle symlinking include files. Allow for multiple groups of include files to be installed, with the powerful INCSGROUPS knob. Documentation to follow. Added standard `includes' and `incsinstall' targets, use them in Makefile.inc1. Headers from the following makefiles were not installed before (during `includes' in Makefile.inc1): kerberos5/lib/libtelnet/Makefile lib/libbz2/Makefile lib/libdevinfo/Makefile lib/libform/Makefile lib/libisc/Makefile lib/libmenu/Makefile lib/libmilter/Makefile lib/libpanel/Makefile Replaced all `beforeinstall' targets for installing includes with the INCS stuff. Renamed INCDIR to INCSDIR, for consistency with FILES and SCRIPTS, and for compatibility with NetBSD. Similarly for INCOWN, INCGRP, and INCMODE. Consistently use INCLUDEDIR instead of /usr/include. gnu/lib/libstdc++/Makefile and gnu/lib/libsupc++/Makefile changes were only lightly tested due to the missing contrib/libstdc++-v3. I fully tested the pre-WIP_GCC31 version of this patch with the contrib/libstdc++.295 stuff. These changes have been tested on i386 with the -DNO_WERROR "make world" and "make release".
* libstand needs _setjmp/_longjmp for FICL.obrien2002-04-131-0/+100
| | | | Submitted by: jake
* Use -ffreestanding. It is REQUIRED by GCC 3.1 on all architectures.obrien2002-04-091-2/+2
| | | | | | | I don't like putting this very-GCC centric option here; but no one as given a better idea of handling it. Reviewed by: jhb
* Break the sparc64 build. I expect those that complained about this commitobrien2002-04-091-2/+0
| | | | to fix the sparc64 case to their liking.
* sparc64 grew _setjmp/_longjmp.obrien2002-04-081-2/+0
|
* Use -ffreestanding.obrien2002-04-081-3/+1
|
* Remove __P() usage.obrien2002-03-211-5/+5
|
* Remove 'register' keyword.obrien2002-03-2121-167/+167
|
* Kill debugging printf() slipped into my last commit.sobomax2002-03-211-1/+0
| | | | | Noticed by: jhb Hall of shame entry: sobomax
* Add -ffreestanding to CFLAGS for ia64. This should probably be globalpeter2002-03-191-0/+2
| | | | like on the kernel.
* Add splitfs vfs layer into libstand, which allows loading big kernels andsobomax2002-03-176-3/+292
| | | | | | | | | | | | | | | | | | | | | | modules split across several physical medias. Following is how it works: The splitfs code, when asked to open "foo" looks for a file "foo.split" which is a text file containing a list of filenames and media names, e.g. foo.aa "Kernel floppy 1" foo.ab "Kernel floppy 2" foo.ac "Kernel and modules floppy" For each file segment, the process is: - try to open the file - prompt "Insert the disk labelled <whatever> and press any key..." - try to open the file - return error if file could not be located RE team is free to use this feature in the upcoming 5.0-DP1. Reviewed by: msmith, dcs
* o Don't require long long support in bswap64() functions.mike2002-03-091-5/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | o In i386's <machine/endian.h>, macros have some advantages over inlines, so change some inlines to macros. o In i386's <machine/endian.h>, ungarbage collect word_swap_int() (previously __uint16_swap_uint32), it has some uses on i386's with PDP endianness. Submitted by: bde o Move a comment up in <machine/endian.h> that was accidentially moved down a few revisions ago. o Reenable userland's use of optimized inline-asm versions of byteorder(3) functions. o Fix ordering of prototypes vs. redefinition of byteorder(3) functions, so that the non-GCC (libc asm) case has proper prototypes. o Add proper prototypes for byteorder(3) functions in <sys/param.h>. o Prevent redundant duplicate prototypes by making use of the _BYTEORDER_PROTOTYPED define. o Move the bswap16(), bswap32(), bswap64() C functions into MD space for platforms in which asm versions don't exist. This significantly reduces the complexity of some things at the cost of duplicate code. Reviewed by: bde
* Add the following functions/macros to support byte order conversions andtmm2002-02-271-6/+4
| | | | | | | | | | | | | | | | | | | | | | | | device drivers for bus system with other endinesses than the CPU (using interfaces compatible to NetBSD): - bwap16() and bswap32(). These have optimized implementations on some architectures; for those that don't, there exist generic implementations. - macros to convert from a certain byte order to host byte order and vice versa, using a naming scheme like le16toh(), htole16(). These are implemented using the bswap functions. - stream bus space access functions, which do not perform a byte order conversion (while the normal access functions would if the bus endianess differs from the CPU endianess). htons(), htonl(), ntohs() and ntohl() are implemented using the new functions above for kernel usage. None of the above interfaces is currently exported to user land. Make use of the new functions in a few places where local implementations of the same functionality existed. Reviewed by: mike, bde Tested on alpha by: mike
* o Move NTOHL() and associated macros into <sys/param.h>. These aremike2002-02-182-1/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | deprecated in favor of the POSIX-defined lowercase variants. o Change all occurrences of NTOHL() and associated marcros in the source tree to use the lowercase function variants. o Add missing license bits to sparc64's <machine/endian.h>. Approved by: jake o Clean up <machine/endian.h> files. o Remove unused __uint16_swap_uint32() from i386's <machine/endian.h>. o Remove prototypes for non-existent bswapXX() functions. o Include <machine/endian.h> in <arpa/inet.h> to define the POSIX-required ntohl() family of functions. o Do similar things to expose the ntohl() family in libstand, <netinet/in.h>, and <sys/param.h>. o Prepend underscores to the ntohl() family to help deal with complexities associated with having MD (asm and inline) versions, and having to prevent exposure of these functions in other headers that happen to make use of endian-specific defines. o Create weak aliases to the canonical function name to help deal with third-party software forgetting to include an appropriate header. o Remove some now unneeded pollution from <sys/types.h>. o Add missing <arpa/inet.h> includes in userland. Tested on: alpha, i386 Reviewed by: bde, jake, tmm
* Fixed world breakage in previous commit. The generated headers are inbde2002-02-021-1/+1
| | | | the current directory which is rarely ${.CURDIR}.
* Complete bzip2-1.0.2 import.sobomax2002-02-015-15/+58
| | | | MFC in: 14 days
* We support writing to at least one filesystem now.jhb2001-12-111-1/+1
| | | | | | PR: kern/32389 Submitted by: Jonathan Mini <mini@haikugeek.com> Sponsored by: ClickArray, Inc.
* Add support for overwriting the existing contents of a file to the UFSjhb2001-12-111-4/+119
| | | | | | | | | driver in libstand. This specifically does not expand or truncate files since the filesystem may be dirty or inconsistent. PR: kern/32389 Submitted by: Jonathan Mini <mini@haikugeek.com> Sponsored by: ClickArray, Inc.
* Back out my 'fix', resid is different for strategy than for writealfred2001-11-301-2/+2
|
* Make the same fix for writes to RAW objects.alfred2001-11-301-2/+2
|
* write should return the number of bytes written, not 0 on success.alfred2001-11-301-1/+1
| | | | | Submitted by: Jonathan Mini <mini@haikugeek.com> PR: kern/32350
* - Change the f_isdir field of struct file to be a flags field and twojhb2001-11-061-13/+54
| | | | | | | | | new flags: F_ROOTDIR and F_RR (Rock Ridge present). - Cache the SUSP LEN_SKP parameter in struct file as well. - If we open() '/', then force a read of the directory's contents so we can examine the directory record of '.' to see if Rock Ridge is present. - If Rock Ridge extensions are present, lookup Rock Ridge names in readdir().
* - Add a simple SUSP parser.jhb2001-11-061-8/+154
| | | | | - Use the SUSP parser to detect Rock Ridge (RRIP) extensions and to look up alternate names when opening files.
* Switch to using ANSI function declarations and add missing functionjhb2001-11-061-31/+15
| | | | | prototypes. I'm tired of getting stupid bugs from changing function parameters and not getting warnings from the compiler when I goof it up.
* Make the output from assert() look more like the example in the C99mike2001-10-291-4/+4
| | | | | | standard. Requested by: bde
* Only provide function information in compile environments that supportmike2001-10-271-4/+7
| | | | | | | the C99 variable __func__ and never for C++. Provide a more meaningful example in the assert(3) manual. Reviewed by: asmodai, bde
* Remove the -I../libc/${MACHINE_ARCH} that was there solely forpeter2001-10-261-3/+0
| | | | the #include "DEFS.h" that was only used on i386 (which has been fixed).
* Change #include "DEFS.h" to <machine/asm.h>.peter2001-10-251-1/+1
|
* Add __FBSDID.asmodai2001-10-241-3/+5
| | | | | Change __assert() function to print failing function name. This makes us C99 conforming.
* Make this Makefile suitable for sparc64.robert2001-10-151-2/+5
|
* Define the types iaddr_t and saddr_t for sparc64.robert2001-10-151-0/+4
|
* Compensate for "Compensate for header dethreading" by backing it out.bde2001-10-101-2/+0
|
* mdoc(7) police: Use the new .In macro for #include statements.ru2001-10-011-3/+3
|
* mdoc(7) police: markup nits.ru2001-10-011-9/+13
|
OpenPOWER on IntegriCloud