67335 Commits

Author SHA1 Message Date
Jérôme Duval
e01dfaf620 build: add acpi_thermal, amd_thermal and pch_thermal to minimum definition
Change-Id: I943b77390266c4e444ddb406455ebaa6a9549565
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8856
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
hrev58550
2025-01-23 05:25:54 +00:00
Jérôme Duval
4d5debea9e amd_thermal: new driver
inspired by ksmn in OpenBSD

Change-Id: Ic272fc15f1ea082496db99ed2df15c77655ba9c7
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8855
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2025-01-23 05:25:54 +00:00
Jérôme Duval
77f06cf2ae pch_thermal: use user_memcpy() to write in a user buffer
Change-Id: I8eccde638ba30051fcec375b7d616e1d1bddf5ed
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8854
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
2025-01-23 05:25:54 +00:00
Jérôme Duval
5a2be54dd0 kernel: data_acquisition_other is also found in drivers
Change-Id: Ia3f9c661a97b54d9bfa33ca0df9f5bd773023c2f
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8853
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2025-01-23 05:25:54 +00:00
Augustin Cavalier
414774d79f kernel/vm: Rename VMCache::HasPage to StoreHasPage.
It checks whether the page or page's data is present in an underlying
"backing store", not whether the page is present in the cache itself.

No functional change intended.
hrev58549
2025-01-22 16:19:33 -05:00
Augustin Cavalier
ece9fcbaa8 kernel/vm: Assert in VMCache::InsertPage() that the offset is within the cache.
This would have caught the problem fixed in the previous commit.
Also adjust the assertion in MovePage for correctness.
hrev58548
2025-01-22 15:39:58 -05:00
Augustin Cavalier
8ff91e4a44 kernel/vm: Always insert new clean pages into the topmost cache on fault.
The previous logic, which dates back to the NewOS kernel, inserted them
into the deepest cache instead if the fault was a read and not a write.
But this creates problems if the deepest cache is of a smaller size than
the topmost cache, because then we'll be inserting pages with offsets
past the cache's virtual_end. In the case there are multiple levels of
caches between the topmost and the deepest cache which all are smaller
than the topmost, then when/if the deepest cache is merged with the second-
deepest cache, those pages will get skipped and freed when they may still
be in-use, which was the cause of #19367.

To solve this, just insert new pages into the topmost cache always.
Inserting them into the deepest cache seems to have been an optimization
(and a savings of pages), and not a matter of correctness.
2025-01-22 15:39:57 -05:00
John Scipione
4ae0548774 Terminal: Make Colors window height shorter and font-dependent
Roughly the same height as the Appearance window at 12pt font.

Change-Id: Iaa456aecfde6ebe92f4829e3aabca6a29b68bc08
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8847
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev58547
2025-01-22 19:28:58 +00:00
John Scipione
622853ff8e Appearance and Terminal: Move ColorPreview to shared
Move ColorListView and ColorItem to shared in BPrivate namespace.

ColorItem typedef to BPrivate::BColorItem for apps that are already
using this class.

Gravity screensaver:
* ColorItem => BColorItem.
* Use make_color() to set colors.

Make color drop message name agnostic, check for B_RGB_COLOR_TYPE.
Add be:sender and source to drag message.

Add _SetTermColors() convenience method to set colors on all tabs.

Change-Id: I5a9f55d3ab423ccaa341997cf444603373024553
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8846
Reviewed-by: John Scipione <jscipione@gmail.com>
2025-01-22 19:28:58 +00:00
John Scipione
012d90c553 BColorControl: SetValue and Invoke on color drop if enabled
Change-Id: I055750707ed625b21c6b4cf02faf2509f615e169
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8845
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2025-01-22 19:28:58 +00:00
John Scipione
a6fee6a1ca intel_extreme: Remove spurious whitespace
Change-Id: I5a15cada42d1d527b0d65f89401d04e7771ef4b6
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8852
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev58546
2025-01-20 19:32:32 +00:00
Dru Satori
0db74e1ae1 intel_extreme: add support for Alder Lake chipsets.
Added AlderLake-P and AlderLake-N variants to agp_gart bus
and intel_extreme driver. Tested and confirmed working.

