Skip to content

Instantly share code, notes, and snippets.

@johalun
johalun / libudev-devd.diff
Created May 31, 2018 12:50
libudev-devd update
diff --git a/devel/libudev-devd/Makefile b/devel/libudev-devd/Makefile
index c65aa3a543ec..26d04eeb9afb 100644
--- a/devel/libudev-devd/Makefile
+++ b/devel/libudev-devd/Makefile
@@ -1,7 +1,7 @@
# $FreeBSD$
PORTNAME= libudev-devd
-PORTVERSION= 0.3
+PORTVERSION= 0.4
@johalun
johalun / gist:183b4c8c7371b97a35261efaf4d9e6d0
Created June 3, 2018 07:53
netmap pkt-gen rx fail 12-current 2018-06-02
pkt-gen -i em0 -f rx fails after a few second with poll error.
hw: Dell broadwell laptop with I218-LM NIC
dmesg:
095.668289 [1706] nm_rxsync_prologue em0 RX0: fail 'head < kring->nr_hwcur || head > kring->nr_hwtail' h 160 c 160 t 671 rh 160 rc 160 rt 671 hc 671 ht 671
095.668315 [1751] netmap_ring_reinit called for em0 RX0
@johalun
johalun / gist:21ccbc88672903bf509331e6b1490859
Last active June 7, 2018 14:01
Missing patch for SO_REUSEPORT_LB
diff --git a/cddl/lib/libdtrace/udp.d b/cddl/lib/libdtrace/udp.d
index 70652cbfce4..917baa663c7 100644
--- a/cddl/lib/libdtrace/udp.d
+++ b/cddl/lib/libdtrace/udp.d
@@ -58,12 +58,12 @@ translator udpsinfo_t < struct inpcb *p > {
udps_rport = p == NULL ? 0 : ntohs(p->inp_inc.inc_ie.ie_fport);
udps_laddr = p == NULL ? "" :
p->inp_vflag == INP_IPV4 ?
- inet_ntoa(&p->inp_inc.inc_ie.ie_dependladdr.ie46_local.ia46_addr4.s_addr) :
- inet_ntoa6(&p->inp_inc.inc_ie.ie_dependladdr.ie6_local);
@johalun
johalun / gist:9e14371365994ab076ad28759a9b8bbb
Last active July 27, 2018 15:22
FreeBSD12 - i915 SKL: Error on resume when DMC firmware loaded
Jul 27 16:15:15 jd acpi[1906]: resumed at 20180727 16:15:15
Jul 27 16:15:15 jd kernel: [drm:wait_panel_status] Wait complete
Jul 27 16:15:15 jd kernel: [drm:intel_power_well_enable] enabling DDI A/E IO power well
Jul 27 16:15:15 jd kernel: [drm:edp_panel_vdd_on] Turning eDP port A VDD on
Jul 27 16:15:15 jd kernel: [drm:edp_panel_vdd_on] PP_STATUS: 0x80000008 PP_CONTROL: 0x0000000b
Jul 27 16:15:15 jd kernel: [drm:intel_dp_set_signal_levels] Using signal levels 00000000
Jul 27 16:15:15 jd kernel: [drm:intel_dp_set_signal_levels] Using vswing level 0
Jul 27 16:15:15 jd kernel: [drm:intel_dp_set_signal_levels] Using pre-emphasis level 0
Jul 27 16:15:15 jd kernel: [drm:_intel_dp_set_link_train] Using DP training pattern TPS1
Jul 27 16:15:15 jd kernel: [drm:intel_dp_link_training_clock_recovery] clock recovery OK
@johalun
johalun / gist:0ba31eba8defa8f5efb0edc32d8841aa
Created July 30, 2018 19:25
suspend resume with fw loaded dmesg
[drm:drm_calc_vbltimestamp_from_scanoutpos] crtc 1 : v p(0,2146)@ 35.043888 -> -2197.428336 [e 0 us, 0 rep]
[drm:drm_update_vblank_count] updating vblank count on crtc 1: current=1552, diff=0, hw=1488 hw_last=1488
[drm:drm_calc_vbltimestamp_from_scanoutpos] crtc 1 : v p(0,-58)@ 35.043888 -> -2200.981866 [e 0 us, 0 rep]
[drm:drm_update_vblank_count] updating vblank count on crtc 1: current=1552, diff=1, hw=1489 hw_last=1488
[drm:drm_handle_vblank_events] vblank event on 1553, current 1553
[drm:drm_calc_vbltimestamp_from_scanoutpos] crtc 0 : v p(0,-14)@ 35.052401 -> -2200.981866 [e 0 us, 0 rep]
[drm:drm_update_vblank_count] updating vblank count on crtc 0: current=1584, diff=1, hw=3073 hw_last=3072
[drm:drm_handle_vblank_events] vblank event on 1585, current 1585
[drm:drm_mode_object_get] OBJ ID: 110 (7)
[drm:drm_mode_object_put] OBJ ID: 110 (8)
johannes@jd2:~ % xrandr --newmode "1024x768_50.00" 52.00 1024 1072 1168 1312 768 771 775 793 -hsync +vsync
johannes@jd2:~ % xrandr --verbose --addmode eDP-1 "1024x768_50.00"
johannes@jd2:~ % xrandr --output eDP-1 --mode 1024x768_50.00
johannes@jd2:~ % xrandr -q
Screen 0: minimum 320 x 200, current 1024 x 768, maximum 8192 x 8192
eDP-1 connected 1024x768+0+0 (normal left inverted right x axis y axis) 309mm x 174mm
1920x1080 60.02 + 47.99
1400x1050 59.98
1280x1024 60.02
1280x960 60.00
@johalun
johalun / gist:c9383ff03cb29e12c3f4978e06ca6413
Created September 18, 2018 11:42
devd output from wifi usb adapter insert with failing to create wlan0
Parsing /etc/devd.conf
setting scsi-controller-regex=(aac|adv|adw|aha|ahc|ahd|aic|amr|bt|ciss|dpt|esp|ida|iir|ips|isp|mlx|mly|mpr|mps|mpt|ncr|ncv|nsp|stg|sym|trm)[0-9]+
setting wifi-driver-regex=(ath|bwi|bwn|ipw|iwi|iwm|iwn|malo|mwl|ral|rsu|rtwn|rum|run|uath|upgt|ural|urtw|wi|wpi|wtap|zyd)[0-9]+
Parsing files in /etc/devd
Parsing /etc/devd/uath.conf
Parsing /etc/devd/zfs.conf
Parsing /etc/devd/hyperv.conf
Parsing /etc/devd/asus.conf
Parsing /etc/devd/devmatch.conf
@johalun
johalun / gist:1e096d47e5b24682ad6803e3ba4c05d7
Created November 12, 2018 21:52
amd ryzen 3 2200g vm panics
Unread portion of the kernel message buffer:
panic: page 0xfffff800b636d630 has object
cpuid = 1
time = 1542033179
KDB: stack backtrace:
db_trace_self_wrapper() at db_trace_self_wrapper+0x2b/frame 0xfffffe002a97f620
vpanic() at vpanic+0x1a3/frame 0xfffffe002a97f680
panic() at panic+0x43/frame 0xfffffe002a97f6e0
vm_page_alloc_check() at vm_page_alloc_check+0x81/frame 0xfffffe002a97f6f0
vm_page_alloc_domain_after() at vm_page_alloc_domain_after+0x295/frame 0xfffffe002a97f770
#0 doadump (textdump=1) at pcpu.h:230
#1 0xffffffff806c7190 in kern_reboot (howto=260) at /usr/src/sys/kern/kern_shutdown.c:451
#2 0xffffffff806c75e3 in vpanic (fmt=<value optimized out>, ap=<value optimized out>)
at /usr/src/sys/kern/kern_shutdown.c:877
#3 0xffffffff806c7343 in panic (fmt=<value optimized out>) at /usr/src/sys/kern/kern_shutdown.c:804
#4 0xffffffff809f5491 in mtrash_ctor (mem=<value optimized out>, size=<value optimized out>,
arg=<value optimized out>, flags=<value optimized out>) at /usr/src/sys/vm/uma_dbg.c:162
#5 0xffffffff809f06cb in uma_zalloc_arg (zone=0xfffff8000202e2a0, udata=0x0, flags=<value optimized out>)
at /usr/src/sys/vm/uma_core.c:2446
#6 0xffffffff806a1b8a in malloc (size=624, mtp=0xffffffff821f7dc0, flags=258) at uma.h:362
Section "Device"
Identifier "Card0"
#Driver "modesetting"
Driver "amdgpu"
BusID "PCI:16:0:0"
EndSection