Commit Graph

58534 Commits

Author SHA1 Message Date
Augustin Cavalier
ffd36865cf sata_request: Cargo-cult some behaviors from FreeBSD.
See 13778#comment:3 for information on FreeBSD behaviors.

I didn't manage to locate where the specification talks about this
(but my specification-fu is rather poor), and it didn't fix the check_sense
syslog spamming on my machine.

But it seems to continue to function as before on my hardware as well as
VirtualBox and VMware, so perhaps it might fix something else.

Signed-off-by: Alexander von Gluck IV <kallisti5@unixzen.com>
2018-07-10 17:43:14 -04:00
John Scipione
e88a89e676 Appearance Prefs: drag and drop between ColorWhichItems
Fixes final piece of #8618

Already added support for list items to drag colors out and you can
drag and drop between the list items and preview. but, what was
missing was drag and drop between list items. Updated
ColorWhichListItem to also accept color drops through their
parent ColorWhichListView.

Also included some related style fixes, use B_RGB_COLOR_TYPE
constant in place of (type_code)'RGBC'. 80-char limit fixes.

Simplify similar code in ColorPreview class to parse out rgb_color
from message.

ColorPreview passes dropped color along to APRView

APRView no longer accepts color drops, this is handled by ListView
and ColorPreview now.

Consolidated "RGBColor" and "which" message name strings into
constants defined in defs.h.

Change-Id: I88ec2a4ffe077620ec4cc3b032196cbff0f09615
2018-07-10 21:20:09 +00:00
Murai Takashi
5d898e77d2 Media addon server: Suppress warnings
Use media_format.Clear() to suppress -Werror=class-memaccess
pointed out by gcc8.

