From patchwork Mon Jun 20 15:23:13 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Brown X-Patchwork-Id: 583164 Delivered-To: patch@linaro.org Received: by 2002:a05:7000:5036:0:0:0:0 with SMTP id e22csp796280mab; Mon, 20 Jun 2022 08:24:09 -0700 (PDT) X-Google-Smtp-Source: AGRyM1s3dipv3skwR9qfmZkMEZuPd8hCJ4rd2EpE+WyRi+nTptC6qdJ0mJOxJqOMENpRg5kjYT8s X-Received: by 2002:a63:6a42:0:b0:3fe:2556:c629 with SMTP id f63-20020a636a42000000b003fe2556c629mr21969785pgc.159.1655738649455; Mon, 20 Jun 2022 08:24:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655738649; cv=none; d=google.com; s=arc-20160816; b=qLBz1E3JvIMAwJIXQIU/k9oRuESVzwGL5Eiswol0KnTawRoa2QVdM7bz6C+kn/pRo3 PvCOndb9Vghnmr2LsUR42PgGA3J8oPpGsmiydH5xgRutIeLeeUAHvDW3XX8oUB4O0zD/ +eoaTq9wOknW7wIvMYuEcYUrszm8yCBAvZGNxLNFP1t+sfg8bW6iK5wnDKexkD0ldlFW P03KU52dWA2Fs6XCsMaaYduWCSgifyJAP+eHeyvBodMBpXiOO4TUdCtrfkzy0t9ZO09n DlUcgf+umULYTafytHWJX/d1qAhMXLjolAUdjD7ffkSkXZJGltc6OCLuFEV6mn+qqN/V T1jA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence :mime-version:message-id:date:subject:cc:to:from:dkim-signature :dkim-signature; bh=wGhR0Sc0l11Hqqp19G9vd9geuVLB0qU1NikfAAEf4fg=; b=AR/2eKbLLD9tIxPSHvvDk8FfXW5Yfzss7YvHQxdlp+jC/h8eXbwlyCmIIr6YEt77x7 73X8Cip+kvwqpNX15XrUiOkZ+m+varOAx1JPiUmi05rtbx0kFsJsOVc4dTSQtoyBsXhV gpbjB1GS4RNT2cVDYO09mFlKfdPdXCBLCsS9Dpmvielfn0Vipcgvv9EiZizC6aQnr1RM BJ4snLIbNF9wVM+Wpi/joN6cE2FX+IFdidS+5VWfK7i9ZWMnpRlsRccIEsch6q2dlSyf I+aphUQmJkcGnWT1M2du9h1NAgvPSwi6x4GUFP3++hJOoT+24CVydom0gfp6H5tg5+L3 1ORw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lists.infradead.org header.s=bombadil.20210309 header.b=x2xuKXDM; dkim=neutral (body hash did not verify) header.i=@kernel.org header.s=k20201202 header.b=h6NZdsu+; spf=pass (google.com: best guess record for domain of linux-mtd-bounces+patch=linaro.org@lists.infradead.org designates 2607:7c80:54:3::133 as permitted sender) smtp.mailfrom="linux-mtd-bounces+patch=linaro.org@lists.infradead.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from bombadil.infradead.org (bombadil.infradead.org. [2607:7c80:54:3::133]) by mx.google.com with ESMTPS id l63-20020a638842000000b003fc5209dbdesi16759638pgd.646.2022.06.20.08.24.09 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 20 Jun 2022 08:24:09 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-mtd-bounces+patch=linaro.org@lists.infradead.org designates 2607:7c80:54:3::133 as permitted sender) client-ip=2607:7c80:54:3::133; Authentication-Results: mx.google.com; dkim=pass header.i=@lists.infradead.org header.s=bombadil.20210309 header.b=x2xuKXDM; dkim=neutral (body hash did not verify) header.i=@kernel.org header.s=k20201202 header.b=h6NZdsu+; spf=pass (google.com: best guess record for domain of linux-mtd-bounces+patch=linaro.org@lists.infradead.org designates 2607:7c80:54:3::133 as permitted sender) smtp.mailfrom="linux-mtd-bounces+patch=linaro.org@lists.infradead.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=wGhR0Sc0l11Hqqp19G9vd9geuVLB0qU1NikfAAEf4fg=; b=x2xuKXDMqrVDtE qpqnJc9NIHz1uW2Q42uLgaokqj8qgMWwmfgpxagW/emehfdOL/pkg0myNBNFluNaNCT2Sa8aWreYf 5Zv0t/6X8Lx/8ulexkA2lJFBsdahitGOpIp99tR0WY66QDGuY4OHvvDUIssIuUWvlYa8GfyMEE/yL S2kMWz6NvQnh4N97DCAr/XOP6mlidBOGXGk3SufWklhTQBxGVwP2LTaFhXmtSC9d98zbP3UOvLrmg YMYD3y/24+SdBgden2o/IlDJ8k/jAOaaA3AexUH+nBc9four0x18iDmySJjSHICPdFDedFQGpMHmI 8ypZe2iOVd22MsVANOgg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1o3JFL-001Ewl-Su; Mon, 20 Jun 2022 15:23:23 +0000 Received: from ams.source.kernel.org ([145.40.68.75]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1o3JFJ-001Ew3-O6 for linux-mtd@lists.infradead.org; Mon, 20 Jun 2022 15:23:23 +0000 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 ams.source.kernel.org (Postfix) with ESMTPS id 2A35FB80F1A; Mon, 20 Jun 2022 15:23:20 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id ADEEBC3411B; Mon, 20 Jun 2022 15:23:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1655738599; bh=J0AVDvwi+PvxIkqAwYINYekO84CN0cY/Zc6Bz0k7oMY=; h=From:To:Cc:Subject:Date:From; b=h6NZdsu+zrm+km9v7oUwCxlz2jij0HFJeCWnakjcFIThZU9/kfERl1Dbf+aqw4Kyw PgxHi3Bba7Zbfn1i/PrOR4c9sVehBYk4iXUrJIq+MvRZPb+epvtXhKWLlAsNAdwfBS BwqN+23HTk1ihgT/VBAKCvnMon3KvAdjeimG6a4CbUeWGBuyoSbYoQpFRmE1kRf+lM JYlo8LV8SxcZo5jQyV31Lsy28EREklR3RUq5WWXxQAx3qq10fn82BS9wj5kQEuGs1J ylU5pK7t2JIje3ITtfbMC/YiXvdtQ/3pXTN0uSWa+U3/m/GpLOkJ9Ck/XHqaweUwkM OdpxzSRoqjxlg== From: Mark Brown To: Miquel Raynal , Richard Weinberger , Vignesh Raghavendra Cc: linux-mtd@lists.infradead.org, Mark Brown Subject: [PATCH] mtd: dataflash: Add SPI ID table Date: Mon, 20 Jun 2022 16:23:13 +0100 Message-Id: <20220620152313.708768-1-broonie@kernel.org> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1386; h=from:subject; bh=J0AVDvwi+PvxIkqAwYINYekO84CN0cY/Zc6Bz0k7oMY=; b=owEBbQGS/pANAwAKASTWi3JdVIfQAcsmYgBisJC+XxHok8kBSYShad6IPvtjg1uJL1N7n8LcEigy 1la3FiyJATMEAAEKAB0WIQSt5miqZ1cYtZ/in+ok1otyXVSH0AUCYrCQvgAKCRAk1otyXVSH0CK8B/ 4tBdKhwDwlw1bJv8O4ad2WC+rOH5V9M91yOPs//g4hYfrbie1kFBQ3QZmimVpM4z6kMLxTVTW9dVY5 l/Ciuhe822Gvi0+I+9B72N3k602ckUzPdxVyTe+zCLMqGOyKveGgeK/QVeo1wvPZMLLrDJ03BvuIAU EOcfdZICIm7NrABWTs7jgDFpgvAQdvbX383AZkdWToq13AGmcHreUeP3HPeZ5sHtbZw2/chAXCV7ig Hbroje36TH7pTKz8F2cYwri8ImmVJ+CaydVDKarsJUJl1LxxbJdfeMIlhZGU8Wv0zg/3Px8/8EqW9V SQwiWyNCztKGtioR26ma/5zyzge+gN X-Developer-Key: i=broonie@kernel.org; a=openpgp; fpr=3F2568AAC26998F9E813A1C5C3F436CA30F5D8EB X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220620_082321_968407_56D551C5 X-CRM114-Status: GOOD ( 13.74 ) X-Spam-Score: -5.4 (-----) X-Spam-Report: Spam detection software, running on the system "bombadil.infradead.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: 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 reverte [...] Content analysis details: (-5.4 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -5.0 RCVD_IN_DNSWL_HI RBL: Sender listed at https://www.dnswl.org/, high trust [145.40.68.75 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain -0.2 DKIMWL_WL_HIGH DKIMwl.org - High trust sender X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-mtd" Errors-To: linux-mtd-bounces+patch=linaro.org@lists.infradead.org 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 --- 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... */ };