Re: [PATCH v4 01/58] mtd: nand: denali: add missing nand_release() call in denali_remove()

2015-12-11 Thread Brian Norris
Hi Boris, On Fri, Dec 11, 2015 at 11:03:05PM +0100, Boris Brezillon wrote: > On Thu, 10 Dec 2015 16:40:08 -0800 > Brian Norris <computersforpe...@gmail.com> wrote: > > On Thu, Dec 10, 2015 at 08:59:45AM +0100, Boris Brezillon wrote: > > > Unregister the NAND device f

Re: [PATCH v4 01/58] mtd: nand: denali: add missing nand_release() call in denali_remove()

2015-12-10 Thread Brian Norris
On Thu, Dec 10, 2015 at 08:59:45AM +0100, Boris Brezillon wrote: > Unregister the NAND device from the NAND subsystem when removing a denali > NAND controller, otherwise the MTD attached to the NAND device is still > exposed by the MTD layer, and accesses to this device will likely crash > the

Re: [PATCH] jffs2: bug fix of creating node when gc or find space

2015-12-10 Thread Brian Norris
+ David (JFFS2 "maintainer") David, Looks like there was a similar patch / bug report from Huawei about a year ago, though this one has some modifications: http://patchwork.ozlabs.org/patch/416301/ It's among the outstanding jffs2 patches from the last 2 years, after I filtered out the noise:

Re: [PATCH] mtd: nand: fix ONFI parameter page layout

2015-12-01 Thread Brian Norris
On Tue, Dec 01, 2015 at 10:33:18AM +0100, Boris Brezillon wrote: > On Mon, 30 Nov 2015 12:17:29 -0800 > Brian Norris <computersforpe...@gmail.com> wrote: > > On Mon, Nov 23, 2015 at 11:23:07AM +0100, Boris Brezillon wrote: > > > src_ssync_features field is only 1 byte

Re: [PATCH] mtd: spi-nor: include mtd.h header for struct mtd_info definition

2015-11-30 Thread Brian Norris
On Sat, Nov 28, 2015 at 03:05:26PM +0100, Rafał Miłecki wrote: > On 27 November 2015 at 23:33, Brian Norris <computersforpe...@gmail.com> > wrote: > > On Fri, Nov 27, 2015 at 10:25:55AM +0100, Rafał Miłecki wrote: > >> On 26 November 2015 at 09:05, Rafał Miłec

Re: [PATCH] mtd: nand: fix ONFI parameter page layout

2015-11-30 Thread Brian Norris
On Mon, Nov 23, 2015 at 11:23:07AM +0100, Boris Brezillon wrote: > src_ssync_features field is only 1 byte large, and the 4th reserved area > is actually 8 bytes large. > > Signed-off-by: Boris Brezillon > Fixes d1e1f4e42b5 ("mtd: nand: add support for reading

Re: [PATCH] mtd: spi-nor: include mtd.h header for struct mtd_info definition

2015-11-27 Thread Brian Norris
On Fri, Nov 27, 2015 at 10:25:55AM +0100, Rafał Miłecki wrote: > On 26 November 2015 at 09:05, Rafał Miłecki wrote: > > So far struct spi_nor was using just a pointer to struct mtd_info so it > > wasn't needed to have it fully defined there. After recent change we > > embed

Re: [PATCH] mtd: blkdevs: fix potential deadlock + lockdep warnings

2015-10-30 Thread Brian Norris
On Mon, Oct 26, 2015 at 07:38:49PM -0700, Brian Norris wrote: > Commit 073db4a51ee4 ("mtd: fix: avoid race condition when accessing > mtd->usecount") fixed a race condition but due to poor ordering of the > mutex acquisition, introduced a potential deadlock. [...] > &g

[PATCH] mtd: blkdevs: fix potential deadlock + lockdep warnings

2015-10-26 Thread Brian Norris
ock(>lock); [ 53.698306]lock(mtd_table_mutex); [ 53.704658] lock(>lock); [ 53.707946] [ 53.707946] *** DEADLOCK *** Fixes: 073db4a51ee4 ("mtd: fix: avoid race condition when accessing mtd->usecount") Reported-by: Felipe Balb

Re: [PATCH] mtd: mtdpart: fix add_mtd_partitions error path

2015-09-30 Thread Brian Norris
On Thu, Jul 30, 2015 at 12:18:03PM +0200, Boris Brezillon wrote: > If we fail to allocate a partition structure in the middle of the partition > creation process, the already allocated partitions are never removed, which > means they are still present in the partition list and their resources are

Re: [PATCH] mtd: nand: sunxi: fix sunxi_nand_chips_cleanup()

2015-09-21 Thread Brian Norris
On Sun, Sep 13, 2015 at 06:14:43PM +0200, Boris Brezillon wrote: > The sunxi_nand_chips_cleanup() function is missing a call to list_del() > which generates a double free error. And if you could manage to get past that...an infinite loop, no? > Reported-by: Priit Laes >

Re: [PATCH v4] mtd: nand: sunxi: fix OOB handling in ->write_xxx() functions

2015-09-21 Thread Brian Norris
On Mon, Sep 14, 2015 at 10:02:04AM -0700, Brian Norris wrote: > On Mon, Sep 14, 2015 at 10:41:03AM +0200, Boris Brezillon wrote: > > The USER_DATA register cannot be accessed using byte accessors on A13 > > SoCs, thus triggering a bug when using memcpy_toio on this register. > &

Re: [PATCH v4] mtd: nand: sunxi: fix OOB handling in ->write_xxx() functions

2015-09-14 Thread Brian Norris
On Mon, Sep 14, 2015 at 10:41:03AM +0200, Boris Brezillon wrote: > The USER_DATA register cannot be accessed using byte accessors on A13 > SoCs, thus triggering a bug when using memcpy_toio on this register. > Declare an helper macros to convert an OOB buffer into a suitable > USER_DATA value and

Re: [PATCH v3] mtd: nand: sunxi: fix OOB handling in ->write_xxx() functions

2015-09-11 Thread Brian Norris
On Thu, Sep 03, 2015 at 09:06:48AM +0200, Boris Brezillon wrote: > The USER_DATA register cannot be accessed using byte accessors on A13 > SoCs, thus triggering a bug when using memcpy_toio on this register. > Declare two helper macros to convert an OOB buffer into a suitable > USER_DATA value and

Re: Requesting inclusion of mtd/nand patches in linux-3.14.y

2015-08-25 Thread Brian Norris
On Tue, Jul 28, 2015 at 10:34:30AM -0700, Greg KH wrote: On Tue, Jul 28, 2015 at 03:40:46PM +0200, Mason wrote: This is my second time requesting inclusion of a patch, please point out any breach of protocol :-) I never saw your first request, where did you send that? FWIW, I was just