Change-Id: Ib75ee4cb7aa8018af25dd6bdcf79b4dd7c14d240
2018-07-10 21:19:35 +00:00
Augustin Cavalier
12552deffc freebsd11_network: Use FreeBSD's usbdevs file.
Since eventually FreeBSD drivers will be using it, this makes more sense.
Adapt the pegasus driver to it (there's all of one ID out of some multiple
dozen that isn't in the file...)
2018-07-09 23:11:00 -04:00
Augustin Cavalier
9fcd8dadfe freebsd11_network: Adopt the generation of usbdevs.h.
The only thing using it at present is the "pegasus" driver, so it
already doesn't make a lot of sense to keep it in src/apps/devices.
Since in the future it will be used by FreeBSD USB network drivers,
it makes sense for the FreeBSD compat layer to adopt it.

Also some related cleanup to the awk files -- they are now stored
in a "tools" subdirectory, which is more similar to where FreeBSD does it.
We are also now using FreeBSD's usbdevs2h.awk instead of NetBSD's,
as this seems to fit with the overall schema.
2018-07-09 23:09:21 -04:00
Augustin Cavalier
131c64ad4a vfs: Add missing NULL check of volume->ops.
I got a reproducible KDL that upon close inspection seems to have been
a NULL dereference of this, thanks to GCC's mix-source-and-assembly
functionality.

Unfortunately, I deleted my mount_server settings before I fully understood
what was going on, and afterwards it no longer reproduced, so it seems to
have been related to that. I'm confident enough this is the correct fix to
commit it anyway.
2018-07-09 21:08:57 -04:00
Alexander von Gluck IV
e66bdff5cc build/arch: Adjust min. ppc floppy + archive sizes. Now used.
Change-Id: I9bfcc79e1db623542258953a781de6e7b2e44f92
2018-07-09 10:38:10 -05:00
Alexander von Gluck IV
da54ef94a8 build/profiles: Add @minimum-cd profile for things like ppc
Change-Id: Id50d6ff6eaca598c00043d5668ad836a48a74262
2018-07-09 10:36:07 -05:00
Alexander von Gluck IV
18e7b99797 build: Drop specalized haiku-boot-cd-ppc target
* Now generated via haiku-boot-cd when target ppc

Change-Id: I1d4e83c4d95ebc18b0dab28ffb2af03db5dc9d1d
2018-07-09 09:46:30 -05:00
Augustin Cavalier
4c43ed243f freebsd11_network: Don't panic on bus_describe_intr. 2018-07-08 15:46:01 -04:00
Jérôme Duval
de2ba86e5e ntfs: gcc2 build fixes. 2018-07-08 19:29:31 +02:00
Jérôme Duval
65e832b71a exfat: fix warning. 2018-07-08 19:19:18 +02:00
Jérôme Duval
d04d6d36d1 bindfs: fix warnings on x86_64. 2018-07-08 19:18:57 +02:00
Jérôme Duval
30be8412d9 ntfs: add comments for NULL interface functions. 2018-07-08 19:04:22 +02:00
Jérôme Duval
a2a8608d32 ntfs: fix signature of fs_mount(). 2018-07-08 19:04:22 +02:00
Jérôme Duval
6ad86087a6 ntfs: convert attributes.* to unix endlines. 2018-07-08 19:04:21 +02:00
Jérôme Duval
c6ee40d2a1 ntfs: attributes read() and write() now pass a kernel buffer to libntfs.
same as f8d3a9ee49 for attributes.
2018-07-08 19:04:06 +02:00
Jérôme Duval
f8d3a9ee49 ntfs: read() and write() now pass a kernel buffer to libntfs.
when a user buffer is provided, we now pass a 128KB kernel buffer
to libntfs. The old loop in case of partial buffer read/write
was useless as ntfs_attr_pread() and ntfs_attr_pwrite() were
provided the same buffer. The new loop fills/dumps the user buffer
from/to the kernel buffer.
when a kernel buffer is provided, it is passed to libntfs, the new
loop exits after one cycle.
2018-07-08 19:02:37 +02:00
Augustin Cavalier
b0e0298370 bluetooth: Remove non-Haiku target platforms logic. 2018-07-07 17:04:19 -04:00
Augustin Cavalier
cf5cc3958d freebsd11_network: Additions for atheroswifi. 2018-07-07 14:24:06 -04:00
Augustin Cavalier
6c9b5f2292 aironetwifi: Sync with FreeBSD 11.1.
Untested; but the changes are relatively minimal.
2018-07-07 14:24:05 -04:00
Augustin Cavalier
76218ef1ca freebsd11_network: Add bus_alloc_resource_anywhere. 2018-07-07 14:24:04 -04:00
Jérôme Duval
208c323649 real_time_clock: fix _user_get_timezone() after 6ad3d25212
6ad3d25212 changed the timezoneOffset type from
time_t to int32 without adjusting the user_memcpy size. Harmless as the
function is hardly used with a non-null argument.
2018-07-07 16:07:39 +02:00
Augustin Cavalier
1b98805383 freebsd11_network: Restore the old mbuf member access mechanism.
This time with a comment noting that they work around a GCC2 compiler bug,
so some poor soul doesn't make the same mistake I did. Fixes the GCC2 KDLs
caused by my previous commits.
2018-07-06 18:28:18 -04:00
Augustin Cavalier
8101468dbf jmicron2x0: Sync with FreeBSD 11.1.
Same Jamfile cleanups as previous commits.

This completes the upgrade of wired ethernet drivers to 11.1! :D
2018-07-06 18:28:17 -04:00
Augustin Cavalier
081fecc2f1 dec21xxx: Sync with FreeBSD 11.1.
Same Jamfile cleanups as in previous commits.
2018-07-06 18:28:17 -04:00
Jérôme Duval
4603cb3cd3 bootstrap: update binutils x86_64 versions. 2018-07-06 19:01:27 +02:00
Jérôme Duval
defd975ae2 Update libroot stubs. 2018-07-06 18:59:36 +02:00
Augustin Cavalier
ac555254d4 idualwifi7260: GCC2 fixes (again.) 2018-07-06 11:38:18 -04:00
Augustin Cavalier
4cc829dc65 freebsd11_network: Synchronize fbsd_uipc_mbuf with FreeBSD 11.
Includes changes to the mbuf struct to more closely mirror FreeBSD 11.
Tested with the idualwifi7260 driver.
2018-07-06 10:58:45 -04:00
Augustin Cavalier
5af0299e37 freebsd11_network: Implement m_ext reference-counting and M_NOFREE.
Some FreeBSD developers report that this is required for HT mode, which
might explain why it's so broken on Haiku. I was also told the iwm driver
requires it for multi-frame RX, but as per the previous commit it still
KDLs even with it.

This commit also includes a refactor of the mbuf header implementation,
which now more closely mirrors FreeBSD's.
2018-07-06 10:32:45 -04:00
Augustin Cavalier
1431b61885 idualwifi7260: Properly enable the SINGLE_FRAME flag.
I did this correctly in the original commit, but then inverted the logic
in my C89 fixes commit by mistake ... whoops.

It seems to cause double-frees even with mbuf refcounting (though they do
occur later on), so leave it fully disabled for now.
2018-07-06 10:30:52 -04:00
Augustin Cavalier
ac06bf48c4 freebsd11_network: Combine Unit.cpp and unit.c into unit.cpp.
There's a number of these "C++ wrappers for C code" wrappers in the
freebsd_network compat layer, and there don't seem to be very many
good reasons to use them. We can just as well declare these C++ functions
with C linkage so they can be used from C code directly. So, time to
start cleaning this up.
2018-07-05 22:22:38 -04:00
Augustin Cavalier
49da1d2e3b crypt: Use int8 instead of int. 2018-07-05 22:04:35 -04:00
Augustin Cavalier
61e7a6b1f9 3com: Sync with FreeBSD 11.1.
No functional changes to the actual driver, it seems.
2018-07-05 17:13:11 -04:00
Andrew Lindesay
3b17d8dd7f HaikuDepot / PackageKit: Repositories 'Identifier' URL
Repositories are identified with a 'url' in the
remote 'repo.info' file.  There is also a
'base url' which is the URL locally with which
the system is able to access the repository
data on.  There is some confusion between these
two terms in the source.  This change aims to
separate the two out and consistently name them.
The settings for the repository locally also was
not storing these values and that has been fixed.
Debug info about the repositories also did not
display the two urls consistently and will now
also do so.  Finally, HaikuDepot now correlates
locally configured repositories with the data in
HaikuDepotServer using the identifier URL; this
makes the use of mirrors with HaikuDepot possible.

Fixes #13888
Change-Id: I66dfe589b05c24e1ab123a6945352e0f24b60bf1
2018-07-05 20:06:54 +00:00
Augustin Cavalier
a00c8c4491 freebsd11_network: Add another missing NULL check to taskqueue_free.
Also add missing \ns to the new printfs.
2018-07-05 15:46:02 -04:00
Murai Takashi
c7eabc40dc JPEGTranslator: Replace strncpy() with strlcpy()
Replace strncpy() with strlcpy(), since destination size equals
maximum number of characters to copy.
Pointed by gcc8 [-Werror=stringop-truncation].

Change-Id: I3e2a98802ddb379890aefaf8c3f0efb1cd347188
2018-07-05 13:12:56 +00:00
John Scipione
e2d19ae5b7 BListView: do not modify selection on MouseUp if drag & drop
bug seems to have been introduced only recently in hrev52062
2018-07-04 21:55:35 -07:00
Augustin Cavalier
4e5f9d9753 idualwifi7260: C89 fixes to appease GCC2. 2018-07-04 21:50:14 -04:00
Augustin Cavalier
e89c61736e drivers/network/wlan: Import idualwifi7260 from FreeBSD 11.2.
The lowest model number supported by this driver is "3160", but that's just
Intel's insanity: the 7260 was released the quarter before it. So following
our naming convention strictly, "7260" is the correct name for this driver.

The firmware situation for this one is also a little different. Unlike past
instances where Intel has released mostly nonsubstantial firmware updates,
allowing us to just copy a recent-ish version from the iwlwifi archives,
the firmware is more closely tied to the driver in this series. As a result,
some of this firmware is not even used by Linux yet (they're a few versions
behind it seems), so the firmware packages included here come from FreeBSD.

One major hardware feature - RX of multiple frames at a time - is disabled
in this commit, as it depends on mbuf reference-counting, according to the
FreeBSD developers I asked, which we do not implement yet. I'll hopefully
get to looking at that in the next few weeks.

And with that, I finally have WiFi on my primary laptop, my original reason
for setting out on this quest last year. This commit was pushed through it,
even :)
2018-07-04 20:46:32 -04:00
Augustin Cavalier
999fe6b3ea freebsd11_network: Additions for idualwifi7260. 2018-07-04 20:46:31 -04:00
Augustin Cavalier
02463a2c73 freebsd11_network: Handle NULL gracefully instead of faulting.
FreeBSD does not have these checks, but drivers seem to expect that they
can call these functions with NULL and not crash.

