Commit Graph

63672 Commits

Author SHA1 Message Date
Augustin Cavalier
e12a5fe215 kernel/slab: Change checks in FreeRawOrReturnCache to panic instead.
The function is largely useless if we cannot lock kernel space,
and the consumers may not expect it to silently "fail." Hence,
we now put the invocation of deferred_free in free_etc directly.
2022-02-08 18:33:20 -05:00
Augustin Cavalier
fc38a41393 BReferenceable: Fix build when the kernel is built with DEBUG enabled. 2022-02-08 18:28:16 -05:00
John Scipione
8b25c6d727 Appearance: Store decorator filename to disk untranslated
Save ShortcutName() (i.e. filename) instead of the potentially
translated decorator Name(). If the decorator has no ref but
fInitStatus is B_OK and fPath == "Default" return Default
decorator in ShortcutName(). The Default decorator unlike other
decorators has no file on disk associated with it.

We don't need to look for ShortcutName() when iterating through
decorators anymore because we look for "Default" then file names
before we try to find by name.

Fixes #16412

Change-Id: I3109681d11931e7f55b7afaf3a65af2fb9ed5e10
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4320
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-02-07 21:38:44 +00:00
urnenfeld
20b3c898d8 boot/efi/arm64: Enable FP/SIMD
* Kernel code uses q0 registers belonging to the 128 bits vectorial & floating point registers
* Apply stylistic suggestion from previous review

Change-Id: I41b5a807c3867de4bb3b9450607d48098f9471ef
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4925
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-02-07 21:36:55 +00:00
Augustin Cavalier
e88ab494a8 pkgman: Note in full-sync command summary that it may downgrade packages.
Fixes #10835.
2022-02-07 16:20:33 -05:00
Augustin Cavalier
e48ac4a3de Debugger: Add missing NULL check in ReportUserInterface.
Fixes #16565.
2022-02-07 16:14:50 -05:00
Augustin Cavalier
cb860bd2eb Add intel22x driver to the default images.
Fixes #17212.
2022-02-07 16:07:12 -05:00
Augustin Cavalier
1fc7d77323 XHCI: Downgrade tracing of CancelQueuedTransfers.
Now we only do it if TRACE_USB is enabled, or force-cancellation is specified.
2022-02-07 15:55:32 -05:00
Augustin Cavalier
312ea06980 XHCI: Do not print "transfer error" for COMP_STOPPED.
STOPPED errors are generated by StopEndpoint commands, which we issue,
so presumably we expect that we will get some STOPPED errors when doing
so, thus printing these is not really necessary.
2022-02-07 15:54:31 -05:00
Augustin Cavalier
125a7abe6f package_infos/webpositive: provides app:webpositive. 2022-02-07 15:11:30 -05:00
Augustin Cavalier
1267e873d3 protocols/unix: Do not re-build Referenceable.cpp.
It is now part of the general kernel exports (and is used by
packagefs, among other things.)
2022-02-07 15:08:21 -05:00
Augustin Cavalier
f6b6606652 BReferenceable: Always enable DEBUG in kernel mode when PARANOID_KERNEL_FREE is enabled.
This checks the reference counts are actually 0 (or 1 and allocated
on the stack). As PARANOID_KERNEL_FREE is enabled at KDEBUG_LEVEL 2,
this will thus be enabled on nightly builds.
2022-02-07 15:07:37 -05:00
Augustin Cavalier
ebf0b53a7e kernel/util/atomic: Permit atomic_pointer_get to accept const* pointers. 2022-02-07 14:35:23 -05:00
Augustin Cavalier
50157a8d17 kernel/condition_variable: Make ConditionVariableEntry::Variable non-inline.
We have to use an atomic here.
2022-02-07 14:22:39 -05:00
Augustin Cavalier
c9d521ea5b kernel/condition_variable: Various cleanups.
* Adjust a comment that now goes with 3 functions and not just 1.

 * Remove spinlock switch function, this is useless as it cannot
   change interrupt states here, but we require interrupts to
   be enabled to wait on a ConditionVariable.

 * Remove WaitStatus function from ConditionVariableEntry; unused
   and would require locks anyway.

 * Implement Publish using Init.
2022-02-07 14:22:12 -05:00
Augustin Cavalier
8774bf6012 libroot: Remove linker hack to prevent weak symbols.
Now that we support them in runtime_loader.
2022-02-07 14:19:58 -05:00
Augustin Cavalier
c41b379e5a runtime_loader: Support resolving weak symbols as NULL.
In the case where a weakly declared symbol has no definition,
it should just resolved to be NULL instead of failing to load at all.

GCC 11 builds of libroot.so wind up having one weak symbol
declaration that is unresolved at runtime, to __cxa_pure_virtual,
which seems to be provided by some object in libsupc++.a that ld
does not pull in automatically (and has to be forced at present.)

This change also amends symbol patcher behavior: it is now possible
for the symbol patcher to indicate symbols should be hidden by
changing the passed-in type to 0, instead. (Otherwise, weak symbols
would always get a value of NULL instead of being able to be hidden.)

