Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp3023743rwb; Mon, 15 Aug 2022 16:21:20 -0700 (PDT) X-Google-Smtp-Source: AA6agR4e9Z1PSgVV+5QrFzFUHEeKJJ85UTxuxJWF4/SuNgyiWJyCN8rXjp5bDvAWlV9IVOKLN6T4 X-Received: by 2002:a17:907:c10:b0:731:58aa:7783 with SMTP id ga16-20020a1709070c1000b0073158aa7783mr12346224ejc.19.1660605581999; Mon, 15 Aug 2022 16:19:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660605581; cv=none; d=google.com; s=arc-20160816; b=is/rZHv2B47zY1Cjkg6HRFxsT4z4Z5UB92/K+CkJIlPU4cSXVoi3CGR0Ukfw9mIcWo l9xG/AyD8bTIjmEjGTH/nYWVPNPv8YFhX6D71lw/7pJ/T0irkydvkUfOFVnWmytkIKsi 1QGiEX5y4BtishIMbwBt8UmNdFlB3djvGXjGKSHsUKawrWU5gLClGTyKOh1L+mbVXM5q JA2qi/NNV8tTOuDPx60nNDJXEcqGvdd6kCjLciNYR9mYxllQeism75cKyZbT8reHqGDY a7vGxWqyuKrRBB9jdjNuPxwMrtIz4HQ+vFYYJRp7GFvkG7/eoQTivuaso6+KWia3hLTa Wg2g== 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=kEgjkWxzD7WkAKFxs028YtjupMds0XDtpz0bmFO5ox0=; b=kTaVR88NS3eQm/oy0Mbyg7g5iNja4lPxm6FdVnYKEPvbJcG0/z4aChJRa7vqnQ+cdG 8+S0ZGDh1cQlu629TekGU0muwvVmNfJ2Oa5lq1Gcm7hmedqi6e/v09OEdnzQ43znMuBl T8rjZguNldwx0AaNYS1gFEmJt60FPAsfW0qp+fRDr3G9jpJExwWBdC4aCok5GNrrG0K4 ROH4TwLiLatAadjY8XwTEr7T26mVu9mrlgshlSdS28Dk3rV5yN2WMY4nx1/wqlxQfrTL 9UwbCebhQe2795QWaE4ppBlZqdmooff49n1dSMXzKyJeC6uqYlqbhG2QtLq/4oPcrHZX sE8w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="tmJ/Hn0Y"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k16-20020a1709063e1000b00730c1be119asi7526883eji.408.2022.08.15.16.19.17; Mon, 15 Aug 2022 16:19:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="tmJ/Hn0Y"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 S233871AbiHOWAZ (ORCPT + 99 others); Mon, 15 Aug 2022 18:00:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56380 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1347213AbiHOV73 (ORCPT ); Mon, 15 Aug 2022 17:59:29 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 11A5910DCE9; Mon, 15 Aug 2022 12:35:09 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 29B1561184; Mon, 15 Aug 2022 19:34:42 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2C7FCC433C1; Mon, 15 Aug 2022 19:34:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660592081; bh=bOmIgRM4vNz3Df9Jf/OuuxejBYT6qZkU/b0bYL8I7/w=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=tmJ/Hn0Y7VPD1ZxOrbMhfJDQjYmWXa5IoMSUPbZmoOi/ZmjSVRVzyNhvQ+J3dwQAj 5oOXTHPMoZVADEZLI4KIlo9f5QnR7Cxo/Dkie/Ir4JBdhZ8Z5Vgq3My7CWsUVbv/Tm Kfjh70JGEUCbYmCKvU1OU/cU5c8P3NJ4uyIpyJ3E= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Mark Brown , Miquel Raynal , Sasha Levin Subject: [PATCH 5.18 0692/1095] mtd: dataflash: Add SPI ID table Date: Mon, 15 Aug 2022 20:01:31 +0200 Message-Id: <20220815180458.001073972@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220815180429.240518113@linuxfoundation.org> References: <20220815180429.240518113@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Mark Brown [ Upstream commit ac4f83482afbfd927d0fe118151b747cf175e724 ] 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 Signed-off-by: Miquel Raynal Link: https://lore.kernel.org/linux-mtd/20220620152313.708768-1-broonie@kernel.org Signed-off-by: Sasha Levin --- drivers/mtd/devices/mtd_dataflash.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/mtd/devices/mtd_dataflash.c b/drivers/mtd/devices/mtd_dataflash.c index 134e27328597..25bad4318305 100644 --- a/drivers/mtd/devices/mtd_dataflash.c +++ b/drivers/mtd/devices/mtd_dataflash.c @@ -112,6 +112,13 @@ static const struct of_device_id dataflash_dt_ids[] = { MODULE_DEVICE_TABLE(of, dataflash_dt_ids); #endif +static const struct spi_device_id dataflash_spi_ids[] = { + { .name = "at45", }, + { .name = "dataflash", }, + { /* sentinel */ } +}; +MODULE_DEVICE_TABLE(spi, dataflash_spi_ids); + /* ......................................................................... */ /* @@ -936,6 +943,7 @@ static struct spi_driver dataflash_driver = { .probe = dataflash_probe, .remove = dataflash_remove, + .id_table = dataflash_spi_ids, /* FIXME: investigate suspend and resume... */ }; -- 2.35.1