Commit Graph

59474 Commits

Author SHA1 Message Date
Augustin Cavalier
8267c19341 freebsd_network: Lots of additions and modifications for iflib. 2019-01-03 21:20:34 -05:00
Augustin Cavalier
88c3c4fa49 freebsd11_wlan: Disable sysinits.
These are currently no-ops; but soon enough they won't be...
2019-01-03 21:20:33 -05:00
Augustin Cavalier
92d70a24ca freebsd_network: Fix and implement some mbuf functions.
Spotted while reviewing the code during iflib porting.
2019-01-03 21:20:33 -05:00
JackBurton79
fe55edcaf4 Terminal: Font width can be a fractional value, so we need to use a float.
Adapt other code accordingly. Minimum changes to fix ticket #11478
In theory also font height could be fractional, so we might need to
review other parts of the code.

Change-Id: Idbdbe38193ca5a32b3d09c7cf9accfc917760cae
Reviewed-on: https://review.haiku-os.org/821
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Reviewed-by: Stephan Aßmus <superstippi@gmx.de>
2019-01-03 21:27:27 +00:00
PulkoMandy
4c1d9cf74e Fix "since" entries in BPropertyInfo.
These methods and fields are missing from the R4 and R5 Be Book, but are
mentionned in the R4 release notes and present in the R5 headers.

Change-Id: I4de8298449bd66e0ee7fe0b52690552916314123
Reviewed-on: https://review.haiku-os.org/820
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2019-01-03 19:09:22 +00:00
Stephan Aßmus
f8550e541b Added two DrawStringDry() versions for obtaining pen location only
When recording into a BPicture (ServerPicture, actually), one cannot
simply record the commands only, when the drawing itself would modify
state. This affects all drawing commands that change the pen location.
Therefore it is necessary to have a way to "dry-run" drawing a string
in order to know the pen location that would result. This is what
these two new methods help achieve.

Change-Id: Ic399a5513f18c12c16c0ab10a55e768c1b30e4e0
Reviewed-on: https://review.haiku-os.org/816
Reviewed-by: Rene Gollent <rene@gollent.com>
2019-01-03 18:19:02 +00:00
Michael Lotz
6990ae7b84 Installer: Fix use-after-free of target directory name.
When CopyEngine::_CopyFolder() would recursively call itself, the
fCurrentTargetFolder would be set to the entry name of that directory.
When this returned, this was never reset to the parent directory name
and would eventually use a freed string when the BEntry was reused
for the next entry.
2019-01-03 14:08:59 +01:00
Stephan Aßmus
f10faf61ac Change DrawString() and add StrokeLine() to reveal wrong pen-position
Change-Id: Iec584657741f2bb682bff557dcd3b733a9166c7c
Reviewed-on: https://review.haiku-os.org/815
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2019-01-02 21:21:52 +00:00
Stephan Aßmus
1876ba00cd DrawState: Return mask from ReadFontFromLink()
When changing the font state, a uin16 mask at the beginning of the
commands encodes which font parameters are transmitted in the link
data. Return this mask, so that one can know what parameters have
changed in the DrawState's ServerFont.

Change-Id: I52a9a665aac8eb0e6505193eba32c4b137846c78
Reviewed-on: https://review.haiku-os.org/814
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2019-01-02 21:21:52 +00:00
Michael Lotz
ddb1ff5587 kernel/x86_64: Fix overwriting the GDT/IDT by each CPU.
The constructor calls for GlobalDescriptorTable and
InterruptDescriptorTable were run on each CPU, each time clearing out
any changes already done on other CPUs.

For the IDT this didn't matter as the result would always be the same.
In case of the GDT the result would surprisingly be mostly hidden. The
used GDT entries are for the double fault stacks (which is rarely hit),
the user TLS (which will only be used in compat mode) and the TSS which
is immediately cached in the task register.

The clearing of the GDT allowed for a tiny window of time between
setting up the entry for the TSS and it actually being loaded (and
cached) in the task register. When this happened, the load of the TR
caused a not present fault, which at this point leads to a tripple
fault and reset due to no fault handlers being installed yet.

Fixes #14659.

Change-Id: I6e5c00d412ab17c3ef05740ba71228e6ca266c1e
Reviewed-on: https://review.haiku-os.org/810
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
2019-01-02 16:27:53 +00:00
Michael Lotz
22ca923f71 kernel/x86_64: Fix descriptor index off-by-one in assert.
This was apparently copied from GlobalDescriptorTable::SetTSS() which
needs two table entries and therefore checks for index + 1. For the
SetUserTLS case this isn't needed and would cause aborts when reaching
the maximum CPU count (64 currently).