Fixes a number of boot-failure tickets (and makes it possible for me at least
to test drivers without rebooting from KDL every failure), though of course the
drivers themselves will still not work.
2018-07-04 20:46:31 -04:00
John Scipione
6fdf2dd2b3 Tracker: center text horizontally again
We alwasys draw text at the bottom of the calculated TextWidget
rect, that's why it needed to be centered to get the desired
placement. However, there is two places
2018-07-04 16:35:06 -07:00
John Scipione
6b9353b4a3 Tracker: Revert to previous CalcRectCommon bottom calc
... in list mode. Fixes #12997

This bug was introduced in hrev50528 along with new 32x32 icon size
in list mode. I'm not sure what I was thinking on this particular
line but reverting it seems to fix the problem and logically the
original code makes sense.
2018-07-04 14:08:38 -07:00
Andrew Lindesay
cd417b96c9 HaikuDepot: Trace Logging of RPC Payloads
Changes the trace logging so that JSON-RPC payloads
are included in the log stream.  Also fixes a
memory-leak in the JSON-RPC client.

Change-Id: Ic19c64869acc525232a60ac2fd814a71bfdafdc8
2018-07-04 13:27:42 +00:00
John Scipione
1dd1976fba Deskbar: update time width based on Deskbar orientation.
Fixes #8641