Fixes #8288.

Previously-reviewed-on: https://review.haiku-os.org/c/haiku/+/4768
Change-Id: I6485c4e515cb53c6b81db971efbc10008fa6bd9d
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4932
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-02-07 19:03:25 +00:00
X512
cba95132ca libroot: add timespec_get to build
* Added in hrev55773

Change-Id: Ib57b53c76641e87c5ac0c0cde2407a7bfe45ce41
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4935
Reviewed-by: Jessica Hamilton <jessica.l.hamilton@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
2022-02-07 16:38:47 +00:00
Rudolf Cornelissen
74e271b2a2 intel_extreme: eDP port width register read is OK after all (SandyBridge). 2022-02-06 22:26:26 +00:00
Autocomitter
a49db24180 Update translations from Pootle 2022-02-05 16:01:49 +00:00
Rudolf Cornelissen
9d361aaed2 intel_extreme: eDP port width seems fixed at 4 on SandyBridge. 2022-02-05 10:37:35 +00:00
Rudolf Cornelissen
4b5e0c3bcd intel_extreme: Sandy/IvyBridge fix 4 lanes DP detect, fully pgm eDP link 2022-02-04 19:56:27 +01:00
David Karoly
a18ff64517 boot/arm: remove unused arch_mmu.h
This file is used only by the u-boot raw bootloader and
it has identical content to platform/u-boot/mmu.h.

Therefore we can use mmu.h in the u-boot loader and remove
this header.

EFI platform has its own arch_mmu.h in
headers/private/kernel/boot/platform/efi

Change-Id: Ie77774fbcf4855f9bc643176c179670f6169b3b6
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4929
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
2022-02-04 11:42:45 +00:00
Augustin Cavalier
f39294c273 freebsd_iflib: Remove Haiku-specific semaphores code and use msleep instead.
Now that the interlocking issues are resolved with the previous commit,
using the main TQ_SLEEP mechanism no longer causes deadlocks and
network I/O freezes, so we can drop the custom code and use FreeBSD's
code instead.
2022-02-04 00:45:41 -05:00
Augustin Cavalier
33c03035d1 freebsd_network: Rewrite ConditionVariable-using code.
The old code was not at all correct with respect to interlocking.
The new code should be, and is also much simpler.
2022-02-04 00:45:41 -05:00
Augustin Cavalier
1960df3158 freebsd_network: Add some missing __BEGIN_DECLS/__END_DECLS. 2022-02-04 00:45:41 -05:00
Jérôme Duval
32f411b9ab hda: detect some audio devices per device ID
as it's possible they use the audio class_sub instead of hd_audio.
* also power up the audio function, this seems required on Jasper Lake.
* tested on Acer Swift 1 SF114-34.

Change-Id: I603018b1b973e7884aa99a58be1c24e568f2d5ae
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4928
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
2022-02-04 05:40:11 +00:00
Augustin Cavalier
a8d965a0c4 kernel/condition_variable: Borrow the scheduler lock instead of self-unblocking.
Self-unblocking is not done anywhere else in the kernel and may not be
such a bright idea, it seems.

This also allows the elimination of some atomics, and resolves a race
that otherwise would have required another wait-loop. Performance
differences seem to be within the realm of noise.

Fixes #17553.

Change-Id: Id719ba51ed3f2a15557c8d53947182a5f8879b7b
2022-02-03 17:32:22 -05:00
Autocomitter
2d6d3938e7 Update translations from Pootle 2022-02-02 22:21:48 +00:00
X512
d03e5994ee ConditionVariable: add classical wait interface with lockable
Change-Id: Id18264e786dba818138caf3908c7a89b18e2a1dd
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4921
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-02-02 19:45:27 +00:00
X512
32fd04c959 AutoLocker: get ability to get lockable
Change-Id: Id8f554494ce83725c40ccebdf0e58e54bf1bf47c
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4920
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-02-02 19:45:27 +00:00
X512
fce7f3a748 integrate AutoDeleter's into pointers
Change-Id: I6c3925a7aec4d0647c76c2a03aad7b08985d7166
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3490
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-02-02 19:29:52 +00:00
David Karoly
478279116b boot/efi/arch: remove comments related to ConvertPointer
Change-Id: I1c0ebe04c180f3c50ac07c7d043a33d2c4563a18
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4924
Reviewed-by: Fredrik Holmqvist <fredrik.holmqvist@gmail.com>
2022-02-02 16:36:14 +00:00
Rudolf Cornelissen
ed9bb4dc76 intel_extreme: decoupled PIPE/eDP link programming from FDI train, fixed eDP pgm error. 2022-02-01 23:48:48 +00:00
Rudolf Cornelissen
41f6b7906d intel_extreme: if no EDID found use boottime EDID if there 2022-01-31 22:05:08 +00:00
Jérôme Duval
f9e868fc8f sdhci: accomodate 64-bit PCI BARs
* init works better with this. it doesn't work yet, but at least the boot
isn't completely borked.
* also fix the infinite loop in SoftwareReset() to timeout after 100ms.