Change-Id: I27bd777fedadbd3740ac8c791199ec9300b06327
Reviewed-on: https://review.haiku-os.org/809
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2019-01-02 00:22:14 +00:00
Michael Lotz
44a1cfb8d8 kernel/x86: Reimplement locking for early boot message output.
The normal locking uses spinlocks that require getting at the current
CPU, which in turn needs a current thread set. This has not been set up
at this point and would simply cause tripple faults.

Use manual locking using atomic ops instead.

Change-Id: Ica894389330ef481eec84b667234139746ac4a46
Reviewed-on: https://review.haiku-os.org/808
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2019-01-02 00:22:14 +00:00
Adrien Destugues
d52d36aa5d open: don't print "invalid argument" when opening an URL.
Reset the error code.

Change-Id: I5b58c3082f5758d4cbca8c9706048e3414f939c9
Reviewed-on: https://review.haiku-os.org/807
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2019-01-01 17:48:29 +00:00
Humdinger
b02e6250e9 Mail: fix layout when resending
When resending a mail, don't put the To-field in the second column
after the From-field as it's done for incoming mail. To- and From-field
are the same layout as for creating a new mail.

Use the member fResending instead of the parameter "resending" the
THeaderView was called with.

Initialize fCcControl in ctor.
2018-12-30 10:39:33 +01:00
Michael Lotz
02f41b1a74 app_server: Cleanup argument checks to use boolean expressions. 2018-12-29 00:52:05 +01:00
Michael Lotz
3752309050 app_server: Cleanup error check logic to be more consistent.
Some of these only returned generic errors.
2018-12-29 00:52:05 +01:00
Michael Lotz
8071db3259 app_server: Add char limit to GlyphLayoutEngine::LayoutGlyphs().
Many of the consumers fill in data into preallocated arrays. Some of
them already ignored values past the array size manually, some didn't.

Add a maxChar argument and set it from the incoming array sizes for
the various consumer cases.
2018-12-29 00:52:05 +01:00
Michael Lotz
64a11edb02 app_server: Make more use of BStackOrHeapArray.
Variable length arrays on the stack are always risky when the length
is indeterminate as they can easily overflow the stack. Replace their
use by BStackOrHeapArray, fixes #6354.

Also replace most other dynamic allocations by BStackOrHeapArray as
it is more convenient and may avoid unnecessary dynamic allocations.

