From owner-freebsd-net@freebsd.org Mon Jan 9 00:37:13 2017 Return-Path: Delivered-To: freebsd-net@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6EB2BCA2717 for ; Mon, 9 Jan 2017 00:37:13 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5E02B1A09 for ; Mon, 9 Jan 2017 00:37:13 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id v090bDL7098582 for ; Mon, 9 Jan 2017 00:37:13 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-net@FreeBSD.org Subject: [Bug 181741] [kernel] [patch] Packet loss when 'control' messages are present with large data (sendmsg(2)) Date: Mon, 09 Jan 2017 00:37:13 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: chris.torek@gmail.com X-Bugzilla-Status: In Progress X-Bugzilla-Resolution: X-Bugzilla-Priority: Normal X-Bugzilla-Assigned-To: freebsd-net@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 09 Jan 2017 00:37:13 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D181741 --- Comment #12 from chris.torek@gmail.com --- The test code demonstrating the new bug is slightly wrong (or insufficient = at least). What's happening is that one of the attached patches also changes = the code in uipc_finalizecontrol() to always prepend SCM_CREDS to DGRAM sockets= .=20 The result is that you need a larger control-message buffer here so that you can get both the credentials (i.e., who sent you the fd) *and* the rights (= the fd itself). With the small control-message buffer you have room only for t= he prepended credentials. Apparently UNP_WANTCREDS is not set on the pre-connected SOCK_DGRAM socketp= air. So, dropping or altering that particular commit (so that it prepends SCM_C= REDS only if UNP_WANTCREDS is set, whether or not this is a one-shot stream-ish socket or repeating datagram socket) will make the test program run. Or, making its control message receive buffer bigger will also make the test program run... --=20 You are receiving this mail because: You are the assignee for the bug.=