Re: Patch mtd: nand: don't use read_buf for 8-bit ONFI transfers has been added to the 3.14-stable tree

2015-07-28 Thread Brian Norris
@vger.kernel.org know about it. IIRC, that patch goes best with this one too: commit 3dad2344e92c6e1aeae42df1c4824f307c51bcc7 Author: Brian Norris computersforpe...@gmail.com Date: Wed Jan 29 14:08:12 2014 -0800 mtd: nand: force NAND_CMD_READID onto 8-bit bus Someone who

Re: [PATCH] mtd: fix: avoid race condition when accessing mtd-usecount

2015-05-07 Thread Brian Norris
On Thu, May 07, 2015 at 05:17:45PM -0700, Brian Norris wrote: On Thu, May 07, 2015 at 05:10:12PM -0700, Brian Norris wrote: On Tue, Apr 21, 2015 at 12:20:22PM +0200, Giuseppe Cantavenera wrote: @@ -484,7 +486,7 @@ int del_mtd_blktrans_dev(struct mtd_blktrans_dev *old) if (old-open

[PATCH 1/2] of: handle both '/' and ':' in path strings

2015-03-17 Thread Brian Norris
that. Fixes: 106937e8ccdc (of: fix handling of '/' in options for of_find_node_by_path()) Signed-off-by: Brian Norris computersforpe...@gmail.com Cc: stable@vger.kernel.org --- This is for -stable only because the regression is marked for stable. Not sure the first one deserves to go to -stable, actually

[PATCH 2/2] of: unittest: Add option string test case with longer path

2015-03-17 Thread Brian Norris
. Signed-off-by: Brian Norris computersforpe...@gmail.com --- drivers/of/unittest.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/of/unittest.c b/drivers/of/unittest.c index aba8946cac46..52c45c7df07f 100644 --- a/drivers/of/unittest.c +++ b/drivers/of/unittest.c @@ -97,6 +97,11

Re: [PATCH v4 1/2] mtd: nand: pxa3xx: Fix PIO FIFO draining

2015-02-28 Thread Brian Norris
On Wed, Feb 18, 2015 at 11:32:07AM +0100, Maxime Ripard wrote: The NDDB register holds the data that are needed by the read and write commands. However, during a read PIO access, the datasheet specifies that after each 32 bytes read in that register, when BCH is enabled, we have to make sure

Re: [PATCH v3 1/2] mtd: nand: pxa3xx: Fix PIO FIFO draining

2015-02-23 Thread Brian Norris
On Tue, Feb 17, 2015 at 02:16:43PM -0300, Ezequiel Garcia wrote: On 02/17/2015 02:07 PM, Robert Jarzmik wrote: It will be Brian choice eventually, but if you say that you will submit that approach for next cycle, and yours for stable, and that for next you'll convert mdelay() to

Re: [PATCH v2 1/2] mtd: nand: pxa3xx: Fix PIO FIFO draining

2015-02-06 Thread Brian Norris
On Fri, Feb 06, 2015 at 09:13:07AM +0100, Boris Brezillon wrote: Hi Brian, On Thu, 5 Feb 2015 17:08:35 -0800 Brian Norris computersforpe...@gmail.com wrote: On Wed, Feb 04, 2015 at 11:10:28AM +0100, Boris Brezillon wrote: On Mon, 26 Jan 2015 15:56:03 +0100 Maxime Ripard maxime.rip

Re: [PATCH v2 1/2] mtd: nand: pxa3xx: Fix PIO FIFO draining

2015-02-06 Thread Brian Norris
On Fri, Feb 06, 2015 at 11:17:15AM -0300, Ezequiel Garcia wrote: On 02/06/2015 05:13 AM, Boris Brezillon wrote: On Thu, 5 Feb 2015 17:08:35 -0800 Brian Norris computersforpe...@gmail.com wrote: On Wed, Feb 04, 2015 at 11:10:28AM +0100, Boris Brezillon wrote: I know the datasheet says

Re: [PATCH v2 1/2] mtd: nand: pxa3xx: Fix PIO FIFO draining

2015-02-05 Thread Brian Norris
+ Rob This patch has conflicts with an ARM64-preparation from Rob. I'd like to get this patch in first, as it's a bugfix. But I'd like to settle Boris's comments first. (Regarding the request to get this into 3.19: not likely. Judging by the age of the bug, it's not massively critical, and we

Re: FAILED: patch [PATCH] mtd: m25p80,spi-nor: Fix module aliases for m25p80 failed to apply to 3.17-stable tree

2014-11-11 Thread Brian Norris
+ linux-mtd, Rafal On Tue, Nov 11, 2014 at 05:08:25PM +, Ben Hutchings wrote: On Tue, 2014-11-11 at 14:17 +0900, Greg KH wrote: On Mon, Nov 10, 2014 at 03:53:49PM -0800, Brian Norris wrote: On Mon, Nov 10, 2014 at 01:34:24PM +0900, Greg Kroah-Hartman wrote: The patch below does

Re: FAILED: patch [PATCH] mtd: m25p80,spi-nor: Fix module aliases for m25p80 failed to apply to 3.17-stable tree

2014-11-11 Thread Brian Norris
On Wed, Nov 12, 2014 at 04:26:47AM +0900, Greg Kroah-Hartman wrote: On Tue, Nov 11, 2014 at 05:08:25PM +, Ben Hutchings wrote: On Tue, 2014-11-11 at 14:17 +0900, Greg KH wrote: On Mon, Nov 10, 2014 at 03:53:49PM -0800, Brian Norris wrote: On Mon, Nov 10, 2014 at 01:34:24PM +0900

Re: FAILED: patch [PATCH] mtd: m25p80,spi-nor: Fix module aliases for m25p80 failed to apply to 3.17-stable tree

2014-11-10 Thread Brian Norris
On Mon, Nov 10, 2014 at 01:34:24PM +0900, Greg Kroah-Hartman wrote: The patch below does not apply to the 3.17-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to

Re: [PATCH 3.10.y+] PM / sleep: Use valid_state() for platform-dependent sleep states only

2014-09-05 Thread Brian Norris
On Fri, Sep 05, 2014 at 08:29:09AM +0200, Francis Moreau wrote: On 09/04/2014 11:21 PM, Brian Norris wrote: [...] Signed-off-by: Rafael J. Wysocki rafael.j.wyso...@intel.com Cc: stable@vger.kernel.org # 3.10+: 27ddcc6596e5: PM / sleep: Add state field to pm_states[] entries Cc: stable

Re: [PATCH 3.10.y+] PM / sleep: Use valid_state() for platform-dependent sleep states only

2014-09-05 Thread Brian Norris
On Fri, Sep 05, 2014 at 02:47:58PM -0700, Greg Kroah-Hartman wrote: On Fri, Sep 05, 2014 at 12:45:12AM -0700, Brian Norris wrote: On Fri, Sep 05, 2014 at 08:29:09AM +0200, Francis Moreau wrote: On 09/04/2014 11:21 PM, Brian Norris wrote: [...] Signed-off-by: Rafael J. Wysocki

Re: [PATCH 3.10.y+] PM / sleep: Use valid_state() for platform-dependent sleep states only

2014-09-05 Thread Brian Norris
On Fri, Sep 05, 2014 at 03:36:26PM -0700, Greg Kroah-Hartman wrote: If they apply cleanly, then just list the git commit ids, and I can take care of the rest. OK. Is this a policy that should be documented? AIUI, we have a few options: 1. Include 'Cc: stable@vger.kernel.org' in

Re: [stable -3.14] PM backports for pm_test / CONFIG_PM_DEBUG

2014-09-04 Thread Brian Norris
On Thu, Sep 04, 2014 at 09:40:41PM +0200, Rafael J. Wysocki wrote: On Wednesday, September 03, 2014 06:02:19 PM Brian Norris wrote: I think I've narrowed it down to this commit that should be backported to -stable (for 3.9+?): 43e8317b0bba PM / sleep: Use valid_state() for platform

[PATCH 3.10.y+] PM / sleep: Use valid_state() for platform-dependent sleep states only

2014-09-04 Thread Brian Norris
From: Rafael J. Wysocki rafael.j.wyso...@intel.com [Upstream commit 43e8317b0bba1d6eb85f38a4a233d82d7c20d732] Use the observation that, for platform-dependent sleep states (PM_SUSPEND_STANDBY, PM_SUSPEND_MEM), a given state is either always supported or always unsupported and store that

[stable -3.14] PM backports for pm_test / CONFIG_PM_DEBUG

2014-09-03 Thread Brian Norris
Hi, If I enable CONFIG_PM_DEBUG on a 3.14.y kernel, I can see the following results: # cat /sys/power/state freeze standby mem # cat /sys/power/pm_test [none] core processors platform devices freezer # echo core /sys/power/pm_test # cat /sys/power/state [

Re: [PATCH] mtd: nand: omap: fix omap_calculate_ecc_bch() for-loop error

2014-07-13 Thread Brian Norris
# 3.15.x+ I see that the original patch was tagged for 3.13+, but the code it fixes was only in 3.15. Maybe I just tagged it wrong? At any rate, the patch looks good. Thanks for the backport. Acked-by: Brian Norris computersforpe...@gmail.com Signed-off-by: Ted Juan ted.j...@gmail.com Acked

Re: FAILED: patch [PATCH] mtd: nand: omap: fix omap_calculate_ecc_bch() for-loop error failed to apply to 3.15-stable tree

2014-07-08 Thread Brian Norris
: 7bcd1dca1d587ad29f9825ba4414620440e8c8da mtd: nand: omap: ecc.calculate: merge omap3_calculate_ecc_bch8 in omap_calculate_ecc_bch Cc: stable@vger.kernel.org # 3.13.x+ Signed-off-by: Ted Juan ted.j...@gmail.com Acked-by: Pekon Gupta pe...@ti.com Signed-off-by: Brian Norris computersforpe...@gmail.com diff

Re: [PATCH] mtd: pxa3xx_nand: make the driver work on big-endian systems

2014-05-28 Thread Brian Norris
On Thu, May 22, 2014 at 02:56:52PM +0200, Thomas Petazzoni wrote: The pxa3xx_nand driver currently uses __raw_writel() and __raw_readl() to access I/O registers. However, those functions do not do any endianness swapping, which means that they won't work when the CPU runs in big-endian but the

[PATCH] stable_kernel_rules: spelling/word usage

2014-04-02 Thread Brian Norris
than should be then Signed-off-by: Brian Norris computersforpe...@gmail.com --- Documentation/stable_kernel_rules.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/stable_kernel_rules.txt b/Documentation/stable_kernel_rules.txt index b0714d8f678a

Re: [patch 1/4] jffs2: unlock f-sem on error in jffs2_new_inode()

2014-03-05 Thread Brian Norris
On Thu, Feb 27, 2014 at 04:33:20PM +0800, Wang Nan wrote: On 2014/2/27 14:55, Brian Norris wrote: On Thu, Feb 27, 2014 at 08:53:37AM +0800, Wang Nan wrote: On 2014/2/26 10:03, Brian Norris wrote: On Wed, Feb 12, 2014 at 12:44:54PM -0800, Andrew Morton wrote: From: Wang Guoli andy.wanggu

Re: [patch 1/4] jffs2: unlock f-sem on error in jffs2_new_inode()

2014-02-26 Thread Brian Norris
+ linux-mtd Hi Wang, On Thu, Feb 27, 2014 at 08:53:37AM +0800, Wang Nan wrote: On 2014/2/26 10:03, Brian Norris wrote: On Wed, Feb 12, 2014 at 12:44:54PM -0800, Andrew Morton wrote: From: Wang Guoli andy.wanggu...@huawei.com Subject: jffs2: unlock f-sem on error in jffs2_new_inode

Re: [patch 4/4] jffs2: remove wait queue after schedule()

2014-02-25 Thread Brian Norris
list, later wake_up() may end up accessing invalid memory. This was spotted by eyes. Signed-off-by: Li Zefan lize...@huawei.com Cc: David Woodhouse dw...@infradead.org Cc: Brian Norris computersforpe...@gmail.com Cc: Artem Bityutskiy artem.bityuts...@linux.intel.com Cc: stable

Re: [patch 1/4] jffs2: unlock f-sem on error in jffs2_new_inode()

2014-02-25 Thread Brian Norris
andy.wanggu...@huawei.com Signed-off-by: Wang Nan wangn...@huawei.com Cc: Artem Bityutskiy artem.bityuts...@linux.intel.com Cc: David Woodhouse dw...@infradead.org Cc: Wang Guoli andy.wanggu...@huawei.com Cc: Brian Norris computersforpe...@gmail.com Cc: stable@vger.kernel.org # 2.6.34+ Signed

Re: [patch 3/4] jffs2: avoid soft-lockup in jffs2_reserve_space_gc()

2014-02-25 Thread Brian Norris
...@infradead.org Cc: Brian Norris computersforpe...@gmail.com Cc: Artem Bityutskiy artem.bityuts...@linux.intel.com Cc: stable@vger.kernel.org Signed-off-by: Andrew Morton a...@linux-foundation.org --- fs/jffs2/nodemgmt.c | 13 + 1 file changed, 9 insertions(+), 4 deletions(-) diff

Re: [patch 1/4] jffs2: unlock f-sem on error in jffs2_new_inode()

2014-02-25 Thread Brian Norris
+ linux-mtd (I realized MTD wasn't CC'd on these re-sends) On Tue, Feb 25, 2014 at 06:03:31PM -0800, Brian Norris wrote: Hi Andrew, I've run all 4 of these patches (for the second one, I'm using my latest version; I'll resend it formally) through a little bit of testing here. Hi Wang

Re: [U-Boot] [PATCH v3 1/3] mtd: nand: omap: fix ecclayout to be in sync with u-boot NAND driver

2014-02-23 Thread Brian Norris
On Mon, Feb 17, 2014 at 10:11:52AM +0100, Albert ARIBAUD wrote: On Mon, 17 Feb 2014 13:11:23 +0530, Pekon Gupta pe...@ti.com wrote: Fixes: commit a919e51161b58ed7e6e663daba99ab7d558808f3 mtd: nand: omap2: clean-up BCHx_HW and BCHx_SW ECC configurations in device_probe Fixes

Re: [patch 2/4] jffs2: fix unbalanced locking

2014-02-13 Thread Brian Norris
Hi Li, On Thu, Feb 13, 2014 at 04:27:16PM +0800, Li Zefan wrote: On 2014/2/13 14:48, Brian Norris wrote: On Wed, Feb 12, 2014 at 12:44:55PM -0800, Andrew Morton wrote: From: Li Zefan lize...@huawei.com Subject: jffs2: fix unbalanced locking This was found by our internal debugging

Re: [patch 2/4] jffs2: fix unbalanced locking

2014-02-12 Thread Brian Norris
lize...@huawei.com Cc: David Woodhouse dw...@infradead.org Cc: Brian Norris computersforpe...@gmail.com Cc: Artem Bityutskiy artem.bityuts...@linux.intel.com Cc: stable@vger.kernel.org Signed-off-by: Andrew Morton a...@linux-foundation.org --- fs/jffs2/readinode.c |3 +++ 1 file

Re: [PATCH] Partially revert mtd: nand: pxa3xx: Introduce 'marvell,armada370-nand' compatible string

2013-12-12 Thread Brian Norris
On Mon, Dec 09, 2013 at 06:36:26PM -0300, Ezequiel Garcia wrote: This reverts c0f3b8643a6fa2461d70760ec49d21d2b031d611. Modified to say partially reverts. The armada370-nand compatible support is not complete, and it was mistake to add it. Revert it and pospone the support until the

Re: [PATCH v2] mxc_nand: remove duplicated ecc_stats counting

2013-12-04 Thread Brian Norris
On Fri, Nov 29, 2013 at 02:14:29PM +0100, Michael Grzeschik wrote: The ecc_stats.corrected count variable will already be incremented in the above framework-layer just after this callback. Cc: stable@vger.kernel.org Added a 2.6.36+ note, just for reference. Signed-off-by: Michael Grzeschik

Re: [PATCH v3] mtd: gpmi: fix the NULL pointer

2013-11-12 Thread Brian Norris
On Tue, Nov 12, 2013 at 12:23:08PM +0800, Huang Shijie wrote: The imx23 board will check the fingerprint, so it will call the mx23_check_transcription_stamp. This function will use @chip-buffers-databuf as its buffer which is allocated in the nand_scan_tail(). Unfortunately, the

Re: [PATCH] mtd: gpmi: Fix NULL pointer dereference

2013-11-11 Thread Brian Norris
Hi Fabio, Huang, On Mon, Nov 11, 2013 at 03:08:47PM -0200, Fabio Estevam wrote: From: Fabio Estevam fabio.este...@freescale.com Currently mx23_check_transcription_stamp() uses chip-buffers-databuf as its buffer, which is allocated by nand_scan_tail(). Since commit 720e7ce5 (mtd: gpmi:

Re: [PATCH v2] mtd: gpmi: Fix NULL pointer dereference

2013-11-11 Thread Brian Norris
this into account. Cc: stable@vger.kernel.org # 3.12 Signed-off-by: Fabio Estevam fabio.este...@freescale.com --- Changes since v1: - Drop sizeof(*buffer) from size calculatio in kzalloc (Brian Norris) - Propagate the error if mx23_check_transcription_stamp returns a negative error code (Brian Norris

Re: [PATCH fix] mtd: gpmi: wake up the process at the end of the DMA callback

2013-11-11 Thread Brian Norris
Hi Huang, On Mon, Nov 11, 2013 at 12:13:45PM +0800, Huang Shijie wrote: [1] The gpmi uses the nand_command_lp to issue the commands to NAND chips. The gpmi issues a DMA operation with gpmi_cmd_ctrl when it handles a NAND_CMD_NONE control command. So when we read a page(NAND_CMD_READ0)

Re: [PATCH v2] mtd: gpmi: Fix NULL pointer dereference

2013-11-11 Thread Brian Norris
the logic in mx23_boot_init() to take this into account. Cc: stable@vger.kernel.org # 3.12 Signed-off-by: Fabio Estevam fabio.este...@freescale.com --- Changes since v1: - Drop sizeof(*buffer) from size calculatio in kzalloc (Brian Norris) - Propagate the error if mx23_check_transcription_stamp

Re: [PATCH v2] mtd: gpmi: Fix NULL pointer dereference

2013-11-11 Thread Brian Norris
On Mon, Nov 11, 2013 at 6:47 PM, Brian Norris computersforpe...@gmail.com wrote: On Mon, Nov 11, 2013 at 6:31 PM, Huang Shijie b32...@freescale.com wrote: 于 2013年11月12日 03:13, Fabio Estevam 写道: In actually, this patch only fixes partial of the bug. When we login the rootfs, and erase all

Re: [PATCH] mtd: gpmi: Fix NULL pointer dereference

2013-11-11 Thread Brian Norris
On Mon, Nov 11, 2013 at 6:47 PM, Huang Shijie b32...@freescale.com wrote: 于 2013年11月12日 02:23, Brian Norris 写道: (2) The second switched the whole NAND buffer over to a kzalloc'd buffer, with NAND_OWN_BUFFERS. I'm not a huge fan of NAND_OWN_BUFFERS, and I think drivers should only

Re: [PATCH V2] mtd: gpmi: fix the NULL pointer

2013-11-11 Thread Brian Norris
Hi Huang, On Mon, Nov 11, 2013 at 06:40:19PM +0800, Huang Shijie wrote: The imx23 board will check the fingerprint, so it will call the mx23_check_transcription_stamp. This function will use @chip-buffers-databuf as its buffer which is allocated in the nand_scan_tail(). Unfortunately, the

Re: [PATCH] mtd: gpmi: Fix NULL pointer dereference

2013-11-11 Thread Brian Norris
On Mon, Nov 11, 2013 at 7:44 PM, Fabio Estevam feste...@gmail.com wrote: On Tue, Nov 12, 2013 at 12:47 AM, Huang Shijie b32...@freescale.com wrote: 于 2013年11月12日 02:23, Brian Norris 写道: For imx23, the work flow is like this: [1] first check the fingerprint, if we can find it, we will return

Re: [PATCH V2] mtd: gpmi: fix the NULL pointer

2013-11-11 Thread Brian Norris
+ Fabio, in case he missed this (it was also in HTML, so it might not have gotten through the filters) On Tue, Nov 12, 2013 at 11:28:24AM +0800, Huang Shijie wrote: 于 2013年11月12日 11:18, Brian Norris 写道: So I would recommend the following: set the NAND_SKIP_BBTSCAN, then rearrange

Re: [PATCH 1/2] mtd: gpmi: fix the NULL pointer

2013-11-08 Thread Brian Norris
On Thu, Nov 07, 2013 at 05:46:36PM +0800, Huang Shijie wrote: The imx23 board will check the fingerprint, so it will call the mx23_check_transcription_stamp. This function will use @chip-buffers-databuf as its buffer which is allocated in the nand_scan_tail(). Unfortunately, the

Re: [PATCH bugfix] mtd: gpmi: serialize all the dma operations

2013-11-07 Thread Brian Norris
Hi Huang, On Wed, Nov 06, 2013 at 04:53:27PM +0800, Huang Shijie wrote: [1] The gpmi uses the nand_command_lp to issue the commands to NAND chips. It will issue a DMA operation when it handles a NAND_CMD_NONE control command. So when we read a page(NAND_CMD_READ0) from the NAND, we may

Re: [PATCH 2/2] mtd: gpmi: Revert mtd: gpmi: remove the nand_scan()

2013-11-06 Thread Brian Norris
On Wed, Nov 6, 2013 at 9:16 AM, Fabio Estevam feste...@gmail.com wrote: From: Fabio Estevam fabio.este...@freescale.com Commit f720e7ce (mtd: gpmi: remove the nand_scan()) caused the following regression on mx23: ... This reverts commit f720e7ce510bf79f029be45ce200ccfce5551280. Cc:

Re: [PATCH 2/2] mtd: gpmi: Revert mtd: gpmi: remove the nand_scan()

2013-11-06 Thread Brian Norris
On Wed, Nov 6, 2013 at 10:42 AM, Fabio Estevam feste...@gmail.com wrote: On Wed, Nov 6, 2013 at 4:08 PM, Brian Norris computersforpe...@gmail.com wrote: I seriously doubt that a total revert is the correct answer to this problem. Can you pick up the discussion with Huang on the mailing Agree

Re: [PATCH 1/5] mtd: m25p80: fix allocation size

2013-10-27 Thread Brian Norris
On Sun, Oct 27, 2013 at 9:30 AM, Marek Vasut ma...@denx.de wrote: Hi Brian, [...] @@ -1137,14 +1135,10 @@ static int m25p_probe(struct spi_device *spi) static int m25p_remove(struct spi_device *spi) { struct m25p *flash = spi_get_drvdata(spi); - int status;

Re: [PATCH V2] mtd: gpmi: fix the ecc regression

2013-10-25 Thread Brian Norris
On Fri, Oct 25, 2013 at 7:08 AM, David Woodhouse dw...@infradead.org wrote: On Fri, 2013-10-25 at 21:41 -0400, Huang Shijie wrote: On Fri, Oct 25, 2013 at 02:29:42PM +0100, David Woodhouse wrote: On Fri, 2013-10-25 at 21:33 -0400, Huang Shijie wrote: I am ok with your patch. but we

Re: [PATCH 1/5] mtd: m25p80: fix allocation size

2013-10-24 Thread Brian Norris
On Wed, Oct 23, 2013 at 07:58:19PM -0700, Brian Norris wrote: This patch fixes two memory errors: 1. During a probe failure (in mtd_device_parse_register?) the command buffer would not be freed. 2. The command buffer's size is determined based on the 'fast_read' boolean

Re: [PATCH v2 fix] mtd: gpmi: fix the ecc regression

2013-10-24 Thread Brian Norris
On Thu, Oct 24, 2013 at 04:48:16PM +0800, Huang Shijie wrote: The legacy ecc layout is to use all the OOB area by computing the ecc strength and ecc step size ourselves. The patch 2febcdf mtd: gpmi: set the BCHs geometry with the ecc info makes the gpmi to use the ECC info(ecc strength and

[PATCH 1/5] mtd: m25p80: fix allocation size

2013-10-23 Thread Brian Norris
-by: Brian Norris computersforpe...@gmail.com Reported-by: Yuhang Wang wangyuhang2...@gmail.com Cc: stable@vger.kernel.org --- drivers/mtd/devices/m25p80.c | 20 +++- 1 file changed, 7 insertions(+), 13 deletions(-) diff --git a/drivers/mtd/devices/m25p80.c b/drivers/mtd/devices/m25p80.c

Re: [PATCH] mtd: nand: hack ONFI for non-power-of-2 dimensions

2013-10-21 Thread Brian Norris
On Tue, Aug 27, 2013 at 07:19:18PM -0700, Brian Norris wrote: Some bright specification writers decided to write this in the ONFI spec (from ONFI 3.0, Section 3.1): The number of blocks and number of pages per block is not required to be a power of two. In the case where one

[PATCH] mtd: nand: hack ONFI for non-power-of-2 dimensions

2013-08-27 Thread Brian Norris
) [... trim ...] ---[ end trace 0c9363860d865ff2 ]--- So to fix this, just truncate these dimensions down to the greatest power-of-2 dimension that is less than or equal to the specified dimension. Signed-off-by: Brian Norris computersforpe...@gmail.com Cc: stable@vger.kernel.org --- drivers

Re: [PATCH] mtd: m25p80: Micron SPI uses Macronix-style 4-byte addressing

2013-08-11 Thread Brian Norris
On Fri, Aug 9, 2013 at 11:46 AM, Marek Vasut ma...@denx.de wrote: Dear Brian Norris, For SPI NOR flash that are larger than 128Mbit (16MiB), we need 4 bytes of address space to reach the entire flash; however, the original SPI flash protocol used only 3 bytes for the address. So far

[PATCH] mtd: m25p80: Micron SPI uses Macronix-style 4-byte addressing

2013-08-09 Thread Brian Norris
need to treat those parts any diffently, as they will discard the EN4B opcode as a no-op. Signed-off-by: Brian Norris computersforpe...@gmail.com Cc: Vivien Didelot vivien.dide...@savoirfairelinux.com Cc: Marek Vasut ma...@denx.de Cc: stable@vger.kernel.org # 3.10+ --- drivers/mtd/devices/m25p80

Re: [STABLE] mtd: nand: allow NAND_NO_SUBPAGE_WRITE to be set from driver

2012-10-18 Thread Brian Norris
On 10/17/2012 02:41 PM, Greg Kroah-Hartman wrote: On Sun, Oct 14, 2012 at 11:50:42PM -0700, Brian Norris wrote: This is a backport of the following commit, for application to the 3.6.y and earlier stable trees: Applied to 3.6, it didn't apply to 3.4.y Hmm. Supplying another backport

Re: [STABLE] mtd: nand: allow NAND_NO_SUBPAGE_WRITE to be set from driver

2012-10-16 Thread Brian Norris
On 10/16/2012 06:59 PM, Ben Hutchings wrote: On Sun, 2012-10-14 at 23:50 -0700, Brian Norris wrote: This is a backport of the following commit, for application to the 3.6.y and earlier stable trees: commit bf7a01bf7987b63b121d572b240c132ec44129c4 mtd: nand: allow

[STABLE] mtd: nand: allow NAND_NO_SUBPAGE_WRITE to be set from driver

2012-10-15 Thread Brian Norris
options from accidentally being set by the driver. But the original thought turns out to be a bad idea occasionally. Thus, kill it. Note, this patch fixes some major gpmi-nand breakage. Signed-off-by: Brian Norris computersforpe...@gmail.com Tested-by: Huang Shijie shij...@gmail.com Cc: stable

[PATCH] jffs2: don't fail on bitflips in OOB

2012-08-31 Thread Brian Norris
, this patch should have no effect. Signed-off-by: Brian Norris computersforpe...@gmail.com Cc: stable@vger.kernel.org --- fs/jffs2/wbuf.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/fs/jffs2/wbuf.c b/fs/jffs2/wbuf.c index 6f4529d..a6597d6 100644 --- a/fs/jffs2/wbuf.c

Re: Patch ahci: add AHCI_HFLAG_DELAY_ENGINE host flag has been added to the 3.0-stable tree

2012-03-24 Thread Brian Norris
Hi Greg, On Fri, Mar 23, 2012 at 10:10 AM, gre...@linuxfoundation.org wrote: If you, or anyone else, feels it should not be added to the stable tree, please let stable@vger.kernel.org know about it. Please, do *not* send this patch (or the rest of the series) to anything pre-3.3. It's 3.3

Re: Patch ahci_platform: add STRICT_AHCI platform type has been added to the 3.2-stable tree

2012-03-24 Thread Brian Norris
Hi Greg, On Fri, Mar 23, 2012 at 10:10 AM, gre...@linuxfoundation.org wrote: If you, or anyone else, feels it should not be added to the stable tree, please let stable@vger.kernel.org know about it. Please, do *not* send this patch (or the rest of the series) to 3.2 stable. It was intended

Re: Patch ahci: add AHCI_HFLAG_DELAY_ENGINE host flag has been added to the 3.2-stable tree

2012-03-24 Thread Brian Norris
Hi Greg, On Fri, Mar 23, 2012 at 10:10 AM, gre...@linuxfoundation.org wrote: If you, or anyone else, feels it should not be added to the stable tree, please let stable@vger.kernel.org know about it. Please, do *not* send this patch (or the rest of the series) to 3.2 stable. It was intended

Re: Patch ahci: move AHCI_HFLAGS() macro to ahci.h has been added to the 3.2-stable tree

2012-03-24 Thread Brian Norris
Hi Greg, On Fri, Mar 23, 2012 at 10:10 AM, gre...@linuxfoundation.org wrote: If you, or anyone else, feels it should not be added to the stable tree, please let stable@vger.kernel.org know about it. Please, do *not* send this patch (or the rest of the series) to 3.2 stable. It was intended

Re: Patch ahci: move AHCI_HFLAGS() macro to ahci.h has been added to the 3.0-stable tree

2012-03-24 Thread Brian Norris
Hi Greg, On Fri, Mar 23, 2012 at 10:10 AM, gre...@linuxfoundation.org wrote: If you, or anyone else, feels it should not be added to the stable tree, please let stable@vger.kernel.org know about it. Please, do *not* send this patch (or the rest of the series) to 3.0 stable. It was intended