Message ID | 1db1e8bd253cbb652835c0cef6a0a2bb9a4970eb.1682325582.git.christophe.jaillet@wanadoo.fr |
---|---|
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 b10csp2607989vqo; Mon, 24 Apr 2023 02:18:00 -0700 (PDT) X-Google-Smtp-Source: AKy350bgFQhIcOVxfm1kFuCXVSAMVCFHTuNcfs5rZMsPQ+pfOXRvkeF+y8BF24+K9VUXibrlzlTm X-Received: by 2002:a17:902:ec8b:b0:1a6:9079:2bb3 with SMTP id x11-20020a170902ec8b00b001a690792bb3mr15822074plg.33.1682327880530; Mon, 24 Apr 2023 02:18:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682327880; cv=none; d=google.com; s=arc-20160816; b=RBFiFwUf4bCIXnTTE8foLTeIG5X1y08B2Nps//DRTvRcQVe7RBmfcCt4ytWN0yWqx4 6/BBgeBuBLBtUOCKtp0cBaxWClgTaRpLP95YXk1sN0OoN+V+MjL0UVBHLjnW98pefDUW Xh+3VFQpkyRH2wNtm6qMP5WUp66xceCUwF1Q1+eA/uM8jQZ1w5Z8BeZ+xDXmzKpVdVsh jKJI/m+egufZuULxjttbDvaE9LX1nj1/vL1jCnVaESGTvNHtSTQqixrB3Hrtz7ojtWUq QIxDg3IfycOHSbXQAmjoWAmZb01HLawfhVURBDph9PokPtyrJSz2uLrx0y8Z5Rj72syh raLw== 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=vgMfnD5w8L8osmiEQCPKAcBxZ5zFalY5WsdQV5PqFVU=; b=VBANrdslrAAJ06GqvDnRtmQji8LdC67BeeR8RuJ8xVqvCx5DlVrowi2Wx/Owzo3Deb NGIjl6J6dF7pAIwqLP/jf88aL9l8XHgUx+WvVXNzkMuZOzzqS41lRzbQTDOvNc6EN7qF feCrsXoxzTzk13Wdln+hcQ6mPSrIqWjCZZuOrZe5BmJg4rGlI8NtrwxoklrjsQBnHPyS uEg6ILwMSg2H00IHXhCWUJ+qJqHFNfpRgENVt5A+RkRz46woVTgnqGF4rn9KzEEEIEGT q4GolgtttyIBgKtpoV434f1TfSv8OghWkhu/kIyWReo6M197rBXcqTPFJFrAZ/LvW15j iTxA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@wanadoo.fr header.s=t20230301 header.b=X9QChUa0; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id bb1-20020a170902bc8100b001a4ee96c00bsi10359956plb.357.2023.04.24.02.17.47; Mon, 24 Apr 2023 02:18:00 -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=@wanadoo.fr header.s=t20230301 header.b=X9QChUa0; 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 S231199AbjDXIkF (ORCPT <rfc822;zxc52fgh@gmail.com> + 99 others); Mon, 24 Apr 2023 04:40:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32820 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230416AbjDXIkE (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 24 Apr 2023 04:40:04 -0400 Received: from smtp.smtpout.orange.fr (smtp-14.smtpout.orange.fr [80.12.242.14]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A8ED8E4F for <linux-kernel@vger.kernel.org>; Mon, 24 Apr 2023 01:40:01 -0700 (PDT) Received: from pop-os.home ([86.243.2.178]) by smtp.orange.fr with ESMTPA id qrjpp9pdVS2Yhqrjqpy8BT; Mon, 24 Apr 2023 10:39:59 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=wanadoo.fr; s=t20230301; t=1682325599; bh=vgMfnD5w8L8osmiEQCPKAcBxZ5zFalY5WsdQV5PqFVU=; h=From:To:Cc:Subject:Date; b=X9QChUa0hH2ybgHWlFRyPLmC5Dd0l0eKvnf5G6fJo66FWer4zD/ICt0pjXKSaN76J y/J8oE8QazQDRAZkQvMnNDELOuZq66MPu0VaRSnO45ebxzG1gTBVSf6vQqtMTiVdBq 9xoBjg6jyAfzx8JfM3fWaXhAeOcm6qfWGI7jkifXS6CSNXBFJnF7KIusxzgwfWO70n HdvGnUzH2/g3MnX5YgfksRY636m0p6Tc/h4YufQzqyEsAhQ81hgMsLZCI6sYAyX0Zb eIrWarETpt4fDopYH99zjv38VHPTW4mYE60syRYxi45Sii3+sZccwAy4t3U2WATTOD uOREdSNVtKMWw== X-ME-Helo: pop-os.home X-ME-Auth: Y2hyaXN0b3BoZS5qYWlsbGV0QHdhbmFkb28uZnI= X-ME-Date: Mon, 24 Apr 2023 10:39:59 +0200 X-ME-IP: 86.243.2.178 From: Christophe JAILLET <christophe.jaillet@wanadoo.fr> To: Heikki Krogerus <heikki.krogerus@linux.intel.com>, Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org, Christophe JAILLET <christophe.jaillet@wanadoo.fr>, linux-usb@vger.kernel.org Subject: [PATCH] usb: typec: mux: Remove some unneeded includes Date: Mon, 24 Apr 2023 10:39:56 +0200 Message-Id: <1db1e8bd253cbb652835c0cef6a0a2bb9a4970eb.1682325582.git.christophe.jaillet@wanadoo.fr> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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?1764048639674361292?= X-GMAIL-MSGID: =?utf-8?q?1764048639674361292?= |
Series |
usb: typec: mux: Remove some unneeded includes
|
|
Commit Message
Christophe JAILLET
April 24, 2023, 8:39 a.m. UTC
This driver includes many header files that are unneeded.
Remove them and add <linux/device.h> where devm_kzalloc() is defined.
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
---
Based on one of my script, this reduces the number of included files
during the build process of this file from 551 to 345.
---
drivers/usb/typec/mux/gpio-sbu-mux.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
Comments
On Mon, Apr 24, 2023 at 10:39:56AM +0200, Christophe JAILLET wrote: > This driver includes many header files that are unneeded. > Remove them and add <linux/device.h> where devm_kzalloc() is defined. > > Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> > --- > Based on one of my script, this reduces the number of included files > during the build process of this file from 551 to 345. > --- > drivers/usb/typec/mux/gpio-sbu-mux.c | 5 +---- > 1 file changed, 1 insertion(+), 4 deletions(-) > > diff --git a/drivers/usb/typec/mux/gpio-sbu-mux.c b/drivers/usb/typec/mux/gpio-sbu-mux.c > index f62516dafe8f..c07856069d43 100644 > --- a/drivers/usb/typec/mux/gpio-sbu-mux.c > +++ b/drivers/usb/typec/mux/gpio-sbu-mux.c > @@ -3,14 +3,11 @@ > * Copyright (C) 2022 Linaro Ltd. > */ > > -#include <linux/bits.h> > -#include <linux/i2c.h> > -#include <linux/kernel.h> > +#include <linux/device.h> > #include <linux/module.h> > #include <linux/mutex.h> > #include <linux/gpio/consumer.h> > #include <linux/platform_device.h> > -#include <linux/regmap.h> > #include <linux/usb/typec_dp.h> > #include <linux/usb/typec_mux.h> > > -- > 2.34.1
diff --git a/drivers/usb/typec/mux/gpio-sbu-mux.c b/drivers/usb/typec/mux/gpio-sbu-mux.c index f62516dafe8f..c07856069d43 100644 --- a/drivers/usb/typec/mux/gpio-sbu-mux.c +++ b/drivers/usb/typec/mux/gpio-sbu-mux.c @@ -3,14 +3,11 @@ * Copyright (C) 2022 Linaro Ltd. */ -#include <linux/bits.h> -#include <linux/i2c.h> -#include <linux/kernel.h> +#include <linux/device.h> #include <linux/module.h> #include <linux/mutex.h> #include <linux/gpio/consumer.h> #include <linux/platform_device.h> -#include <linux/regmap.h> #include <linux/usb/typec_dp.h> #include <linux/usb/typec_mux.h>