https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=295788
--- Comment #33 from Roger Olofsson <[email protected]> ---
Since I haven't yet found out how to debug a kernel module using lldb I did the
following as therapy.
pkg delete drm-515-kmod
cd /usr/ports/graphics/drm-61-kmod
make WITH_DEBUG=yes
make install
reboot
From remote laptop ssh:d into the asus. Looks the same as for drm-515-kmod.
Next version drm-66-kmod requires FreeBSD 15 but I am willing to wager that it
behaves the same.
Roger
# lldb -- /usr/local/libexec/Xorg :1 -keeptty
(lldb) target create "/usr/local/libexec/Xorg"
Current executable set to '/usr/local/libexec/Xorg' (x86_64).
(lldb) settings set -- target.run-args ":1" "-keeptty"
(lldb) target modules search-paths add / /
(lldb) b i915_gem_create_context
Breakpoint 1: no locations (pending).
WARNING: Unable to resolve breakpoint to any actual locations.
(lldb) process launch
Process 1721 launched: '/usr/local/libexec/Xorg' (x86_64)
X.Org X Server 1.21.1.23
X Protocol Version 11, Revision 0
Current Operating System: FreeBSD asus-r517sa 14.4-RELEASE-p6 FreeBSD
14.4-RELEASE-p6 #3 releng/14.4-n273726-3d95ec875867-dirty: Thu Jun 18 22:20:14
CEST 2026 raggen@asus-r517sa:/usr/obj/usr/src/amd64.amd64/sys/GENERIC amd64
Current version of pixman: 0.46.2
Before reporting problems, check http://wiki.x.org
to make sure that you have the latest version.
Markers: (--) probed, (**) from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.1.log", Time: Tue Jun 23 21:10:35 2026
Converted `%D/X11/%X' to `/usr/local/share/X11/xorg.conf.d'
Converted `/etc/X11/%X' to `/etc/X11/xorg.conf.d'
Converted `%C/X11/%X' to `/usr/local/etc/X11/xorg.conf.d'
Converted `/etc/X11/%X' to `/etc/X11/xorg.conf'
Converted `/etc/%X' to `/etc/xorg.conf'
Converted `%P/etc/X11/%X.%H' to `/usr/local/etc/X11/xorg.conf.asus-r517sa'
Converted `%P/etc/X11/%X' to `/usr/local/etc/X11/xorg.conf'
Converted `%P/lib/X11/%X.%H' to `/usr/local/lib/X11/xorg.conf.asus-r517sa'
Converted `%P/lib/X11/%X' to `/usr/local/lib/X11/xorg.conf'
(==) Using system config directory "/usr/local/share/X11/xorg.conf.d"
InputClass section parsed
InputClass section parsed
InputClass section parsed
InputClass section parsed
OutputClass section parsed
InputClass section parsed
InputClass section parsed
InputClass section parsed
InputClass section parsed
InputClass section parsed
InputClass section parsed
LoaderOpen(/usr/local/lib/xorg/modules/extensions/libglx.so)
LoaderOpen(/usr/local/lib/xorg/modules/drivers/modesetting_drv.so)
LoaderOpen(/usr/local/lib/xorg/modules/drivers/scfb_drv.so)
LoaderOpen(/usr/local/lib/xorg/modules/drivers/vesa_drv.so)
scfb trace: probe start
scfb trace: probe done
LoaderOpen(/usr/local/lib/xorg/modules/libglamoregl.so)
1 location added to breakpoint 1
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = breakpoint 1.1
frame #0: 0x0000000842db79fd crocus_dri.so`i915_gem_create_context(fd=17,
context_id=0x00000008208fc5d4) at intel_gem.c:34:39
31 bool
32 i915_gem_create_context(int fd, uint32_t *context_id)
33 {
-> 34 struct drm_i915_gem_context_create create = {};
35 if (intel_ioctl(fd, DRM_IOCTL_I915_GEM_CONTEXT_CREATE, &create))
36 return false;
37 *context_id = create.ctx_id;
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a01 crocus_dri.so`i915_gem_create_context(fd=17,
context_id=0x00000008208fc5d4) at intel_gem.c:34:39
31 bool
32 i915_gem_create_context(int fd, uint32_t *context_id)
33 {
-> 34 struct drm_i915_gem_context_create create = {};
35 if (intel_ioctl(fd, DRM_IOCTL_I915_GEM_CONTEXT_CREATE, &create))
36 return false;
37 *context_id = create.ctx_id;
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a03 crocus_dri.so`i915_gem_create_context(fd=17,
context_id=0x00000008208fc5d4) at intel_gem.c:34:39
31 bool
32 i915_gem_create_context(int fd, uint32_t *context_id)
33 {
-> 34 struct drm_i915_gem_context_create create = {};
35 if (intel_ioctl(fd, DRM_IOCTL_I915_GEM_CONTEXT_CREATE, &create))
36 return false;
37 *context_id = create.ctx_id;
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a08 crocus_dri.so`i915_gem_create_context(fd=17,
context_id=0x00000008208fc5d4) at intel_gem.c:34:39
31 bool
32 i915_gem_create_context(int fd, uint32_t *context_id)
33 {
-> 34 struct drm_i915_gem_context_create create = {};
35 if (intel_ioctl(fd, DRM_IOCTL_I915_GEM_CONTEXT_CREATE, &create))
36 return false;
37 *context_id = create.ctx_id;
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000843552bf0 crocus_dri.so`memset
crocus_dri.so`memset:
-> 0x843552bf0 <+0>: jmpq *0x6d3c2(%rip)
0x843552bf6 <+6>: pushq $0x6
0x843552bfb <+11>: jmp 0x843552b80
crocus_dri.so`memmove:
0x843552c00 <+0>: jmpq *0x6d3ba(%rip)
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752cf0 libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752cf3 libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752cf6 libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752cfa libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752d04 libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752d08 libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752d0c libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752d50 libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752d53 libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752d70 libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb)
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752d73 libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752d75 libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752d78 libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000829752d7d libc.so.7`memset at memset.S:142
139
140
141 ENTRY(memset)
-> 142 MEMSET erms=0
143 END(memset)
144
145 .section .note.GNU-stack,"",%progbits
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a0d crocus_dri.so`i915_gem_create_context(fd=17,
context_id=0x00000008208fc5d4) at intel_gem.c:35:20
32 i915_gem_create_context(int fd, uint32_t *context_id)
33 {
34 struct drm_i915_gem_context_create create = {};
-> 35 if (intel_ioctl(fd, DRM_IOCTL_I915_GEM_CONTEXT_CREATE, &create))
36 return false;
37 *context_id = create.ctx_id;
38 return true;
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a10 crocus_dri.so`i915_gem_create_context(fd=17,
context_id=0x00000008208fc5d4) at intel_gem.c:35:8
32 i915_gem_create_context(int fd, uint32_t *context_id)
33 {
34 struct drm_i915_gem_context_create create = {};
-> 35 if (intel_ioctl(fd, DRM_IOCTL_I915_GEM_CONTEXT_CREATE, &create))
36 return false;
37 *context_id = create.ctx_id;
38 return true;
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a15 crocus_dri.so`i915_gem_create_context(fd=17,
context_id=0x00000008208fc5d4) at intel_gem.c:35:8
32 i915_gem_create_context(int fd, uint32_t *context_id)
33 {
34 struct drm_i915_gem_context_create create = {};
-> 35 if (intel_ioctl(fd, DRM_IOCTL_I915_GEM_CONTEXT_CREATE, &create))
36 return false;
37 *context_id = create.ctx_id;
38 return true;
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a19 crocus_dri.so`i915_gem_create_context(fd=17,
context_id=0x00000008208fc5d4) at intel_gem.c:35:8
32 i915_gem_create_context(int fd, uint32_t *context_id)
33 {
34 struct drm_i915_gem_context_create create = {};
-> 35 if (intel_ioctl(fd, DRM_IOCTL_I915_GEM_CONTEXT_CREATE, &create))
36 return false;
37 *context_id = create.ctx_id;
38 return true;
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a60 crocus_dri.so`intel_ioctl(fd=-1394008449,
request=0, arg=0x0000000000000011) at intel_gem.h:79
76 */
77 static inline int
78 intel_ioctl(int fd, unsigned long request, void *arg)
-> 79 {
80 int ret;
81
82 do {
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a61 crocus_dri.so`intel_ioctl(fd=-1394008449,
request=0, arg=0x0000000000000011) at intel_gem.h:79
76 */
77 static inline int
78 intel_ioctl(int fd, unsigned long request, void *arg)
-> 79 {
80 int ret;
81
82 do {
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a64 crocus_dri.so`intel_ioctl(fd=0, request=0,
arg=0x0000000000000000) at intel_gem.h:79
76 */
77 static inline int
78 intel_ioctl(int fd, unsigned long request, void *arg)
-> 79 {
80 int ret;
81
82 do {
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a68 crocus_dri.so`intel_ioctl(fd=0, request=0,
arg=0x0000000000000000) at intel_gem.h:79
76 */
77 static inline int
78 intel_ioctl(int fd, unsigned long request, void *arg)
-> 79 {
80 int ret;
81
82 do {
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a6b crocus_dri.so`intel_ioctl(fd=17, request=0,
arg=0x0000000000000000) at intel_gem.h:79
76 */
77 static inline int
78 intel_ioctl(int fd, unsigned long request, void *arg)
-> 79 {
80 int ret;
81
82 do {
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a6f crocus_dri.so`intel_ioctl(fd=17,
request=3221775469, arg=0x0000000000000000) at intel_gem.h:79
76 */
77 static inline int
78 intel_ioctl(int fd, unsigned long request, void *arg)
-> 79 {
80 int ret;
81
82 do {
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a73 crocus_dri.so`intel_ioctl(fd=17,
request=3221775469, arg=0x00000008208fc570) at intel_gem.h:83:21
80 int ret;
81
82 do {
-> 83 ret = ioctl(fd, request, arg);
84 } while (ret == -1 && (errno == EINTR || errno == EAGAIN));
85 return ret;
86 }
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a76 crocus_dri.so`intel_ioctl(fd=17,
request=3221775469, arg=0x00000008208fc570) at intel_gem.h:83:25
80 int ret;
81
82 do {
-> 83 ret = ioctl(fd, request, arg);
84 } while (ret == -1 && (errno == EINTR || errno == EAGAIN));
85 return ret;
86 }
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a7a crocus_dri.so`intel_ioctl(fd=17,
request=3221775469, arg=0x00000008208fc570) at intel_gem.h:83:34
80 int ret;
81
82 do {
-> 83 ret = ioctl(fd, request, arg);
84 } while (ret == -1 && (errno == EINTR || errno == EAGAIN));
85 return ret;
86 }
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a7e crocus_dri.so`intel_ioctl(fd=17,
request=3221775469, arg=0x00000008208fc570) at intel_gem.h:83:15
80 int ret;
81
82 do {
-> 83 ret = ioctl(fd, request, arg);
84 } while (ret == -1 && (errno == EINTR || errno == EAGAIN));
85 return ret;
86 }
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000842db7a80 crocus_dri.so`intel_ioctl(fd=17,
request=3221775469, arg=0x00000008208fc570) at intel_gem.h:83:15
80 int ret;
81
82 do {
-> 83 ret = ioctl(fd, request, arg);
84 } while (ret == -1 && (errno == EINTR || errno == EAGAIN));
85 return ret;
86 }
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x0000000843552cd0 crocus_dri.so`ioctl
crocus_dri.so`ioctl:
-> 0x843552cd0 <+0>: jmpq *0x6d352(%rip)
0x843552cd6 <+6>: pushq $0x14
0x843552cdb <+11>: jmp 0x843552b80
crocus_dri.so`dup:
0x843552ce0 <+0>: jmpq *0x6d34a(%rip)
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x000000082972fa60 libc.so.7`__sys_ioctl at ioctl.S:4
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x000000082972fa65 libc.so.7`__sys_ioctl at ioctl.S:4
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x000000082972fa68 libc.so.7`__sys_ioctl at ioctl.S:4
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x000000082972fa6a libc.so.7`__sys_ioctl at ioctl.S:4
(lldb) si
Process 1721 stopped
* thread #1, name = 'Xorg', stop reason = instruction step into
frame #0: 0x000000082972f628 libc.so.7`.cerror at cerror.S:50
47 .globl CNAME(__error)
48 .type CNAME(__error),@function
49 HIDENAME(cerror):
-> 50 pushq %rax
51 call PIC_PLT(CNAME(__error))
52 popq %rcx
53 movl %ecx,(%rax)
(lldb)
--
You are receiving this mail because:
You are the assignee for the bug.
lmpx.com only provides a reader for public news (NNTP) servers. It is not
affiliated with the servers or forums shown here and is not responsible for
the content of articles, which is written by their respective authors.