Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A533EC433F5 for ; Sun, 21 Nov 2021 01:46:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237614AbhKUBtO (ORCPT ); Sat, 20 Nov 2021 20:49:14 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44718 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237566AbhKUBtN (ORCPT ); Sat, 20 Nov 2021 20:49:13 -0500 Received: from mail-lf1-x132.google.com (mail-lf1-x132.google.com [IPv6:2a00:1450:4864:20::132]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E9D7AC061748 for ; Sat, 20 Nov 2021 17:46:08 -0800 (PST) Received: by mail-lf1-x132.google.com with SMTP id f18so62431201lfv.6 for ; Sat, 20 Nov 2021 17:46:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bytedance-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=eC7ekTcNVcHToA7WbyMk8TOSIabpI8giHuuCFWYBVHY=; b=ZLaZpQncZZfoAiI8KH3Z6X84qkK27pbn9jZmBbIsmzNChnaRDRQo0/rxwhCbcxMZln A/L2fC3hg5lQ74xdjhEWlSJolhWBGICGVuov/cCwGc2IebcpF/pxu6AVPEJByavl2bIu THIvhXCAqYYICY3jWybcDAjT8BNkrrR889btRCfUnCXJV6Sgrdh9RrDx6LTeMv7x/PQT yXFPCTuFi14AlPH178sBL4sNovZEnFQcEA/yodB32eY6+5Sd11BJeVAg0XvPS5xYnJar l56iwSUpsyARR72VnBfO5ZWoqq8P86ZZmkyQ6IKPPTdTb6eLOoRVPm5ylWem6I6R+0AV CpAg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=eC7ekTcNVcHToA7WbyMk8TOSIabpI8giHuuCFWYBVHY=; b=i8jYJBh3l5MIbxiluqW2lZaJqDMoniiUviuk1S+V7N66xMJkZzxnTeresHqpaJGwvz FrSh08txTXf+BDdZTrEQRsBbZzbzez4B1RSgl2eHJhyvqv5nGz3UWq/sKzRfeucY2uMj Bo11uIA35SVjf6Jp+xT+B9zHbLdPY7/vs59Jv3sY0YW/rwp4IJ4hAtsi1HYuqO4aT58R m5kDPV37gvZea/3TnQegrc+RQvx9+SDWyxeGrAvZE8xPfEz7gznjhcvKTFhZlp4LLqyL rRLjaXlRoP4a2rK5JMPPd2Pl5tohYtQju4oJNJzgSParQih9o56bJ4XTWgmgrZ0UN9Fg iImQ== X-Gm-Message-State: AOAM530nXDg3bRCHP/M31I2ENNfwzzUfYprQ4ZkG3S7o25DDbiHXMBbL 6m2f2gQtIYhypdkJBXyXagvmtOaYyR0+Zw7uJBPhMA== X-Google-Smtp-Source: ABdhPJxfWi45CRv/695sTqDhdy6mX54xURuW0+JjIkOQYekJSB/icDp4YLBXjbdux+sf1/mczR3mZrREiZtrK5Xe6+E= X-Received: by 2002:a05:6512:6d1:: with SMTP id u17mr46632225lff.427.1637459166469; Sat, 20 Nov 2021 17:46:06 -0800 (PST) MIME-Version: 1.0 References: <20211119120521.18813-1-vincent.whitchurch@axis.com> <163742160874.26850.6419902452041932137.git-patchwork-notify@kernel.org> In-Reply-To: <163742160874.26850.6419902452041932137.git-patchwork-notify@kernel.org> From: "Jiang Wang ." Date: Sat, 20 Nov 2021 17:45:55 -0800 Message-ID: Subject: Re: Re: [PATCH] af_unix: fix regression in read after shutdown To: patchwork-bot+netdevbpf@kernel.org Cc: Vincent Whitchurch , "David S. Miller" , Jakub Kicinski , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , kernel@axis.com, Martin KaFai Lau , Song Liu , Yonghong Song , John Fastabend , KP Singh , Casey Schaufler , Networking , open list , bpf Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Thanks for the fix. Regards, Jiang On Sat, Nov 20, 2021 at 7:20 AM wrote: > > Hello: > > This patch was applied to netdev/net.git (master) > by David S. Miller : > > On Fri, 19 Nov 2021 13:05:21 +0100 you wrote: > > On kernels before v5.15, calling read() on a unix socket after > > shutdown(SHUT_RD) or shutdown(SHUT_RDWR) would return the data > > previously written or EOF. But now, while read() after > > shutdown(SHUT_RD) still behaves the same way, read() after > > shutdown(SHUT_RDWR) always fails with -EINVAL. > > > > This behaviour change was apparently inadvertently introduced as part of > > a bug fix for a different regression caused by the commit adding sockmap > > support to af_unix, commit 94531cfcbe79c359 ("af_unix: Add > > unix_stream_proto for sockmap"). Those commits, for unclear reasons, > > started setting the socket state to TCP_CLOSE on shutdown(SHUT_RDWR), > > while this state change had previously only been done in > > unix_release_sock(). > > > > [...] > > Here is the summary with links: > - af_unix: fix regression in read after shutdown > https://git.kernel.org/netdev/net/c/f9390b249c90 > > You are awesome, thank you! > -- > Deet-doot-dot, I am a bot. > https://korg.docs.kernel.org/patchwork/pwbot.html > >