The get_edid_info function just does a memcpy of the info from the
driver. There is no need to trace to syslog everytime this happens
(which is a lot).
Also convert an error message from TRACE to ERROR so it remains visible
when tracing is disabled.
The context can be better allocated if it knows which codec it will be
used with (preallocating things with the correct size). To do this we
need to delay allocation from the constructor to the Init method.
* Tianocore is still in an early state for RISCV64 with a lot of work
needed around qemu support.
* u-boot however is working, and can load EFI binaries... so follow the
arm model for now. (EFI via u-boot, or EFI via EFI Bios)
Change-Id: I3dfde25db17b114aedce6faefc58d7556e17a46a
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3176
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
It is pointless to ask for a second confirmation in SoftwareUpdater,
since the user understands that the system needs to be rebooted for the
changes to take effect.
Change-Id: I00c728264c32e3688e396e70925b90501ccac6de
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3185
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
When a thread is created, it is expected that some other thread (usually the
creating thread) will want to make sure it completes. This is done using the
pthread_join() or wait_for_thread() calls.
It is possible that threads end before another thread waits for its completion.
That's why there is a dead thread list for each team, which holds thread ids
and their exit status so that a call to pthread_join() or wait_for_thread() in
the future can complete succesfully.
The dead thread list was limited to 32 threads per team. If there would be
more, the oldest thread would be kicked off. This could cause issues in
situations where a team would create more than 32 threads, and would start
waiting for their result after they have finished. Some of the calls would fail
because the threads would no longer be in the dead list.
This specifically caused problems for cargo (the Rust package manager), which
could depending on the number of dependencies, could create more than 32
threads. See: https://github.com/nielx/rust/issues/3
This change removes the limit of dead threads within a team. Note that there is
a risk that a badly written program that does not detach or joins its threads
can make this an endless list, but the impact is relatively small (dead threads
only occupy a bit of kernel memory).
Change-Id: I0135dd54e10ee48a529f23228d21237d4f1a74e2
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3178
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
The catalogs are loaded from separate files, so there is no need to have
an app entry_ref to load them, just a MIME type is enough.
The implementation is a bit simplified: only the default catalog format
is allowed (unlike when loading from entry_ref, where extra catalog
formats can be added in add-ons).
Unrelated cleanup: remove unused code to load catalogs from attributes
of an application. We considered this when designing the locale kit, but
using resources or separate files works better.
Use this in Cortex, where some strings are in a static library, so they
don't have an associated executable or library or add-on to identify
them. The code in Cortex is not complete localization, several parts
should use StringForRate, BStringFormat, etc.
Change-Id: I09be22b1f50891250c4497c51e1db8dcee279140
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3172
Reviewed-by: Kacper Kasper <kacperkasper@gmail.com>
- Use the longest device name as a min size
- Refactor things a bit to simplify the code
- Also set weights in the top group view to ensure a nice ratio between
the list and the other part of the window
* mmc might be not ideal. But raw is just a single partition and
anyboot is heavily x86. MMC will technically work for now to get
bootable images.
* floppyboot isn't used on EFI platforms, since we call two different
actions, just drop floppyboot altogether on EFI SD Images.
Change-Id: Idabb5483304007dd601bf8a1158036ffd24f73aa
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3165
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
This patch fixes the following issues:
The cat command in fs_shell only printed 10 bytes instead of the entire
file. Also, when the number of bytes to be read from file was large it would
cause segmentation fault because of stackoverflow.
This was noticed while testing xfs and ufs filesystems and has now been
fixed.
Change-Id: I3891f2834c5b76330f666ebee97b20bd5529742a
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3157
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
Had to abbreviate the trailing 's' to make it fit the alignment...
Change-Id: Iae88c4cd92c3f54bf3ea3433ea3dafe5df90a8e8
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3168
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
For areas >= 32TiB the page protection array size would overflow.
Change-Id: Ic95d9a6e35bbedb165c2bbd382f6c47edde07ac2
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3167
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
When copying an area with vm_copy_area only the new protection would be
applied and any possibly existing page protections on the source area
were ignored.
For areas with stricter area protection than page protection, this lead
to faults when accessing the copy. In the opposite case it lead to too
relaxed protection. The currently only user of vm_copy_area is
fork_team which goes through all areas of the parent and copies them to
the new team. Hence page protections were ignored on all forked teams.
Remove the protection argument and instead always carry over the source
area protection and duplicate the page protections when present.
Also make sure to take the page protections into account for deciding
whether or not the copy is writable and therefore needs to have copy on
write semantics.
Change-Id: I52f295f2aaa66e31b4900b754343b3be9a19ba30
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3166
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Change-Id: Ia386d9155dda37ff6608a33dee349bf5332890c3
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3162
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Reviewed-by: François Revol <revol@free.fr>
Change-Id: Id050fad59ede444f2eab7eca681c6ec44612aaf9
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3160
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Reviewed-by: François Revol <revol@free.fr>
Somehow the first review merged only the commit log.
FreeBSD doesn't have m68k anyway, so use fenv from musl with as less
changes as possible.
Change-Id: I6372af6679e6773fbb6bf4c8b5b30512971a97a6
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3161
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Note it is not enough to fit, you also need to disable USB boot.
Change-Id: I5159c9ddebb242c4d4874d70430da6852073fdb4
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3102
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
For some reason the kernel ended up with a bunch of .text.foo or
.data.rel.bar sections, each with their own ELF section headers and
other metadata. Forcing them into the base sections drops the binary
size by about 100kB, even for the stripped one.
I suspect it should work on other archs as well.
Change-Id: I7a8f46480d71267c07b75325423a0f5bfd2d12fb
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3101
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
We don't have room for disklabel copies anymore.
+ style fixes
Change-Id: I22502167a4f5f8bc3df1b017072461d77a299b16
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3100
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Next floppies actually do have a "disk label" (partitionning scheme),
the boot block being later on the disk.
This commit generates an identical label to the image I have here (but
not the copies at other sectors), including the checksum.
Change-Id: I7f939c26e70e3626d9af7a3eb342cfd32c298e3d
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3098
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Doesn't work yet though:
- we don't implement heap yet,
- non-color machines have 2bpp, so we'll have to hack this in some way.
Change-Id: Idf8f69c2256837db3915949d93265decbb43a524
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3097
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Those were found in the official headers in the NeXTstep ISO, how come I
didn't even look there in the first place?
We do get enough info to use the framebuffer, but sadly the SCSI IO
seems invalid. Both the NetBSD and even NeXTstep bootblock have their
own embedded drivers, maybe they didn't trust their own rom?
Change-Id: I0a47c433da89b15091644cd5c69ffff24d0cdd1f
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3096
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Since the boot ROM API structure is declared with a custom alignment, we
simulate it with padding bytes around, and use aligntest.prg to verify
using ARAnyM + TOS/MiNT as we know how to link simple PRG files.
It now prints something to the screen then panics when initializing the
heap.
For now one must insert the loader manually into an existing floppy
image:
dd if=generated-m68k/objects/haiku/m68k/release/system/boot/next_m68k/haiku_loader.next_m68k bs=$((0x8000)) seek=1 of=next_floppy.img conv=notrunc
Change-Id: I06d74e9d85a352aab68dedce545bbe5fe9e990d5
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2220
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
FreeBSD doesn't have m68k anyway, so use fenv from musl with as less
changes as possible.
Not sure the 'hidden' define should go there.
Change-Id: I343f72d61dcacf7dfc180d112529f5a6521d7e3b
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2213
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
This enables generation of exceptions that are due to uncorrected
hardware errors. The exception handlers were already in place and will
now actually trigger kernel panics.
Note that this is the simplest form of MCE "handling" and does not add
anything of the broader machine check architecture (MCA) that also allow
reporting of corrected errors. As MCEs are generally hard to decode due
to their hardware specifity, this merely makes such problems more
obvious.
Might help to discern hardware issues in cases that would otherwise just
triple fault and cause a reboot.
Change-Id: I9e3a2640458f7c562066478d0ca90e3a46c3a325
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3155
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Reviewed-by: Axel Dörfler <axeld@pinc-software.de>
... with the replicant tray below the menu bar.
Deskbar now has four modes:
1. vertical mini-mode (old mini-mode)
2. horizontal mini-mode (new mini-mode, was vertical)
3. vertical expando-mode (default)
4. horizonal expando-mode
Horizontal mini-mode gets the corner, then it switches to vertical
mini-mode above or below that, then to vertical expando-mode after
that. Horizontal expando mode is in center-screen top and bottom.
Clock vertical centering simplification.
Change-Id: I216008c20feb28f793693046792bbcfdf1e703e3
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3146
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>