Re: [Openocd-development] NAND File I/O parses wrong argument

2009-11-19 Thread Zach Welch
On Wed, 2009-11-18 at 23:25 -0600, Dean Glazeski wrote: Hi all, Recent NAND file I/O changes are parsing the wrong argument for the size. Should be third argument, not second. Pushed. Let me know if you find any other problems. Incidentally, does the 'new verify' command work for you

Re: [Openocd-development] NAND File I/O parses wrong argument

2009-11-19 Thread Dean Glazeski
nand verify is not working. I'm trying to trace it to the problem, but it appears there is something wrong with the file struct that's reading the file. Somehow the data read from the file doesn't match the actual data in the file. The odd ball thing is that nand erase, followed by nand write,

Re: [Openocd-development] NAND File I/O parses wrong argument

2009-11-19 Thread Dean Glazeski
After writing this email, I came across the bug. There are a few ways to fix it and I'll leave it to you to decide. The dev.address needs to be advanced with the file.address in the main verify loop. This might be replaceable by just advancing dev and not file, or moving both, etc. As another

Re: [Openocd-development] NAND File I/O parses wrong argument

2009-11-19 Thread Zach Welch
Thanks for the feedback. I will take a closer look at the code. I am not entirely surprised by this bug in the new function (given the way that I implemented it), but it's great to hear that I didn't cause any other regressions with the existing commands. --Z On Thu, 2009-11-19 at 16:58 -0600,

Re: [Openocd-development] NAND File I/O parses wrong argument

2009-11-19 Thread Zach Welch
On Thu, 2009-11-19 at 15:08 -0800, Zach Welch wrote: At the moment, I just want correctness. Thanks for doing the detective work, but you're also welcom. Whoops... that one slipped away from me you're also welcome to put together an initial patch for it. Similarly, you are welcome to

Re: [Openocd-development] NAND File I/O parses wrong argument

2009-11-19 Thread Dean Glazeski
Here's a patch to fix the increment. I'll mess around with error output later. There are a lot of areas that I would like to visit to update error output. So many errors don't present proper fault output. It makes it hard to trace problems when regressions happen :) I'll spend some time with

Re: [Openocd-development] NAND File I/O parses wrong argument

2009-11-19 Thread Zach Welch
Thanks. I think David and I have both been improving the error handling in places that we touch, but we need a more systematic approach to it. I have been thinking about starting an automated test suite for 0.4.0, as such might have prevented a few of the minor issues that we've seen. Any

[Openocd-development] NAND File I/O parses wrong argument

2009-11-18 Thread Dean Glazeski
Hi all, Recent NAND file I/O changes are parsing the wrong argument for the size. Should be third argument, not second. // Dean Glazeski From e569df94abf628bcec2652971fc825fc5e46193b Mon Sep 17 00:00:00 2001 From: Dean Glazeski dngl...@gmail.com Date: Wed, 18 Nov 2009 23:22:25 -0600 Subject: