65763 Commits

Author SHA1 Message Date
PulkoMandy
0199d1f39b ffmpeg: remove interlaced_frame
Change-Id: I870bea36c6180e46ae3d63fe407126606bdda3c1
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7254
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
hrev57535
2024-01-28 16:14:21 +00:00
PulkoMandy
6dd4427158 ffmpeg: use accessors for AVStream indexes
The fields are not publicly exposed directly anymore

Change-Id: I39348116378c11fd3a1c4f08756b5a31f54b8781
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7255
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
hrev57534
2024-01-28 16:13:13 +00:00
PulkoMandy
1978089f7c API docs: document menu reordering functions
Change-Id: Ic1a914af343aa713cfb7edc813c6a6458cb5027f
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7357
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: Niels Sascha Reedijk <niels.reedijk@gmail.com>
hrev57533
2024-01-28 16:12:09 +00:00
PulkoMandy
67380402ab BMenu: use std::stable_sort to implement SortItems
This fixes two problems:

- Use of a stable sorting algorithm makes sure that the relative
  position between items that compare equal are not modified
- More importantly, the compare function in BList passes a
  pointer-to-pointer (in this case a BMenuItem**) and this was masked by
  the casts due to BList lack of type safety. So, BMenu::SortItems was
  not working at all when trying to use it as its prototype would imply.

NetworkStatus and Network preferences worked around this by doing the
extra dereferencing in their compare functions. I did not find any
other places in Haiku where this function is used (it was introduced
specifically for this in hrev55562). All 3rd party code that had a
similar workaround will have to be fixed to remove it (if there is
anything using that function).

Change-Id: Ia78fd1363f2c012f6eff6f9a47e8b3aac2752ebd
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7356
Reviewed-by: Niels Sascha Reedijk <niels.reedijk@gmail.com>
2024-01-28 16:12:09 +00:00
John Scipione
8446d3b9b5 Tracker: Miscellaneous cleanup
Move DraggableContainerIcon out of ContainerWindow.cpp into new.
Move CompareLabels to Utilities.cpp

Rename fContainerWindowFlags to fOpenFlags. These are the flags set
by OpenContainerWindow to save and restore state and should not be
confused with the windowFlags that are passed to BWindow. There are
two sets of flags, which I'm calling openFlags and windowFlags.

Rename fUseLayouts to fUsesLayout and useLayouts to useLayout. Put
all the constructor created flags at the top.

"window" variable name is ok, we don't need to say "containerWindow".

Rename Addons to AddOns everywhere with a capital O.
Rename BuildAddOnMenu() to BuildAddOnsMenu() with an s.
Rename AttributeMenu...() methods to AttributesMenu...() with an s.
Rename SetUp...() methods to Setup...() with a lowercase u.

Replace a few instances of fPoseView with PoseView() inline in
BContainerWindow and BDeskWindow.

A few more minor fixes in BDeskWindow.

Replace BPoint(0, 0) with B_ORIGIN in Pose.h

Change-Id: If30803753b63b19e35f14c0f0c4e08111d0d0980
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7240
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
hrev57532
2024-01-28 09:46:35 +00:00
John Scipione
90510b4af9 Tracker: Remove Trash settings remnants
PoseView.cpp changes
* Create DoDelete() and DoMoveToTrash() convenience methods in BPoseView.
- Call DoMoveToTrash() in B_DELETE handler checking Shift.

Tracker: Update Delete warning dialog

This dialog pops up when you Move to Trash with Shift held down.

The Skip Trash version has been deleted since we've decided to
no longer using this settings.

Push Cancel button over to right on the "Delete files" version.

Handle default case in switches so that a weird value is returned it
will Cancel. If BAlert receives B_QUIT_REQUESTED it returns -1 for
example according to the Haiku Book so make sure to handle this case.

Add B_CLOSE_ON_ESCAPE flag and handle that case.

Change-Id: I16c532bfef585081207f1df3edc93f69dec6e529
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7199
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
2024-01-28 09:46:35 +00:00
Autocomitter
6b427174c5 Update translations from Pootle hrev57531 2024-01-27 08:18:45 +00:00
Augustin Cavalier
4fbebc21b8 registrar: Back out change to convert case in B_REG_MIME_GET_SUPPORTING_APPS.
This reverts commit 3ab43722bf0e4078ab924d015f7f790e84b570cb.

