Received: by 10.213.65.68 with SMTP id h4csp250513imn; Fri, 23 Mar 2018 03:57:29 -0700 (PDT) X-Google-Smtp-Source: AG47ELuBvO8Z0Ba512tt2oYzxXLQXyLecA38w8xnebcoUTZsM/PccIIvloUXVSjl6lSOw2CLAtvu X-Received: by 2002:a17:902:760e:: with SMTP id k14-v6mr9850499pll.292.1521802649337; Fri, 23 Mar 2018 03:57:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521802649; cv=none; d=google.com; s=arc-20160816; b=c8UeTrRVc6iKdGs3/1bnDFrLknU8mReO+JlhABG360B/jyAUqF9pH1mw/lU52ZdB5s SBOfK4dQaVemWphVPvBCDmUKG1ptgZ2iYttpi7BS2ci1/HFqd0u6q3XpKU/D1hBRu+9w uBr2X41nvQ9FFjEqIkNXHSilp0IsjFQgPBdqWkBnTCFYWL/bKJDpVuepVoqbe7GSa18M q399bg4Kw+sS1dzNaWttO2N8K+3rPt0T9wGtcooGJeJVGpuowc8nXb6u7tdHVgW/RSQV FkkZrrlFPC4CVPY/QetUroYNJw/JuuAMLk01KTuoi9ic6yyJp37F++JqK9lVUnudlpTU KFvA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=5NGcNHgqoV/i8T5wGi98Lx90frRJe0AMBbwfw8QQ8T0=; b=Xepu9Q1Pwi16Qgeo7fCLJGpEYLFx8X7lM3XrYuOpK6rdlv5A8W9SsxD4FdyoVu/mV1 akXcwp7hViZeWqZlvejxq23AzwUzdKU8vJsxcWzOt7469/tgJrpjWIQYyqeXtEEre4iZ yIrINydyi096lC7IANS4mfA5IvSOKLUTpnR2+FSIbngREv2MTpSfC0ObPiGi5YdlsYRr 5tAJM8xtv+/SwAb5L0ZnqpFHVrRWwyhqeTAJeXV8beBZ+EZaCwsPaQlL/4Yfb7r2c8n5 zvSpcrGW36eQFXtwwW7Uvosz+C6lApuoOr5pDJ8fb780oruPqrR6aEuJH3mqkrlXTn6c fD7Q== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q10-v6si8663169pll.237.2018.03.23.03.57.15; Fri, 23 Mar 2018 03:57:29 -0700 (PDT) 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755661AbeCWKNE (ORCPT + 99 others); Fri, 23 Mar 2018 06:13:04 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:44570 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752464AbeCWKNB (ORCPT ); Fri, 23 Mar 2018 06:13:01 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 1771711E1; Fri, 23 Mar 2018 10:13:00 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Christian Gmeiner , Martin Kepplinger , Dmitry Torokhov , Sasha Levin Subject: [PATCH 4.4 10/97] Input: ar1021_i2c - fix too long name in drivers device table Date: Fri, 23 Mar 2018 10:53:57 +0100 Message-Id: <20180323094158.078104191@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180323094157.535925724@linuxfoundation.org> References: <20180323094157.535925724@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.4-stable review patch. If anyone has any objections, please let me know. ------------------ From: Dmitry Torokhov [ Upstream commit 95123fc43560d6f4a60e74f72836e63cd8848f76 ] The name field in structure i2c_device_id is 20 characters, and we expect it to be NULL-terminated, however we are trying to stuff it with 21 bytes and thus NULL-terminator is lost. This causes issues when one creates device with name "MICROCHIP_AR1021_I2C" as i2c core cuts off the last "C", and automatic module loading by alias does not work as result. The -I2C suffix in the device name is superfluous, we know what bus we are dealing with, so let's drop it. Also, no other driver uses capitals, and the manufacturer name is normally not included, except in very rare cases of incompatible name collisions. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=116211 Fixes: dd4cae8bf166 ("Input: Add Microchip AR1021 i2c touchscreen") Reviewed-By: Christian Gmeiner Tested-by: Martin Kepplinger Signed-off-by: Dmitry Torokhov Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- drivers/input/touchscreen/ar1021_i2c.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/input/touchscreen/ar1021_i2c.c +++ b/drivers/input/touchscreen/ar1021_i2c.c @@ -152,7 +152,7 @@ static int __maybe_unused ar1021_i2c_res static SIMPLE_DEV_PM_OPS(ar1021_i2c_pm, ar1021_i2c_suspend, ar1021_i2c_resume); static const struct i2c_device_id ar1021_i2c_id[] = { - { "MICROCHIP_AR1021_I2C", 0 }, + { "ar1021", 0 }, { }, }; MODULE_DEVICE_TABLE(i2c, ar1021_i2c_id);