Change-Id: I76dac8360eaf3575adf7d0b3bf3e2b72daeedb21
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4923
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-01-31 17:49:19 +00:00
waddlesplash
50ea01e93d Revert "runtime_loader: Support resolving weak symbols as NULL."
This reverts commit 74843df324.

Reason for revert: Change was not ready, see comments on #8288.

Change-Id: I82dc23ca5a86fa2906fb6eb19f9f872603618fad
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4897
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-01-31 15:20:28 +00:00
David Karoly
4f912a8b33 enable building EFI loader for x86
Change-Id: Ic7d2c3194b8555f7b6704131f5fc2bce3b139ee4
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4918
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Fredrik Holmqvist <fredrik.holmqvist@gmail.com>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
2022-01-31 14:22:57 +00:00
Augustin Cavalier
74843df324 runtime_loader: Support resolving weak symbols as NULL.
In the case where a weakly declared symbol has no definition,
it should just resolved to be NULL instead of failing to load at all.

GCC 11 builds of libroot.so wind up having one weak symbol
declaration that is unresolved at runtime, to __cxa_pure_virtual,
which seems to be provided by some object in libsupc++.a that ld
does not pull in. We could probably force it to be, but implementing
proper weak symbol resolution seems to be the more sensible path.

Change-Id: Ifd512b73dc67581e6173b5c78ce73ac68971707a
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4768
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: X512 <danger_mail@list.ru>
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
2022-01-31 14:19:39 +00:00
David Karoly
a7b50febfa kernel/x86: use proper phys_addr_t field for storing ACPI root pointer
Change-Id: I475b7b3f9bd0711ecd037043e86559ab691a82a7
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4881
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
Reviewed-by: Fredrik Holmqvist <fredrik.holmqvist@gmail.com>
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
2022-01-31 14:15:46 +00:00
David Karoly
bfd5d56283 boot/efi/mmu: fix sign extension issues
Conversion from pointer to phys_addr_t (i.e. uint64) results
in a sign extension on x86.

Therefore we first convert to addr_t and then convert from
addr_t to phys_addr_t.

Change-Id: Id9d9db03d9940a11ea3892841c271e12fad3975a
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4872
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Fredrik Holmqvist <fredrik.holmqvist@gmail.com>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
2022-01-31 14:14:12 +00:00
Humdinger
8b35436293 Audio mixer: Remove option for linear gain sliders
* always use non-linear gain sliders (was the default setting)
* remove functions and members connected to linear gain setting
* remove "(like BeOS R5)" from "Attenuate by 3 dB" option
* add "Low/High quality" to resample algorithm option

Fixes part of #17554

Change-Id: I746da3f5bcc8f0cb017c75509565b535d5442f71
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4917
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
2022-01-31 11:44:19 +00:00
Alexander von Gluck IV
4ac99e3932 system/boot: Don't borrow libroot objects
* kernel + bootloader get differing compiler flags
* Trying to reuse libroot objects makes what objects
  are being built with which flags slightly confusing.

Change-Id: Ic8ac7255db99d6825ca022afc3f4fd416c57c12d
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4876
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
2022-01-30 22:03:10 +00:00
Rudolf Cornelissen
c749333b59 intel_extreme: added EDID use for eDP laptop panels 2022-01-30 23:35:29 +00:00
Rudolf Cornelissen
d7a6d9cb6e accelerant_common: fixed typo in EDID dump 2022-01-30 23:28:41 +00:00
David Karoly
4ca2120531 boot/efi/x86: take care of PAE flags during MMU initialization
UEFI specification states that on IA-32 paging may or may not be
enabled during startup. If paging is enabled, PAE might be active.

During jump to kernel and early kernel initialiation we use paging
without PAE.

Therefore the following initialization sequence is introduced:
* disable paging
* disable PAE
* load page directory
* enable paging

Change-Id: Ife9a631b914dd5867f6673713e20e8abfce1ea44
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4919
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
2022-01-30 13:39:43 +00:00
Rudolf Cornelissen
ba0c9427cd intel_extreme: for Ivy/SandyBridge added eDP programming for laptops. 2022-01-30 00:21:32 +00:00
Adrien Destugues
071a83af4f fix macOS hosted build after hrev55802
The stat structure fields are not standardized, so we can't use an
hardcoded field name. The code in all other places was already adjusted
with a macro to handle the access, but hrev55802 introduced a new place
where we need to read the access and modification times. Use the macro
there as well.

Thanks to anuragpd4 for reporting the problem!
2022-01-29 15:57:56 +01:00
Autocomitter
9b199d1c7b Update translations from Pootle 2022-01-29 08:07:53 +00:00
Humdinger
7ae9eac3a9 Diskprobe: fix scrollbar insets
Fixes #17558.
Change-Id: I89863e7fcfa61292ac0ef3ccb7752e5c45519c61

Change-Id: I2e4ca735c00bb078ccf203e52e72e1c2f5481e90
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4893
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
Reviewed-by: John Scipione <jscipione@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
2022-01-28 18:22:05 +00:00