<div dir="ltr"><div>Hey Nick,<br><br></div>Thanks for the feedback! I managed to get past that issue (I made a silly mistake and only partially finished rebuilding the kernel after switching branches a couple times), but now I am actually hitting a crash in dwarf2ctf. Unfortunately, the core dump is 7.2GB. I've taken a quick poke around with gdb, and the crash is in ctf_type_resolve. Specifically, the instruction that's faulting is `<span style="font-family:monospace,monospace">mov %rdi,0x8(%rsp)</span>`, which looks to me like it's overflowing a stack. It's possible that means the backtrace I got is actually accurate, but I doubt it; after a few reasonable looking entries, it quickly starts repeating `<span style="font-family:monospace,monospace">#n 0x00007f818c395c7d in ctf_type_align (fp=<optimized out>, type=<optimized out>) at libctf/ctf_types.c:408</span>` for at least the next 15 thousand entries. I've put the output of some rudimentary GDBing in at <a href="https://urldefense.proofpoint.com/v2/url?u=https-3A__pastebin.com_Fbne2xjw&d=DwMFaQ&c=RoP1YumCXCgaWHvlZYR8PZh8Bv7qIrMUB65eapI_JnE&r=TH500uwHRHLHqjhgluCyxMsbZEewvpf7ynuq0G-WrEk&m=R69QilJR7Qqi7XhNkV03JVyMwDa912j7jGdNfnj_hzQ&s=Un_Fl6yOvT7QN5wTaNgMxMWQvJJ9c8M6AirNoMmGJaY&e=">https://pastebin.com/Fbne2xjw</a> . Let me know if you need the core file itself, or any other information.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Mar 1, 2018 at 1:55 PM, Nick Alcock <span dir="ltr"><<a href="mailto:nick.alcock@oracle.com" target="_blank">nick.alcock@oracle.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 1 Mar 2018, Paul Dagnelie said:<br>
<br>
> Hey all,<br>
><br>
> As part of a hackathon project, I was attempting to build the linux kernel<br>
> with dtrace, get it running on a VM, and then get it working with ZFS On<br>
> Linux. I have had moderate success; I managed to get the machine to boot,<br>
> the dtrace modules loaded, and zfs installed. I can run dtrace fbt probes<br>
> and see stack traces! However, there is a significant barrier to doing more<br>
> interesting things: the kernel does not appear to contain any CTF data.<br>
<br>
</span>As you've discovered, CTF data is only built when explicitly requested<br>
<span class=""><br>
> Attempting to run `make ctf` in the linux kernel results in a slew of<br>
> errors of the form ERROR: "osduld_device_info" [fs/exofs/exofs.ko]<br>
> undefined! I was hoping that someone on this list might be able to provide<br>
> some insight into what's going on here, and potentially how to fix the<br>
> issues. Thanks for your time!<br>
<br>
</span>This is almost certainly a bug, but I'd need more build output to be<br>
sure what component it came from. dwarf2ctf has been developed by fixing<br>
bugs as they arise, which means that configs very different from the<br>
ones it's been tested with may malfunction :(<br>
<br>
However, that is not your problem. dwarf2ctf never emits any messages of<br>
the form 'ERROR: ': that error sounds like it's coming from modpost.<br>
(See scripts/mod/modpost.c:add_<wbr>versions()).<br>
<br>
Since modpost runs before dwarf2ctf and is serialized with it (since it<br>
edits the module object files, and dwarf2ctf reads them all in),<br>
dwarf2ctf has never run and thus never had a chance to go wrong. I<br>
suspect that this is a simple bug, probably a .config bug: you've got<br>
exofs built in but CONFIG_SCSI_OSD_ULD is not set, so<br>
drivers/scsi/osd/osd_uld.c, which defines that function, is never<br>
compiled. Alternatively, it's quite possible that you can only build<br>
exofs if you have built CONFIG_SCSI_OSD_ULD into the kernel rather than<br>
making it a module, since otherwise you might end up with an<br>
inter-modular call, or a call from a non-module to a module: the latter<br>
is definitely verboten.<br>
<br>
The exofs config depends on SCSI_OSD_ULD, so I wouldn't normally expect<br>
this scenario to be possible, but perhaps it's happened anyway.<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
NULL && (void)<br>
</font></span></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr">Paul Dagnelie<br></div></div>
</div>