ldv changed the topic of #strace to: https://strace.io | https://strace.io/logs/ | strace 5.2 is out | strace-devel@lists.strace.io for dev discussions
zhibli has joined #strace
zhibli is now known as zhibinli
<zhibinli> Hi, I've got a question about those auto-generated headers in xlat/
<zhibinli> There are two source files for drm decoders, one is non-mpers and the other is mpers
<zhibinli> some structures in mpers code contains fields which are pointers to another structure in non-mpers code
<zhibinli> when I tried to include "xlat/xxx_flags.h" in the mpers file in order to print the flags of the structure which is in non-mpers file, I got a "multiple definition" error
<zhibinli> Is there any way to resolve this without moving all those non-mpers structures into mpers file?
<zhibinli> For example, struct drm_ctx is a non-mpers structure if I'm correct and it has a flags field. And it should be decoded in the non-mpers file.
<zhibinli> But struct drm_ctx_res (a mpers one) contains a pointer to struct drm_ctx so in the mpers file flags field of struct drm_ctx should be printed as well.
<ldv> zhibinli: there are many cases like this in the code, see e.g. git grep sg_io_info
pombreda has quit [Ping timeout: 245 seconds]
pombreda has joined #strace
<zhibinli> ldv: Got it!