Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp6328457rwb; Mon, 14 Nov 2022 18:38:29 -0800 (PST) X-Google-Smtp-Source: AA0mqf6ynJgmkQFNeWTNOAicR+hfcJsT4zOom1vqG9AdmSWeO/rg/fKxxxM8sE4hilPFa3wDvpiB X-Received: by 2002:a17:906:806:b0:73d:7112:4601 with SMTP id e6-20020a170906080600b0073d71124601mr12085874ejd.239.1668479909138; Mon, 14 Nov 2022 18:38:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668479909; cv=none; d=google.com; s=arc-20160816; b=h2lqK54DHatuWsJXJR+faUNKXjJ6DDOdDOtO/2jDuDjqkT8Rhuwurutxh2GfTOb0w5 ovZccIsKA6I4hMgbzilWGiN9xg4SlLKJgcEtM1msg8+DCnFbWKMzGvqZyt7g0kUHH48N dt+uZ4EyuonUwycX4PnLdIBKw9v+iR339mInohSZzoKQqUG8ER5Ky93tfWdLspXCrgFF Y4c4P+1IBRLMeaL+3P8U0ysDyx9/cgNDQSX6gDE8d16NKov8Do3u2/s/yUS2W5KNeGmX LD0Vd+BBdTQFrT6xnSI+w4R4oP5t/hvFjvHRqSRC32hLnd0bqYL55wXaaoJogOdL05W/ SZ8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from; bh=8tP1P9cgKDNiqGzW7QlE5MB85gHOsqIae4ctrPGpDCM=; b=weQrh7r20QL5BvXJxdd9zC0HUiaBD3BfXvTF7qx/2estzt1kLBsp1WH87pMuStf+aI lMLd4/gyM56i7jdyaIINBedhwVXumUsiEpCmdfQAtpP+mAyx2WlFQlldLQqkU0Skwyq0 L75E7ju8aXzg9BLzsb83W8ydH41p5f+5C3JMFRDwCreh+2hnJqtyTnxddQLnt277V5ng ctA0mQe+EGzM59oVVYFEKiGS3riax5xTACdnKuxd0gXXE9QnupK34yXyID3RWPlvUUy9 iHHE9J4HHXkNco9eQ0n0tqDwwqTG3x0vWM8Op2C4u+xLEScEgVoOQNOBIXOQ5Eczs1+Z 9/7Q== 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 ec16-20020a170906b6d000b0078db517075fsi8648183ejb.659.2022.11.14.18.38.08; Mon, 14 Nov 2022 18:38:29 -0800 (PST) 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 S236364AbiKOCOc (ORCPT + 88 others); Mon, 14 Nov 2022 21:14:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56424 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231202AbiKOCOb (ORCPT ); Mon, 14 Nov 2022 21:14:31 -0500 Received: from mail.nfschina.com (unknown [124.16.136.209]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 0B6536437; Mon, 14 Nov 2022 18:14:30 -0800 (PST) Received: from localhost (unknown [127.0.0.1]) by mail.nfschina.com (Postfix) with ESMTP id 593011E80DAD; Tue, 15 Nov 2022 10:11:32 +0800 (CST) X-Virus-Scanned: amavisd-new at test.com Received: from mail.nfschina.com ([127.0.0.1]) by localhost (mail.nfschina.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tE6_o7KRDhP3; Tue, 15 Nov 2022 10:11:29 +0800 (CST) Received: from localhost.localdomain (unknown [219.141.250.2]) (Authenticated sender: zeming@nfschina.com) by mail.nfschina.com (Postfix) with ESMTPA id 6B0961E80DAC; Tue, 15 Nov 2022 10:11:29 +0800 (CST) From: Li zeming To: jreuter@yaina.de, ralf@linux-mips.org, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com Cc: linux-hams@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Li zeming Subject: [PATCH] ax25: af_ax25: Remove unnecessary (void*) conversions Date: Tue, 15 Nov 2022 10:14:24 +0800 Message-Id: <20221115021424.3367-1-zeming@nfschina.com> X-Mailer: git-send-email 2.18.2 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,MAY_BE_FORGED, 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: X-Mailing-List: linux-kernel@vger.kernel.org The valptr pointer is of (void *) type, so other pointers need not be forced to assign values to it. Signed-off-by: Li zeming --- net/ax25/af_ax25.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/net/ax25/af_ax25.c b/net/ax25/af_ax25.c index 6b4c25a92377..d8da400cb4de 100644 --- a/net/ax25/af_ax25.c +++ b/net/ax25/af_ax25.c @@ -723,7 +723,7 @@ static int ax25_getsockopt(struct socket *sock, int level, int optname, if (maxlen < 1) return -EFAULT; - valptr = (void *) &val; + valptr = &val; length = min_t(unsigned int, maxlen, sizeof(int)); lock_sock(sk); @@ -785,7 +785,7 @@ static int ax25_getsockopt(struct socket *sock, int level, int optname, length = 1; } - valptr = (void *) devname; + valptr = devname; break; default: -- 2.18.2