From patchwork Fri Jul 22 16:10:00 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 2235 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-ed1-f71.google.com (mail-ed1-f71.google.com [209.85.208.71]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id AAE1B3F047 for ; Fri, 22 Jul 2022 18:11:15 +0200 (CEST) Received: by mail-ed1-f71.google.com with SMTP id v9-20020a056402348900b0043bcd680e50sf1689619edc.18 for ; Fri, 22 Jul 2022 09:11:15 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1658506275; cv=pass; d=google.com; s=arc-20160816; b=zllEJ6lqvU5VEbZyNKL40Xm9pc3MsLeMd+FaeDucksZ1nKalb3uRWLfTKyw+DxGwMO Stw5Ef53gnUy5GJFHZnisj7BsmtTSXnV2vwK6EnIP5TPajo0mYLxTbTH8atg1nZbzhdJ MntAXISGJbPa5pLJX2sQ8ro0d6Oc0tLYLrn0FFyap6XjyJ+/534kZvVmgY/SNgMuVsBN bIB+YidnpQAqxBAa0ks6EjmfNmVHTysOzVAJ2O8zOCfTgBBIPEP2VSfKOuVFkLp/0q82 T3lDwvbxdc7XBiAHawR0sYuNayOVmvJYTBFYg4i9TDsQ7IsG+bg4dQLoDAWZgVptEep3 Gj/g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=Mx4WhDoVE9eDaatrUeXtmIleNQy27p8J6+NyWVgG2ZE=; b=HihgGNo8orMikanAS1q1yJiAydQ5lswAxxO9BSrRQpSoWRvOs6mb9RIb2ij5przxDf AlaSeDYefETTMz/Z7+L+vKVMLLv25qNHZuf589RgAef8uiwR3LgYNB62HQ9I5uFbaXNB 1DlB0tCqChDDTdaEzA5eO7pxNvMOkq7qwcNZn3furGQn2pbij2rU6YdDG0jtbZQ/RR/R i7dhZzdAgjd2Cu/KjiHVUHDfpYBHeYPNWg/6Jq8fVpFgVQjNNEzFHcz0dfCNXrh8xdjW IryCU+HxZVCUF6wE1D6gWSH43mZudaYR/K67mkyiXnbZa7bobwYQF1eldIkZJg6cmJcj Ev2Q== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=JCpHs0nO; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:x-original-sender:x-original-authentication-results :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe; bh=Mx4WhDoVE9eDaatrUeXtmIleNQy27p8J6+NyWVgG2ZE=; b=IQGg4aYTJ6vlMJ1eDTtwMZnvEYBm/S4m1bWUyXYiLMCRDcWfAk/CHPg0u55I+wXrs0 YKMWh6HsJG0WY5Jqc4kk4SN2E7mfJa19mXH47Qe/bKNq5Qi/3eHCHozbY51gqdnirq+z DXSRQAKMAl7XRcB3YQE4Pck6bRI9h5rK2NZsE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-spam-checked-in-group:list-post:list-help:list-archive :list-unsubscribe; bh=Mx4WhDoVE9eDaatrUeXtmIleNQy27p8J6+NyWVgG2ZE=; b=TuGZiCiMb8rnSTDJMSmQ7FJmGCQAsepsitDtB/+ZQDfORJvqyw3Z/ZsndOiqqIX9qm x0sNoqQYh741kjId0YAabluPodrXbBw8KfluHC5OesNw+J1UeMmhlv3UAb0B1gpf+qSa 9l96720ctUu+upMOMkiib42bswCM6Cp+ofg0+h3cSSiYuWe8YwAvMDEhqfH/0z5Kq5/7 P8hGGeEfniRIsdUsqugzK3Ler1OVvb8K8TTdtrVE/fJI1mXwOv/ZxIaIkC7UuzYlrkL7 oDNLcRt/NmCx78PH0FBRBNk2Q3e5FyA7btJqcHhnTnJpbVuA9YwFQih/1bCZO5QOGvxA OKlQ== X-Gm-Message-State: AJIora//t7ustWiyMMSzwLCs+S+2Ee+G06ObqNSM3SUhRINPDkhTUWmG 6uniIUHpxIca6X8Hapj9cdSdrAuo X-Google-Smtp-Source: AGRyM1vUxIdUEvPROyfPN9t39NE4ggMOyoOrHLkWBK8TKTAnNGrdrWr5XsHabbyFjZoXeLOZJHzXBg== X-Received: by 2002:a17:907:7617:b0:72b:49fe:fdf7 with SMTP id jx23-20020a170907761700b0072b49fefdf7mr499990ejc.25.1658506275476; Fri, 22 Jul 2022 09:11:15 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a05:6402:11cb:b0:43a:7c1c:8981 with SMTP id j11-20020a05640211cb00b0043a7c1c8981ls2106863edw.0.-pod-prod-gmail; Fri, 22 Jul 2022 09:11:14 -0700 (PDT) X-Received: by 2002:a05:6402:3047:b0:43a:9e43:95e5 with SMTP id bs7-20020a056402304700b0043a9e4395e5mr558500edb.385.1658506274534; Fri, 22 Jul 2022 09:11:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1658506274; cv=none; d=google.com; s=arc-20160816; b=GT8KQKTfBM+pLmGuonUj0ZOrFxjS+xN9o2SwcV586ZPDSbHOrcqzDLcxpvBACsvoQk F7jXvQpfxJvSKBXdVbJTdPOKMX3gj04GOda7oAt7w2MDBSzKkFCiej3bcrFy3VZS8U+5 00dNpL1LOzCwCe+xzcCCYOvRDvZMdsxdv6QhMsLjwnX3u2SOrmTCaLITCiFVp8Jk5Pbf VWPWnRfvE/e1vTjzhEGR1LOtb0j5D86TIm91tGLgrBVw+W9TvdEwMyVZ6wPvFwyYq6qK 6tER0HXKEMQRpe+vL0jmHYiwZ+7cPYm0p+PNndyM1xUesWmItJDLrUNNFVZG3xaQl9XO uaPA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=PqkGaZHSNiv+wfu/yU2ktE6N+nN1VwOJ0uXBw8IizDw=; b=HM9lLt11/2Jd2LEOjM4eQSj05sJ09eZT7roCdYeF3v3aOFBHym0dnsqrSHb+iTeRLO uok5kS8Z6Ybo1UjMmInRD3o7fBDfiLC73+7I1zE268Y44STjHpVmT9VKuXOI2oixzv32 iMjeU+pRCDhjuqU6gfKLy9X4+AUbbZ7K6QHlTvr9mSA3NF3PCyIwxbtu4iSRKJn/yAXH CO50wA5cxYUIMCFJYqxtvl1ILMV/lOztYvH8/y3IVsEWJvvQCRzcVmZNj6g4h1U0FtJb jjJhaCA3nGMYXPFteSMbg8EAZPzz2GksMGxbdCDTLlxciifR4ByX07CmMmdBPzTMhAWh uilA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=JCpHs0nO; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id j5-20020a170906430500b0072a6696313asor2332211ejm.76.2022.07.22.09.11.14 for (Google Transport Security); Fri, 22 Jul 2022 09:11:14 -0700 (PDT) Received-SPF: pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41; X-Received: by 2002:a17:906:9751:b0:72f:1b36:e1de with SMTP id o17-20020a170906975100b0072f1b36e1demr479298ejy.451.1658506274266; Fri, 22 Jul 2022 09:11:14 -0700 (PDT) Received: from dario-ThinkPad-T14s-Gen-2i.pdxnet.pdxeng.ch (host-87-14-98-67.retail.telecomitalia.it. [87.14.98.67]) by smtp.gmail.com with ESMTPSA id d19-20020a170906305300b006fe8ac6bc69sm2174025ejd.140.2022.07.22.09.11.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Jul 2022 09:11:13 -0700 (PDT) From: Dario Binacchi To: u-boot@lists.denx.de Cc: Amarula patchwork , michael@amarulasolutions.com, Dario Binacchi , Patrice Chotard , Simon Glass , Wolfgang Denk Subject: [PATCH v4 06/14] mtd: nand: Export symbol nand_decode_ext_id Date: Fri, 22 Jul 2022 18:10:00 +0200 Message-Id: <20220722161009.2686504-7-dario.binacchi@amarulasolutions.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20220722161009.2686504-1-dario.binacchi@amarulasolutions.com> References: <20220722161009.2686504-1-dario.binacchi@amarulasolutions.com> MIME-Version: 1.0 X-Original-Sender: dario.binacchi@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=JCpHs0nO; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , From: Michael Trimarchi In preparation of moving specific nand support that are not jedec or onfi Signed-off-by: Michael Trimarchi Signed-off-by: Dario Binacchi --- (no changes since v1) drivers/mtd/nand/raw/nand_base.c | 3 ++- include/linux/mtd/rawnand.h | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/mtd/nand/raw/nand_base.c b/drivers/mtd/nand/raw/nand_base.c index 145de22be852..174c760f3416 100644 --- a/drivers/mtd/nand/raw/nand_base.c +++ b/drivers/mtd/nand/raw/nand_base.c @@ -4160,7 +4160,7 @@ static int nand_get_bits_per_cell(u8 cellinfo) * chip. The rest of the parameters must be decoded according to generic or * manufacturer-specific "extended ID" decoding patterns. */ -static void nand_decode_ext_id(struct nand_chip *chip) +void nand_decode_ext_id(struct nand_chip *chip) { struct mtd_info *mtd = &chip->mtd; int extid, id_len; @@ -4286,6 +4286,7 @@ static void nand_decode_ext_id(struct nand_chip *chip) } } +EXPORT_SYMBOL_GPL(nand_decode_ext_id); /* * Manufacturer detection. Only used when the NAND is not ONFI or JEDEC diff --git a/include/linux/mtd/rawnand.h b/include/linux/mtd/rawnand.h index d8141cb4d114..8fb2a43296f5 100644 --- a/include/linux/mtd/rawnand.h +++ b/include/linux/mtd/rawnand.h @@ -1374,4 +1374,7 @@ int nand_read_data_op(struct nand_chip *chip, void *buf, unsigned int len, int nand_write_data_op(struct nand_chip *chip, const void *buf, unsigned int len, bool force_8bit); +/* Default extended ID decoding function */ +void nand_decode_ext_id(struct nand_chip *chip); + #endif /* __LINUX_MTD_RAWNAND_H */