Commit Graph

1314 Commits

Author SHA1 Message Date
dyoung
9943264696 Build and install ppath(3), property-list paths library. 2011-08-26 21:22:07 +00:00
matt
0435f73056 Fix bug when only restoring r31 (lr was not being restored properly). 2011-08-12 14:48:00 +00:00
uwe
89e9839f44 Reword the comment about "millicode" nature of these functions and add
it to sdivsi3_i4i.S too.
2011-08-05 02:00:25 +00:00
uwe
41f19aa9d6 Reword the comment about "millicode" nature of these functions and add
it to sdivsi3.S too.

Remove !_KERNEL code left over from the days when we shared these
files with userland.

Use .L prefix for local label.
2011-08-05 01:59:39 +00:00
uwe
ab79e8db68 For unsignad integer division gcc used to emit a call to __udivsi3
"millicode" function that uses compiler-private ABI.  Newer gcc uses
heavily tuned __udivsi3_i4i that is NOT compatible with __udivsi3
because it's expected to clobber different registers.  We don't want
to link the kernel against libgcc and we don't have resources to write
heavily tuned version ourselves, so clone __udivsi3 but adjust it to
conform to the __udivsi3_i4i clobber spec.

Ditto for signed division.

You can make gcc use old routines with -mdiv=call-div1 to avoid few
extra instructions to save/restore the right registers in the signed
division funcion.
2011-08-04 03:20:09 +00:00
jakllsch
a6deec34f7 Fix printf formating in ifdef DEBUG sections. 2011-07-30 03:43:20 +00:00
joerg
3eb244d801 Retire varargs.h support. Move machine/stdarg.h logic into MI
sys/stdarg.h and expect compiler to provide proper builtins, defaulting
to the GCC interface. lint still has a special fallback.
Reduce abuse of _BSD_VA_LIST_ by defining __va_list by default and
derive va_list as required by standards.
2011-07-17 20:54:30 +00:00
mrg
b259e2f2c8 revert the _i4i aliases. they are not the right thing. 2011-07-14 09:48:03 +00:00
mrg
2f4b41bf98 add weak aliases for __sdivsi3_i4i and __udivsi3_i4i. 2011-07-06 01:29:54 +00:00
matt
fee0e13d37 If GCC 4.0 or later, use __builtin_offsetof for offsetof.
This make GCC 4.5 with offsetof in mbuf.h and kern_cpu.c
2011-07-05 01:56:45 +00:00
mrg
db6886e029 apply some -O0 with gcc 4.5 and vax. 2011-07-03 15:29:34 +00:00
mrg
80d3d3c382 fix the names of the _END symbols passed to .size; fixes rump issues,
and kernels still work fine, and ofwboot still links.
2011-07-02 23:36:02 +00:00
matt
805a90b602 Add the _restgpr* and _savegpr* entries that GCC 4.5 wants. This file is
designed to support the other GCC 4.5 variants that may be required.
2011-07-02 03:35:03 +00:00
mrg
e405cd7d86 remove HAVE_GCC == 4 conditional 2011-06-20 08:22:43 +00:00
joerg
df3149f5ef Don't use C versions of memcmp, memcpy, memmove, memset and strchr
on x86 for standalone code. The assembler versions are much smaller.
2011-06-16 16:47:53 +00:00
joerg
be964ea63f Add an optional MD calling convention flag for use in libsa when space
optimisation is critical. Use this on i386 to switch to register passing
calling convention for the file system entry points and most assembler
call backs that have to preserve at least 3 registers.
2011-06-16 13:44:56 +00:00
joerg
c97378d081 Add an optional MD calling convention flag for use in libsa when space
optimisation is critical. Use this on i386 to switch to register passing
calling convention for the file system entry points and most assembler
call backs that have to preserve at least 3 registers.
2011-06-16 13:27:58 +00:00
mrg
42abd36401 catch up with the userland copy:
>revision 1.6
>date: 2011/03/23 20:54:35;  author: martin;  state: Exp;  lines: +2 -2
>Avoid using %g7

