CVS: cvs.openbsd.org: src

2024-06-05 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/06/05 13:22:04

Modified files:
sys/arch/m88k/m88k: eh_common.S vm_machdep.c 

Log message:
Pass cpu_fork() function to the new process through caller-saved registers
in the pcb rather than on the stack. This makes the code simpler and faster
and gets rid of one short timeframe where the stack pointer is only aligned
to an 8 byte boundary instead of a 16 byte boundary.



CVS: cvs.openbsd.org: src

2024-05-24 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/05/24 10:44:12

Modified files:
gnu/usr.bin/gcc/gcc: Makefile.in 

Log message:
Remove target getting in the way of config.status and causing compilation
failure when using make -j; this used to be hidden because of the objective-C
generated files, which are no longer built. No change for regular make.



CVS: cvs.openbsd.org: src

2024-05-22 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/05/22 05:49:36

Modified files:
usr.bin/ssh: Makefile.inc 

Log message:
Do not pass -Werror if building with gcc 3, for asn1.h and bio.h cause
(admittedly bogus) warnings with gcc 3.



CVS: cvs.openbsd.org: src

2024-05-17 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/05/17 14:11:58

Modified files:
sys/dev/wscons : wsmouse.c 

Log message:
Make sure `row' is not used uninitialized in wsmouse_matching().



CVS: cvs.openbsd.org: src

2024-05-17 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/05/17 14:07:33

Modified files:
sys/arch/alpha/include: intr.h 

Log message:
Cast alpha_pal_swpipl return value to int in splx, to make sure both sides
of the ternary operator have the same type. NFC



CVS: cvs.openbsd.org: src

2024-05-17 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/05/17 14:05:08

Modified files:
sys/arch/sparc64/include: autoconf.h 
sys/arch/sparc64/sparc64: autoconf.c 

Log message:
Constify the first argument of getdevunit(). NFCI



CVS: cvs.openbsd.org: src

2024-05-17 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/05/17 14:03:13

Modified files:
sys/dev/sbus   : esp_sbus.c 

Log message:
Update comments to match reality.



CVS: cvs.openbsd.org: src

2024-04-30 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/30 11:06:00

Modified files:
sys/nfs: nfsproto.h 

Log message:
Make nfstov_mode() return mode_t rather than uint16_t.
This is a no-op since we only care about the low 12 bits in NFS anyway.

ok jsg@ semarie@



CVS: cvs.openbsd.org: src

2024-04-30 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/30 11:05:20

Modified files:
sys/nfs: nfs_serv.c nfs_socket.c nfs_srvcache.c 
 nfs_subs.c nfs_syscalls.c nfs_vnops.c 

Log message:
Constify NFS data whenever possible. Also make a few more const data static.

ok jsg@ semarie@



CVS: cvs.openbsd.org: src

2024-04-30 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/30 11:04:23

Modified files:
sys/nfs: nfs_serv.c nfs_socket.c nfs_subs.c nfs_var.h 
 nfs_vfsops.c nfs_vnops.c nfsm_subs.h nfsnode.h 

Log message:
Convert all the NFS macros (in nfsm_subs.h) into inline functions with the
appropriate extra arguments.

This (hopefully) completes the unmessyfication work started by thib@ a long,
long time ago (in a galaxy far away).

The conversion logic has been:
- nfsm_dissect has been turned into an rvalue expression, leaving the
cast operation up to its caller.
- macros which had three different exit paths (return, goto nfsmout or
fallthrough) have been split so that no macros have more than two exit paths.
- then they have been modified to return a value, which lets the caller
figure out what exit path is needed.
- local variables abused by the macros are now local variables of the new
inline functions.

This single commit is the sum of 25 intermediate diffs, which have all been
carefully reviewed by (at least) jsg@ and semarie@.

Tested with v2 and v3 servers and clients.

ok jsg@ semarie@



CVS: cvs.openbsd.org: src

2024-04-30 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/30 10:54:47

Modified files:
sys/nfs: nfs_bio.c 

Log message:
Do not cast off_t to u_long in uvm_vnp_setsize call (only misbehaves on 32-bit
platforms.)

ok mpi@



CVS: cvs.openbsd.org: src

2024-04-24 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/24 23:23:45

Modified files:
sys/arch/sparc64/conf: Makefile.sparc64 

Log message:
Use -mno-fpu when compiling with clang now that the in-tree clang supports
this option; from Brad.



CVS: cvs.openbsd.org: src

2024-04-14 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/14 13:08:09

Modified files:
sys/arch/sparc64/include: pte.h 
sys/arch/sparc64/sparc64: autoconf.c ipifuncs.c locore.s 

Log message:
Turn sp_tlb_flush_{ctx,pte} into function pointers, and pick one out of three
flavours: pre-usIII, usIII, and sun4v.

This allows us to get rid of the HORRID_III_HACK define in locore and switch
pre-usIII systems to the older, slightly simpler, code for these routines.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-04-11 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/11 12:58:45

Modified files:
lib/libkvm : kvm_sparc64.c 
sys/arch/sparc64/include: pmap.h 
sys/arch/sparc64/sparc64: db_interface.c genassym.cf ipifuncs.c 
  pmap.c 

Log message:
Stop making  include , and fix the very few
files which really need  guts.



CVS: cvs.openbsd.org: src

2024-04-10 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/10 13:43:16

Modified files:
gnu/usr.bin/binutils-2.17/bfd: elf.c 

Log message:
When rewriting an ELF header (i.e. in strip and objcopy), keep the
.openbsd.syscalls section with the PT_OPENBSD_SYSCALLS phdr, even though is
does not have the ALLOC flag; otherwise the phdr gets rewritten with a size
of zero, which prevents the binary from working.

ok kettenis@



CVS: cvs.openbsd.org: src

2024-04-10 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/10 13:39:23

Modified files:
distrib/alpha/miniroot: Tag: OPENBSD_7_5 Makefile 

Log message:
OpenBSD 7.5 Errata 002:
Install media for alpha architecture was broken due to strip(1) bug.

ok deraadt@



CVS: cvs.openbsd.org: src

2024-04-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/08 14:09:18

Modified files:
sys/arch/sparc64/sparc64: locore.s 

Log message:
Stop redeclaring ENTRY, the  flavour is as good as we need it.
While there, replace inlined NENTRY by actual use of that macro.

ok kettenis@



CVS: cvs.openbsd.org: src

2024-04-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/08 14:08:19

Modified files:
sys/arch/sparc64/sparc64: locore.s 

Log message:
Fix misplaced END() macro.

ok kettenis@



CVS: cvs.openbsd.org: src

2024-04-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/08 14:07:53

Modified files:
sys/arch/sparc64/include: frame.h 
sys/arch/sparc64/sparc64: db_trace.c genassym.cf locore.s 

Log message:
Remove unused tf_fault and tf_kstack members from struct trapframe. These
fields were (seldom) written to but never used for anything.

ok kettenis@



CVS: cvs.openbsd.org: src

2024-04-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/08 14:07:07

Modified files:
sys/arch/sparc64/sparc64: locore.s 

Log message:
Remove demap code for MMU miss faults.

This code was #if 0, except for instruction misses where it had been enabled
probably by mistake... and was demapping in the data mmu anyway...
(#include )

ok kettenis@



CVS: cvs.openbsd.org: src

2024-04-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/08 14:05:51

Modified files:
sys/arch/sparc64/sparc64: clock.c locore.s 

Log message:
There is too much #ifdef DEBUG stuff cluttering locore, really. While some of
it had sense in the early days of the sparc64 port, this code has bitrotten
and is getting in the way. Time for a visit to the Attic.

This removes:
- interrupt handling debug code (forcing hz = 1, probably broken since years).
- unused or too invasive DEBUG code which noone will ever use in this state.
- #if 0 code blocks which have been this way since locore.s revision 1.1 and
will never get enabled.

ok kettenis@



CVS: cvs.openbsd.org: src

2024-04-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/08 14:02:18

Modified files:
sys/arch/sparc64/sparc64: locore.s 

Log message:
Introduce more assembler macros to deduplicate code and improve readability:
- one macro for the inline pseg_get logic used in various MMU trap handlers.
- one macro for the TSB locking logic in various PTE update routines.
- one macro for the sun4v rwindow content saving.

ok kettenis@



CVS: cvs.openbsd.org: src

2024-04-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/08 14:00:27

Modified files:
sys/arch/sparc64/include: hypervisor.h 
sys/arch/sparc64/sparc64: hvcall.S ipifuncs.c locore.s pmap.c 

Log message:
Remove dead code and data, fix typos, kill wrong comments.

ok kettenis@



CVS: cvs.openbsd.org: src

2024-04-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/08 13:59:57

Modified files:
sys/arch/sparc64/sparc64: locore.s 

Log message:
Fix cut'n'paste error in data miss handler causing wrong label to be used in
some failure conditions.



CVS: cvs.openbsd.org: src

2024-04-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/08 13:59:28

Modified files:
sys/arch/sparc64/sparc64: autoconf.c 

Log message:
Fix sun4v patching of sp_tlb_flush_ctx() to pass flags in the right register.

ok kettenis@



CVS: cvs.openbsd.org: www

2024-04-04 Thread Miod Vallat
CVSROOT:/cvs
Module name:www
Changes by: m...@cvs.openbsd.org2024/04/04 03:10:58

Modified files:
.  : sparc64.html 

Log message:
Fix bogus cut'n'paste introduced in 1.416



CVS: cvs.openbsd.org: src

2024-04-03 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/03 12:43:32

Modified files:
sys/arch/amd64/amd64: pmap.c 
sys/arch/i386/i386: pmap.c 
sys/uvm: uvm_pmap.h 

Log message:
pmap_virtual_space() and pmap_steal_memory() are mutually exclusive, so
make sure only one of them is prototyped and only one of them is implemented.
ok mpi@ kettenis@



CVS: cvs.openbsd.org: src

2024-04-03 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/04/03 12:41:38

Modified files:
sys/dev/ic : ncr53c9x.c ncr53c9xvar.h 

Log message:
Reuse the timeout from struct scsi_xfer rather than declaring one in
struct ncr53c9x_ecb.

When the scsi_xfer timeout was introduced *cough* 23 years ago, SCSI drivers
were progressively updated to use this, but for some reason that driver got
missed.

ok dlg@ krw@



CVS: cvs.openbsd.org: src

2024-03-31 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/31 04:14:46

Modified files:
etc/etc.landisk: MAKEDEV 

Log message:
Regen



CVS: cvs.openbsd.org: src

2024-03-31 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/31 04:14:35

Modified files:
etc/etc.landisk: MAKEDEV.md 

Log message:
Fix /dev/bio major.



CVS: cvs.openbsd.org: src

2024-03-31 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/31 03:49:33

Modified files:
sys/dev/isa: isavar.h 
Removed files:
sys/arch/powerpc/isa: isa_machdep.h 

Log message:
Remove long dead isa-on-powerpc leftovers.



CVS: cvs.openbsd.org: src

2024-03-31 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/31 01:23:29

Modified files:
sys/arch/alpha/include: cpu.h 
sys/arch/m88k/include: cpu.h 
sys/arch/sh/include: cpu.h 

Log message:
Stop referring to dead-since-30-years gatherstats() in comments.



CVS: cvs.openbsd.org: src

2024-03-30 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/30 04:43:38

Modified files:
sys/arch/luna88k/conf: Makefile.luna88k 

Log message:
Use illop1 as failure instruction in the locore gap file.



CVS: cvs.openbsd.org: src

2024-03-30 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/30 04:42:26

Modified files:
libexec/ld.so/m88k: ld.script 

Log message:
Prefer illop1 rather than nop for text padding in the ld.so linker script.



CVS: cvs.openbsd.org: src

2024-03-30 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/30 04:41:17

Modified files:
gnu/usr.bin/binutils-2.17/ld/emulparams: elf32m88k_obsd.sh 

Log message:
Provide illop1 instruction encoding as TRAP.



CVS: cvs.openbsd.org: src

2024-03-30 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/30 02:44:20

Modified files:
libexec/ld.so/sparc64: rtld_machine.c 

Log message:
Remove nonsensical comments. NFC



CVS: cvs.openbsd.org: src

2024-03-30 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/30 01:50:39

Modified files:
lib/libc/stdlib: malloc.c 

Log message:
In _malloc_init(), round up the region being mprotected RW to the malloc
page size, rather than relying upon mprotect to round up to the actual mmu
page size.

This repairs malloc operation on systems where the malloc page size
(1 << _MAX_PAGE_SHIFT) is larger than the mmu page size.

ok otto@



CVS: cvs.openbsd.org: src

2024-03-30 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/30 01:45:21

Modified files:
sys/arch/sparc64/sparc64: pmap.c 

Log message:
Bring back an inline db_enter(), which makes backtraces easier to grok
when sh*t hits the fan; per kettenis@ request and forgotten in previous
cleaning commit.



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:29:34

Modified files:
sys/arch/sparc64/dev: ebus_mainbus.c fhc.c psycho.c pyro.c 
  sbus.c schizo.c vbus.c vpci.c 
sys/arch/sparc64/include: intr.h 
sys/arch/sparc64/sparc64: clock.c intr.c machdep.c 

Log message:
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@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:27:53

Modified files:
sys/arch/sparc64/include: cpu.h proc.h 
sys/arch/sparc64/sparc64: db_interface.c genassym.cf locore.s 
  machdep.c pmap.c vm_machdep.c 

Log message:
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@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:26:38

Modified files:
sys/arch/sparc64/sparc64: clock.c cpu.c machdep.c pmap.c 

Log message:
Remove truly unneeded includes (not included indirectly).

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:25:55

Modified files:
sys/arch/sparc64/sparc64: locore.s 

Log message:
Check for %otherwin being nonzero earlier in rft_user.

There is one code path using it in %g2 and another using it in %g7.
There is no reason for them to use different registers, and fixing
this allows the check to be performed a bit earlier.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:23:17

Modified files:
sys/arch/sparc64/sparc64: locore.s 

Log message:
Simplify two more places where we don't need to check for unbiased stacks.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:20:03

Modified files:
sys/arch/sparc64/sparc64: locore.s 

Log message:
STACKFRAME macro is always invoked on a well-formed 64-bit stack, no need
to check for missing BIAS.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:19:30

Modified files:
sys/arch/sparc64/sparc64: trap.c 

Log message:
Text faults should not invoke uvm_grow() since the fault address is not on
stack. Remove duplicated "panic if uvm_fault() fails and we are in kernel mode"
blocks.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:18:19

Modified files:
sys/arch/sparc64/dev: pyro.c vpci.c 
sys/arch/sparc64/include: intr.h 
sys/arch/sparc64/sparc64: clock.c intr.c locore.s 

Log message:
send_softint() was designed as being able to target a particular cpu, but the
code for this was never written and all uses target the running cpu anyway,
so stop pretending it may do things it won't do and drop that cpu argument.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:17:13

Modified files:
sys/arch/sparc64/dev: zs.c 
sys/arch/sparc64/include: z8530var.h 
sys/arch/sparc64/sparc64: autoconf.c conf.c intr.c locore.s 
  machdep.c pmap.c trap.c 

Log message:
Update/fix/remove obsolete or just plainly wrong comments.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:16:38

Modified files:
sys/arch/sparc64/include: signal.h 
sys/arch/sparc64/sparc64: locore.s 

Log message:
Stop including  in locore and remove _LOCORE guards
from this header file.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:16:01

Modified files:
sys/arch/sparc64/include: intr.h 
sys/arch/sparc64/sparc64: intreg.h 

Log message:
Move C declarations from intreg.h to  which includes it.

This makes intreg.h locore-friendly - it only contains the MAXINTNUM define
after that.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:14:56

Modified files:
sys/arch/sparc64/sparc64: genassym.cf 

Log message:
Get rid of unnecessary defines in assym.h.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:14:31

Modified files:
sys/arch/sparc64/fpu: fpu.c fpu_extern.h 
sys/arch/sparc64/include: reg.h 
sys/arch/sparc64/sparc64: emul.c genassym.cf process_machdep.c 
  trap.c 

Log message:
Clean the fpu trap code:
- since there are no hardware fpu operation queues on real sparc64 hardware,
don't bother declaring the relevant struct and fields.
- when an fpu instruction needs to be emulated, pass it directly to
fpu_cleanup rather than fake its appearance in the fpu queue. While there,
also pass the ready-to-use union sigval computed in trap() in case a
signal needs to be delivered.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:12:59

Modified files:
sys/arch/sparc64/sparc64: vm_machdep.c 

Log message:
Be sure to reset p->p_md.md_fpstate to NULL after freeing it in cpu_exit().
There should hopefully be no further faults on this proc causing an fpu
state to be handled, but better play safe than sorry.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:11:32

Modified files:
sys/arch/sparc64/conf: files.sparc64 
sys/arch/sparc64/sparc64: cache.h cpu.c locore.s machdep.c 
  pmap.c 
Removed files:
sys/arch/sparc64/sparc64: cache.c 

Log message:
Clean-up cache-related definitions and routines.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:09:49

Modified files:
sys/arch/sparc64/sparc64: machdep.c ofw_machdep.c 

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

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:09:04

Modified files:
sys/arch/sparc64/dev: z8530kbd.c zs.c 
sys/arch/sparc64/include: cpu.h 
sys/arch/sparc64/sparc64: autoconf.c intr.c locore.s trap.c 

Log message:
Remove dead code. Some of it had been dead since the very beginning of the
sparc64 port.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:08:11

Modified files:
sys/arch/sparc64/fpu: fpu.c fpu_add.c fpu_compare.c fpu_div.c 
  fpu_explode.c fpu_implode.c fpu_subr.c 
sys/arch/sparc64/include: reg.h 
sys/arch/sparc64/sparc64: genassym.cf trap.c 

Log message:
No longer include  from , and have the few
users which need both explicitly include both.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:07:11

Modified files:
sys/arch/sparc64/fpu: fpu.c fpu_add.c fpu_compare.c fpu_div.c 
  fpu_emu.h fpu_explode.c fpu_extern.h 
  fpu_implode.c fpu_mul.c fpu_sqrt.c 
  fpu_subr.c 

Log message:
De-register fpu completion code.

There are pending changes to some of these files, and this would get in the
way.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:06:14

Modified files:
sys/arch/sparc64/include: autoconf.h conf.h cpu.h idprom.h pte.h 
  vmparam.h 
sys/arch/sparc64/sparc64: clock.c locore.s machdep.c 
  ofw_machdep.c pmap.c trap.c 

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

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:05:34

Modified files:
sys/arch/sparc64/include: asm.h 

Log message:
Remove unconditional define of _LOCORE.

This was used to get once-protected-by-_LOCORE defines from
, but is now completely unnecessary and possibly dangerous.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:04:37

Modified files:
sys/arch/sparc64/include: frame.h 

Log message:
Now that this file is no longer used by any libc C file, get rid of checks
for the _LIBC preprocessor symbol.

Also move the CC64FSZ and BIAS defines earlier in order to only have one
!_LOCORE block.

ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 15:02:11

Modified files:
lib/libc/arch/sparc64/fpu: fpu_add.c fpu_compare.c fpu_div.c 
   fpu_explode.c fpu_implode.c fpu_mul.c 
   fpu_sqrt.c fpu_subr.c 

Log message:
Do not include  in libc sparc64 fpu routines, they don't
need any of its contents.
ok claudio@ kettenis@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 00:52:50

Modified files:
gnu/usr.bin/gcc: Makefile.bsd-wrapper 
gnu/usr.bin/cc : Makefile 
Removed files:
gnu/usr.bin/cc/cc1obj: Makefile 

Log message:
No longer build the objective-C compiler (cc1obj). Its standard library
(libobjc) had been removed from the build years ago, there is no need to
keep the compiler.
ok beck@ joshua@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 00:50:06

Modified files:
sys/kern   : kern_sysctl.c 

Log message:
Remove one global variable duplicating uvmexp.pagesize.
ok guenther@ deraadt@



CVS: cvs.openbsd.org: src

2024-03-29 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/29 00:49:00

Modified files:
lib/libm   : Makefile 

Log message:
Simplify the conditionals for architectures which do not need any particular
md files lists.
ok guenther@ deraadt@



CVS: cvs.openbsd.org: src

2024-03-27 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/27 14:03:29

Modified files:
lib/libc/arch/sh: SYS.h 
lib/libc/arch/sh/sys: brk.S sbrk.S sigprocmask.S sigsuspend.S 
  tfork_thread.S 

Log message:
When the syscall number has to be loaded from a pc-relative location,
abuse END macros to place the number at the end of the syscall wrapper
rather than in the middle of it, so that there is no need to branch
around it; this saves two instructions per syscall number >= 128.

While there, also tweak the error return (SET_ERRNO_AND_RETURN) to only
return a 64-bit value for lseek; this saves another instruction for
all other syscalls.

With input from guenther@; "Anything that makes the machine faster" deraadt@



CVS: cvs.openbsd.org: src

2024-03-26 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/26 13:12:34

Modified files:
regress/sys/kern/noexec: testfly.S 

Log message:
add cfi instructions to repair this test on amd64 and arm64.
ok kettenis@



CVS: cvs.openbsd.org: src

2024-03-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/08 09:18:53

Modified files:
sys/arch/m88k/m88k: subr.S 

Log message:
Make sure copyoutstr() invoked with a length of zero returns ENAMETOOLONG.

This bug has been present in that file since the very beginning, more than
28 years ago.



CVS: cvs.openbsd.org: src

2024-03-05 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/05 12:27:47

Modified files:
regress/lib/libc/atexit: atexit_test.c 

Log message:
Ugly workaround to let this compile again on non-clang platforms.



CVS: cvs.openbsd.org: src

2024-03-04 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/04 12:35:13

Modified files:
regress/lib/libm/msun: Makefile 

Log message:
Add more platforms.



CVS: cvs.openbsd.org: src

2024-03-04 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/04 10:09:23

Modified files:
lib/libm/arch/sh: s_fabsf.c 

Log message:
Bring back the fabsf strong alias to fabs, lost sometime ago during
libm symbol visibility rework.

This would warrant a libm.so minor bump, but as 7.5 packages build have
started, this won't happen (and hopefully noone will notice since this
only affects landisk).

ok deraadt@



CVS: cvs.openbsd.org: src

2024-03-03 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/03 04:15:38

Modified files:
regress/lib/libm/msun: Makefile 

Log message:
Fill the list of expected test failures for m88k.



CVS: cvs.openbsd.org: src

2024-03-03 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/03 04:14:34

Modified files:
sys/arch/m88k/m88k: m88100_fp.c trap.c 

Log message:
Cope with the rare case of an imprecise FPU exception caught when
reenabling the FPU as part of the regular processing of another exception.



CVS: cvs.openbsd.org: src

2024-03-03 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/03 04:03:13

Modified files:
sys/arch/m88k/m88k: m88100_fp.c 

Log message:
Workaround a 88100 errata where a FPU imprecise exception may be raised
for floating-point-to-int conversions by mistake (these instructions are
not supposed to raise this exception).



CVS: cvs.openbsd.org: src

2024-03-02 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/02 09:51:00

Modified files:
lib/libc/arch/m88k/gen: fabs.S 

Log message:
Shorter and simpler version which does not need to use the stack.



CVS: cvs.openbsd.org: src

2024-03-02 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/03/02 05:02:42

Modified files:
lib/libc/arch/m88k: Symbols.list 
lib/libc/arch/m88k/gen: fabs.S 

Log message:
Provide the missing fabsl alias to fabs.

No shlib_version change needed, jumping on the version bump of the mkdtems
addition.



CVS: cvs.openbsd.org: src

2024-02-28 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/28 05:53:31

Modified files:
sys/dev/ic : fxp.c 

Log message:
Fix rx_bufs accounting buglet; reported on bugs@ by dns at strangeloop dot cc;
ok claudio@ deraadt@



CVS: cvs.openbsd.org: src

2024-02-21 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/21 23:45:22

Modified files:
usr.sbin/bgpd  : rde.c util.c 

Log message:
Workaround for gcc3 - the use of anonymous unions now makes it complain
when named initializers use fields within these anonymous unions.

Hopefully a short-term bandaid until the appropriate changes are identified
and backported to gcc3.

ok claudio@



CVS: cvs.openbsd.org: src

2024-02-18 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/18 14:27:38

Modified files:
sys/arch/m88k/m88k: trap.c 

Log message:
Fix format strings in TRAPDEBUG code and unbreak 88110_syscall. NFC



CVS: cvs.openbsd.org: src

2024-02-14 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/14 13:44:54

Modified files:
sys/arch/alpha/alpha: locore.s 

Log message:
Remove spurious GET_CURPROC in copyout() mistakenly introduced in r1.43.



CVS: cvs.openbsd.org: src

2024-02-14 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/14 05:48:31

Modified files:
sys/arch/alpha/alpha: genassym.cf 

Log message:
Remove defines no longer needed in locore. NFC



CVS: cvs.openbsd.org: src

2024-02-14 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/14 05:36:35

Modified files:
sys/arch/m88k/include: cpu.h 

Log message:
Remove never ever used cpu_exec() macro, apparently already obsolete by the
time this file was introduced close to 30 years ago.



CVS: cvs.openbsd.org: src

2024-02-13 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/13 23:17:51

Modified files:
sys/kern   : init_main.c 

Log message:
Enable the pool gc thread on m88k MULTIPROCESSOR kernels now that
pmap_unmap_direct() has been fixed; also tested by aoyama@



CVS: cvs.openbsd.org: src

2024-02-13 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/13 23:16:53

Modified files:
sys/arch/m88k/include: pmap.h 
sys/arch/m88k/m88k: pmap.c 

Log message:
Make sure pmap_unmap_direct flushes dirty cache lines.



CVS: cvs.openbsd.org: src

2024-02-13 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/13 10:51:17

Modified files:
sys/dev/ic : oosiop.c 

Log message:
Fix splbio usage in oosiop_scsicmd() - it does not need to be taken early
since the switch to iopool years ago, but on the other had the update of
the command TAILQ needs to be done at splbio, and it wasn't.



CVS: cvs.openbsd.org: src

2024-02-13 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/13 03:16:28

Modified files:
sys/uvm: uvm_page.c 

Log message:
Remove sanity checks from uvm_pagefree(). The first thing this function does
is invoke uvm_pageclean(), which performs the exact same sanity check, so
one set of checks is enough.

ok mpi@



CVS: cvs.openbsd.org: www

2024-02-09 Thread Miod Vallat
CVSROOT:/cvs
Module name:www
Changes by: m...@cvs.openbsd.org2024/02/09 15:09:38

Modified files:
.  : donations.html 

Log message:
Got more toys.



CVS: cvs.openbsd.org: src

2024-02-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/08 13:30:54

Modified files:
games/phantasia: Makefile 

Log message:
Oops, commited wrong version of CLEANFILES in previous.



CVS: cvs.openbsd.org: src

2024-02-08 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/08 13:28:54

Modified files:
games/hack : Makefile 
games/monop: Makefile 
games/phantasia: Makefile 
gnu/usr.bin/cc/cc_tools: Makefile 
gnu/usr.bin/clang/libLLVMExecutionEngine: Makefile 
gnu/usr.bin/clang/libLLVMIRPrinter: Makefile 
gnu/usr.bin/clang/libLLVMInstrumentation: Makefile 
gnu/usr.bin/clang/libLLVMObject: Makefile 
gnu/usr.bin/clang/libclangAST: Makefile 
gnu/usr.bin/clang/libclangBasic: Makefile 
gnu/usr.bin/clang/liblldCommon: Makefile 
gnu/usr.bin/clang/lldb: Makefile 
gnu/usr.bin/clang/lldb-server: Makefile 
lib/libcurses  : Makefile 
usr.sbin/mrouted: Makefile 

Log message:
Feed more generated files to the clean target; joint work with naddy@



CVS: cvs.openbsd.org: src

2024-02-07 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/07 13:54:53

Modified files:
sys/arch/m88k/m88k: pmap.c 

Log message:
Use tlb_flush() rather than complete invalidation in pmap_set_modify().
This has been missed in 1.68.



CVS: cvs.openbsd.org: src

2024-02-07 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/02/07 13:32:54

Modified files:
sys/arch/hppa/hppa: mainbus.c 

Log message:
Fix signedness to make sure we don't left shift into the sign bit.



CVS: cvs.openbsd.org: src

2024-01-20 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/01/21 00:17:06

Modified files:
sys/arch/loongson/dev: kb3310.c 

Log message:
Print raw battery information if KB3310_DEBUG, not DEBUG. NFC



CVS: cvs.openbsd.org: src

2024-01-19 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/01/19 13:06:00

Modified files:
distrib/sparc64/miniroot: Makefile 
distrib/sparc64/ramdisk: Makefile 
distrib/sparc64/ramdiskB: Makefile 

Log message:
More files to be blessed by the clean target.



CVS: cvs.openbsd.org: src

2024-01-11 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/01/11 12:16:27

Modified files:
sys/arch/alpha/alpha: trap.c 
sys/arch/amd64/amd64: trap.c 
sys/arch/arm64/arm64: syscall.c 
sys/arch/m88k/m88k: trap.c 
sys/arch/mips64/mips64: trap.c 
sys/arch/powerpc/powerpc: trap.c 
sys/arch/powerpc64/powerpc64: syscall.c 
sys/arch/riscv64/riscv64: syscall.c 
sys/arch/sparc64/sparc64: trap.c 

Log message:
Since no system call takes more than 6 arguments, and no more than one
off_t argument, there is no need to process more than 6 arguments on
64-bit platforms and 8 on 32-bit platforms.

Make the syscall argument gathering code simpler by removing never-used code
to fetch more arguments from the stack, and local argument arrays when pointing
to the trap frame does the job.

ok guenther@ jsing@



CVS: cvs.openbsd.org: src

2024-01-07 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/01/07 13:52:44

Modified files:
sys/kern   : makesyscalls.sh 

Log message:
Error out if one syscall ever takes more than 6 arguments.

This is not necessarily wrong per se, but would need special consideration,
as not all platforms are currently able to process more than six syscall
arguments (and upcoming diffs will rely upon reasonably-sized argument
lists), so better break now and reconsider later if need be.

ok deraadt@



CVS: cvs.openbsd.org: src

2024-01-05 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2024/01/05 12:34:20

Modified files:
sys/arch/hppa/hppa: trap.c 

Log message:
Remove more __syscall() leftovers.



CVS: cvs.openbsd.org: src

2023-12-26 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2023/12/26 07:04:50

Modified files:
sys/arch/macppc/dev: asms.c 

Log message:
Update documentation URL



CVS: cvs.openbsd.org: src

2023-12-21 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2023/12/21 12:40:47

Modified files:
share/man/man4 : ugold.4 
sys/dev/usb: ugold.c 

Log message:
New TEMPerGold sensor; reported by Mikolaj Kucharski on bugs@



CVS: cvs.openbsd.org: src

2023-12-21 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2023/12/21 12:34:08

Modified files:
sys/kern   : makesyscalls.sh syscalls.master 

Log message:
Remove logic and comments related to INDIR now that they aren't supported
anymore.
ok tb@ deraadt@, no need to regen anything



CVS: cvs.openbsd.org: src

2023-12-15 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2023/12/15 08:20:16

Modified files:
sys/arch/m88k/m88k: trap.c 

Log message:
Drop no-longer-applicable comment.



CVS: cvs.openbsd.org: src

2023-12-15 Thread Miod Vallat
CVSROOT:/cvs
Module name:src
Changes by: m...@cvs.openbsd.org2023/12/15 03:17:40

Modified files:
etc/etc.loongson: login.conf 

Log message:
Sync limits with octeon.



  1   2   3   4   5   6   7   8   9   10   >