Change-Id: I1ac1e04fbba222a2f9eef483d68575665561e837
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8840
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev58545
2025-01-20 17:17:43 +00:00
John Scipione
04bf57110c Tracker: Disallow control characters in file name edit
Change-Id: I1e87768cc70fdd501ca0a4710df619dd2d59ce7a
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8170
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: nephele nephele <nep-git@packageloss.eu>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
hrev58544
2025-01-20 16:27:04 +00:00
Autocomitter
d292bcc64b Update translations from Pootle hrev58543 2025-01-18 08:09:55 +00:00
John Scipione
0d50dc1f3e Tracker: Call AdoptSystemColors() to apply read-only tint
2 - 1.147 = 0.853

Change-Id: I260af9d07f5e43e939ce351bfd4036665ad126f4
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8269
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
hrev58542
2025-01-17 16:57:38 +00:00
John Scipione
9105063938 BTextView: Use document colors on AdoptSystemColors()
AdoptSystemColors() tints document background color to match panel
color if uneditable.

Calling MakeEditable() will automatically apply or unapply uneditable
background tint if you have previously called AdoptSystemColors().

Parent BView::AdoptSystemColors() sets panel colors, we want document
colors here. Do not alter text color - only view, low and high colors
are changed.

Document AdoptSystemColors() and MakeEditable() in BTextView docs.

Change-Id: Ib215735f27bb01fc2f95fcf2fee0185e5fc83f70
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8263
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
2025-01-17 16:57:38 +00:00
John Scipione
13553050f9 HaikuDepot: MarkupTextView SetForegroundColor to HighUIColor
Also the bullet point color
Allow Usage Conditions window to be resized
Tint disabled color instead of hardcoding

Copyright 2024 Haiku, Inc.

Fixes the other half of #19067

Change-Id: Ibf74d9dd673807b0f107e56cefb5b30916baed96
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8262
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
2025-01-17 16:57:38 +00:00
Augustin Cavalier
cce39b3cc0 ramfs: Add lock for NodeListeners.
This is only needed on add/remove; when the lists are actually
iterated we should already have a write lock.
hrev58541
2025-01-17 00:13:43 -05:00
Augustin Cavalier
ebc6bc8ed7 ramfs: Add iterator locking to index classes. hrev58540 2025-01-16 23:23:39 -05:00
Augustin Cavalier
5ac03c3714 ramfs: Clean up Iterator lockers API.
No functional change intended.
2025-01-16 23:23:19 -05:00
Augustin Cavalier
c9892ac20f ramfs: A write lock is needed when truncating files.
Should fix all KDLs in #19360.
2025-01-16 23:21:47 -05:00
Augustin Cavalier
48bfa9ee2f ramfs: Add some WriteLocked assertions.
These would have caught the problem in #19360.
2025-01-16 23:21:04 -05:00
Augustin Cavalier
6d6a53f147 kernel/fs: Add missing frees to I/O context destruction.
Fixes a memory leak regression from 12d6ecf0df54dc8752f7ccd1f430d74f45fcbd9b.
hrev58539
2025-01-16 20:07:31 -05:00
Augustin Cavalier
3f35917df2 kernel/team: Slight cleanup to the synchronization logic in load_image_internal.
Adjust the comment and use ASSERT() rather than a panic().
2025-01-16 19:49:47 -05:00
Augustin Cavalier
1124f672a0 kernel/vm: Improve address range blocking for uninitialized/freed memory.
* Use a "null" cache and avoid committing memory unnecessarily.

 * Block the 64-bit ranges also. On x86_64 the kernel is above
   userspace, so we have to |= KERNEL_BASE here; but in case
   something actually tries to access those pointers directly
   they should get a GPE anyway (as the address should be outside
   the canonical range.) If it's not, then SMAP should catch it.
