Commit Graph

257715 Commits

Author SHA1 Message Date
knakahara
7b815c4232 fix ipsecif(4) unmatch curlwp_bind.
XXX pullup-8
2018-04-06 09:28:26 +00:00
knakahara
cc1df90a04 fix ipsec(4) encap_lock leak.
XXX pullup-8
2018-04-06 09:24:13 +00:00
ozaki-r
6ca7de5d0d Add tests for GARP without DAD
Additionally make the existing tests for GARP more explicit.
2018-04-06 09:23:36 +00:00
ozaki-r
9e4591fa4a Show outputs of commands if $DEBUG 2018-04-06 09:22:38 +00:00
ozaki-r
4cb98a5a0c Improve packet checks and error reporting 2018-04-06 09:21:57 +00:00
ozaki-r
d9bc5a721a Don't set IN_IFF_* flags to ia4_flags if DAD is disabled
This fix allows that a GARP packet is sent when adding an IP address to an
interface with IFF_UP on a kernel with IPv4 DAD is disabled
(net.inet.ip.dad_count=0), which is the same behavior of NetBSD 7, i.e.,
before introducing the IPv4 DAD.
2018-04-06 09:20:29 +00:00
ozaki-r
6cc7615fd0 Simplify; clear then set flags to ia4_flags (NFCI) 2018-04-06 09:19:16 +00:00
bouyer
1ff0364419 Fix bad cut'n'paste, pointed out by David Binderman in PR port-arm/53158 2018-04-06 08:23:40 +00:00
mrg
ffba61a5f0 switch m68000 and m68k to GCC 6. ok mlelstv. 2018-04-05 22:38:58 +00:00
christos
019d365a3a Pass -S to ed(1) so that patches containing ! commands don't run commands.
Real cause of CVS-2018-0492:
    https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=894667)
2018-04-05 18:50:10 +00:00
christos
c02518ebec add -S to disable ! commands. 2018-04-05 18:44:57 +00:00
christos
7a9e78e3c6 Appease the compiler gods; yes I know what I am doing adding to a literal
string.
2018-04-05 16:31:54 +00:00
maxv
3e56f9fe75 Set the "method" string at boot time too. 2018-04-05 15:04:29 +00:00
maxv
7ca564306b Hum, don't let userland set bit 13, because this can crash the kernel. 2018-04-05 14:14:27 +00:00
maxv
1521863a51 Fix the check, should be >=. 2018-04-05 14:11:20 +00:00
wiz
349b123f81 Use mdoc macros. 2018-04-05 11:07:00 +00:00
jmcneill
fa54a1e96e Remove AWIN_DEBE_FWINIT blocks 2018-04-05 10:21:39 +00:00
jmcneill
c79f4661ef Remove NAWIN_MP blocks (this code was experimental in the original driver and is not worth porting over) 2018-04-05 10:19:25 +00:00
maxv
0ec930420c Call cpu_speculation_init on i386 too. We don't have IBRS for i386, but
we do have the AMD DIS_IND method.
2018-04-05 08:43:07 +00:00
mrg
ab8259cd20 pretty much everything depends upon insn-opinit.h via optabs-query.h
so set it in DPSRCS.  hopefully this fixes PR 53137.
2018-04-05 05:38:59 +00:00
ozaki-r
1ff21b4734 Kill remaining rt->rt_refcnt++ 2018-04-05 03:39:14 +00:00
christos
331fc54718 Be more selective about detecting a SYSV include as opposed to a dependency
line. Dependency lines should contain a '::' operator or ':<space>'.
2018-04-05 00:31:10 +00:00
kamil
8e4f836c68 Add new ATF tests for Address Sanitzier (ASan)
Add new C and C++ tests:
 - t_asan_double_free
 - t_asan_global_buffer_overflow
 - t_asan_heap_overflow
 - t_asan_off_by_one
 - t_asan_uaf

Each tests checks:
 - regular build
 - 32-bit
 - PIC
 - PIE
 - profile

These tests require paxctl(8) to disable ASLR in order to work in a
predictable way. This is especially true for all !regular builds with
additional compiler flags.

There are no static variations of these tests as this mode is not supported
in upstream ASan.

Enable these tests on amd64 and i386.

This is part two patch, adding the remaining C++ changes.