Now that GetSupportingApps does case conversion, we don't need to do it here.
hrev57530
2024-01-26 18:20:35 -05:00
Augustin Cavalier
cdf3559b27 Storage Kit: Do case conversion in SupportingApps::{Get,Set}SupportedTypes.
We already convert everything to lowercase in BuildSupportingAppsTable(),
so we should do the same here.

Fixes #18752 (again.)
2024-01-26 18:19:16 -05:00
Augustin Cavalier
89fcf815e6 Storage Kit: Source clean up to SupportingApps.
Remove extraneous comments, early-return on error (and thus de-indent.)
No functional change intended.
2024-01-26 18:09:33 -05:00
Augustin Cavalier
94d33dcbb6 XHCI: Rework _LinkDescriptorForPipe to avoid double-links.
The previous logic would link from the end of the ring to the start,
and the TRB there would always itself be a link TRB. Now, we avoid this
by linking back to the start from within the TD segments, and putting
the "Event Data" TRB there.

May help with some problems.

Change-Id: I92c4e135ee28c8c89646594a99fb40ee0d6c4484
2024-01-26 17:36:26 -05:00
Augustin Cavalier
45436c7a67 freebsd_iflib: Remove workaround for multi-packet receive.
Following the last commit, we can just let if_input
process the whole chain at once.

The logic here may not have been correct, and possibly
caused memory leaks under high-traffic conditions.

May help with #18585 and others.
hrev57528
2024-01-26 16:02:48 -05:00
Augustin Cavalier
9504fccf29 freebsd_network: ether_input needs to support multiple packets.
It does on FreeBSD, though not many drivers make use
of this functionality (on Haiku, only iflib appeared to,
and it has a workaround at the moment.)
2024-01-26 16:00:13 -05:00
Augustin Cavalier
17aa6d0125 IPv4: Make header fields go out of scope when no longer usable.
There was a comment indicating where this happened, but then
there was a use of one of them after this point. Fix that,
and add { } around their use to prevent this from happening again.
2024-01-26 14:32:59 -05:00
Alexander von Gluck IV
6738595a67 build-packages/x86_64: align gcc to current repo gcc
* Tested no issues on boot.

Change-Id: I2825ac8614172d649d1821a7a6c25e6cf63f716f
hrev57527
2024-01-25 12:31:48 -06:00
Humdinger
cdae7cfdbe Add a descriptive contents of the Haiku-Extras package
Good to know what's included. Also when searching stuff in HaikuDepot.

Change-Id: Ia87e657075e8066d4b460194c2ba19f6f4715f15
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7345
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>
hrev57526
2024-01-25 11:57:01 +00:00
Humdinger
15037a29f1 Move TV app into haiku_extras package
As discussed at
https://discuss.haiku-os.org/t/what-does-the-tv-program-do/14511

Change-Id: I7d9501cad2b9d4b3c6898ec39398101727c2eee8
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7344
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
hrev57525
2024-01-24 09:56:30 +00:00
Jérôme Duval
b352d8ccd8 virtio_gpu: add the accelerant to the regular image
fix 32-bit warnings

Change-Id: If85acfce1ac93998c13e5d9fa2e02823e219e428
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7342
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: X512 X512 <danger_mail@list.ru>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
hrev57524
2024-01-24 09:54:55 +00:00
Humdinger
3ab43722bf MIMEManager: use lowercase MIME when calling GetSupportingApps()
The list of supporting applications is generated case-insensitive
by making all items lowercase, see
src/kits/storage/mime/SupportingApps.cpp:302

Force the MIME type to lowercase before calling GetSupportingApps()
or a MIME containing uppercase isn't found.

Fixes #18752

Change-Id: I38252cd1be8f059d7df4bf8775855b6343a489c0
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7340
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
hrev57523
2024-01-23 09:49:30 +00:00
Jérôme Duval
591a1d179a AdapterIO: add FlushBefore() to strip the beginning of the MallocIO object
by default, AdapterIO is initialized with a BMallocIO object, which will
be extended indefinitely. Flushing regularly is necessary to avoid
excessive memory usage. Tested in StreamRadio.

Change-Id: I9f3142c0a2300ad44dc54ccf6932d41c9526320b
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7302
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
hrev57522
2024-01-23 09:49:17 +00:00
Andrew Lindesay
88af15cfbd HaikuDepot : Refactor Screenshots
Rework the way in which the application deals
with screenshots so that there is a repository
of screenshots that is referenced from
identifiers on the package model and not that
the screenshot bitmaps are stored with the
model and not cleaned up.

