Message ID | 20230413114705.157046-4-kevin.brodsky@arm.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp970976vqo; Thu, 13 Apr 2023 04:50:19 -0700 (PDT) X-Google-Smtp-Source: AKy350bik2IXtDxl1qkBJxeG8XcWfEYcY+wAsUxuMVPN/n4Ahc3HMQ+RihMK87WyHFG8XhqDVa9F X-Received: by 2002:a05:6a20:8987:b0:d9:dfc:4cb6 with SMTP id h7-20020a056a20898700b000d90dfc4cb6mr1847329pzg.35.1681386619559; Thu, 13 Apr 2023 04:50:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681386619; cv=none; d=google.com; s=arc-20160816; b=mj825bhyRtVgv8h7eFzdEv0Y9zAXDBLMOY4Yjeu0G+vo6B82JzKWTGUpJQpIEAoRNz 9d+NjKJgp439uOizkv/odn9obC3jboTusIubt6a8rxVvRR74fjysWqzOV0NMiiVIG8Nk eDqD5P8HfGzySWJ3myVhlA1yhMSMRk9508espJ2aOSNs3HJ9vgILztRuuExeMX2p4Tw+ Xhx9naD4GscymzR5LYtgM30Qs5woDo4Uqv01axXg5rD0qDQL3F5bMyumcQmUGpHdiPhX 98IhIYsa55408BthaMpvM6AK9XS/I2Vit6K7SpYoEAbH89V+TJ7onFDEQEWz8hHdalhD ZSgg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=Ynf/PWSOSIWvKRvm/dopf02SDVOtm+hyQqKDswVVODY=; b=AiOT6mENg+FmecJO68NqIVQ5dGtjG7gupLpVrw+TX8hKWAe3nVacb6L9DZkxXQag0c iTUIEmvLyVqZups6oi6jMoUY6zr+hhkODbE9BKlLVEVhIUcqDJ6Pz+9j0wIe7IGZEbwA ybbL2O4wEAJI1eH7nNe/lDyMqmsLcrnOVlGpdPfpZm7QeuOg3Z4thncq33ugvCUlftsa 4RjNR+LSm/bzpP0TkLB4cPCMMy+ahPBOM/DsFii5dRRAk7IO1kjaoMvp5mR9AC2ejKZF YBGLDamY1M0Gn2LejK4tEqJooJuLeyI9+5ZZ3ToAx834AKNx9ofMBW8tN17sYctN5U1E uTTw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id l185-20020a6391c2000000b0051b4a135853si1747804pge.686.2023.04.13.04.50.06; Thu, 13 Apr 2023 04:50:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231342AbjDMLs1 (ORCPT <rfc822;peter110.wang@gmail.com> + 99 others); Thu, 13 Apr 2023 07:48:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47978 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231204AbjDMLsG (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 13 Apr 2023 07:48:06 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id C82C7AF37; Thu, 13 Apr 2023 04:47:40 -0700 (PDT) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id E2377153B; Thu, 13 Apr 2023 04:48:05 -0700 (PDT) Received: from e123572-lin.arm.com (e123572-lin.cambridge.arm.com [10.1.194.65]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 721B33F73F; Thu, 13 Apr 2023 04:47:20 -0700 (PDT) From: Kevin Brodsky <kevin.brodsky@arm.com> To: netdev@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Kevin Brodsky <kevin.brodsky@arm.com>, Christoph Hellwig <hch@lst.de>, Eric Dumazet <edumazet@google.com>, "David S. Miller" <davem@davemloft.net>, Jakub Kicinski <kuba@kernel.org> Subject: [PATCH v2 3/3] net/ipv6: Initialise msg_control_is_user Date: Thu, 13 Apr 2023 12:47:05 +0100 Message-Id: <20230413114705.157046-4-kevin.brodsky@arm.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20230413114705.157046-1-kevin.brodsky@arm.com> References: <20230413114705.157046-1-kevin.brodsky@arm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1763061656054186064?= X-GMAIL-MSGID: =?utf-8?q?1763061656054186064?= |
Series |
net: Finish up ->msg_control{,_user} split
|
|
Commit Message
Kevin Brodsky
April 13, 2023, 11:47 a.m. UTC
do_ipv6_setsockopt() makes use of struct msghdr::msg_control in the
IPV6_2292PKTOPTIONS case. Make sure to initialise
msg_control_is_user accordingly.
Cc: Christoph Hellwig <hch@lst.de>
Cc: Eric Dumazet <edumazet@google.com>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Kevin Brodsky <kevin.brodsky@arm.com>
---
net/ipv6/ipv6_sockglue.c | 1 +
1 file changed, 1 insertion(+)
Comments
On Thu, Apr 13, 2023 at 12:47:05PM +0100, Kevin Brodsky wrote: > do_ipv6_setsockopt() makes use of struct msghdr::msg_control in the > IPV6_2292PKTOPTIONS case. Make sure to initialise > msg_control_is_user accordingly. Looks good: Reviewed-by: Christoph Hellwig <hch@lst.de>
diff --git a/net/ipv6/ipv6_sockglue.c b/net/ipv6/ipv6_sockglue.c index 2917dd8d198c..ae818ff46224 100644 --- a/net/ipv6/ipv6_sockglue.c +++ b/net/ipv6/ipv6_sockglue.c @@ -716,6 +716,7 @@ int do_ipv6_setsockopt(struct sock *sk, int level, int optname, goto done; msg.msg_controllen = optlen; + msg.msg_control_is_user = false; msg.msg_control = (void *)(opt+1); ipc6.opt = opt;