Add allocation checks and early returns to all places while at it.
2018-12-29 00:52:05 +01:00
Michael Lotz
22ce55254f app_server: Fix invalid cast of int32 to size_t array.
Make ServerFont::GetBoundingBoxesForStrings() use size_t.
2018-12-29 00:52:05 +01:00
Michael Lotz
9dad3fb4b0 app_server: Style and comment cleanup, no functional change. 2018-12-29 00:52:05 +01:00
Barrett17
e7933432e9 BCodecRoster: Remove MakeFormatFor
* I want to introduce a new way for plugins to
register for a format. Supporting the old FormatManager is
too painful at this point and not worth the effort.
2018-12-28 23:01:02 +01:00
Barrett17
fa911df6e6 Move FormatManager back to the media_kit
* We don't aim to replicate this functionality. I don't
think this will be useful at all in future iterations.
Originally I planned to rewrite it on top of the new
BMediaFormat, but now I am of the hopinion this is
greatly unneeded.
2018-12-28 22:55:25 +01:00
Barrett17
49a4b18141 media_server: Clean unused gFormatManager object 2018-12-28 22:24:07 +01:00
Barrett17
f3e317617f Move GetNextEncoder implementations to BCodecRoster 2018-12-28 22:24:07 +01:00
Barrett17
708de94fde MetaData: Add doxygen brief 2018-12-28 22:24:07 +01:00
Augustin Cavalier
0c3e5b9745 ipro100: Upgrade to FreeBSD 12. 2018-12-27 16:55:48 -05:00
Augustin Cavalier
522d143920 emulex_oce: Upgrade to FreeBSD 12. 2018-12-27 16:55:35 -05:00
Augustin Cavalier
2aaa3af64d dec21xxx: Upgrade to FreeBSD 12. 2018-12-27 16:55:23 -05:00
Augustin Cavalier
25531c5613 broadcom570x: Upgrade to FreeBSD 12; fix logic inversion in Haiku code.
See inline comment in brgphy.c.
2018-12-27 16:54:24 -05:00
Augustin Cavalier
65124582dc broadcom440x: Upgrade to FreeBSD 12. 2018-12-27 16:54:15 -05:00
Augustin Cavalier
3bfc859a38 attansic: Upgrade to FreeBSD 12. 2018-12-27 16:53:47 -05:00
Augustin Cavalier
ca813faa3c atheros813x: Upgrade to FreeBSD 12. 2018-12-27 16:53:24 -05:00
Augustin Cavalier
b240ae40df ar81xx: Upgrade to FreeBSD 12. 2018-12-27 16:53:15 -05:00
Augustin Cavalier
71f1250df5 3com: Upgrade to FreeBSD 12. 2018-12-27 16:52:27 -05:00
Augustin Cavalier
d5b99ecde7 freebsd_network: Some small additions for FreeBSD 12 drivers. 2018-12-27 16:51:48 -05:00
Augustin Cavalier
125df15288 drivers/vlance: Remove.
Never included in the build, and entirely superseded by the "pcnet"
driver from FreeBSD.
2018-12-27 14:15:30 -05:00
Augustin Cavalier
3592a2eba4 vt612x: Clean up Jamfiles. 2018-12-27 14:14:45 -05:00
Augustin Cavalier
9b7ef99599 syskonnect: Clean up Jamfiles. 2018-12-27 14:14:45 -05:00
Augustin Cavalier
34b46b4548 rtl8139: Clean up Jamfiles. 2018-12-27 14:14:45 -05:00
Augustin Cavalier
72d64e3cb1 rtl81xx: Clean up Jamfiles. 2018-12-27 14:14:44 -05:00
Augustin Cavalier
df1dd1f8a8 rdc: Clean up Jamfiles. 2018-12-27 14:14:44 -05:00
Augustin Cavalier
cb5334b37b pcnet: Clean up Jamfiles. 2018-12-27 14:14:44 -05:00
Augustin Cavalier
148d1b2c69 nforce: Clean up Jamfiles. 2018-12-27 14:14:44 -05:00
Augustin Cavalier
3fcac9ac04 marvell_yukon: Clean up Jamfiles. 2018-12-27 14:14:43 -05:00
Augustin Cavalier
360f405d3d packages/HaikuSource: Place sources into develop/sources.
Fixes #14781.
2018-12-27 13:08:03 -05:00
Barrett17
e0a0f13051 ffmpeg: Use unsigned integers for chapter data 2018-12-27 12:26:45 +01:00
Barrett17
e98351d3bc MetaData: Revert types to uint32 and define framerate as float
* Adds some missing methods signatures.
* integer vs float framerate is a longstanging debate. In theory,
in digital a/v there should not be need for floating point framerates.
This is because unless the software is run on exoteric hardware, there
is not need for it. Unfortunately, some legacy from the past like the
29.7 hz debate (NTSC) still may need to work under floating point framerates.
Even if in pratice it'd be run at 30 hz anyway.
* In theory, to handle all those correctly we should use a rational framerate,
however most code should be rewritten to support that correctly, and
it'd add some excessive complexities.
* All integer types are reverted back to unsigned ones. There's really
no reason to use signed integers there, and more importantly the danger
for integer underflows and the attached security concerns is very big.
2018-12-27 12:26:45 +01:00
Barrett17
ec75b9fc8e MetaData: Add missing keys 2018-12-27 12:26:44 +01:00
Michael Lotz
13beda00d3 kernel: Fix race condition when waiting for load of new team.
There was no synchronization of the check of the done flag and the
waiting thread suspending to wait for it. It was therefore possible that
the new team both set the flag and triggered the wakeup of the waiting
thread in that time window, causing it to miss both the set flag and the
thread resumption.

Use a condition variable instead.

Fixes #13081.

Change-Id: I93c45db8dd773fe42b45c4b67153bcd39e200d3b
Reviewed-on: https://review.haiku-os.org/803
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2018-12-26 23:48:41 +00:00
Augustin Cavalier
b5ccfd350d ntfs: Actually return errors from fs_mount.
This should fix the "mount succeeded but ops is NULL!" panic that
occurs on auto-mounting read-only NTFS disks on boot.
2018-12-26 17:30:28 -05:00