Change-Id: I632def96852a518b3f6b1c8b81909de117bbbc54
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7296
Reviewed-by: Andrew Lindesay <apl@lindesay.co.nz>
hrev57521
2024-01-21 09:26:50 +00:00
Autocomitter
136aeaaa47 Update translations from Pootle hrev57520 2024-01-20 08:21:36 +00:00
Augustin Cavalier
aeb3a97aba XHCI: Properly handle "Length invalid" and erroring TRBs on the endpoint ring.
Should improve #18432 and other tickets.

Change-Id: Iaafe2d9d61bc0514e4dd6283b9e75496d5e2d44a
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7341
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev57519
2024-01-18 19:14:04 +00:00
Jérôme Duval
0b733c9c80 virtio_gpu: initial driver
sample for qemu: -device virtio-vga,edid=on,xres=1024,yres=768 -display sdl
display mode can be set in the Screen preferences.

Change-Id: If1d6aeecb208ce7c62c42eea1a95c71237c4375a
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7038
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
hrev57518
2024-01-18 17:44:40 +00:00
Augustin Cavalier
a2270c7035 kernel/vm: Avoid committing memory in vm_map_file for PRIVATE_MAP without PROT_WRITE.
Instead, rely on commitment being done later, when the
protections are changed. set_area_protection() already
did just that, but set_memory_protection did not, so
it is implemented here.

Fixes #18733.

Change-Id: Ia58aee93faf1296fce69d723b12d0fa0a8440706
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7339
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev57517
2024-01-17 20:21:30 +00:00
Jérôme Duval
33fb08b1a5 ccp: add new IDs
Change-Id: Id9b2512d9f3b44d6ea25cb939dfd3054fe07600a
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7338
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev57516
2024-01-16 17:09:34 +00:00
Jérôme Duval
84cc2b9655 random: move virtio in a subdir
Change-Id: Idd776d6599613807c611cc6f72d8c1d2b9234946
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7337
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2024-01-16 17:09:34 +00:00
Jérôme Duval
21d87cd45a app_server: recursive scan in /dev/graphics/
* /dev/graphics/virtio_gpu/0 is a valid entry
* app_server doesn't set the initial mode if it's identical; use
0x0 as initial resolution.

Change-Id: Ica0323e6c5d78b39f05499edc93fa9c949b97dc8
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7037
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
hrev57515
2024-01-16 07:09:47 +00:00
Augustin Cavalier
e5e1f48bf5 PCI: Convert constant missed in prior commit. hrev57514 2024-01-15 15:24:58 -05:00
Augustin Cavalier
fabb71cc0e PCI: Support more than 6 PCI memory ranges.
Also use the standard kernel-wide constants for IO or memory space
rather than defining new ones, as well as the PCI constants for
address types.

Change-Id: Iad03f7666ad5121a5c9a398339aa1a191339a1d1
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7336
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev57513
2024-01-15 20:18:57 +00:00
Augustin Cavalier
6533df4fe4 iaxwifi200 & idualwifi7260: Synchronize with OpenBSD. hrev57512 2024-01-15 14:12:49 -05:00
Augustin Cavalier
7bcc4a30f9 openbsd_wlan: Synchronize net80211 with OpenBSD. 2024-01-15 14:12:09 -05:00
PulkoMandy
8e4a60d3f1 PCI: handle "non fixed" addresses
If the max address for a PCI bus is not fixed, try to compute it from
the minimum and length (if available).

Change-Id: I23d87da32779d22324f944b5b359390f523ec7a7
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7111
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev57511
2024-01-15 18:44:39 +00:00
Autocomitter
a38355a483 Update translations from Pootle hrev57510 2024-01-13 08:20:56 +00:00
Andrew Lindesay
b72cc7f405 HaikuDepot : Fix Compile Warnings
Change-Id: I3f44eb33d26c1236de2b132a27ca3ad4ddb0bbc1
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7298
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
hrev57509
2024-01-11 09:20:37 +00:00
Augustin Cavalier
2fb174a701 kernel/fs: Add missing initialization. hrev57508 2024-01-10 12:51:10 -05:00
Jérôme Duval
77cf55c4ad kernel/vfs: create_vnode should also create non existing entries when traversing
Fixes #18355.

