Message ID | 20230319133732.1702841-1-trix@redhat.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp731601wrt; Sun, 19 Mar 2023 06:58:30 -0700 (PDT) X-Google-Smtp-Source: AK7set+KgtuDmLvF73ncyo6q0dTpDgGKMIFS9fQNYDgAlrLMQAB7PY7qWP/z653sF0FXcteoEG5G X-Received: by 2002:a17:903:1383:b0:1a1:bcf:db5f with SMTP id jx3-20020a170903138300b001a10bcfdb5fmr11947843plb.25.1679234309939; Sun, 19 Mar 2023 06:58:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679234309; cv=none; d=google.com; s=arc-20160816; b=kKR7hmNR8g/zq1ho4HvB67i2eV3h7U4WpyoU0LCdKvi7SkxME5ynaJDErpCsV4YNck 4Rhw5ARuh5DMkhJPlkHvO5ohm8ZSyEEU1jk3VPltVXnCDwhAT/Ab0CbYJfxmMZDClphx uu8UTxV6okTFBCjP4xPVdLxZI8JUHfHuuGAIvB3pybM5yzJRQksVfat4Be9IbPsBTvTZ W9nRNsFBSefQNu4vAyU62jiIk897wThUAFq5xC+QnHCKuetn5qxdcpq1J9FhKxjwVC9u F9uevnMUSe/NOzFKR+AJDqE2k+5P30UHJ6BgXKw0+RICLsZW/ePqgCBfz0mQkThCGoFg 6cfQ== 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:dkim-signature; bh=4ElBMEAOxAifaU/g2MZDiubtm18mJfcsN/DjXe1709c=; b=LzgKbd3Mt7RKcZmUfnGFUyv932Mhp+JZas4z/g/p4k4pi1D9r3/NyzcbLSq9/kj3TP uA1H3ko44c5mUJo49UtIpkERnMfiNjDJOdYvgWBczQRqdvzrGDpPmxGjC1SLl7p9hxHr WXNweSgJPa1NTyVsps4KSj7R3GHmzX/m0nEHrQj03COYSk9mWAP3bRPukQxm1w4AWvhA IHCE+kpJsa8Uxg5UcPjoOgP0aJyU1sQ6O0jBDG/L+R3CSvHBN7o3EwmLBEbfSOF7Hdxf CnzkkecniTH56QrXoUQcooVv/HOaiD1K7G2o7QSJrWmHwvqmw0JPg7Q9lSE9WWqPKjBC 5Rgw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=aAmaQvMs; 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=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id v11-20020a1709029a0b00b0019cec83ecd5si8015807plp.66.2023.03.19.06.58.14; Sun, 19 Mar 2023 06:58:29 -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; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=aAmaQvMs; 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=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229550AbjCSNi1 (ORCPT <rfc822;pusanteemu@gmail.com> + 99 others); Sun, 19 Mar 2023 09:38:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41512 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229791AbjCSNiX (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Sun, 19 Mar 2023 09:38:23 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F2DC9213D for <linux-kernel@vger.kernel.org>; Sun, 19 Mar 2023 06:37:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1679233058; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=4ElBMEAOxAifaU/g2MZDiubtm18mJfcsN/DjXe1709c=; b=aAmaQvMsKsE1vYXlUg/KEWNkMq4KDauGrD77KGhhkN656L9aWk57tX4xYkD91wbj+0u+UM KY3ZbdeBrp8nro6SF44UQEngDzQcFQiYg2cblis5lbactKOdm5dHSJsUTZuf2G94AYNEjW +EGHeedNs0b1vaZ4Jymr/wuy5WroDFI= Received: from mail-qk1-f197.google.com (mail-qk1-f197.google.com [209.85.222.197]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-356-QeYXp4JnPmqm72aLl2yVqQ-1; Sun, 19 Mar 2023 09:37:36 -0400 X-MC-Unique: QeYXp4JnPmqm72aLl2yVqQ-1 Received: by mail-qk1-f197.google.com with SMTP id l27-20020a05620a211b00b00745b3e62004so4404178qkl.4 for <linux-kernel@vger.kernel.org>; Sun, 19 Mar 2023 06:37:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679233056; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=4ElBMEAOxAifaU/g2MZDiubtm18mJfcsN/DjXe1709c=; b=BECimHrvQBrH0wWTQdC7RKbZnbWti0hBI/HU0E2UA3UxNVPP/ENR3PeOnlsQk+j+nz sGU1IqcE3B+LyJQcfvDSQ87NTP4HiD3CzHbAbVtNaPTTHvJBAjIqWYNj/tZuHpvGYW2u sR6GDueXg1zTDN9nRTSOA9ja8xGkuALVfAimyqtdq84qPdDPGUjAaFVOTuJp3iHLuUCT hZSqq1rqRBhXLod8V2h/I7EzpFLoK4WsRZCsd+ImVx9ff4QV9MW7UAsbOaUC4KIu19yH P83AZaqVyrS69rWDxpQOFAvA2W/YAsJN6QW3ksN/I5pFLf7ayURS0iqGw29Wy+VaTCo9 PVSg== X-Gm-Message-State: AO0yUKXJcjBER0a8EVHSHLZ9drT0NP3Ih8JRUMHx7FMJMVFwjfoSEHyQ iycrKnKCET8k0/wRyNP0+KyhwynX7TNy/Dl2OwZWZJFvLMU6HDr/i/EcyfVojMZQ5t5RsuKmCg7 Rhrnvfyfpb5x1HoKtnA0QU+FR X-Received: by 2002:ac8:7d8d:0:b0:3b8:5bc6:deab with SMTP id c13-20020ac87d8d000000b003b85bc6deabmr23562505qtd.8.1679233056183; Sun, 19 Mar 2023 06:37:36 -0700 (PDT) X-Received: by 2002:ac8:7d8d:0:b0:3b8:5bc6:deab with SMTP id c13-20020ac87d8d000000b003b85bc6deabmr23562486qtd.8.1679233055937; Sun, 19 Mar 2023 06:37:35 -0700 (PDT) Received: from dell-per740-01.7a2m.lab.eng.bos.redhat.com (nat-pool-bos-t.redhat.com. [66.187.233.206]) by smtp.gmail.com with ESMTPSA id h12-20020ac8568c000000b003d75bb8e652sm4551676qta.65.2023.03.19.06.37.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 19 Mar 2023 06:37:35 -0700 (PDT) From: Tom Rix <trix@redhat.com> To: heikki.krogerus@linux.intel.com, gregkh@linuxfoundation.org, nathan@kernel.org, ndesaulniers@google.com, sven@svenpeter.dev, agx@sigxcpu.org, Jonathan.Cameron@huawei.com, jun.nie@linaro.org, u.kleine-koenig@pengutronix.de Cc: linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, Tom Rix <trix@redhat.com> Subject: [PATCH] usb: typec: tipd: remove unused tps6598x_write16,32 functions Date: Sun, 19 Mar 2023 09:37:32 -0400 Message-Id: <20230319133732.1702841-1-trix@redhat.com> X-Mailer: git-send-email 2.27.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,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?1760804795552427213?= X-GMAIL-MSGID: =?utf-8?q?1760804795552427213?= |
Series |
usb: typec: tipd: remove unused tps6598x_write16,32 functions
|
|
Commit Message
Tom Rix
March 19, 2023, 1:37 p.m. UTC
clang with W=1 reports
drivers/usb/typec/tipd/core.c:180:19: error: unused function
'tps6598x_write16' [-Werror,-Wunused-function]
static inline int tps6598x_write16(struct tps6598x *tps, u8 reg, u16 val)
^
drivers/usb/typec/tipd/core.c:185:19: error: unused function
'tps6598x_write32' [-Werror,-Wunused-function]
static inline int tps6598x_write32(struct tps6598x *tps, u8 reg, u32 val)
^
These static functions are not used, so remove them.
Signed-off-by: Tom Rix <trix@redhat.com>
---
drivers/usb/typec/tipd/core.c | 10 ----------
1 file changed, 10 deletions(-)
Comments
On Sun, Mar 19, 2023 at 09:37:32AM -0400, Tom Rix wrote: > clang with W=1 reports > drivers/usb/typec/tipd/core.c:180:19: error: unused function > 'tps6598x_write16' [-Werror,-Wunused-function] > static inline int tps6598x_write16(struct tps6598x *tps, u8 reg, u16 val) > ^ > drivers/usb/typec/tipd/core.c:185:19: error: unused function > 'tps6598x_write32' [-Werror,-Wunused-function] > static inline int tps6598x_write32(struct tps6598x *tps, u8 reg, u32 val) > ^ > These static functions are not used, so remove them. > > Signed-off-by: Tom Rix <trix@redhat.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> > --- > drivers/usb/typec/tipd/core.c | 10 ---------- > 1 file changed, 10 deletions(-) > > diff --git a/drivers/usb/typec/tipd/core.c b/drivers/usb/typec/tipd/core.c > index 485b90c13078..af6ecb54b52c 100644 > --- a/drivers/usb/typec/tipd/core.c > +++ b/drivers/usb/typec/tipd/core.c > @@ -177,16 +177,6 @@ static inline int tps6598x_read64(struct tps6598x *tps, u8 reg, u64 *val) > return tps6598x_block_read(tps, reg, val, sizeof(u64)); > } > > -static inline int tps6598x_write16(struct tps6598x *tps, u8 reg, u16 val) > -{ > - return tps6598x_block_write(tps, reg, &val, sizeof(u16)); > -} > - > -static inline int tps6598x_write32(struct tps6598x *tps, u8 reg, u32 val) > -{ > - return tps6598x_block_write(tps, reg, &val, sizeof(u32)); > -} > - > static inline int tps6598x_write64(struct tps6598x *tps, u8 reg, u64 val) > { > return tps6598x_block_write(tps, reg, &val, sizeof(u64)); thanks,
Tom Rix <trix@redhat.com> 于2023年3月19日周日 21:37写道: > > clang with W=1 reports > drivers/usb/typec/tipd/core.c:180:19: error: unused function > 'tps6598x_write16' [-Werror,-Wunused-function] > static inline int tps6598x_write16(struct tps6598x *tps, u8 reg, u16 val) > ^ > drivers/usb/typec/tipd/core.c:185:19: error: unused function > 'tps6598x_write32' [-Werror,-Wunused-function] > static inline int tps6598x_write32(struct tps6598x *tps, u8 reg, u32 val) > ^ > These static functions are not used, so remove them. > > Signed-off-by: Tom Rix <trix@redhat.com> > --- > drivers/usb/typec/tipd/core.c | 10 ---------- > 1 file changed, 10 deletions(-) > Reviewed-by: Jun Nie <jun.nie@linaro.org>
diff --git a/drivers/usb/typec/tipd/core.c b/drivers/usb/typec/tipd/core.c index 485b90c13078..af6ecb54b52c 100644 --- a/drivers/usb/typec/tipd/core.c +++ b/drivers/usb/typec/tipd/core.c @@ -177,16 +177,6 @@ static inline int tps6598x_read64(struct tps6598x *tps, u8 reg, u64 *val) return tps6598x_block_read(tps, reg, val, sizeof(u64)); } -static inline int tps6598x_write16(struct tps6598x *tps, u8 reg, u16 val) -{ - return tps6598x_block_write(tps, reg, &val, sizeof(u16)); -} - -static inline int tps6598x_write32(struct tps6598x *tps, u8 reg, u32 val) -{ - return tps6598x_block_write(tps, reg, &val, sizeof(u32)); -} - static inline int tps6598x_write64(struct tps6598x *tps, u8 reg, u64 val) { return tps6598x_block_write(tps, reg, &val, sizeof(u64));