Commit Graph

65789 Commits

Author SHA1 Message Date
Augustin Cavalier
dbc23cdfb7 userlandfs: Allocate requests in-kernel as kernel-only.
Things still seem to work, and may fix some SMAP
violations.
2024-01-30 21:44:02 -05:00
Augustin Cavalier
41a1732deb userlandfs: Disable use of the file cache in FUSE for now.
It still needs more work, it appears.

Fixes #18746.
2024-01-30 21:43:26 -05:00
Augustin Cavalier
d385686cbf userlandfs: Make DoIO handle IO smaller than the request size properly.
When _InternalIO returns with "bytes" smaller than the
original request, this isn't an error (or something we
should retry), but just something we need to pass on.

Fixes part of #18746. However, even after this commit,
file reads don't work quite right: reading past the end
of a file returns errors instead of just no data.
2024-01-30 21:43:00 -05:00
Joachim Mairböck
cbe17a5f23 haiku_extras: add provides for TV and acpi_call
Also fix the broken DeskBar symlink for TV.

Change-Id: I23a9cc5cf3e3d0c6ae1608a3b96a37e9a8c431a2
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7362
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2024-01-30 21:19:57 +00:00
Augustin Cavalier
ed574cce93 TTY: Return success on partial writes.
Otherwise the calling program will think that
no part of the write succeeded, when in fact
it did.

tty_read() already did this correctly. Not sure
how this wasn't uncovered previously.

Fixes #18447.
2024-01-30 16:01:21 -05:00
Augustin Cavalier
ef1427bb58 PowerStatus: Add logic to automatically install in Deskbar.
Modeled after NetworkStatus. Also add it to
default_deskbar_items.sh.

Fixes #18748.
2024-01-30 14:44:28 -05:00
Augustin Cavalier
6a47944773 kernel/condition_variable: Add another check of the wait status after _RemoveFromVariable.
If it was set, we want to return it.
2024-01-30 14:22:54 -05:00
Augustin Cavalier
a162e7af99 desklink: Size custom items based on Deskbar's current icon size.
Fixes #18757.
2024-01-30 14:18:29 -05:00
Augustin Cavalier
b2720cd3d9 BScrollView: Don't adjust other dimension if it's negative.
Some non-layout applications start out with negative
view dimensions. Making them positive too early on can
break the view's appearance, it seems.

Fixes #18690.
2024-01-30 13:52:56 -05:00
Augustin Cavalier
230de61bd6 registrar: Truncate the recent apps/entries lists to 100 items.
The constant can easily be changed if needed.

Fixes #18737.
2024-01-30 13:44:45 -05:00
Augustin Cavalier
4fec81750d TCP: Refactor sending logic.
* Break segment setup out into its own method.

 * Break the actual sending logic out into its own method.
  - While at it, remove some old/obsolete comments and
    rearrange some of the logic to match.

 * Separate the send-pure-ACK and send-data methods.
  - This way, the "force" parameters will act differently,
    specifying "force" to SendAcknowledge() may generate
    a duplicate ACK, while to SendQueued() it will either
    send data smaller than a segment size, or do nothing.

Functional changes should be minor, and the code
meanwhile should be much easier to read.

Change-Id: I1e14b9a1e3b7c8b2d3bf8ae30f1369d8c9f662a4
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7361
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2024-01-30 17:34:27 +00:00
Augustin Cavalier
d2f65e76ee OHCI: Remove unused variable following previous commit. 2024-01-30 00:43:57 -05:00
Augustin Cavalier
8c458fc42b USB: Initialize packet descriptors inside the stack.
Allows deletion of generic code from bus drivers.
2024-01-30 00:39:47 -05:00
Augustin Cavalier
02f5db9104 usb_audio: Always USB_ISO_ASAP rather than scheduling transfers by frame.
Seems to make things work much better.
2024-01-30 00:16:07 -05:00
Augustin Cavalier
005ba2b47d usb_audio: Do not use any timeout in _MultiBufferExchange.
The other multi-audio drivers do likewise.
2024-01-30 00:14:49 -05:00
Augustin Cavalier
1f6757e31f XHCI: Overhaul isochronous transfer handling.
* Each packet needs to be its own TD.

 * All transfers are scheduled in frames, not microframes.

Combined with a few fixes to the USB audio driver, this seems
to get things working much better than before.
2024-01-30 00:14:23 -05:00
Augustin Cavalier
d49d21bba0 graphics/virtio: Disable tracing.
Reduces syslog spam.
2024-01-29 22:52:37 -05:00
Augustin Cavalier
6eaaa52128 usb_disk: Cancel queued transfers on the interrupt endpoint in removed().
May help with some KDLs.
2024-01-29 22:06:34 -05:00
Augustin Cavalier
5c2c391d20 TCP: Remove overridden default buffer size.
The default of 65535 now seems to work OK,
following previous commits.
2024-01-29 16:06:25 -05:00
Augustin Cavalier
c4f37b0017 TCP: Initiate a send before waiting in SendData().
Otherwise, we will sit around here waiting forever,
with the send queue full but nothing actually sending
data.
2024-01-29 16:05:54 -05:00
Augustin Cavalier
0382176581 IPv4: Overall MTU is 65535 (0xFFFF).
If the route supports a greater MTU, we need to
clamp it.

The loopback reports an MTU greater by one byte
(65536), and if we don't clamp it here, TCP will
try to send packets actually that large (and fail.)
2024-01-29 16:05:11 -05:00
Máximo Castañeda
3c51bab74e runtime_loader: remove unnecessary loop
Left behind when we moved from changing only /usr/bin/env to anything
under /usr/bin.

Change-Id: I9ceba844e18deda5f3d395fc6b5df84a1a8ce363
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7360
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2024-01-29 18:58:44 +00:00
Máximo Castañeda
621200ebbd BOutlineListView: fix ItemUnderAt and accept NULL as superitem
ItemUnderAt was returning items that were not under the superitem (this
was fixed for EachItemUnder in hrev52210).
Make a NULL superitem mean the parent of the topmost items. Despite not
being explicitly documented in the BeBook, that's how BeOS works, the
MenuWorld test app uses it and, well, it's handy.

Change-Id: I2551e8ce874a6238c5e5fb1eb742e68e62d3928a
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7359
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
2024-01-29 18:58:03 +00:00
Máximo Castañeda
787179956b tools/elfsymbolpatcher: fix format warnings
Change-Id: I3e7d2feff9e8bfae981d2f16f95adb835870cdd5
2024-01-29 19:30:26 +01:00
Máximo Castañeda
d579eb9efe HaikuBook: minor fixes
Fix some copy-pasta and strange grammar.
Remove a note that seems unnecessary in context and easy to misinterpret
out of context.

Change-Id: If1ce26b293c8098c260a9697fb0ef0611a4958c4
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7358
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
2024-01-29 18:15:16 +00:00
Trung Nguyen
ba9a9ce167 headers/os: Add missing Interface Kit includes
Adds headers that have not been directly or indirectly included by
the "InterfaceKit.h" master include.

Change-Id: Id163e0e8db54bc553593819801e0e854cde78fa3
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7376
Reviewed-by: Niels Sascha Reedijk <niels.reedijk@gmail.com>
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
2024-01-28 20:36:07 +00:00
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>
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>
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>
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>
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 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 3ab43722bf.

Now that GetSupportingApps does case conversion, we don't need to do it here.
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.
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
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>
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>
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>
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>
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>
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>
2024-01-21 09:26:50 +00:00
Autocomitter
136aeaaa47 Update translations from Pootle 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>
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>
2024-01-18 17:44:40 +00:00