History log of /dragonfly/sys/kern/link_elf.c (Results 1 – 25 of 47)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# 135d05a5 21-Feb-2023 Aaron LI <aly@aaronly.me>

kernel/linker: Support preloaded modules to use full path as name

Now that the preloaded modules use full paths as their names, so pass
the pathname to preload_delete_name(), and also update it to c

kernel/linker: Support preloaded modules to use full path as name

Now that the preloaded modules use full paths as their names, so pass
the pathname to preload_delete_name(), and also update it to correctly
compare the pathname to module's MODINFO_NAME field.

Meanwhile, do minor style cleanups.

show more ...


Revision tags: v6.4.0, v6.4.0rc1, v6.5.0, v6.2.2, v6.2.1, v6.2.0, v6.3.0, v6.0.1, v6.0.0, v6.0.0rc1, v6.1.0, v5.8.3, v5.8.2, v5.8.1, v5.8.0, v5.9.0, v5.8.0rc1, v5.6.3, v5.6.2, v5.6.1, v5.6.0, v5.6.0rc1, v5.7.0, v5.4.3, v5.4.2, v5.4.1, v5.4.0, v5.5.0, v5.4.0rc1, v5.2.2, v5.2.1, v5.2.0, v5.3.0, v5.2.0rc, v5.0.2, v5.0.1, v5.0.0, v5.0.0rc2, v5.1.0, v5.0.0rc1, v4.8.1, v4.8.0, v4.6.2, v4.9.0, v4.8.0rc, v4.6.1
# 57e09377 07-Aug-2016 Matthew Dillon <dillon@apollo.backplane.com>

kernel - Cleanup gcc warnings

* Cleanup gcc warnings at higher optimization levels. This will allow
us to build kernels -O2 or -O3.


Revision tags: v4.6.0, v4.6.0rc2, v4.6.0rc, v4.7.0, v4.4.3, v4.4.2, v4.4.1, v4.4.0, v4.5.0, v4.4.0rc, v4.2.4, v4.3.1, v4.2.3, v4.2.1, v4.2.0, v4.0.6, v4.3.0, v4.2.0rc, v4.0.5, v4.0.4
# 59b728a7 18-Feb-2015 Sascha Wildner <saw@online.de>

sys/kern: Adjust some function declaration vs. definition mismatches.

All these functions are declared static already, so no functional change.


Revision tags: v4.0.3, v4.0.2
# 90b407c1 29-Nov-2014 Imre Vadasz <imre@vdsz.com>

link_elf: Work around a GCC optimization bug. Fixes ddb stack traces.

Taken-from: FreeBSD r102348


Revision tags: v4.0.1, v4.0.0, v4.0.0rc3, v4.0.0rc2, v4.0.0rc, v4.1.0, v3.8.2, v3.8.1, v3.6.3, v3.8.0, v3.8.0rc2, v3.9.0, v3.8.0rc
# 210e20d7 21-May-2014 Sascha Wildner <saw@online.de>

kernel: Remove some unused code.


Revision tags: v3.6.2, v3.6.1
# 3596743e 14-Jan-2014 Markus Pfeiffer <markus.pfeiffer@morphism.de>

devfs: add passing of file pointer through to dev_dclose


Revision tags: v3.6.0, v3.7.1, v3.6.0rc, v3.7.0, v3.4.3, v3.4.2, v3.4.0, v3.4.1, v3.4.0rc, v3.5.0
# dbefba87 07-Jan-2013 Sascha Wildner <saw@online.de>

kernel: Replace the remaining __amd64__ with __x86_64__ for consistency.


# 77a4bf30 05-Jan-2013 Sascha Wildner <saw@online.de>

kernel: Remove some unused variables in kern/, opencrypto/ and platform/.


Revision tags: v3.2.2, v3.2.1, v3.2.0, v3.3.0
# d8061892 10-Sep-2012 Sascha Wildner <saw@online.de>

kernel: Use NULL instead of 0 for pointers, part 1/x.