Change-Id: I96abb95c14a74bcf9fec802badeb16c978a3b3d1
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6321
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev57507
2024-01-10 17:43:46 +00:00
Augustin Cavalier
79c0b6288f kernel/fs: Make vnode_path_to_vnode and derived methods take VnodePutter&.
Upcoming changes will make this method return values in _vnode even
when they return error codes under some conditions. To avoid easily-
caused memory leaks, this commit refactors the output variable to
be VnodePutter&, and all consuming methods to thus make use of Putters.

Should not be a functional change.

Change-Id: Id7b9066f8cd50c159d52c921b16e475e4e1de806
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7301
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2024-01-10 17:43:46 +00:00
Jérôme Duval
96bad7685b PowerStatus: add state "Not charging"
some laptops decide to not charge a fast full battery to not consume a cycle.
In this discharging state, the current rate is zero, thus no time left can be computed.
We add a state "Not charging" to clearly differentiate and avoid user confusion.
PowerStatus was triggering low battery notifications, this is also fixed.

Change-Id: I4745c78eb0863ab01fe34cb065707d068cff0f0e
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7300
Reviewed-by: Fredrik Holmqvist <fredrik.holmqvist@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
hrev57506
2024-01-09 04:07:05 +00:00
Augustin Cavalier
bb09458028 kernel/vfs: Convert from custom VNodePutter to the generic VnodePutter.
The latter is actually an AutoDeleter based on CObjectDeleter.
No functional change intended.
hrev57505
2024-01-08 15:14:09 -05:00
Augustin Cavalier
76f69a9e77 kernel/fs: More usage of FileDescriptorDeleter.
Remaining non-uses are mostly in specialized functions that e.g. operate
on many file descriptors at once (like vfs_exec_io_context.)

Reduces "goto"s. Should not have any functional change.
hrev57504
2024-01-08 14:57:38 -05:00
Augustin Cavalier
1bde6f6c36 kernel/fs: Standardize AutoDeleters for file_descriptor on FileDescriptorPutter.
No functional change intended.
2024-01-08 14:52:14 -05:00
Augustin Cavalier
fa766875af kernel: Rename DescriptorPutter to FileDescriptorPutter.
For consistency. No functional change.
2024-01-08 14:11:30 -05:00
Augustin Cavalier
1322e37a03 docs/user: Fix typo. hrev57503 2024-01-08 14:07:53 -05:00
Augustin Cavalier
12bba3817d nvme, mmc: Fix SMAP violations in B_GET_MEDIA_STATUS.
Fixes #18736.
hrev57502
2024-01-06 12:07:25 -05:00
X512
3433ec7334 vfs/preallocate: fix file descriptor leak
Fixes #18724.

Change-Id: I1a17a36106d13853888342a397ecd03087b1fdcf
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7299
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
hrev57501
2024-01-06 15:20:09 +00:00
Autocomitter
cfcb53d90a Update translations from Pootle hrev57500 2024-01-06 08:17:18 +00:00
Jérôme Duval
fffd9d7dd4 AdapterIO: only for SEEK_SET is the position absolute
Change-Id: I8debbcc0a2d9e499bebcebe5361475737dc8f9f0
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7295
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
hrev57499
2024-01-04 15:06:37 +00:00
X512
21fa9b3bb4 registrar: use smaller minimal timer interval
Fixes #4576.

Change-Id: Ie0788ba9b48597bb9cead20b3125af251b5b59cf
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2888
Reviewed-by: Fredrik Holmqvist <fredrik.holmqvist@gmail.com>
hrev57498
2024-01-03 19:18:46 +00:00
Adrien Destugues
8d27b645e7 features.h: fix build when BSD headers are not in include path
In our C library we try to provide a "clean" POSIX/ISO-C set of include
files that strictly conforming applications can use. However, we also
want to provide some extensions that are commonly available in BSD or
GNU systems.

These are normally provided in a separate directory
(headers/compatibility/bsd) and additionally guarded by compiler defines
that can either be explicitly set, or enabled by default if the language
standard (selected from the compiler command line) is one with GNU
extensions (this is the default for GCC). This is controlled by a header
file called features.h.

However, for some headers it is not so simple to split the GNU
extensions apart from the other parts of the file, because it's not just
extra functions, but additional flags and defines.

So, we need the "features.h" mechanism to be available even in the base
set of headers, but not enable anything if the BSD headers are not in
the search path. The simplest way to achieve this is to have an empty
features.h in the base set of headers, that can then be overriden by the
one in headers/compatibility/bsd if needed.

Fixes #18732

Change-Id: Ia54d1206c2fba378ae276ed4232aee8443180afb
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7287
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
hrev57497
2024-01-03 17:11:56 +00:00