Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#794 closed defect (fixed)

Cannot ping QEMU gateway (

Reported by: Jakub Jermář Owned by:
Priority: major Milestone:
Component: helenos/unspecified Version: mainline
Keywords: Cc:
Blocker for: Depends on:
See also:


Dynamic linking support for amd64 somehow regressed the ability to ping in the default QEMU networking setup:

15674715412ae9b74ef57bcf964741ea2f00c1bb is the first bad commit
commit 15674715412ae9b74ef57bcf964741ea2f00c1bb
Author: Jiri Svoboda <jiri@wiwaxia>
Date:   Mon Jan 8 20:37:57 2018 +0100

    Enable dynamic linking on amd64

:100644 100644 7f202ce2d6c5153b848b2fe87479115966600c6e 2da39668649bff020abc59b0784e3e6b8122fc3b M	HelenOS.config
:040000 040000 97352ce91febacd715419f77394206623e824c66 602e6f5b7e681323d8639baef848935edac5787f M	defaults
:040000 040000 621f32f17ddbeec3c1a49dc9ec00a2e2f346d7ee 304a77cff52ba697348da1a4b2f459e9a63affad M	uspace

Change History (3)

comment:1 by Jiri Svoboda, 5 years ago

I could only reproduce this problem on amd64 with shared libraries enabled. I could not reproduce it on ia32 or ppc32 with dynamic linking or on amd64 with static libraries.

The ping client would never receive a response from inetsrv, because inetping_recv() of inetsrv would receive EPERM from async_data_write_start() trying to send the payload of the ping reply. The pointer was invalid, going just a little bit beyond the end of the valid memory area.

The pointer computation in icmp_recv_echo_reply() and icmpv6_recv_echo_reply() was incorrect (adding byte offset to a non-byte pointer).

comment:2 by Jiri Svoboda, 5 years ago

Resolution: fixed
Status: newclosed

comment:3 by Jiri Svoboda, 5 years ago

Not sure how we could have ever gotten correct payload from the ping reply. Note that you can also ping the loopback addresses: (v4) and ::1 (v6).

Note: See TracTickets for help on using tickets.