fixes rump on sparc, at least somewhat.
tested that normal kernels runs fine this with this change, too.
2011-06-13 03:23:53 +00:00
joerg
a216da57a6 Default to -Wno-sign-compare -Wno-pointer-sign for clang.
Push -Wno-array-bounds down to the cases that depend on it.
Selectively disable warnings for 3rd party software or non-trivial
issues to be reviewed later to get clang -Werror to build most of the
tree.
2011-05-26 12:56:24 +00:00
tsutsui
f38f34147b KNF a bit. 2011-05-20 16:33:07 +00:00
nakayama
99c51b3804 Use %zd for ssize_t, and %zu for size_t. 2011-05-13 23:35:09 +00:00
zoltan
b3cd019cf9 Separate the IP and UDP code paths inside libsa, so I can add HTTP booting
later.
2011-05-11 16:23:40 +00:00
bouyer
d9210c2405 Add a new libquota library, which contains some blocks to build and/or
parse quota plists; as well as a getfsquota() function to retrieve quotas
for a single id from a single filesystem (whatever filesystem this is:
a local quota-enabled fs or NFS). This is build on functions getufsquota()
(for local filesystems with UFS-like quotas) and getnfsquota();
which are also available to userland programs.
move functions from quota2_subr.c to libquota or libprop as appropriate,
and ajust in-tree quota tools.
move some declarations from kernel headers to either sys/quota.h or
quota/quota.h as appropriate. ufs/ufs/quota.h still installed because
it's needed by other installed ufs headers.
ufs/ufs/quota1.h still installed as a quick&dirty way to get a code
using the old quotactl() to compile (just include ufs/ufs/quota1.h instead of
ufs/ufs/quota.h - old code won't compile without this change and this is
on purpose).
Discussed on tech-kern@ and tech-net@ (long thread, but not much about
libquota itself ...)
2011-03-24 17:05:39 +00:00
jakllsch
bdf5f7401d Add quad srcs if building x86_64 32-bit libkern. 2011-02-26 18:17:55 +00:00
matt
7fe5f9cb4c Add quad srcs if using MIPS O32 ABI 2011-02-26 16:28:10 +00:00
joerg
eb077f08e0 No trailing 0 byte for hexdigits. 2011-02-25 00:20:36 +00:00
joerg
36ed38c29f Move HEXDIGIT to mvme68k's sboot. It seems to be the only user.
Save a byte by explicitly specifying the size.
2011-02-25 00:17:35 +00:00
matt
7a630fe12e Define CTASSERT in terms of __CTASSERT 2011-02-19 02:02:14 +00:00
christos
392bc55180 revert bad whitespace change. 2011-02-17 21:15:31 +00:00
christos
abd082246f fix -Wself-assign warning 2011-02-17 19:38:48 +00:00
rmind
9b6bd2d968 Remove clause 3 (UCB advertising clause) from the University of Utah
copyright.  Confirmed by Mike Hibler, mike at cs.utah.edu - thanks!
Also, merge UCB and Utah copyright texts back into one, as they
originally were.

Extra verification by snj@.
2011-02-08 20:20:06 +00:00
skrll
f80f065ff5 This file needs opt_multiprocessor.h early so we pick up the right
definition from cpu.h, etc.

XXX should revisit the _STANDALONE vs _KERNEL split
2011-01-31 12:10:58 +00:00
matt
ecfd85d839 Fix KDASSERTMSG defintions for !DEBUG 2011-01-26 01:02:46 +00:00
matt
084c578c30 Add KDASSERTMSG (KDASSERT already exists). 2011-01-24 22:53:07 +00:00
skrll
ed569699ed Fix build. 2011-01-24 15:01:30 +00:00
skrll
024e5c66df Fix MULTIPROCESSOR curlwp/curcpu handling... missed in previous commit. 2011-01-22 10:58:44 +00:00
matt
51db1c5cf3 Kill _NOREGNAMES. Everything should be using %rX now. If it doesn't it
soon will.
2011-01-17 08:23:53 +00:00
matt
19cb1fa295 Don't define _NOREGNAMES since all of libkern is now compiled with it. 2011-01-17 07:07:36 +00:00
matt
156ba6dbc5 Add -D_NOREGNAMES 2011-01-16 03:22:19 +00:00
jakllsch
dc93c72587 Pacify Clang -Wformat-security. 2011-01-06 02:45:13 +00:00
jakllsch
71481e188f Zero the in-memory super block after allocation. It contains a pointer
that, if not properly initialized, could be improperly deallocated.
2011-01-02 21:37:01 +00:00
christos
e5c1816344 fix slightly wrong format. 2010-12-26 23:55:52 +00:00
he
b7a6da19d6 Print size_t and ssize_t with %zd, not just %d.
(How did this build before?)
2010-12-26 17:48:37 +00:00
jakllsch
fbe9cca8ce Correct recently exposed printf format problem. 2010-12-25 01:08:44 +00:00
christos
62010e9c69 panic takes a printf format too. 2010-12-24 23:12:28 +00:00
ws
45d6c7c30c Allow multiple path separators between/after directory names.
Problem found while analyzing PR kern/43963.
2010-10-18 11:08:26 +00:00
jym
b60c232a64 Use standard ELF types for ELF code, instead of paddr_t. paddr_t should
only be used for low level code, like virtual memory internals.
2010-09-16 00:26:49 +00:00
pooka
f3c7386990 Rename jump label to something a little more negative. No, I'm
not doing it for cosmetic value or out of angst.  See, PIC_PROLOGUE
on i386 uses the "1" label internally.  Now, everything would be
fine and dandy for the first 551245 calls to random.  After that
p+q is negative and the jump is taken.  However, it is taken into
the middle of PIC_PROLOGUE instead of where upon superficial
examination we assumed we are jumping.  This causes wrong(tm) things
to happen and "ret" triggers a jump into hyperspace.

(no, I did not see that coming)
2010-09-07 20:35:50 +00:00
christos
e5690d15fe PR/43830: Valery Ushakov: libsa/loadfile_elf32.c loads .shstrtab into
unallocated memory. Don't load if counting.
2010-09-02 17:10:14 +00:00
christos
bd0a22e5e8 add a LOAD_BACKWARDS flag on sections that might load backwards. 2010-08-25 16:30:01 +00:00