Found-with: Coccinelle (http://coccinelle.lip6.fr/)


Revision tags: v3.0.3
# 51295aee 23-May-2012 Sascha Wildner <saw@online.de>

kernel: Remove some bogus casts to the own type.


Revision tags: v3.0.2, v3.0.1, v3.1.0, v3.0.0
# 4090d6ff 03-Jan-2012 Sascha Wildner <saw@online.de>

kernel: Use NULL for pointers.


# 86d7f5d3 26-Nov-2011 John Marino <draco@marino.st>

Initial import of binutils 2.22 on the new vendor branch

Future versions of binutils will also reside on this branch rather
than continuing to create new binutils branches for each new version.


# b12defdc 18-Oct-2011 Matthew Dillon <dillon@apollo.backplane.com>

kernel - Major SMP performance patch / VM system, bus-fault/seg-fault fixes

This is a very large patch which reworks locking in the entire VM subsystem,
concentrated on VM objects and the x86-64 pma

kernel - Major SMP performance patch / VM system, bus-fault/seg-fault fixes

This is a very large patch which reworks locking in the entire VM subsystem,
concentrated on VM objects and the x86-64 pmap code. These fixes remove
nearly all the spin lock contention for non-threaded VM faults and narrows
contention for threaded VM faults to just the threads sharing the pmap.

Multi-socket many-core machines will see a 30-50% improvement in parallel
build performance (tested on a 48-core opteron), depending on how well
the build parallelizes.

As part of this work a long-standing problem on 64-bit systems where programs
would occasionally seg-fault or bus-fault for no reason has been fixed. The
problem was related to races between vm_fault, the vm_object collapse code,
and the vm_map splitting code.

* Most uses of vm_token have been removed. All uses of vm_spin have been
removed. These have been replaced with per-object tokens and per-queue
(vm_page_queues[]) spin locks.

Note in particular that since we still have the page coloring code the
PQ_FREE and PQ_CACHE queues are actually many queues, individually
spin-locked, resulting in very excellent MP page allocation and freeing
performance.

* Reworked vm_page_lookup() and vm_object->rb_memq. All (object,pindex)
lookup operations are now covered by the vm_object hold/drop system,
which utilize pool tokens on vm_objects. Calls now require that the
VM object be held in order to ensure a stable outcome.

Also added vm_page_lookup_busy_wait(), vm_page_lookup_busy_try(),
vm_page_busy_wait(), vm_page_busy_try(), and other API functions
which integrate the PG_BUSY handling.

* Added OBJ_CHAINLOCK. Most vm_object operations are protected by
the vm_object_hold/drop() facility which is token-based. Certain
critical functions which must traverse backing_object chains use
a hard-locking flag and lock almost the entire chain as it is traversed
to prevent races against object deallocation, collapses, and splits.

The last object in the chain (typically a vnode) is NOT locked in
this manner, so concurrent faults which terminate at the same vnode will
still have good performance. This is important e.g. for parallel compiles
which might be running dozens of the same compiler binary concurrently.

* Created a per vm_map token and removed most uses of vmspace_token.

* Removed the mp_lock in sys_execve(). It has not been needed in a while.

* Add kmem_lim_size() which returns approximate available memory (reduced
by available KVM), in megabytes. This is now used to scale up the
slab allocator cache and the pipe buffer caches to reduce unnecessary
global kmem operations.

* Rewrote vm_page_alloc(), various bits in vm/vm_contig.c, the swapcache
scan code, and the pageout scan code. These routines were rewritten
to use the per-queue spin locks.

* Replaced the exponential backoff in the spinlock code with something
a bit less complex and cleaned it up.

* Restructured the IPIQ func/arg1/arg2 array for better cache locality.
Removed the per-queue ip_npoll and replaced it with a per-cpu gd_npoll,
which is used by other cores to determine if they need to issue an
actual hardware IPI or not. This reduces hardware IPI issuance
considerably (and the removal of the decontention code reduced it even
more).

* Temporarily removed the lwkt thread fairq code and disabled a number of
features. These will be worked back in once we track down some of the
remaining performance issues.

Temproarily removed the lwkt thread resequencer for tokens for the same
reason. This might wind up being permanent.

Added splz_check()s in a few critical places.

* Increased the number of pool tokens from 1024 to 4001 and went to a
prime-number mod algorithm to reduce overlaps.

* Removed the token decontention code. This was a bit of an eyesore and
while it did its job when we had global locks it just gets in the way now
that most of the global locks are gone.

Replaced the decontention code with a fall back which acquires the
tokens in sorted order, to guarantee that deadlocks will always be
resolved eventually in the scheduler.

* Introduced a simplified spin-for-a-little-while function
_lwkt_trytoken_spin() that the token code now uses rather than giving
up immediately.

* The vfs_bio subsystem no longer uses vm_token and now uses the
vm_object_hold/drop API for buffer cache operations, resulting
in very good concurrency.

* Gave the vnode its own spinlock instead of sharing vp->v_lock.lk_spinlock,
which fixes a deadlock.

* Adjusted all platform pamp.c's to handle the new main kernel APIs. The
i386 pmap.c is still a bit out of date but should be compatible.

* Completely rewrote very large chunks of the x86-64 pmap.c code. The
critical path no longer needs pmap_spin but pmap_spin itself is still
used heavily, particularin the pv_entry handling code.

A per-pmap token and per-pmap object are now used to serialize pmamp
access and vm_page lookup operations when needed.

The x86-64 pmap.c code now uses only vm_page->crit_count instead of
both crit_count and hold_count, which fixes races against other parts of
the kernel uses vm_page_hold().

_pmap_allocpte() mechanics have been completely rewritten to remove
potential races. Much of pmap_enter() and pmap_enter_quick() has also
been rewritten.

Many other changes.

* The following subsystems (and probably more) no longer use the vm_token
or vmobj_token in critical paths:

x The swap_pager now uses the vm_object_hold/drop API instead of vm_token.

x mmap() and vm_map/vm_mmap in general now use the vm_object_hold/drop API
instead of vm_token.

x vnode_pager

x zalloc

x vm_page handling

x vfs_bio

x umtx system calls

x vm_fault and friends

* Minor fixes to fill_kinfo_proc() to deal with process scan panics (ps)
revealed by recent global lock removals.

* lockmgr() locks no longer support LK_NOSPINWAIT. Spin locks are
unconditionally acquired.

* Replaced netif/e1000's spinlocks with lockmgr locks. The spinlocks
were not appropriate owing to the large context they were covering.

* Misc atomic ops added

show more ...


Revision tags: v2.12.0, v2.13.0, v2.10.1, v2.11.0, v2.10.0, v2.9.1, v2.8.2, v2.8.1, v2.8.0, v2.9.0, v2.6.3, v2.7.3, v2.6.2, v2.7.2, v2.7.1, v2.6.1, v2.7.0, v2.6.0, v2.5.1, v2.4.1, v2.5.0, v2.4.0
# 1c0e3286 03-Sep-2009 Simon Schubert <corecode@dragonflybsd.org>

modules: pull in most of FreeBSD's module linker changes

The big user-visible difference is that the module dependency
system changed. Module dependencies are now the same as for
the loader, and th

modules: pull in most of FreeBSD's module linker changes

The big user-visible difference is that the module dependency
system changed. Module dependencies are now the same as for
the loader, and the hack linker (and Makefile) magic is not
needed anymore.

Obtained-from: FreeBSD

show more ...


# b8fb634a 04-Aug-2009 Matthew Dillon <dillon@apollo.backplane.com>

kernel module loader - fix load dependencies from preload modules by kernel

The boot loader is supposed to load module dependencies but it misses
a few when e.g. 'snd_hda' is specified in loader.con

kernel module loader - fix load dependencies from preload modules by kernel

The boot loader is supposed to load module dependencies but it misses
a few when e.g. 'snd_hda' is specified in loader.conf. This resulted
in the kernel itself trying to load the missing dependencies, but the
kernel was running the sysinits for those dependencies immediately during
the preload stage instead of registering them.

Pass a flag to the loader chain to register the sysinits instead of
running them if a dependency is loaded during the preload stage. This
fixes the problem. And also, by the way, the loader does not need to
load dependencies any more (though it still does).

Reported-by: corecode, swildner

show more ...


Revision tags: v2.3.2, v2.3.1, v2.2.1, v2.2.0, v2.3.0, v2.1.1, v2.0.1
# d5fc85d0 01-Aug-2008 Matthew Dillon <dillon@dragonflybsd.org>

AMD64 work:

* Sync elf64.h w/ Jordan's work + FreeBSD to get proper elf hash types

* Use proper elf types for symbol lookups


# addd2777 06-Feb-2008 Nicolas Thery <nth@dragonflybsd.org>

linker_file_add_dependancy() never fails so change its return type to void and
simplify calling sequences.


# 4c6a3739 05-Jan-2008 Nicolas Thery <nth@dragonflybsd.org>

kmalloc(M_WAITOK) never returns NULL.


# ba39e2e0 30-Apr-2007 Matthew Dillon <dillon@dragonflybsd.org>

Revamp SYSINIT ordering. Relabel sysinit IDs (SI_* in sys/kernel.h) to
make them less confusing, particularly with regard to the relative order
init routines are called in.

Reorder many sysinits.

Revamp SYSINIT ordering. Relabel sysinit IDs (SI_* in sys/kernel.h) to
make them less confusing, particularly with regard to the relative order
init routines are called in.

Reorder many sysinits. Reorder the SMP and CLOCK code to bring all the
cpus up far earlier in the boot sequence and to make the full threading and
clocking subsystems available for device config.

show more ...


# e4846942 28-Dec-2006 Matthew Dillon <dillon@dragonflybsd.org>

Make kernel_map, buffer_map, clean_map, exec_map, and pager_map direct
structural declarations instead of pointers. Clean up all related code,
in particular kmem_suballoc().

Remove the offset calcu

Make kernel_map, buffer_map, clean_map, exec_map, and pager_map direct
structural declarations instead of pointers. Clean up all related code,
in particular kmem_suballoc().

Remove the offset calculation for kernel_object. kernel_object's page
indices used to be relative to the start of kernel virtual memory in order
to improve the performance of VM page scanning algorithms. The optimization
is no longer needed now that VM objects use Red-Black trees. Removal of
the offset simplifies a number of calculations and makes the code more
readable.

show more ...


# 6ea70f76 23-Dec-2006 Sascha Wildner <swildner@dragonflybsd.org>

Rename printf -> kprintf in sys/ and add some defines where necessary
(files which are used in userland, too).


# f8c7a42d 20-Dec-2006 Matthew Dillon <dillon@dragonflybsd.org>

Rename sprintf -> ksprintf
Rename snprintf -> knsprintf

Make allowances for source files that are compiled for both userland and
the kernel.


# 1b874851 11-Sep-2006 Matthew Dillon <dillon@dragonflybsd.org>

Move flag(s) representing the type of vm_map_entry into its own vm_maptype_t
type. This is a precursor to adding a new VM mapping type for virtualized
page tables.


# efda3bd0 05-Sep-2006 Matthew Dillon <dillon@dragonflybsd.org>

Rename malloc->kmalloc, free->kfree, and realloc->krealloc. Pass 1


# a11aaa81 12-Aug-2006 Matthew Dillon <dillon@dragonflybsd.org>

VNode sequencing and locking - part 3/4.

VNode aliasing is handled by the namecache (aka nullfs), so there is no
longer a need to have VOP_LOCK, VOP_UNLOCK, or VOP_ISSLOCKED as 'VOP'
functions. Bot

VNode sequencing and locking - part 3/4.

VNode aliasing is handled by the namecache (aka nullfs), so there is no
longer a need to have VOP_LOCK, VOP_UNLOCK, or VOP_ISSLOCKED as 'VOP'
functions. Both NFS and DEADFS have been using standard locking functions
for some time and are no longer special cases. Replace all uses with
native calls to vn_lock, vn_unlock, and vn_islocked.

We can't have these as VOP functions anyhow because of the introduction of
the new SYSLINK transport layer, since vnode locks are primarily used to
protect the local vnode structure itself.

show more ...


12