Received: by 2002:a05:6358:7058:b0:131:369:b2a3 with SMTP id 24csp5130544rwp; Sun, 16 Jul 2023 20:39:57 -0700 (PDT) X-Google-Smtp-Source: APBJJlGkCV/OYfcj6y+Bm9GLoz41L8X1Ce5ZWtwr4OuhcDGvXr3BXtlnsI8EKRFFDqGYLNuvZjl8 X-Received: by 2002:a17:902:ec8b:b0:1b3:d8ac:8db3 with SMTP id x11-20020a170902ec8b00b001b3d8ac8db3mr7029329plg.6.1689565196978; Sun, 16 Jul 2023 20:39:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689565196; cv=none; d=google.com; s=arc-20160816; b=nkOuVkRsSE115mlA2jnwlUyjHOZryF6D2BxWHROqj+982vGmCx0enLQok4U/rmt7s/ zDGyxTZ2VoG32ULRY+ngrwrEu5uPdGSahIlRoGUCoKnivi2r+vVR3aHDJuryr1FSQyz3 5d6e3UFY45bLVk63/NvnxsliVSS0miGgUmYaJpaBKiD1GI6ow0vt1vOgg0Ov7EgQzNME vGKzCjCgdRW8TQfTSU871PWuQ3aVfDbyLC5WXZB+A1hobmpr8ts0Df/jHHVYzkzFEtln BH4pfg7qvLW766c61yB43n2A+sulMYrnfQC9Uj7v/gMX/kWcgtI+5VinN9UQKEiuhvwm PCCg== 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 :message-id:date:subject:cc:to:from; bh=EVnNb3HPiqiJixui28J63Wh09sP9c6151aaKLoiYHaQ=; fh=h5cCB7cZyuL1WJASUsw0XLzy+nlkIWJl668ijkKbiIM=; b=mGksIydrT+cpTJ1K2xL/QzDZulPoTI0AhbHnHAbn2PlxEA/N/HYFJF+s2JAJIt0AIE BL/JYocexovCyg6CNZlmYTKPE7cYRwpri2tSM5twwmH29PNPIZzJWtJ+kIBe6xx6HDpr QOjL/lDYyuN26RUUqgFjjVvNOEdaeJDkEz+msR+sgLWXCuQxUtIkV2a/+TntGWBj7hKT 63PpzvrNwPvnIyH7MQAeGbmVT8aZrhcbZVod+SKLzmLv/SjYuxwvoNcZ936XplWVaUzU 8RahG5me7bY19V3usjHWjCETcCAwy9HjMO/GjVzXfpYF17liNBJfEJ/m/YaHBmQVHhOI XJtw== 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g6-20020a1709026b4600b001b3414a1fa9si10962002plt.175.2023.07.16.20.39.44; Sun, 16 Jul 2023 20:39:56 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231228AbjGQDLn (ORCPT + 99 others); Sun, 16 Jul 2023 23:11:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38252 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231263AbjGQDLb (ORCPT ); Sun, 16 Jul 2023 23:11:31 -0400 Received: from mail.nfschina.com (unknown [42.101.60.195]) by lindbergh.monkeyblade.net (Postfix) with SMTP id 74BEFE41; Sun, 16 Jul 2023 20:11:24 -0700 (PDT) Received: from localhost.localdomain (unknown [180.167.10.98]) by mail.nfschina.com (Maildata Gateway V2.8.8) with ESMTPA id 5BCED6012605B; Mon, 17 Jul 2023 11:11:22 +0800 (CST) X-MD-Sfrom: yunchuan@nfschina.com X-MD-SrcIP: 180.167.10.98 From: Wu Yunchuan To: mostrows@earthlink.net, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, xeb@mail.ru Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org, Wu Yunchuan , Guillaume Nault Subject: [PATCH net-next v3 2/9] net: ppp: Remove unnecessary (void*) conversions Date: Mon, 17 Jul 2023 11:11:15 +0800 Message-Id: <20230717031115.54432-1-yunchuan@nfschina.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_BLOCKED,RDNS_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=no 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: X-Mailing-List: linux-kernel@vger.kernel.org No need cast (void*) to (struct sock *). Signed-off-by: Wu Yunchuan Reviewed-by: Guillaume Nault --- drivers/net/ppp/pppoe.c | 4 ++-- drivers/net/ppp/pptp.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/net/ppp/pppoe.c b/drivers/net/ppp/pppoe.c index 3b79c603b936..ba8b6bd8233c 100644 --- a/drivers/net/ppp/pppoe.c +++ b/drivers/net/ppp/pppoe.c @@ -968,7 +968,7 @@ static int __pppoe_xmit(struct sock *sk, struct sk_buff *skb) ***********************************************************************/ static int pppoe_xmit(struct ppp_channel *chan, struct sk_buff *skb) { - struct sock *sk = (struct sock *)chan->private; + struct sock *sk = chan->private; return __pppoe_xmit(sk, skb); } @@ -976,7 +976,7 @@ static int pppoe_fill_forward_path(struct net_device_path_ctx *ctx, struct net_device_path *path, const struct ppp_channel *chan) { - struct sock *sk = (struct sock *)chan->private; + struct sock *sk = chan->private; struct pppox_sock *po = pppox_sk(sk); struct net_device *dev = po->pppoe_dev; diff --git a/drivers/net/ppp/pptp.c b/drivers/net/ppp/pptp.c index 32183f24e63f..6b3d3df99549 100644 --- a/drivers/net/ppp/pptp.c +++ b/drivers/net/ppp/pptp.c @@ -148,7 +148,7 @@ static struct rtable *pptp_route_output(struct pppox_sock *po, static int pptp_xmit(struct ppp_channel *chan, struct sk_buff *skb) { - struct sock *sk = (struct sock *) chan->private; + struct sock *sk = chan->private; struct pppox_sock *po = pppox_sk(sk); struct net *net = sock_net(sk); struct pptp_opt *opt = &po->proto.pptp; @@ -575,7 +575,7 @@ static int pptp_create(struct net *net, struct socket *sock, int kern) static int pptp_ppp_ioctl(struct ppp_channel *chan, unsigned int cmd, unsigned long arg) { - struct sock *sk = (struct sock *) chan->private; + struct sock *sk = chan->private; struct pppox_sock *po = pppox_sk(sk); struct pptp_opt *opt = &po->proto.pptp; void __user *argp = (void __user *)arg; -- 2.30.2