To fix this bug first I had to fix a long-standing todo:
TODO: SetOrientation never gets called, fix that when in vertical mode,
we want to limit the width so that it can't overlap the bevels in the
parent view.

I made TBarView a friend class of TReplicantTray and called
fReplicantTray->fTime->SetOrientation() when switching between
horizontal and vertical mode. I could have added a setter method
instead but I didn't feel like it was worth it.

SetOrientation calls ResizedToPreferred which calls GetPreferredSize,
which resizes the text width, then it calls CalculateTextPlacement
which places the time string correctly.

Removed GetCurrentTime invocation from GetPreferredSize since that
happens in Update already. Was added in
573f748c5f originally.

Also need to call SetOrientation in TReplicantTray::AttachedToWindow
just after creating the TTime object in order for it to resize the
time view correctly on startup in horizontal mode. It needs to know
that it is horizontal so that it will expand to fit longer than
default time string.
2018-07-04 12:31:23 +00:00
David Murphy
f5face4114 BListView: Fix drag n' drop in multi-select mode
Move list selection logic into MouseUp instead of MouseDown
Change-Id: I4e7c7f6636dabce130578777b5e1203d6695499a
Fixes #9190
2018-07-04 00:47:01 +00:00
Augustin Cavalier
382d022473 libroot: Use 'int' not 'char' in crypt code.
It seems 'char' is unsigned on ARM, so GCC errors on the -1s in here.
2018-07-03 19:08:33 -04:00
Augustin Cavalier
b806d76f78 HaikuPortsCross: Updates for ARM. 2018-07-03 19:06:33 -04:00