Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp9571984pxu; Mon, 28 Dec 2020 21:54:25 -0800 (PST) X-Google-Smtp-Source: ABdhPJwa7iJKhoBM2fgolLXbX11Po/7NbWmlcdIjGppTRre6p2jhNzAY/S3xixQH7Sg7R8edCTvZ X-Received: by 2002:a17:906:ce23:: with SMTP id sd3mr44407319ejb.69.1609221264860; Mon, 28 Dec 2020 21:54:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1609221264; cv=none; d=google.com; s=arc-20160816; b=jhbgOqR4mPj3SgCUhxnY2om8hQHrZ/X8eJWPU0wjXzfD7yoomkUbkf+Rc6M4JHhREm ydNJYl4xslvNbli8JHU9/SwnVj67gwuyn34EnmvXsfIcdKim40YOm5vRu5tw9eiuj9U+ PizuF1kp5YlSmNsKx9J5KamU4M5MOg6UnydOCtaptTCoGZ57gjTsfOhAPd9f7nQlj/kk MB+D/M4CEKCyHFhLNN/uOLESwbpnzLjxHpl8I3gH9cYIxnWODfFNiYptWGad4En+6aGp CUwbaAmdDOXt48tLRKd9l3ZB7ZK9u0d0NO9cVkEIBO+axYdX0elLys5NsD9SHjQ9fKJ6 F7gg== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=Ws6av0vO/n+wtrNUa74n3tClewh7290nN7ExGkq43UI=; b=ytqe7exYwr+QGsAGMBZF5wdqlceV3KhL+OQTOB5tNK79Tuq8c0OCiCn8G2e2FWr+7D NAWRTGxTP2vUWOr6Q7WuZflMkz5mwduxSw/HQgQsrBhkrl6LQQi+edeNVz2kr0OXG7O/ iK5E/ocuIu2UxEkqZV4i5CnOnh/LEJa1rr8LVQu9fvp11rw65eBRpNhWtgZOmgGsEVch W14DNSunfohSAL5WsPoKm7AW+nI3+x/Cu2GQfhlgsf833LyW/Z03uEsDBiIXrhSPDD2u lzCRvjyUHiimVEuuEq2tjib7/xlrIUjGXRNNZlj5iFAb76EyiNNxhPj12yNHO97FIUAL 9+pg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@0x0f.com header.s=google header.b=YY41nMVe; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id hd41si21293308ejc.168.2020.12.28.21.53.51; Mon, 28 Dec 2020 21:54:24 -0800 (PST) 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=@0x0f.com header.s=google header.b=YY41nMVe; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726189AbgL2FwH (ORCPT + 99 others); Tue, 29 Dec 2020 00:52:07 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35370 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726021AbgL2FwG (ORCPT ); Tue, 29 Dec 2020 00:52:06 -0500 Received: from mail-pl1-x62b.google.com (mail-pl1-x62b.google.com [IPv6:2607:f8b0:4864:20::62b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 64F89C0613D6 for ; Mon, 28 Dec 2020 21:51:26 -0800 (PST) Received: by mail-pl1-x62b.google.com with SMTP id j1so6733482pld.3 for ; Mon, 28 Dec 2020 21:51:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=0x0f.com; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Ws6av0vO/n+wtrNUa74n3tClewh7290nN7ExGkq43UI=; b=YY41nMVeSFbTCpTx+MYE+RLVcV7VcqULCF0sXiC5fu3HDw4t/KZWH7ZUF1rr8VHw8u 4i0NUe0+vqLBoKxuvW761+OekAaEKXolvcFlzmK76eVnaWnhEQjf+VhNQLvvhO3NrTq3 qCIgzBCCmuUYOTIku0kq01wRcRZd7K+1ybJtI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Ws6av0vO/n+wtrNUa74n3tClewh7290nN7ExGkq43UI=; b=Yz86ZSZKMkvfoitM4J13n5UPh5YnsPqnsWyrb719Anpjec5IULPtd6k7CtQyXQQ8kS F09KXiPkebgKQHPdZVlpUYIapyHvkdqkwbbWazGYJsEfofRdsjGRjgXHZlYp8meps0mn BTJ5Ihr8rEBwxCB6UO8rpxj/M7Z5BOLSGMqnRkylMeIs7BGuGqdDWYQwKr0VsHAw3RqS MBSYhnLZt7duGQLoOPHZlsL/CZlkDBKuWmrnyMbY4PStylaojZ0HRYHjGCxhhlBE/fGk FffYNsJ6OVRAWYd6t6/WzEcmTTRAhnfkDdPopI9us6H1QxDyGKKbkArtwIB/LvunIda/ kiyw== X-Gm-Message-State: AOAM533UC1970UmYckDk+f2MKVYaSUH5TWG9V8eH0EB47mlVqaCj+iJR waVpeOUFnnUYTxxFXyViPGKjQA== X-Received: by 2002:a17:90b:90f:: with SMTP id bo15mr2474480pjb.148.1609221085820; Mon, 28 Dec 2020 21:51:25 -0800 (PST) Received: from shiro.work (p1268123-ipngn200803sizuokaden.shizuoka.ocn.ne.jp. [118.13.124.123]) by smtp.googlemail.com with ESMTPSA id x23sm45041113pge.47.2020.12.28.21.51.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 28 Dec 2020 21:51:25 -0800 (PST) From: Daniel Palmer To: linux-mtd@lists.infradead.org Cc: linux-kernel@vger.kernel.org, miquel.raynal@bootlin.com, richard@nod.at, vigneshr@ti.com, Daniel Palmer Subject: [PATCH 0/1] Add basic support for Foresee SPI NAND Date: Tue, 29 Dec 2020 14:50:58 +0900 Message-Id: <20201229055059.2255021-1-daniel@0x0f.com> X-Mailer: git-send-email 2.30.0.rc2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This is my very crude attempt at adding support for Longsys' Foresee branded SPI NAND parts that are showing up on some boards. I fully admit I have no idea what I'm doing here and I basically took one of the existing files, ripped out what I didn't understand and tried to fill in the numbers from the datasheet without really knowing what they mean. This worked well enough for me to get something that looks like a correct dump of the SPI NAND from a board I'm working with. I need the vendor firmware on the board for reverse engineering so I haven't actually tried to write anything yet. The datasheet for this chip is linked. If someone that actually knows what they're doing could take a look and point out my mistakes that would be great. Link: https://datasheet.lcsc.com/szlcsc/2008121142_FORESEE-FS35ND01G-S1Y2QWFI000_C719495.pdf Daniel Palmer (1): mtd: spinand: add support for Foresee FS35ND01G drivers/mtd/nand/spi/Makefile | 2 +- drivers/mtd/nand/spi/core.c | 1 + drivers/mtd/nand/spi/longsys.c | 45 ++++++++++++++++++++++++++++++++++ include/linux/mtd/spinand.h | 1 + 4 files changed, 48 insertions(+), 1 deletion(-) create mode 100644 drivers/mtd/nand/spi/longsys.c -- 2.30.0.rc2