Received: by 2002:ab2:3141:0:b0:1ed:23cc:44d1 with SMTP id i1csp1087420lqg; Sat, 2 Mar 2024 15:19:58 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCV9W3/U9pWowB7QQT32iCv969CAgcSgvGth6PYKuJj1QHo1az5PCCKYjTPPQi17LHqMtrWYk40OZ8wLD3cpDM2L9VqtkFcqA5eM/le2aw== X-Google-Smtp-Source: AGHT+IFKe/UBtYdtXl9ArWIW7HywFHUF/yeIR2HCqiFNzJc3zA6Y/DOQTUIMJufoF70BFxn8jYqd X-Received: by 2002:a17:903:11c7:b0:1db:dd24:9962 with SMTP id q7-20020a17090311c700b001dbdd249962mr13766075plh.21.1709421597887; Sat, 02 Mar 2024 15:19:57 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709421597; cv=pass; d=google.com; s=arc-20160816; b=0Dy/qADSoa/z7DK6+zns+m6T7t42rKy5Ref1Lvw6dQkdF2xnYttfsXoyq5ZrS7tbbk EGN4qZC4AdnlVStY1WgbGSDS3skPQ9BL/vT6Osm2UnZzbAP6t1yWrX15X/fHVrGWS2nE XXM4zfEUicbRzNQqrk+DHef/LxISSWeEKWPaNHc9hnEhg1gf8KOUZAYJeeGrVA5L454Z 8QMi8Qf+qSOmge6V4Hx2O4J22fjTkLf5Ng3/tHuf7piXsurfhFL9T5E1MMDZvYg6L5Ai NdWHTFjaf1+T6ysv89v7zQyXaqQbSzXVIJPhBfofqzK5z5mtvSG/xbyh/HIivm5YvVKD siug== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-disposition:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:message-id:subject:cc:to:from:date :dkim-signature; bh=yl9YhJ9Pat9I4841GAOwQcUbovZDN591i7vJgihLH04=; fh=y6qC/SwYrKckPXQ2atHu0Ye3dIX17/JcY8M1kMlGtUc=; b=aYoh6kRvpq7aoOn26OuydQHo8LoZ2S+xYdespXL+pMrckcLJoeRYfoLUE0iXDW25gL zpnrJbq01gbQP0/4ftnspWYw9X7uD59Ar95CjER6SDFN93w8C0+3tCaqLHIj/SXDr1WF bfIxgVF5kRNOyH80JPerPN3VUU2/eeavL3kG9rkdzeBCdtwutc8wmNRjoxL6/wMPKrEZ crnG25MjvLtY/XaNqWSZCNn2BCWOQZCXgHvEiYYMYMgNJyQ0ziShoHWT219EI2dEZ1Ep k2wSuEf5fH4LQoW3qlQjfZEyPFPV6LGfr29PahbjQFHSIrAvalbIAJ3C7BIzX/1t5v7w oRYw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b="J8WsILe/"; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-89617-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-89617-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id x2-20020a63fe42000000b005dc89319b58si6114823pgj.682.2024.03.02.15.19.57 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 02 Mar 2024 15:19:57 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-89617-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b="J8WsILe/"; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-89617-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-89617-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 8BB75284105 for ; Sat, 2 Mar 2024 23:19:57 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6DDC354725; Sat, 2 Mar 2024 23:19:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="J8WsILe/" Received: from mail-qt1-f173.google.com (mail-qt1-f173.google.com [209.85.160.173]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 29E981EB3F; Sat, 2 Mar 2024 23:19:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.160.173 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709421588; cv=none; b=AzFRuI2MVDY/WYVv50KfZJuDI/YVfKSP3izAaKA1jIsCnweDiUlo6nntlIImqv6zLfkHPtRsCqRnQgCAmPoX0m8lwrYuYllQ0PhsUlodaYf/DVElPI9hZsCIlzg+Q+zTr435/joFZT3eJqu1P5UGNAo1yFdpvZSspfMoAeKPyLE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709421588; c=relaxed/simple; bh=vPP3p9GGRRGZegKNSobm2wNf5DV/YCF3ypsLBCmSIdw=; h=Date:From:To:Cc:Subject:Message-ID:MIME-Version:Content-Type: Content-Disposition; b=oD3U0fWO6G1+sYnaKxQUxROftZk7qo1jCsVgCQS9vzmiUlMwK+1w0VCuu3Mc/gsdn5wAtF0bLr3PcVPcMtoje3opjt2hCttQ94zUQMwm2XBajVS005p5uDms4Ol1pbuepRtkcQ49WG4kvQDbsxF/Z/tYQDqG2VTZ8jI2rkYGm8c= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=J8WsILe/; arc=none smtp.client-ip=209.85.160.173 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-qt1-f173.google.com with SMTP id d75a77b69052e-42e78c39ff0so39808111cf.0; Sat, 02 Mar 2024 15:19:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709421586; x=1710026386; darn=vger.kernel.org; h=content-disposition:mime-version:message-id:subject:cc:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=yl9YhJ9Pat9I4841GAOwQcUbovZDN591i7vJgihLH04=; b=J8WsILe/c0lxtcCKQQ/0R2OH3stc/HlsnH+PpbuTa3bzXSbYECsURyZ9OYW12x193e f0uR1c0q4NgkE0SrCDCWa9kKZLTvsiHVmkQ+n611oGCbAH0aQ3LRV/zVP0AzugW93MsE ybDVfU0BNnB2XZJUrzQhnZgWI5PmOmXMM3qy5w8OEPYFPIpZKt/wgssVnsUBi79mTi8r MZo0SiwfIu7C9HdwrQlV5LJRr8abFTPQnKabX3CwZC2bGoZpCozPzWahQLmirNGDtUkD 97u2n6cqunBELdpH8ZaIgXuGI0h8wWxcxN2orgxPfu2CoDtZiLj9Lm6f8RPQ/hgz0Sas GNFA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709421586; x=1710026386; h=content-disposition:mime-version:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=yl9YhJ9Pat9I4841GAOwQcUbovZDN591i7vJgihLH04=; b=j6I6xnSKVPZNL29TptI0XvNw2fTmKReDia9KZLcO7xIXpNuWdcdQL1QimqiVicreWf MVC81wgHR1OBuofdmKMeHAZXqts7yJrhQ5WjT2mZkkm+H4dknm0YEnU12sTx9eL37ZgX DZJSbD4zPai9CdcfwftAKG6RzVdwSxTObZAf2/2uLtQRw+XpMKEVu1A9S8hFgQRXiQTY JTW3bCpph4I4DwysjPipOm53c/YNzdMK/ERfSHNMUdzMZlwpMyvPDtfChOBoxwKYSlim iMha+KEDtPCFy8Q+4YsCT8W8nHT8bMH8/KrR2F0felmzZVkMEGX5NBpJkW7Aryx28AE5 UD2A== X-Forwarded-Encrypted: i=1; AJvYcCX4rvRFQ2It8hC7Y4NzpLyGG7Gy9hvC+VK3O8pEX+yieGQ7tonRZI14MsxkNVx76Qdt/bLhVJuzZ+CyeT7Uu8FxzjEUHF9RxFAdd3wBh2Hdmto2YoRQUWMl7sCNZsqNBFfu X-Gm-Message-State: AOJu0YwkOdO9kqhP1a9R8hRiQLrHMHhmNjePFLGjAFJVfoyT7UrT+KdC KNjtzYla7hI94F9+HDVHoE4jLQV3hxrJfMGHj8LK2JFNw3auySN9wmOYPAT7 X-Received: by 2002:ac8:5a41:0:b0:42e:ca55:e89a with SMTP id o1-20020ac85a41000000b0042eca55e89amr8281122qta.34.1709421585966; Sat, 02 Mar 2024 15:19:45 -0800 (PST) Received: from localhost ([2601:8c:502:14f0:acdd:1182:de4a:7f88]) by smtp.gmail.com with ESMTPSA id nw5-20020a0562143a0500b0068f2d2f64d1sm3422697qvb.32.2024.03.02.15.19.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 02 Mar 2024 15:19:45 -0800 (PST) Date: Sat, 2 Mar 2024 13:19:42 -0500 From: Oliver Crumrine To: alx@kernel.org Cc: linux-kernel@vger.kernel.org, linux-man@vger.kernel.org, netdev@vger.kernel.org Subject: [PATCH] ip.7: Add not supported by SOCK_STREAM to socket options Message-ID: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline It was not made clear in several socket options that they were not supported by SOCK_STREAM; this patch fixes that. Socket options not supported by SOCK_STREAM are handled in the ip_cmsg_recv_offset function in net/ipv4/ip_sockglue.c. The function is called for udp sockets, and indirectly by ping and raw sockets, but not for TCP sockets, as they don't support these options. Signed-off-by: Oliver Crumrine --- man7/ip.7 | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/man7/ip.7 b/man7/ip.7 index 2b4b06324..104e65feb 100644 --- a/man7/ip.7 +++ b/man7/ip.7 @@ -828,6 +828,9 @@ is not zero, the primary local address of the interface specified by the index overwrites .I ipi_spec_dst for the routing table lookup. +Not supported for +.B SOCK_STREAM +sockets. .TP .BR IP_RECVERR " (since Linux 2.2)" .\" Precisely: since Linux 2.1.15 @@ -989,6 +992,9 @@ in which the kernel returns the original destination address of the datagram being received. The ancillary message contains a .IR "struct sockaddr_in" . +Not supported for +.B SOCK_STREAM +sockets. .TP .BR IP_RECVTOS " (since Linux 2.2)" .\" Precisely: since Linux 2.1.68 @@ -998,6 +1004,9 @@ ancillary message is passed with incoming packets. It contains a byte which specifies the Type of Service/Precedence field of the packet header. Expects a boolean integer flag. +Not supported for +.B SOCK_STREAM +sockets. .TP .BR IP_RECVTTL " (since Linux 2.2)" .\" Precisely: since Linux 2.1.68 -- 2.44.0