Patch submitted by <Siddharth Muralee>
Additional polishing by myself.
2018-04-04 23:53:26 +00:00
kamil
9f0bdbd997 Add new ATF tests for Address Sanitzier (ASan)
Add new C and C++ tests:
 - t_asan_double_free
 - t_asan_global_buffer_overflow
 - t_asan_heap_overflow
 - t_asan_off_by_one
 - t_asan_uaf

Each tests checks:
 - regular build
 - 32-bit
 - PIC
 - PIE
 - profile

These tests require paxctl(8) to disable ASLR in order to work in a
predictable way. This is especially true for all !regular builds with
additional compiler flags.

There are no static variations of these tests as this mode is not supported
in upstream ASan.

Enable these tests on amd64 and i386.

Patch submitted by <Siddharth Muralee>
Additional polishing by myself.
2018-04-04 23:51:35 +00:00
christos
56c37d109f Rename Xpreempt{recurse,resume} -> X{recurse,resume}_preempt so that
they fit the pattern. Also the debugger trap sniffer matches them
without adding special entries...
XXX: pullup-8.
2018-04-04 22:52:58 +00:00
sevan
f1fc57f92c Drop superfluous zero prefix for single digit number days.
heads up by wiz
2018-04-04 21:39:35 +00:00
kamil
d03dc37b86 Sort files in usr/tests/usr.bin/c++/
No functional change intended.
2018-04-04 16:42:48 +00:00
maxv
f74fceec4d Add machdep.spectre_v2.method, a string that tells which method is
active.
2018-04-04 16:23:27 +00:00
bouyer
e81d8d6ba7 Reset more regs at attach time, just in case.
As the mux is in unit 0 but is used by both units, we have to keep
  unit 0's ahb clock enabled.
Properly set sc_output_type.

Now pipeline 1 can be activated without activating pipeline 0 first.
2018-04-04 16:01:05 +00:00
kamil
b4fcb5aedb Correct a small regression typo in usr.bin/c++ ATF tests
TESTS_SH= changed to TESTS_SH+=
2018-04-04 15:53:04 +00:00
kamil
b269e95d9e Sort entries in ATF tests in tests/usr.bin/c++/Makefile
No functional change intended.
2018-04-04 15:08:59 +00:00
maxv
279bb94ad7 Enable the SpectreV2 mitigation by default at boot time. 2018-04-04 12:59:49 +00:00
msaitoh
ecb0e846c2 Regen. 2018-04-04 10:17:52 +00:00
msaitoh
41435ec414 Add Intel Coffee Lake internal graphics devices. From ark.intel.com. 2018-04-04 10:17:22 +00:00
martin
01cb86bb02 Unconditionally include <unistd.h>, as we use ftruncate() unconditionally
too.
Reported (with patch) by Antonio Huete Jimenez in PR 53153, slightly
modified by me.
2018-04-04 09:19:33 +00:00
msaitoh
6ce01cf369 Sync with FreeBSD r331224 except ixv_if_update_admin_status()'s change:
- Fix length of reading buffer when the command is Read Flash in
   ixgbe_host_interface_command().
 - Add missing start_hw() call in ixv_init_locked(). This is not a real bug
   because start_hw just set hw->adapter_stopped to false and anyone refer it.
 - Style change.
 - Update comment.
2018-04-04 08:59:22 +00:00
msaitoh
a06ca63375 Sync with the remaining part of FreeBSD r328265 except sfp_reinit stuff:
- Always schedule module intterrupt in ixgbe_config_link() when a device is
   SFP+ based.
 - Use not loop index but txr->me in ixv_initialize_{transmit,receive}_units().
   It's required for VMDQ but NetBSD doesn't use it, so it's not a bug in
   NetBSD.
 - Simplify ixgbe_bp_wd_set(). No functional change.
 - Whitespace.
2018-04-04 08:13:07 +00:00
msaitoh
2bd987c2e0 Fix a bug that "ifconfig ixgN down up" forgot IFM_NONE setting.
- Don't assume autoneg == 0 is the first call of ixgbe_config_link().
   Check ifm_media, too.
 - Don't override autoneg_advertised in ixgbe_get_phy_id_fw() to not to
   be inconsistent with if_media value.
