Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp3036347pxb; Mon, 18 Oct 2021 07:03:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzyEqB+5ZZohcixbFzO1by/hNj+pXWXLmE7Y1IyWghASryYUBemr1lAmIpJj5SMA3PTsges X-Received: by 2002:a17:902:ecd0:b0:13f:1469:c0f2 with SMTP id a16-20020a170902ecd000b0013f1469c0f2mr27080184plh.10.1634565836118; Mon, 18 Oct 2021 07:03:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634565836; cv=none; d=google.com; s=arc-20160816; b=atIvI1QQNo0zY7gqebB+sojkrgf5HSBOFHnISzzc9uWmhE7/lIDIwFRIM3duZ82QVm OdpUoxedrJ5Nm65OMGZjmR/9syf5pQM16tFf70OlPfRxKgdqo/lPhj5x3hBBZsfLI4TW yWw9ntFRotTN9mT3yV0sQ+5ubHTlMSq+XkaV8soiuyE8Azwvewmj8Utr1aH69jad/BkW M0mcC9nZPiZmolIf27PM/zL6VvooFG/Nl8mlBZQszev+0U2UlkPCybBehqTC49EEWwo+ bMg9f0eZxopvAhOAQZUQ2LJTf7yI14vaF5lODhNjUvn2SZfLjl1ilWdcfXC5BBKDQSSB 85pA== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=39rgjP4uqmQe0e3IDSu734UnKWquQu5DkQk47KqntA0=; b=ug8g9qV1ajF6FDr/gwG3NhXrLkybTwoKSG+7h5mCtvz+7+8Stw+kcnrUuMJXX7l9q1 mC6N/MLg2FvSkn7Pn9NssdIxBl+AHaZx9TBStTb43fei6cczyZ1sRt2f6CXLQxeJ5Sdr IYXVmP/IgmG8gONc7n7Q7Da6cP9DhvU3K6LQCCFY0TH67Ta2KR5YLD95GMEGo/4xgQNm ofEma15ngQLduLC0IOaTe8qU/3Js3Y8G6z2BAmNBXT9S/XCBR4Cyo5ZT4nS5LYGq2TI2 VcUtzDOOz3OCxsySayAv5iPIChsDYNxd121hcGTNzx0VxfKdKHiCOrhx13UrfHF50zAs hdBA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=IYkZ64VG; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v12si23400677pfu.224.2021.10.18.07.03.42; Mon, 18 Oct 2021 07:03:56 -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=@linuxfoundation.org header.s=korg header.b=IYkZ64VG; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234263AbhJROCD (ORCPT + 99 others); Mon, 18 Oct 2021 10:02:03 -0400 Received: from mail.kernel.org ([198.145.29.99]:37464 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234206AbhJRN76 (ORCPT ); Mon, 18 Oct 2021 09:59:58 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 2F1B261A70; Mon, 18 Oct 2021 13:42:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1634564529; bh=qRlZ3O2fCZAUNFvO+4h5GtexXDjDgVaufbLgT+qB8JU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=IYkZ64VGxDkf1cF1Scp8tjKCnZtiwMMKdWbuZ2WVg3xH0kIMAUKinj3t+lRFRQbs4 QvaIcIH9YJpqGX1AQOeCcvF2C8OH6eyN4FtxiPcKmPuorwGRH0enHgkC8CpOL3qcJo QgPuv0yX/mc1ktaEHrEpM1JH9iLQbaWYBSUqj/1k= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Mark Brown Subject: [PATCH 5.14 123/151] spi: spidev: Add SPI ID table Date: Mon, 18 Oct 2021 15:25:02 +0200 Message-Id: <20211018132344.669365810@linuxfoundation.org> X-Mailer: git-send-email 2.33.1 In-Reply-To: <20211018132340.682786018@linuxfoundation.org> References: <20211018132340.682786018@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Mark Brown commit 6840615f85f6046039ebc4989870ddb12892b7fc upstream. Currently autoloading for SPI devices does not use the DT ID table, it uses SPI modalises. Supporting OF modalises is going to be difficult if not impractical, an attempt was made but has been reverted, so ensure that module autoloading works for this driver by adding an id_table listing the SPI IDs for everything. Fixes: 96c8395e2166 ("spi: Revert modalias changes") Signed-off-by: Mark Brown Link: https://lore.kernel.org/r/20210923170023.1683-1-broonie@kernel.org Signed-off-by: Mark Brown Signed-off-by: Greg Kroah-Hartman --- drivers/spi/spidev.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) --- a/drivers/spi/spidev.c +++ b/drivers/spi/spidev.c @@ -673,6 +673,19 @@ static const struct file_operations spid static struct class *spidev_class; +static const struct spi_device_id spidev_spi_ids[] = { + { .name = "dh2228fv" }, + { .name = "ltc2488" }, + { .name = "sx1301" }, + { .name = "bk4" }, + { .name = "dhcom-board" }, + { .name = "m53cpld" }, + { .name = "spi-petra" }, + { .name = "spi-authenta" }, + {}, +}; +MODULE_DEVICE_TABLE(spi, spidev_spi_ids); + #ifdef CONFIG_OF static const struct of_device_id spidev_dt_ids[] = { { .compatible = "rohm,dh2228fv" }, @@ -819,6 +832,7 @@ static struct spi_driver spidev_spi_driv }, .probe = spidev_probe, .remove = spidev_remove, + .id_table = spidev_spi_ids, /* NOTE: suspend/resume methods are not necessary here. * We don't do anything except pass the requests to/from