Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp885692imm; Wed, 1 Aug 2018 06:56:37 -0700 (PDT) X-Google-Smtp-Source: AAOMgpd8lpGhWO1LKUCgJ+5xwsLjy6f6Wx5v6j9JJISOwy/CiBjB5pbaGV2h9jTxZk1dXOirpRRt X-Received: by 2002:a62:cac5:: with SMTP id y66-v6mr26863530pfk.187.1533131797401; Wed, 01 Aug 2018 06:56:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533131797; cv=none; d=google.com; s=arc-20160816; b=HTMvcfr7UCiqFRcsoyf9fSl5sE+Od+6F67h84ZPUxrg2J4Y9NDH4CMGajAA5lQqMJ+ Ta7XjaVWlNHYULpmqNxQRa5mLiur17lfM/20CNBxdggXKkdCHxWT86WQ5NY+xW+41ALi cbTCRRnhIucxgwf6atvqwakRWn9d9XsCupYj8VOlb0jolPeXllYIKMmDEUnQaXOJerDH 1wr3lYbec0W9QhIqMlkWwwFyFKTAJfTMzsWcr6TgUhrKPML239PRFphoS3zqLjKqke8a zLcDWyjx3Cnu28AGAOnRDJzsDe8st2ZliYDojxBnj3tR3W7r6y85yg/k6Fhu7FHovbqv Ga4g== 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:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date:arc-authentication-results; bh=wE7dSr1gviBD1h+ziCKKNq6ggDecXxHv8CoYm7BXrwQ=; b=rR5pBcvz/eudz2Wm3iAgtqgU5oJSbfLE45qjSOH9QQQ22qlO2wPumCPiA9T765vtK5 Q2ANsDJWKXSVLHk5zevPx2YuWudKoTnueHy0gk2puONKlycpoUVn8nWYn6ikecGjATk+ YPy7rvRagg/pH/fxUV8YC0EChNDo8RRzDhjNr8CcoRiDqfblItWkK4REXIYeRgDYEvs7 2OkmAsH/jYAonFvlgI+51g58gDBJnJi02Yjt47ngFtksPSMm8QhdRyFdpJxI5gzkjUIX dWESLpqSr5gTFkvgvQh7R0It9Q8quZogXmLig1diCrUMWdT8lDPvfscvjNi84/qZIVvV QePw== 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 7-v6si15387275pll.369.2018.08.01.06.56.22; Wed, 01 Aug 2018 06:56:37 -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 S2389460AbeHAPlY convert rfc822-to-8bit (ORCPT + 99 others); Wed, 1 Aug 2018 11:41:24 -0400 Received: from mail.bootlin.com ([62.4.15.54]:46582 "EHLO mail.bootlin.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389315AbeHAPlY (ORCPT ); Wed, 1 Aug 2018 11:41:24 -0400 Received: by mail.bootlin.com (Postfix, from userid 110) id E387020756; Wed, 1 Aug 2018 15:55:29 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail.bootlin.com X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,SHORTCIRCUIT, URIBL_BLOCKED shortcircuit=ham autolearn=disabled version=3.4.0 Received: from xps13 (AAubervilliers-681-1-89-120.w90-88.abo.wanadoo.fr [90.88.30.120]) by mail.bootlin.com (Postfix) with ESMTPSA id 9D3B220730; Wed, 1 Aug 2018 15:55:29 +0200 (CEST) Date: Wed, 1 Aug 2018 15:55:30 +0200 From: Miquel Raynal To: Dan Carpenter Cc: Jheng-Jhong Wu , Palle Christensen , devel@driverdev.osuosl.org, Boris Brezillon , Greg Kroah-Hartman , linux-kernel@vger.kernel.org, Masahiro Yamada , Arun Nagendran Subject: Re: [PATCH] staging:mt29f_spinand: MT29F2G failing as only 16-bit arguments and variables used for addressing. Message-ID: <20180801155530.6e824927@xps13> In-Reply-To: <20180801120551.ju6zhxhoef6w5zim@mwanda> References: <1533093861-9761-1-git-send-email-goodwater.wu@gmail.com> <20180801120551.ju6zhxhoef6w5zim@mwanda> Organization: Bootlin X-Mailer: Claws Mail 3.15.0-dirty (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Dan, Dan Carpenter wrote on Wed, 1 Aug 2018 15:05:51 +0300: > On Wed, Aug 01, 2018 at 11:24:19AM +0800, Jheng-Jhong Wu wrote: > > For NAND flash chips with more than 1Gbit (e.g. MT29F2G) more than 16 bits > > are necessary to address the correct page. The driver sets the address for > > more than 16 bits, but it uses 16-bit arguments and variables (these are > > page_id, block_id, row) to do address operations. Obviously, these > > arguments and variables cannot deal with more than 16-bit address. > > > > Signed-off-by: Jheng-Jhong Wu > > This seems reasonable... It would be needed to make commit 6efb21d6d0e7 > ("staging:mt29f_spinand: MT29F2G failing as only 16 bits used for > addressing.") work. It also fixes a static checker warning. > > My only concern is that the mtd/nand code seems to use -1 as a magical > page_id. For example: I guess you missed Boris' comment: this driver is very likely to be removed. A SPI-NAND framework has been added. It does not use the raw NAND framework anymore, which was wrong anyway. Thanks, Miquèl