2025-01-16 15:17:39 -05:00
Augustin Cavalier
cc389ab314 strace: Drop reference to wait_for_thread syscall. hrev58538 2025-01-15 14:55:17 -05:00
Augustin Cavalier
07ed8d0df8 kernel/vm: Block non-root teams from inspecting other teams' memory properties. hrev58537 2025-01-15 14:54:05 -05:00
Augustin Cavalier
f3f347f90d kernel & libroot: Drop wait_for_thread syscall in favor of wait_for_thread_etc.
We don't have many etc and non-etc syscall pairs in this file
(the semaphores seem to be a notable exception), so drop
wait_for_thread and just call wait_for_thread_etc instead.

This breaks syscall ABI, but we've already broken it since beta5
anyway.
2025-01-15 14:52:15 -05:00
Augustin Cavalier
26cf47386e kernel/elf: Map user images with kernel protections only at first.
They're still mapped into the team address space and with user addresses,
of course, and we reset all their protections later on anyway. This allows
a number of arch_cpu_{enable|disable}_user_access() calls to be dropped.

Also adjust the name of ro/text segments to "rx" to match what
runtime_loader now does.

Tested with SMAP enabled, still works.
hrev58536
2025-01-15 13:35:00 -05:00
Augustin Cavalier
b21f31ea16 runtime_loader: Consolidate some elf_region code.
No functional change intended.
2025-01-15 13:35:00 -05:00
Augustin Cavalier
e38be9392a runtime_loader: Actually respect PF_EXECUTE program header.
If it's not set (and we aren't on pre-Haiku GCC2 ABI), then don't make
the region executable.

This mostly only makes a difference for Clang/LLD-linked binaries
that have a readable, non-writable, non-executable program segment.
GCC/LD-linked binaries just have all read-only data in the main
read+execute section by default.
2025-01-15 13:35:00 -05:00
Augustin Cavalier
e0101fa39b runtime_loader: Clean up code in remap_images().
No functional change intended.
2025-01-15 13:35:00 -05:00
Niklas Poslovski
71a7116eb7 Time: Tint AnalogClock use B_DOCUMENT_BACKGROUND_COLOR
... and B_DOCUMENT_TEXT_COLOR with the selected hand using
B_NAVIGATION_BASE_COLOR when dragging instead of blue
(well, it is still blue but customizable).

Analog clock colors adjusted for light and dark modes.

Change-Id: I2d5af04f10090258b0ef989498f8e43dbded8def
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7940
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev58535
2025-01-15 18:09:47 +00:00
Augustin Cavalier
89dd4ee819 ramfs: Avoid acquiring locks for suspend/resume of EntryIterator in more cases.
If we don't have an Entry to attach/detach from, then we don't need
to acquire any locks at all. Now that we return multiple dirents
from read_dir, it's much more likely that we wind up with
EntryIterators in such a state, so this avoids some lock contention.
hrev58534
2025-01-14 21:37:43 -05:00
Augustin Cavalier
3f73e6e934 ramfs: Code cleanup to EntryIterator.
No functional change intended.
2025-01-14 21:17:43 -05:00
Augustin Cavalier
0f63c097ac ramfs: Read multiple dirents in read_dir() at once.
Massively cuts down on syscall count when reading directories.
hrev58533
2025-01-14 19:10:12 -05:00
Augustin Cavalier
eab4f99826 ramfs: Use the generic open_mode_to_access.
And clean up O_TRUNC at the same time.
2025-01-14 18:29:57 -05:00
Augustin Cavalier
7e29de9266 ramfs: Add support for "special" nodes.
Like S_IFIFO. It doesn't support ones with "sub-vnodes", but FIFOs
and UNIX sockets don't seem to use those (does anything, actually?)

