Re: [PATCH v1 3/3] watchdog/aspeed: add support for dual boot

2019-08-23 Thread Ivan Mikhaylov
On Fri, 2019-08-23 at 07:19 -0700, Guenter Roeck wrote: > > > > +/* access_cs0 shows if cs0 is accessible, hence the reverted bit */ > > +static ssize_t access_cs0_show(struct device *dev, > > + struct device_attribute *attr, char *buf) > > +{ > > + struct aspeed_wdt *wdt =

Re: [PATCH v1 3/3] watchdog/aspeed: add support for dual boot

2019-08-23 Thread Guenter Roeck
On Fri, Aug 23, 2019 at 12:35:28PM +0300, Ivan Mikhaylov wrote: > Set WDT_CLEAR_TIMEOUT_AND_BOOT_CODE_SELECTION into WDT_CLEAR_TIMEOUT_STATUS > to clear out boot code source and re-enable access to the primary SPI flash > chip while booted via wdt2 from the alternate chip. > > AST2400 datasheet

[PATCH v1 3/3] watchdog/aspeed: add support for dual boot

2019-08-23 Thread Ivan Mikhaylov
Set WDT_CLEAR_TIMEOUT_AND_BOOT_CODE_SELECTION into WDT_CLEAR_TIMEOUT_STATUS to clear out boot code source and re-enable access to the primary SPI flash chip while booted via wdt2 from the alternate chip. AST2400 datasheet says: "In the 2nd flash booting mode, all the address mapping to CS0# would