Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp2914216pxk; Mon, 28 Sep 2020 03:43:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJweXQIXx28NufK0yUiSFhdr6NiwCLewjdeUpkWDB3WPTGWIcr4vswFPJi+O2iMJiZmyAf3Z X-Received: by 2002:a17:906:1b15:: with SMTP id o21mr939199ejg.377.1601289819662; Mon, 28 Sep 2020 03:43:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601289819; cv=none; d=google.com; s=arc-20160816; b=MiJn1K8yxqTMSpTp7C7yvXKhTVZx3a93NF8Kja7C1A2pk5kEARWJJ+qbtQCX0RMljQ wCo1dxyKHi7EfA+fG12Uo5R8EAJqvM0WEEPz0Awfej/ZldFLcjfbFs3aSFdVmgqmAOpd RMUu+qPN35P/fiI/HyQUJi/5hKaFiiEF/Bf1bfIPO6CH6lZ2egeEFUbHd+OWIeY+Dbz/ YhVj6KFTnCRwsQM7i43Cxk1tII6up6LWIh9ZnQEc3U2ck6OhoER6+rL/cYJmr0yMXaKv BUNtjrOGNJEqXpWsaVjY9L97A8/sr5nPeGbAjhmV2hTj+AWU8a5lU2bmkKzmqHYFpFvO dM0w== 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 :dkim-signature; bh=3rBuEbcYA2LHM9EtzTttUwU6XI5h8fPFHgRL7rmnAS0=; b=NGH63+MJErKbsCk5iklgVHmPgisxMouHfygJYT+cKXPyRTGRKnoM/Bc+qKD9HhXMwi agu4p3uWeWOtABI7L8X3eB6LQ3qVd1bgn+YEmy0AqiLGcaSDkIK+PoF2osf7t1fL2/Gx wgODAjeBDgO4WpZbPNEKk8Q0QJj0kuDpX20WyIJTMYfqhyfeyT1XRpIAwHA1uBLl7J/F bnGQYYv+yEp/TbVi3xLmtNRuK5T9+tkPzElmnTqqxAgDBhfRDS6qhePO0CW6t6e+KC1V sWbPCOPFlhJolTpCnno/+weRwU7RKDV7a9qLimEfMebwstp+T4UEQ8gugqvy+lNLilCX d7Og== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bgdev-pl.20150623.gappssmtp.com header.s=20150623 header.b=wW9p0ooF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h24si398198ejk.247.2020.09.28.03.43.16; Mon, 28 Sep 2020 03:43:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@bgdev-pl.20150623.gappssmtp.com header.s=20150623 header.b=wW9p0ooF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726656AbgI1KmN (ORCPT + 99 others); Mon, 28 Sep 2020 06:42:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33094 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726605AbgI1KmJ (ORCPT ); Mon, 28 Sep 2020 06:42:09 -0400 Received: from mail-wm1-x343.google.com (mail-wm1-x343.google.com [IPv6:2a00:1450:4864:20::343]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3D97BC0613D5 for ; Mon, 28 Sep 2020 03:42:05 -0700 (PDT) Received: by mail-wm1-x343.google.com with SMTP id s13so588772wmh.4 for ; Mon, 28 Sep 2020 03:42:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=3rBuEbcYA2LHM9EtzTttUwU6XI5h8fPFHgRL7rmnAS0=; b=wW9p0ooFod3Bkjml4TY027l7RNbvLUML7kxvbOo9bzSOOntEK2jCMJxDR38WyLDSMt 6r8tTb8wwE4Yp5tNej41crQLAPiH4p05LliJKqKB76w/y+7rIEYpcwKNgBjAhkOdTMg3 gwaAYBty7mKHxoBWxJaNrFejILAEEQFGvnLvl+cw7oIsTKdPkTcuoHd54jqw3eVC1b72 YkRdyvMfYpeAggJ6TeNSkLn8DhC2Qw2KuDUlDHrAbzgL+U01HRFE9gT158HhLUO0bjmX /S3OS2onmluX6QhO7vFsGuQ1ifHa6Ov0Pmh1p4NGn3Efhj2JLnPnWefFZ3JQnnjBC30L 7wgQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=3rBuEbcYA2LHM9EtzTttUwU6XI5h8fPFHgRL7rmnAS0=; b=a0v+a1zU6RckO65pgyVXo0SNLd1GJTCO9NA1mHqH2ZQyfxFi4i4uG+1N7IKnr5rN8M 1gAyro1co1YWJEtYYL73ejPH7vn/HXqgOiFcgGf6PqRokbEdIP5lkM+7xmecQzT/ieuu EE827R9T/qSycI6zo71vGmnyyOi4fmgvNHG7JieWeErKZYvt0+GKOJM5yXcbRBFAKosZ HfqmDyCijCfkp8gYv4CCBOQpgPjLcw2gLlPS8jfJlRlo+D6VC80jLaUv8irTmHvZi6W0 GxMbJwOGt8nGdqWtepJ0SAyMpHM4AD5KYjj3p5JQ65pr7K7zzYIgRFm8iJsYLutTOtKD 7tVg== X-Gm-Message-State: AOAM532JC2OcEOWtjO5wvCcuFpwtAS34u00R1jG1UUnQVc3qrnaLsY0o LrAJUWC7PQJaK5ye+UxRziTpHw== X-Received: by 2002:a1c:4303:: with SMTP id q3mr954114wma.158.1601289723948; Mon, 28 Sep 2020 03:42:03 -0700 (PDT) Received: from debian-brgl.home (lfbn-nic-1-68-20.w2-15.abo.wanadoo.fr. [2.15.159.20]) by smtp.gmail.com with ESMTPSA id f14sm939258wrt.53.2020.09.28.03.42.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 28 Sep 2020 03:42:03 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Jonathan Corbet , Andy Shevchenko , Kent Gibson Cc: linux-gpio@vger.kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v2 4/9] gpio: mockup: use KBUILD_MODNAME Date: Mon, 28 Sep 2020 12:41:50 +0200 Message-Id: <20200928104155.7385-5-brgl@bgdev.pl> X-Mailer: git-send-email 2.26.1 In-Reply-To: <20200928104155.7385-1-brgl@bgdev.pl> References: <20200928104155.7385-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Bartosz Golaszewski Drop the definition for the driver name. Let's use KBUILD_MODNAME for the log format and use the "gpio-mockup" value directly in the only place where it's relevant: in the name of the device. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko --- drivers/gpio/gpio-mockup.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/gpio/gpio-mockup.c b/drivers/gpio/gpio-mockup.c index c5092773afd8..90a1d6c2775f 100644 --- a/drivers/gpio/gpio-mockup.c +++ b/drivers/gpio/gpio-mockup.c @@ -21,7 +21,6 @@ #include "gpiolib.h" -#define GPIO_MOCKUP_NAME "gpio-mockup" #define GPIO_MOCKUP_MAX_GC 10 /* * We're storing two values per chip: the GPIO base and the number @@ -31,7 +30,7 @@ /* Maximum of three properties + the sentinel. */ #define GPIO_MOCKUP_MAX_PROP 4 -#define gpio_mockup_err(...) pr_err(GPIO_MOCKUP_NAME ": " __VA_ARGS__) +#define gpio_mockup_err(...) pr_err(KBUILD_MODNAME ": " __VA_ARGS__) /* * struct gpio_pin_status - structure describing a GPIO status @@ -500,7 +499,7 @@ static int gpio_mockup_probe(struct platform_device *pdev) static struct platform_driver gpio_mockup_driver = { .driver = { - .name = GPIO_MOCKUP_NAME, + .name = "gpio-mockup", }, .probe = gpio_mockup_probe, }; @@ -572,7 +571,7 @@ static int __init gpio_mockup_init(void) properties[prop++] = PROPERTY_ENTRY_BOOL( "named-gpio-lines"); - pdevinfo.name = GPIO_MOCKUP_NAME; + pdevinfo.name = "gpio-mockup"; pdevinfo.id = i; pdevinfo.properties = properties; -- 2.26.1