Received: by 2002:a4a:301c:0:0:0:0:0 with SMTP id q28-v6csp614973oof; Tue, 25 Sep 2018 02:16:20 -0700 (PDT) X-Google-Smtp-Source: ACcGV62W/a6qcclAH/CCTC5yvMEjD6ttFd88sWV9I6gquQCbzTWjXf52kdsTtOOgk2pFuPhgCGjj X-Received: by 2002:a17:902:b182:: with SMTP id s2-v6mr178460plr.84.1537866980936; Tue, 25 Sep 2018 02:16:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537866980; cv=none; d=google.com; s=arc-20160816; b=CtI8Sk7I0zEI0BUuXqy6higKxPKNTNl5H91JJZlefv+cZj3e8YhYKT53RRRMwXeIRK gy11HPxMw/ZVzA1DqUcxWcc5c9ilNmu8aMdpvLMxOFuCQhRQOmbA4dLfdKEEgpQF746d 3JoWCNWtj2V+5qaqOiR4Mr4WG6o8Egp4LwSXv0GN/dneUdIuQJUY/XVSYH6R7kz/wtOy DGOyYPQ5GJfwYt11oDr0a9WhCh8m9Ni4hZZbXUsVBFZ9p6V8AOpj2PFj1Q+lcBD0Rnxq +xB6v+Sbf3WDM4vGbad/z5K3hSoFjxzHSAKtJ1c5Vpjukh1QVuErQK0xwcVPqaFh5eZw 6x1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=enDRCrhYCTuFrVtOfN6hy3AxXYNYyCOdXNUUWNp45dU=; b=jPyzQa5Nt2WDKe+PriX7454rHCWb83lIVLjaIqdNSXD6DnLuNOrAQWPHLZ7af85Ax/ HJWPsMuz54OzmolmYOlesQOJotce8oX6YIY/Vk6JbXWMYW7pxGn7w8ajkLBDdSru9le6 wtXXoOSTIh5kackrH1r4QiH57aBsPPnuJhHkcLIf+hWmqc67shz/gD+sPZRAsI8UnxHC Bm6Ic/4W+myQF79pa0eXk4mnWvlz5qpYjvns243x8PNIwsm5urXqzTD/TqspAoKW7P+2 jBMFrfjNH9KkLtAYjCGI8taXAzVzA2ceMCC7QcwmYJdPl92XaH9QbjA5+0Z9Fo+xXBVN 6WSw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e6-v6si1890184pgh.50.2018.09.25.02.16.05; Tue, 25 Sep 2018 02:16:20 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728861AbeIYPWP (ORCPT + 99 others); Tue, 25 Sep 2018 11:22:15 -0400 Received: from mx08-00178001.pphosted.com ([91.207.212.93]:35420 "EHLO mx07-00178001.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727617AbeIYPWO (ORCPT ); Tue, 25 Sep 2018 11:22:14 -0400 Received: from pps.filterd (m0046661.ppops.net [127.0.0.1]) by mx08-.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id w8P99416011181; Tue, 25 Sep 2018 11:14:32 +0200 Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx08-00178001.pphosted.com with ESMTP id 2mncme7v9w-1 (version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT); Tue, 25 Sep 2018 11:14:32 +0200 Received: from zeta.dmz-eu.st.com (zeta.dmz-eu.st.com [164.129.230.9]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 357CA5D; Tue, 25 Sep 2018 09:14:32 +0000 (GMT) Received: from Webmail-eu.st.com (sfhdag6node2.st.com [10.75.127.17]) by zeta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 04849290E; Tue, 25 Sep 2018 09:14:32 +0000 (GMT) Received: from [10.201.23.29] (10.75.127.45) by SFHDAG6NODE2.st.com (10.75.127.17) with Microsoft SMTP Server (TLS) id 15.0.1347.2; Tue, 25 Sep 2018 11:14:31 +0200 Subject: Re: [PATCH 2/3] mtd: rawnand: stm32_fmc2: add STM32 FMC2 NAND flash controller driver To: Boris Brezillon CC: , , , , , , , , , , References: <1537199260-7280-1-git-send-email-christophe.kerello@st.com> <1537199260-7280-3-git-send-email-christophe.kerello@st.com> <20180924192356.5f2e56fd@bbrezillon> From: Christophe Kerello Message-ID: <3b37bac8-2616-eb7e-b559-2d73b96bfe28@st.com> Date: Tue, 25 Sep 2018 11:14:30 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20180924192356.5f2e56fd@bbrezillon> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.75.127.45] X-ClientProxiedBy: SFHDAG6NODE2.st.com (10.75.127.17) To SFHDAG6NODE2.st.com (10.75.127.17) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-09-25_06:,, signatures=0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Boris, On 09/24/2018 07:23 PM, Boris Brezillon wrote: > Hi Christophe, > > On Mon, 17 Sep 2018 17:47:39 +0200 > wrote: > >> +struct stm32_fmc2 { >> + struct nand_chip chip; >> + struct device *dev; >> + void __iomem *io_base; >> + void __iomem *data_base[FMC2_MAX_CE]; >> + void __iomem *cmd_base[FMC2_MAX_CE]; >> + void __iomem *addr_base[FMC2_MAX_CE]; >> + phys_addr_t io_phys_addr; >> + phys_addr_t data_phys_addr[FMC2_MAX_CE]; >> + struct clk *clk; >> + >> + struct dma_chan *dma_tx_ch; >> + struct dma_chan *dma_rx_ch; >> + struct dma_chan *dma_ecc_ch; >> + struct sg_table dma_data_sg; >> + struct sg_table dma_ecc_sg; >> + u8 *ecc_buf; >> + int dma_ecc_len; >> + >> + struct completion complete; >> + struct completion dma_data_complete; >> + struct completion dma_ecc_complete; >> + >> + struct stm32_fmc2_timings timings; >> + u8 cs_assigned; >> + int cs_sel; >> + int ncs; >> + int cs_used[FMC2_MAX_CE]; >> +}; > > Can we have a clear separation between the NAND controller and NAND > chip structures. I know you only support a single chip per-controller > right now, but I prefer to have things clearly separated from the > beginning. Yes, I can create 2 structures: one for the controller (stm32_fmc2) and one for the NAND chip (stm32_fmc2_nand_chip). Regards, Christophe Kerello. > > Regards, > > Boris >