2018-04-04 06:30:09 +00:00
kre
deb0051437 Document opendisk1() - it has been around long enough.
(pity about the name...)

XXX pullup-8
2018-04-04 04:43:46 +00:00
sevan
9835dc7a54 Some further changes from PR bin/48395. 2018-04-03 21:57:14 +00:00
joerg
f80c3669c3 Rework ifunc support to address a number of short comings:
- Move to a shared _rtld_call_ifunc for rel and rela architectures
- Architectures using rel format must patch IRELATIVE non-PLT
  relocations like RELATIVE in additition to the later ifunc handling
- Consistently record the delta to the end of the relocation group for
  non-PLT IRELATIVE relocations

Hidden ifunc is now supported on all ifunc platforms, even when using
-fno-plt. The combination of -fno-plt and relro is broken due to
incorrect GNU ld output though.
2018-04-03 21:10:27 +00:00
christos
9a42df71a6 the zombie test is not a rump test. 2018-04-03 18:03:16 +00:00
bouyer
c697be8b14 disable all clocks at end of attach function, and re-enable ahb and mod only
in activate function.
enable ram gate (in debe) and video plls (in tcon) only when the video output
is enabled. Saves about 20mw when both video outputs are off.
2018-04-03 16:17:59 +00:00
bouyer
943dba7297 Consistently name the interrupt function "irq" and use this name
in sunxi_gpio_establish(). This is the name used by linux.
2018-04-03 16:01:25 +00:00
bouyer
7db592877c A10 and A20 should have the same display hardware, so consistenly support
sun4i-a10 the same way as sun7i-a20.
This would need to be tested on a real A10.
2018-04-03 13:38:13 +00:00
bouyer
4671046966 Add commented out entries for the display drivers. 2018-04-03 12:56:21 +00:00
bouyer
a4d537b2c9 work in progress on porting graphics drivers from arm/allwinner to fdt.
sunxidebe: display backend drivers
sunxitcon: lcd controller driver
sunxihdmi: hdmi controller driver
sunxidep: display engine pipeline driver. Its role is only to parse the
   fdt display-engine node, and activate de backend drivers based on the
   content of allwinner,pipelines

So far HDMI and lvds output works, in dual-framebuffer mode.
It has only been tested on A20. It should be OK on the A10 too, but
will likely need more work for other SoCs.
Console is not handled yet, and it conflicts with the simplefb driver if
it has been activated by u-boot.
2018-04-03 12:52:16 +00:00
bouyer
4b1d4a545c Add connector and panel drivers (panel supports only panel-lvds and
panel-dual-lvds at this time, but can easily be extended to other types
of panels).
Add an API for ports/endpoints.
Proposed on tech-kern@ a few days ago, ok jmcneill@
2018-04-03 12:40:20 +00:00
bouyer
9f70cab6cf external interrupt functions are named "eint<n>" in the sunxi_gpio_pins[]
arrays, while sunxi_gpio_establish() looks for "eint".
Rename eint<n> to eint in sunxi_gpio_pins[]. Tested with an external interrupt
on PH0 on an A20.

XXX others sunxi_gpio_pins[] contains names like px_eint<n>, px being the
name of the port bank. I guess they should be renamed to "eint" too to work
with sunxi_gpio_establish() but I'm not sure the functions are really the
same, and I have no way to test.
2018-04-03 10:10:17 +00:00
maxv
d40270d9c9 Remove ipsec_copy_policy and ipsec_copy_pcbpolicy. No functional change,
since we used only ipsec_copy_pcbpolicy, and it was a no-op.

Originally we were using ipsec_copy_policy to optimize the IPsec-PCB
cache: when an ACK was received in response to a SYN, we used to copy the
SP cached in the SYN's PCB into the ACK's PCB, so that
ipsec_getpolicybysock could use the cached SP instead of requerying it.

Then we switched to ipsec_copy_pcbpolicy which has always been a no-op. As
a result the SP cached in the SYN was/is not copied in the ACK, and the
first call to ipsec_getpolicybysock had to query the SP and cache it
itself. It's not totally clear to me why this change was made.

But it has been this way for years, and after a conversation with Ryota
Ozaki it turns out the optimization is not valid anymore due to
MP-ification, so it won't be re-enabled.

ok ozaki-r@
2018-04-03 09:03:59 +00:00