From patchwork Thu Feb 8 18:48:04 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Shevchenko X-Patchwork-Id: 198582 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:50ea:b0:106:860b:bbdd with SMTP id r10csp458630dyd; Thu, 8 Feb 2024 13:19:31 -0800 (PST) X-Google-Smtp-Source: AGHT+IFUYOlNI8+lirQ9CUJCKHq62cko5FzOJMKX5GeUzj6HwWENZeWYizCMI1O9h5KLKXPmNVaE X-Received: by 2002:a17:902:f80c:b0:1d9:760d:31c7 with SMTP id ix12-20020a170902f80c00b001d9760d31c7mr412057plb.29.1707427171354; Thu, 08 Feb 2024 13:19:31 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707427171; cv=pass; d=google.com; s=arc-20160816; b=th5jDLQnIRdF6UhVyrTsLHbPFg+RrwELlCQ+Dw3Bon7DnJvolc3esnlTf6xvD2+NAG CRGrMldjIVj+2bSDm8uggb7umN3hKIC4S3uFgYljbBeB5fpelKe8y8IORkIZgP4TkCW1 fQjjtBVgHoRrquGUmiazFs/TDvACdfWiy9onmjTY7aZoZNEV0htrFRBOrj7hPJl62gH+ q/ns4OjBpx+33NmNAtyykfktxCxCPZWuu913Gg7NM7+g9ru8Arv2GsKSYpazi+YbdopV ceZlTjCwlCHlwqx89WHtin0aWCtIK7crvLcbgC7au2TnT3k5oQm4E2gleaqndBjZSiiu RY1g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=Im8sxIYdnsOh/O09iVixyjYqCb+RPsBx8cBLwd5LxZg=; fh=DSNQMxp3LZ4FJmDSS0FoMxdNsd2qVzz6tZ5z1iRj7ec=; b=y+urKGGazc52IpPvoUP3nJpdAAb0PiHGzqmXemDU2AY0IhT+8AcL8kjDd2R8vR43hV lSvcOEEncriAnp+QxzpJn+p/f3MTewVbJee/7Lue0UJ6Qnuve6QE0uYFlkrQwUL3sGej YyzurP9d/0sacNJqi/a/NGtIDDSbtAfrQvqC+L0baT3IFb5hUD4xD9tnzj6Z+zISgVhL y4I4wZxl05d0glcuTQlQWZtz7bGL2bQt2fGA8LfotzvUl3fDTS8NU20JDmu0qpArL8Xw IgfWC7JSvQQgXGiPPX7pkFtYwmQ3Jx9GM4hgEkYllQgkyy3pHvgzk6p3ORSiK6q7kXOO HKMA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=kXJR22dM; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-58571-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-58571-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com X-Forwarded-Encrypted: i=2; AJvYcCUo443s8zENDUsiFZU4nuuedntm4SIdCj1W/x0WtSeGaI9i7bmIPX67UnNJm6mABUGQDkWCqGqzkQo4DED/Y122uIJUEw== Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id jj2-20020a170903048200b001d8b574af48si345611plb.230.2024.02.08.13.19.31 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Feb 2024 13:19:31 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-58571-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=kXJR22dM; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-58571-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-58571-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id A364F284C19 for ; Thu, 8 Feb 2024 18:56:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D3C5B4EB43; Thu, 8 Feb 2024 18:49:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="kXJR22dM" Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1A613241E1; Thu, 8 Feb 2024 18:49:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.19 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707418174; cv=none; b=pvaV5NRaIwGfvkn9Je3oAnk+RMy5GgnpQ3C6c4GIu2wlS/2eI6gpy0d7J8GDmACE9GfVa/oNjO/fSY0mgEtn5IO36MCgTnjFB9tDvedEKEAREQEhXQLNvjZLHh1EaiJSgY261X23HHaCzRyvIxENO0oCFnKP0OPrDzoez6id5Ds= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707418174; c=relaxed/simple; bh=CF1pX065yGAbwnIQLmXi74KKJnRft9elRt9o2Olm5iY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=ml0gfN7JqZ0tTo0sQcYtqa+wyL8vwzQiGDH+tS4ar86+RPtUEg3itOldKKpric/3jMsRMeLupyeG7Ua+FGOz1CM7gOTGXeRPGIER5buewhAwWpHzBZO2pVEU7YF3/NdRyrnzVaVyZ7fen8CijyGoUkQEZkm7NIav2AYYCc0HpAU= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=kXJR22dM; arc=none smtp.client-ip=192.198.163.19 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1707418172; x=1738954172; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=CF1pX065yGAbwnIQLmXi74KKJnRft9elRt9o2Olm5iY=; b=kXJR22dM4kGGLMdYM5E7umSwxoRLAkXpSgk/LrRN1q/1zuYEcdJiYqNt LEhdev3OSBLWXo6+GbTVrGJJvkkFNbqIEOwoduNOSaMDxjenSkQzl1Q0d MSIqlReqJ3sz170aNiGeFNM1sp5slTTylg/wGtXX4J30uXD+KBXXIMyVw ntu9L2UaSaAsi/mrgn8osCOrYaaNHXwj/Txqh6Vj1zg/dx8DwsaFQlUsB GmSiquQ1zAY0e74qG42QRV3I/RTHRjhxFDSZDiTWgC+djXzlWgQspgnyv noI8p3m9rKT7caSCkdcZk2PpvZy21IRhxq2TcHkiwMDfUwN2aEpAjByoq A==; X-IronPort-AV: E=McAfee;i="6600,9927,10978"; a="1186131" X-IronPort-AV: E=Sophos;i="6.05,254,1701158400"; d="scan'208";a="1186131" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmvoesa113.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 08 Feb 2024 10:49:29 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10978"; a="934215532" X-IronPort-AV: E=Sophos;i="6.05,254,1701158400"; d="scan'208";a="934215532" Received: from black.fi.intel.com ([10.237.72.28]) by fmsmga001.fm.intel.com with ESMTP; 08 Feb 2024 10:49:25 -0800 Received: by black.fi.intel.com (Postfix, from userid 1003) id 661E5B2C; Thu, 8 Feb 2024 20:49:21 +0200 (EET) From: Andy Shevchenko To: Andy Shevchenko , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Miguel Ojeda , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Robin van der Gracht , Paul Burton , Geert Uytterhoeven Subject: [PATCH v1 06/15] auxdisplay: linedisp: Move exported symbols to a namespace Date: Thu, 8 Feb 2024 20:48:04 +0200 Message-ID: <20240208184919.2224986-7-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.43.0.rc1.1.gbec44491f096 In-Reply-To: <20240208184919.2224986-1-andriy.shevchenko@linux.intel.com> References: <20240208184919.2224986-1-andriy.shevchenko@linux.intel.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790367154129033498 X-GMAIL-MSGID: 1790367154129033498 Avoid unnecessary pollution of the global symbol namespace by moving library functions in to a specific namespace and import that into the drivers that make use of the functions. For more info: https://lwn.net/Articles/760045/ Signed-off-by: Andy Shevchenko --- drivers/auxdisplay/ht16k33.c | 1 + drivers/auxdisplay/img-ascii-lcd.c | 1 + drivers/auxdisplay/line-display.c | 4 ++-- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/auxdisplay/ht16k33.c b/drivers/auxdisplay/ht16k33.c index a90430b7d07b..c6a42c5c128f 100644 --- a/drivers/auxdisplay/ht16k33.c +++ b/drivers/auxdisplay/ht16k33.c @@ -831,4 +831,5 @@ module_i2c_driver(ht16k33_driver); MODULE_DESCRIPTION("Holtek HT16K33 driver"); MODULE_LICENSE("GPL"); +MODULE_IMPORT_NS(LINEDISP); MODULE_AUTHOR("Robin van der Gracht "); diff --git a/drivers/auxdisplay/img-ascii-lcd.c b/drivers/auxdisplay/img-ascii-lcd.c index 09014ada38bd..c571e54d9eb5 100644 --- a/drivers/auxdisplay/img-ascii-lcd.c +++ b/drivers/auxdisplay/img-ascii-lcd.c @@ -298,3 +298,4 @@ module_platform_driver(img_ascii_lcd_driver); MODULE_DESCRIPTION("Imagination Technologies ASCII LCD Display"); MODULE_AUTHOR("Paul Burton "); MODULE_LICENSE("GPL"); +MODULE_IMPORT_NS(LINEDISP); diff --git a/drivers/auxdisplay/line-display.c b/drivers/auxdisplay/line-display.c index 6b3d25e20eeb..851b2c0f9443 100644 --- a/drivers/auxdisplay/line-display.c +++ b/drivers/auxdisplay/line-display.c @@ -263,7 +263,7 @@ int linedisp_register(struct linedisp *linedisp, struct device *parent, put_device(&linedisp->dev); return err; } -EXPORT_SYMBOL_GPL(linedisp_register); +EXPORT_SYMBOL_NS_GPL(linedisp_register, LINEDISP); /** * linedisp_unregister - unregister a character line display @@ -276,6 +276,6 @@ void linedisp_unregister(struct linedisp *linedisp) del_timer_sync(&linedisp->timer); put_device(&linedisp->dev); } -EXPORT_SYMBOL_GPL(linedisp_unregister); +EXPORT_SYMBOL_NS_GPL(linedisp_unregister, LINEDISP); MODULE_LICENSE("GPL");