Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp3929445imj; Tue, 19 Feb 2019 12:01:41 -0800 (PST) X-Google-Smtp-Source: AHgI3IbhjERNdfsxjxxVUFnXjH/XMe3N++Vai5y4PdY0EyEWsAIkyUe+HzIrQka/YsnyTO+GxMSi X-Received: by 2002:a17:902:1122:: with SMTP id d31mr32759505pla.246.1550606501770; Tue, 19 Feb 2019 12:01:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550606501; cv=none; d=google.com; s=arc-20160816; b=NDm+Xo5xbzI+MSpUW262wG0hL/ePoofvvlJbjiRP5IVNj7jnPJUVZQ5ItLAg/7h7sR 7fToYPsRQ9vxJeKoJjZOZoWtq8qIaGwd3/bXg2Jg9oMfmu+BWfWuU3OxpdhKhQZfFLqv /YUFSjQrnEuG5kZEvLyl2gjCxJWhdi4ipHh5vZAavPLrjK+rO1CqYIXwRsa0SEtMmA5e AnBfZACsZXFaKLx8d7rmgB40a5qpDgc/T0iB9hATIDQcB/kUd7XjzUpABhM4UzD5ZNdA qtychX0coGN0azP6BYA4I784WDj+9KW2lnh+rVhgdEytLpTxEtjiLnAnplEgsFO3g64D 0hDA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=XhedpRHe33utbUmkNHyuG6OXYgLw/1xiYQrpBgv7QCo=; b=XgW57pJswjsS09HH5ecyr2rZ4+q0XkKMrfxDbQ4QVTIayXw5zq7qxSNLkJVHldK9Rx ueSNeb6TRYKYGbSEPLnfLOusLHy7+J/SAzf5SqXZWJ4CKdvwuo3Dlg5fmHPcEIUfwu9I F0ryrmsgw8u/0leou+xTxOsUF49g3zXXhVTkK0TQ/OYCYM7tr16AkuNGasRf+eStzN+f 4Gg+r6+rumffP35eon3TZgnVitbQyZtLbTCpjItcp3qF3HJgZMwitTQGmstMysEL934q yhf6dpQZ2AevjPqop2KMeEXdsEPc3+ka0bJn3gtEHstI4XqbXePm7K59X+SYbD6DYq8V +WRg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=mok.nu Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h4si16081140pgl.409.2019.02.19.12.01.26; Tue, 19 Feb 2019 12:01:41 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=mok.nu Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729672AbfBSUAr (ORCPT + 99 others); Tue, 19 Feb 2019 15:00:47 -0500 Received: from route-level1.fsdata.se ([89.221.252.216]:49358 "EHLO route-level1.fsdata.se" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729537AbfBSUAo (ORCPT ); Tue, 19 Feb 2019 15:00:44 -0500 Received: from DAG01.HMC.local (192.168.46.11) by EDGE01LEVEL1.hmc.local (192.168.46.33) with Microsoft SMTP Server (TLS) id 15.0.847.32; Tue, 19 Feb 2019 21:00:14 +0100 Received: from localhost (94.234.42.81) by DAG01.HMC.local (192.168.46.11) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Tue, 19 Feb 2019 21:00:21 +0100 From: Mattias Jacobsson <2pi@mok.nu> To: , CC: <2pi@mok.nu>, , Subject: [PATCH v4 6/8] platform/x86: huawei-wmi: use MODULE_DEVICE_TABLE() instead of MODULE_ALIAS() Date: Tue, 19 Feb 2019 20:59:54 +0100 Message-ID: <9ff0634026ad398bf0338915d9b8c7b5f32066ba.1550603967.git.2pi@mok.nu> X-Mailer: git-send-email 2.20.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [94.234.42.81] X-ClientProxiedBy: PROXY05.HMC.local (192.168.46.55) To DAG01.HMC.local (192.168.46.11) Received-SPF: Neutral (EDGE01LEVEL1.hmc.local: 192.168.46.11 is neither permitted nor denied by domain of 2pi@mok.nu) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org WMI drivers can if they have specified an array of struct wmi_device_id use the MODULE_DEVICE_TABLE() macro to automatically generate the appropriate MODULE_ALIAS() output. Thus avoiding to keep both the array of struct wmi_device_id and the MODULE_ALIAS() declaration(s) in sync. Change driver to use MODULE_DEVICE_TABLE() instead of MODULE_ALIAS(). Signed-off-by: Mattias Jacobsson <2pi@mok.nu> --- drivers/platform/x86/huawei-wmi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/platform/x86/huawei-wmi.c b/drivers/platform/x86/huawei-wmi.c index 59872f87b741..52fcac5b393a 100644 --- a/drivers/platform/x86/huawei-wmi.c +++ b/drivers/platform/x86/huawei-wmi.c @@ -201,8 +201,7 @@ static struct wmi_driver huawei_wmi_driver = { module_wmi_driver(huawei_wmi_driver); -MODULE_ALIAS("wmi:"WMI0_EVENT_GUID); -MODULE_ALIAS("wmi:"AMW0_EVENT_GUID); +MODULE_DEVICE_TABLE(wmi, huawei_wmi_id_table); MODULE_AUTHOR("Ayman Bagabas "); MODULE_DESCRIPTION("Huawei WMI hotkeys"); MODULE_LICENSE("GPL v2"); -- 2.20.1