History log of /openbsd/sys/arch/sparc64/sparc64/machdep.c (Results 1 – 25 of 218)
Revision Date Author Comments
# 28d09237 22-May-2024 jsg <jsg@openbsd.org>

remove prototypes with no matching function and externs with no var


# 3b372c34 14-May-2024 jsg <jsg@openbsd.org>

remove prototypes with no matching function


# 8a1e8cca 29-Mar-2024 miod <miod@openbsd.org>

Drop the first argument of intr_establish().

Instead, require all callers to put the right value in the ih_pil field, and
have intr_establish() trust them rather than assigning this field again from

Drop the first argument of intr_establish().

Instead, require all callers to put the right value in the ih_pil field, and
have intr_establish() trust them rather than assigning this field again from
its first argument.

ok claudio@ kettenis@

show more ...


# 8ad6162f 29-Mar-2024 miod <miod@openbsd.org>

Store the physical address of each pcb in struct mdproc, and use this in
order to speed up window spills, rather than doing an inline pmap_extract
(well, pseg_get).

ok claudio@ kettenis@


# f635dc10 29-Mar-2024 miod <miod@openbsd.org>

Remove truly unneeded includes (not included indirectly).

ok claudio@ kettenis@


# f75609fc 29-Mar-2024 miod <miod@openbsd.org>

Update/fix/remove obsolete or just plainly wrong comments.

ok claudio@ kettenis@


# c44cb43b 29-Mar-2024 miod <miod@openbsd.org>

Clean-up cache-related definitions and routines.

ok claudio@ kettenis@


# bec25f42 29-Mar-2024 miod <miod@openbsd.org>

Comment out unused routines. They might become used in the future, so they
are better not moved to the Attic yet.

ok claudio@ kettenis@


# e78c98cb 29-Mar-2024 miod <miod@openbsd.org>

Remove dead defines, prototypes and data, and duplicate or misleading comments.

ok claudio@ kettenis@


# deb7b0be 07-Mar-2024 claudio <claudio@openbsd.org>

In _bus_dmamap_load_mbuf() ensure that for large mbuf m_len values
the incr value is rounded to the page boundary. This can happen when
m_defrag() packs a TSO packet into one big mbuf cluster.

Also

In _bus_dmamap_load_mbuf() ensure that for large mbuf m_len values
the incr value is rounded to the page boundary. This can happen when
m_defrag() packs a TSO packet into one big mbuf cluster.

Also fix _bus_dmamap_load_uio() which has the same min(buflen, NBPG); logic.
bus_dmamap_load_uio() is unsued and will be removed after unlock.
OK miod@ bluhm@ kettenis@

show more ...


# 406b1ab8 10-Feb-2024 jsg <jsg@openbsd.org>

fix off-by-one when printing fr_arg

found by "buffer overflow 'fp64->fr_arg' 6 <= 6" smatch error
ok miod@ claudio@


# 5b133f3f 08-Mar-2023 guenther <guenther@openbsd.org>

Delete obsolete /* ARGSUSED */ lint comments.

ok miod@ millert@


# 5b66b1f4 21-Jan-2023 miod <miod@openbsd.org>

Remove dead/unused prototypes


# 1b4a394f 30-Oct-2022 guenther <guenther@openbsd.org>

Simplfity setregs() by passing it the ps_strings and switching
sys_execve() to return EJUSTRETURN.

setregs() is the MD routine used by sys_execve() to set up the
thread's trapframe and PCB such that

Simplfity setregs() by passing it the ps_strings and switching
sys_execve() to return EJUSTRETURN.

setregs() is the MD routine used by sys_execve() to set up the
thread's trapframe and PCB such that, on 'return' to userspace, it
has the register values defined by the ABI and otherwise zero. It
had to set the syscall retval[] values previously because the normal
syscall return path overwrites a couple registers with the retval[]
values. By instead returning EJUSTRETURN that and some complexity
with program-counter handling on m88k and sparc64 goes away.

Also, give setregs() add a 'struct ps_strings *arginfo' argument
so powerpc, powerpc64, and sh can directly get argc/argv/envp
values for registers instead of copyin()ing the one in userspace.

Improvements from miod@ and millert@
Testing assistance miod@, kettenis@, and aoyama@
ok miod@ kettenis@

show more ...


# bd1b8e69 25-Oct-2022 guenther <guenther@openbsd.org>

STACK_OFFSET was to support it varying when compiling some code for
either 32bit or 64bit. With the elimination of 32bit sparc bits
it was just a superfluous indirection of BIAS. Also, CCFSZ is gon

STACK_OFFSET was to support it varying when compiling some code for
either 32bit or 64bit. With the elimination of 32bit sparc bits
it was just a superfluous indirection of BIAS. Also, CCFSZ is gone.

ok miod@

show more ...


# cfac8e34 23-Oct-2022 guenther <guenther@openbsd.org>

Fix a misleading comment

ok miod@ kettenis@


# 1c00236e 21-Oct-2022 miod <miod@openbsd.org>

