From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=79.135.106.121 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796289471; b=i4mS63XL5lFAzmX9PVKFUDMvZ9l0j5ASP66U+kVlfgNt+N8zz4kzg2pgxUAG69pAdrZN gbTpD675umFryPU6QAwyHeH5VE96yw1HAFyKF8FRIjGeAox4Sz5AzD5VOn1fXUmkEP816 i2B+kgun7HGetR+ciR99bBBhks6g3quCWcmhM39UK8EMl1Q6I2/mp5LNAEE8FstnXlJz2 /1cbC7oxAviZICry1xI/OdOjPbp2LKtYjwlcR6YEZK3OC1lG8Ob0Q2o2E22lRQ85fHF1/ vdp3KcvgwKnw9k10niFWAlwkZnxqSdkziSkjT1+edGwRtxV8miagS6GmFGjREd6kORA== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796289471; h=DMARC-Filter:DKIM-Signature:Date:To:From:Cc:Subject:Message-ID: In-Reply-To:References:Feedback-ID:X-Pm-Message-ID:MIME-Version: Content-Type:Content-Transfer-Encoding; bh=76fa+FmnIklD5TprHu41dj1XkDmuEpQoUpHxVN3U1+Y=; b=yck1XYS6D7jr53YkTahX+y6I3D8H1ase4hrrmRYCwUpemRZ1rK4mpBfOb8NyD2omhy1b kEedUkRGBQ9jf1C2AAHtLnaHn3JsKuShe/5jnYzDH8Mqd7wrbX8DnsaSwINQkRnuCK4cY VxlMP+d62mMER+bEGdMk8xy/GjDb0moM1yUk7IQ4RCu1q7DEitiYAjzPemyaB1gTOAczk nvm3Wu8ZdTrvBhOQFk91Y6c3gqgCVFm9wCL/8SKwF/UUKxCAXRD33lcpenDSsgxA1eG76 XcrxQEcOQu2NPWjFO+ZJvAOS6mtLXFHjJAP/xnK7NwkluZ4sv2T53jMQRPHpz068jZw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=proton.me; spf=pass smtp.mailfrom=proton.me; dkim=pass header.d=proton.me header.i=@proton.me header.a=rsa-sha256 header.s=protonmail2 header.b=cTGSqfDx; arc=none smtp.remote-ip=79.135.106.121 Received: from mail-106121.protonmail.ch (mail-106121.protonmail.ch [79.135.106.121]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5DC7C606A681 for ; Thu, 3 Dec 2026 09:17:50 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 5DC7C606A681 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=proton.me Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=proton.me Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=proton.me header.i=@proton.me header.a=rsa-sha256 header.s=protonmail2 header.b=cTGSqfDx DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=proton.me; s=protonmail2; t=1796289468; x=1796548668; bh=76fa+FmnIklD5TprHu41dj1XkDmuEpQoUpHxVN3U1+Y=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=cTGSqfDxto3LWx6NddtAql0yQO6L6Qr5LqmqIV4/US6BWNaJdgIl+kknw/B5/ofgV IT/lXX8jGDDTxpqnRnTZRbyc0ityU1U4H6ozM9ye0Gz3OwAWTMTFdUQ7GhV+Rhuy7U SGnG6UcBX70NS8GoJ8hUiA+qc+GoUuXd1GvCKUIqqicbAmPhYSdIbYLh+IN9OrqEg5 CJKq0e/LgVyNl9tA17I3YyvdfQx4KVGSeNVJmto6vVlbriVib+O4KX7OfgB1vUsHrt jai81LGHOv7zgyk4wwW40468NMoufEeqJXpV3Kju7VoTID2q5Owp7rpoYWynGLYDdu QISblLZeQRaVA== Date: Thu, 03 Dec 2026 09:17:40 +0000 To: Sidraya Jayagond From: Bryam Vargas Cc: Mahanta Jambigi , "D . Wythe" , Eric Dumazet , "David S . Miller" , Paolo Abeni , Jakub Kicinski , Dust Li , Stefan Raspl , Simon Horman , Guangguan Wang , Wen Gu , linux-s390@vger.kernel.org, linux-rdma@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Tony Lu , Ursula Braun , Hidayath Khan , Wenjia Zhang Subject: Re: [PATCH net v2 6/6] net/smc: update the urgent state under the socket spinlock Message-ID: <20261203091733.486365-1-hexlabsecurity@proton.me> In-Reply-To: References: <20261128-b4-disp-360e65c5-v2-0-d9c05004d430@proton.me> <20261128-b4-disp-360e65c5-v2-6-d9c05004d430@proton.me> Feedback-ID: 199661219:user:proton X-Pm-Message-ID: df75cd5f3b55f044982df1426c903b05ebba9068 X-Mailing-List: netdev@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 01/12/26 3:02 pm, Sidraya Jayagond wrote: > Changing the test to "> 0" fixes that case. smc_rx_update_consumer() > then sees skip_pend and takes its diff =3D=3D 1 branch. > > A zero-length recv(MSG_OOB) still sets SMC_URG_READ, but it never > computes skip_pend or calls smc_rx_update_consumer(), so it leaves > the byte behind at any distance. Doing both outside the len > 0 > check would cover that as well. > > Could you add this as a follow-up patch with the same Fixes tag? [...] It is 7/7 of v3, with both changes: https://lore.kernel.org/all/20261203-b4-disp-ba1ad55e-v3-7-6834ff90c5d0@pro= ton.me/ After a one-byte send(MSG_OOB) to a reader that has read everything, recv(MSG_OOB) returns the byte on net and with v2, and the sender's next send() of 4096 bytes times out. With 7/7 the 4096 bytes arrive. A zero-length recv(MSG_OOB) gives the same two results. With "> 0" and the smc_rx_update_consumer() call left inside the len > 0 check, the zero-length case still times out. Thanks for the review and the tags. Bryam