From nobody Mon Sep 8 07:56:06 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3234EEE57EF for ; Fri, 8 Sep 2023 10:17:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242841AbjIHKRw (ORCPT ); Fri, 8 Sep 2023 06:17:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56958 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242806AbjIHKRt (ORCPT ); Fri, 8 Sep 2023 06:17:49 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A8C021FE7 for ; Fri, 8 Sep 2023 03:17:22 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7AFA4C433D9; Fri, 8 Sep 2023 10:17:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1694168227; bh=FMrL+V9+pSz441pre2fqIuiBhaXySkpsxmO1V8C9qk8=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=hzhQfV7Mto8sYitMxK094l8sU39m82qISWwicDglYHbllVMc9C/rv8gSJC5U4C/19 HljZW0ons3FYvgF+H3UaqCXV/o7XiwYyBeWcJbZ04LM1u72QA7+GBpmXX0Y/kkBS4f Bq9BYlgTtR7Thfc640sSFY9DHcw91LkViTJrip/j3w3S3wRZF7qgzoZNJr3QfxwsFI UB5oxnQiaVQ+DoN6VvUX7RAxv1oq3tBFKqsZoDrKCmHdmnH/IJnOXs5Yc/LFtH0ahJ tevrUpqBemOU/geuJmAbaVhwNoXzyHLC3GI4cAiHsTraeADq6epAycoluVZxUvUbrr MN/mKwfOdEHbg== From: Michael Walle Date: Fri, 08 Sep 2023 12:16:36 +0200 Subject: [PATCH v3 18/41] mtd: spi-nor: eon: convert flash_info to new format MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20230807-mtd-flash-info-db-rework-v3-18-e60548861b10@kernel.org> References: <20230807-mtd-flash-info-db-rework-v3-0-e60548861b10@kernel.org> In-Reply-To: <20230807-mtd-flash-info-db-rework-v3-0-e60548861b10@kernel.org> To: Tudor Ambarus , Pratyush Yadav , Miquel Raynal , Richard Weinberger , Vignesh Raghavendra Cc: linux-kernel@vger.kernel.org, linux-mtd@lists.infradead.org, Michael Walle X-Mailer: b4 0.12.2 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The INFOx() macros are going away. Convert the flash_info database to the new format. Signed-off-by: Michael Walle --- drivers/mtd/spi-nor/eon.c | 72 +++++++++++++++++++++++++++++++++++--------= ---- 1 file changed, 54 insertions(+), 18 deletions(-) diff --git a/drivers/mtd/spi-nor/eon.c b/drivers/mtd/spi-nor/eon.c index 4848ffe8b38f..ba09cb6c2abd 100644 --- a/drivers/mtd/spi-nor/eon.c +++ b/drivers/mtd/spi-nor/eon.c @@ -9,24 +9,60 @@ #include "core.h" =20 static const struct flash_info eon_nor_parts[] =3D { - { "en25f32", INFO(0x1c3116, 0, 64 * 1024, 64) - NO_SFDP_FLAGS(SECT_4K) }, - { "en25p32", INFO(0x1c2016, 0, 64 * 1024, 64) }, - { "en25q32b", INFO(0x1c3016, 0, 64 * 1024, 64) }, - { "en25p64", INFO(0x1c2017, 0, 64 * 1024, 128) }, - { "en25q64", INFO(0x1c3017, 0, 64 * 1024, 128) - NO_SFDP_FLAGS(SECT_4K) }, - { "en25q80a", INFO(0x1c3014, 0, 64 * 1024, 16) - NO_SFDP_FLAGS(SECT_4K | SPI_NOR_DUAL_READ) }, - { "en25qh16", INFO(0x1c7015, 0, 64 * 1024, 32) - NO_SFDP_FLAGS(SECT_4K | SPI_NOR_DUAL_READ) }, - { "en25qh32", INFO(0x1c7016, 0, 64 * 1024, 64) }, - { "en25qh64", INFO(0x1c7017, 0, 64 * 1024, 128) - NO_SFDP_FLAGS(SECT_4K | SPI_NOR_DUAL_READ) }, - { "en25qh128", INFO(0x1c7018, 0, 64 * 1024, 256) }, - { "en25qh256", INFO(0x1c7019, 0, 64 * 1024, 0) }, - { "en25s64", INFO(0x1c3817, 0, 64 * 1024, 128) - NO_SFDP_FLAGS(SECT_4K) }, + { + .id =3D SNOR_ID(0x1c, 0x31, 0x16), + .name =3D "en25f32", + .size =3D SZ_4M, + .no_sfdp_flags =3D SECT_4K, + }, { + .id =3D SNOR_ID(0x1c, 0x20, 0x16), + .name =3D "en25p32", + .size =3D SZ_4M, + }, { + .id =3D SNOR_ID(0x1c, 0x30, 0x16), + .name =3D "en25q32b", + .size =3D SZ_4M, + }, { + .id =3D SNOR_ID(0x1c, 0x20, 0x17), + .name =3D "en25p64", + .size =3D SZ_8M, + }, { + .id =3D SNOR_ID(0x1c, 0x30, 0x17), + .name =3D "en25q64", + .size =3D SZ_8M, + .no_sfdp_flags =3D SECT_4K, + }, { + .id =3D SNOR_ID(0x1c, 0x30, 0x14), + .name =3D "en25q80a", + .size =3D SZ_1M, + .no_sfdp_flags =3D SECT_4K | SPI_NOR_DUAL_READ, + }, { + .id =3D SNOR_ID(0x1c, 0x70, 0x15), + .name =3D "en25qh16", + .size =3D SZ_2M, + .no_sfdp_flags =3D SECT_4K | SPI_NOR_DUAL_READ, + }, { + .id =3D SNOR_ID(0x1c, 0x70, 0x16), + .name =3D "en25qh32", + .size =3D SZ_4M, + }, { + .id =3D SNOR_ID(0x1c, 0x70, 0x17), + .name =3D "en25qh64", + .size =3D SZ_8M, + .no_sfdp_flags =3D SECT_4K | SPI_NOR_DUAL_READ, + }, { + .id =3D SNOR_ID(0x1c, 0x70, 0x18), + .name =3D "en25qh128", + .size =3D SZ_16M, + }, { + .id =3D SNOR_ID(0x1c, 0x70, 0x19), + .name =3D "en25qh256", + }, { + .name =3D "en25s64", + .id =3D SNOR_ID(0x1c, 0x38, 0x17), + .size =3D SZ_8M, + .no_sfdp_flags =3D SECT_4K, + }, }; =20 const struct spi_nor_manufacturer spi_nor_eon =3D { --=20 2.39.2