Remove vestigial bits of 32-bit binaries support; drop the `64' suffix in
struct names when the matching `32' flavour got removed.

Joint work with cheloha@, all bugs mine.


# 47c47fea 16-Oct-2022 jsg <jsg@openbsd.org>

Change function definitions using the identifier-list form used in the
1st edition of Kernighan and Ritchie's The C Programming Language, to
that of the parameter-type-list form described in the ANSI

Change function definitions using the identifier-list form used in the
1st edition of Kernighan and Ritchie's The C Programming Language, to
that of the parameter-type-list form described in the ANSI X3.159-1989
standard.

In ISO/IEC 9899:2023 drafts, there is only one form of function definition.
"N2432 Remove support for function definitions with identifier lists".

ok kettenis@

show more ...


# ba203458 06-Oct-2021 claudio <claudio@openbsd.org>

Change sendsig() interface so that the MD code does not need to access
data from struct process anymore. This changes how siginfo and onstack
are accessed and make sendsig() more MP friendly.
With an

Change sendsig() interface so that the MD code does not need to access
data from struct process anymore. This changes how siginfo and onstack
are accessed and make sendsig() more MP friendly.
With and OK semarie@ OK kettenis@

show more ...


# 1e286331 08-Nov-2020 mpi <mpi@openbsd.org>

In case of failure, call sigexit() from trapsignal instead of sensig().

Simplify MD code and reduce the amount of recursion into the signal code
which helps when dealing with locks.

ok cheloha@, de

In case of failure, call sigexit() from trapsignal instead of sensig().

Simplify MD code and reduce the amount of recursion into the signal code
which helps when dealing with locks.

ok cheloha@, deraadt@

show more ...


# 1d9e937e 23-Jun-2020 jmatthew <jmatthew@openbsd.org>

Implement pci_intr_establish_cpu() for pyro(4) and vpci(4) based sparc64
systems. MSIs on these systems are delivered to event queues, which
trigger interrupts when non-empty. The interrupt handler

Implement pci_intr_establish_cpu() for pyro(4) and vpci(4) based sparc64
systems. MSIs on these systems are delivered to event queues, which
trigger interrupts when non-empty. The interrupt handler dequeues the
MSIs and converts them into soft interrupts, which run on the same cpu
as the event queue interrupt.

To target pci device interrupts to different cpus, we set up an event
queue per cpu in the system, or as many as we can, if there are fewer
event queues available. For now, we don't have a way to feed this
information back to intrmap, so instead we just map interrupts for cpus
that don't have an event queue to another cpu that does have one.

Tested on V215 (pyro), T5120, T4-1, S7-2 (vpci).
dlg@ got the pyro side of it working for me.
ok dlg@ kettenis@

show more ...


# 4f1155a8 05-Jun-2020 naddy <naddy@openbsd.org>

Implement cpu_rnd_messybits() as a read of the cycle counter register.

ok dlg@, powerpc/sparc64 ok kettenis@, sparc64/alpha tested by deraadt@


# 01802d2c 31-May-2020 dlg <dlg@openbsd.org>

introduce "cpu_rnd_messybits" for use instead of nanotime in dev/rnd.c.

rnd.c uses nanotime to get access to some bits that change quickly
between events that it can mix into the entropy pool. it do

introduce "cpu_rnd_messybits" for use instead of nanotime in dev/rnd.c.

rnd.c uses nanotime to get access to some bits that change quickly
between events that it can mix into the entropy pool. it doesn't
use nanotime to get a monotonically increasing set or ordered and
accurate timestamps, it just wants something with bits that change.

there's been discussions for years about letting rnd use a clock
that's super fast to read, but not necessarily accurate, but it
wasn't until recently that i figured out it wasn't interested in
time at all, so things like keeping a fast clock coherent between
cpu cores or correct according to ntp is unecessary. this means we
can just let rnd read the cycle counters on cpus and things will
be fine. cpus with cycle counters that vary in their speed and
arent kept consistent between cores may even be desirable in this
context.

so this is the first step in converting rnd.c to reading cycle
counter. it copies the nanotime backend to each arch, and they can
replace it with something MD as a second step later on.

djm@ suggested rnd_messybytes, but we landed on cpu_rnd_messybits.
thanks to visa for his eyes.
ok deraadt@ visa@
deraadt@ says he will help handle any MD fallout that occurs.

show more ...


# c8f27247 29-May-2020 deraadt <deraadt@openbsd.org>

dev/rndvar.h no longer has statistical interfaces (removed during various
conversion steps). it only contains kernel prototypes for 4 interfaces,
all of which legitimately belong in sys/systm.h, whi

dev/rndvar.h no longer has statistical interfaces (removed during various
conversion steps). it only contains kernel prototypes for 4 interfaces,
all of which legitimately belong in sys/systm.h, which are already included
by all enqueue_randomness() users.

show more ...


# 5fcf2a4b 16-May-2020 kettenis <kettenis@openbsd.org>

Make inittodr() and resettodr() MI.

ok deraadt@, mpi@, visa@
ok cheloha@ as well (would have preferred in new file for this code)


123456789