Re: [Openocd-development] flash protection

2009-10-21 Thread Øyvind Harboe
On Wed, Oct 21, 2009 at 2:22 PM, Luca Ottaviano wrote: > Øyvind Harboe ha scritto: >> >>> Unlocking flash is good. >> >> Thanks. I'll hold out a bit longer for any objections. > > I've been thinking about it in the past few days and I concluded that if the > protection is there, ignoring it would

Re: [Openocd-development] flash protection

2009-10-21 Thread Luca Ottaviano
Øyvind Harboe ha scritto: > >> Unlocking flash is good. > > Thanks. I'll hold out a bit longer for any objections. I've been thinking about it in the past few days and I concluded that if the protection is there, ignoring it would destroy its purpose, which is protect from accidentally erasure

Re: [Openocd-development] flash protection

2009-10-20 Thread David Brownell
On Monday 19 October 2009, Michael Schwingen wrote: > > And to allow things like "erase the whole flash" to > > preserve the boot loader (etc) unless something > > explicitly enables erasing it... > >   > No. If I call for a complete chip erase, I want a complete chip erase, > not something that

Re: [Openocd-development] flash protection

2009-10-20 Thread Michael Schwingen
David Brownell wrote: > On Monday 19 October 2009, Øyvind Harboe wrote: > >> Does anyone feel very strongly about flash protection? >> > > Dunno about "strongly", but given my druthers it'd stay > the way it is now. I've not observed it to be a problem. > It is if you use Intel flashs t

Re: [Openocd-development] flash protection

2009-10-19 Thread Øyvind Harboe
On Tue, Oct 20, 2009 at 1:10 AM, David Brownell wrote: > On Monday 19 October 2009, Øyvind Harboe wrote: >> There is an autoerase option to flash write_image. >> >> Would you object strongly to autoerase automatically >> unlocking the flash if necessary? > > That sounds more like "autounlock".  I'

Re: [Openocd-development] flash protection

2009-10-19 Thread David Brownell
On Monday 19 October 2009, Øyvind Harboe wrote: > There is an autoerase option to flash write_image. > > Would you object strongly to autoerase automatically > unlocking the flash if necessary? That sounds more like "autounlock". I'd not object to a new "autounlock" option, defaulting to disable

Re: [Openocd-development] flash protection

2009-10-19 Thread Øyvind Harboe
On Mon, Oct 19, 2009 at 8:34 PM, Magnus Lundin wrote: > Øyvind Harboe wrote: >> >> There is an autoerase option to flash write_image. >> >> Would you object strongly to autoerase automatically >> unlocking the flash if necessary? >> >> >> > > On some targets the write with autoerase is very slow.

Re: [Openocd-development] flash protection

2009-10-19 Thread Magnus Lundin
Øyvind Harboe wrote: > There is an autoerase option to flash write_image. > > Would you object strongly to autoerase automatically > unlocking the flash if necessary? > > > On some targets the write with autoerase is very slow. A sector erase or full erase followed by write is much faster. IM

Re: [Openocd-development] flash protection

2009-10-19 Thread Øyvind Harboe
There is an autoerase option to flash write_image. Would you object strongly to autoerase automatically unlocking the flash if necessary? -- Øyvind Harboe http://www.zylin.com/zy1000.html ARM7 ARM9 ARM11 XScale Cortex JTAG debugger and flash programmer __

Re: [Openocd-development] flash protection

2009-10-19 Thread David Brownell
On Monday 19 October 2009, Øyvind Harboe wrote: > Does anyone feel very strongly about flash protection? Dunno about "strongly", but given my druthers it'd stay the way it is now. I've not observed it to be a problem. > My thinking is that OpenOCD erase should remove flash protection > automati

Re: [Openocd-development] flash protection

2009-10-19 Thread Øyvind Harboe
On Mon, Oct 19, 2009 at 5:23 PM, Luca Ottaviano wrote: > Øyvind Harboe ha scritto: >> >> Does anyone feel very strongly about flash protection? >> >> My thinking is that OpenOCD erase should remove flash protection >> automatically. > > That's a good idea. > > Bear in mind, though, that some CPUs

Re: [Openocd-development] flash protection

2009-10-19 Thread Luca Ottaviano
Øyvind Harboe ha scritto: > Does anyone feel very strongly about flash protection? > > My thinking is that OpenOCD erase should remove flash protection > automatically. That's a good idea. Bear in mind, though, that some CPUs are bugged (eg. Atmel AT91SAM7) so you can set protection bits only f

[Openocd-development] flash protection

2009-10-19 Thread Øyvind Harboe
Does anyone feel very strongly about flash protection? My thinking is that OpenOCD erase should remove flash protection automatically. IMHO, the flash protection is there to stop the application, when running normally, from accidentally erasing the flash. -- Øyvind Harboe http://www.zylin.com