Fixes #19261.

Change-Id: I9eeac4efcbe74e9084653c77d883dbb44e6f1d2c
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8830
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev58532
2025-01-14 23:19:00 +00:00
John Scipione
297aa21e46 Deskbar: Always AdoptParentColors() on StatusView
... be_control_look is assumed.

Change-Id: If41f74ede3debd5439093e0172294861f65f5d6b
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8832
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev58531
2025-01-14 22:46:39 +00:00
John Scipione
e7735d59c3 Deskbar: A few minor style fixes to StatusView (tray)
Change-Id: I89036bda8bc9b93cac90c606dafe0a13cfd8a05d
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8831
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2025-01-14 22:46:39 +00:00
Augustin Cavalier
853ddd218e Debug Kit: Don't find the runtime_loader debug area if no debug context.
We can't clone it or do anything in that case.

Also clean up coding style, and drop B_CLONEABLE_AREA from
the debug area, as it's not needed anymore.
hrev58530
2025-01-14 17:30:36 -05:00
Augustin Cavalier
7331a67227 kernel/util: Require passing a list_link to list_remove_link.
If something other than a list_link is passed, an explicit cast
will now be needed.

No functional change intended.
2025-01-14 17:30:36 -05:00
Augustin Cavalier
7d232f0cf8 kernel/image: Switch to using DoublyLinkedList<> for struct image.
No functional change intended.
2025-01-14 17:30:36 -05:00
Augustin Cavalier
9792c51694 kernel/elf: Use extended_image_info instead of reading runtime_loader structures.
This solves some TODOs and allows image_debug_lookup_user_symbol_address
to be dropped entirely. It should also fix reading symbols from binaries
that have multiple TEXT regions, and most functions are not in the first.
2025-01-14 17:30:36 -05:00
Niklas Poslovski
802fb5b90f Documentation: Replace remaining references of OpenBeOS with Haiku
Fixes #19335

Change-Id: I8458431be907e3f59165c7e9cf43d715e904af3d
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8826
Reviewed-by: John Scipione <jscipione@gmail.com>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
hrev58529
2025-01-13 22:23:11 +00:00
Niklas Poslovski
ee40fc9747 Documentation: Remove old unused doxygen_config files
Change-Id: I5f29561cea9bf34e1c92a381e6293ccae78c48c7
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8829
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Reviewed-by: John Scipione <jscipione@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
hrev58528
2025-01-13 22:22:43 +00:00
Niklas Poslovski
2f8543fe8c interface_kit/ChannelSlider: Fix binary compatibility breakage
Change-Id: I350c80baf7508a9db9a176e3ee050042fafa9321
Reviewed-on: https://review.haiku-os.org/c/haiku/+/8828
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev58527
2025-01-13 20:07:35 +00:00
Augustin Cavalier
e0f5c2e5cd kernel/vm: Distinguish reserved areas from non-existent areas in vm_area_for.
RESERVED_AREA_ID == -1, so previously they weren't distinguishable.
Now we return a different error code for an address that's in a
reserved area.
hrev58526
2025-01-13 15:00:54 -05:00
Augustin Cavalier
c125a32508 kernel/vm: Adjust kernel permissions check in vm_area_for.
Areas in the kernel address space generally won't have B_KERNEL_AREA.
Instead we should check if the area in question has user permissions
at all. If it doesn't, then return an error. If the address space
isn't the kernel one, then we don't bother with this check, as
all areas in the user address space should be returned even if
they don't have permissions or are a "kernel" area.
2025-01-13 14:52:38 -05:00
Augustin Cavalier
43b96dabf2 kernel/user_debugger: Add some padding/flexibility to debug_nub_message.
* Reorder a few messages, and add base numbers so that messages
   can be added in the future to all "sections" without breaking
   previous ABI.

 * Rename some messages for consistency.
2025-01-13 14:50:03 -05:00