Re: [PATCH] cxl: Allow release of contexts which have been OPENED but not STARTED

2015-08-18 Thread Andrew Donnellan
On 19/08/15 02:23, Michael Neuling wrote: So this doesn't break when you add a new state, is it worth writing it as: if (ctx->status >= STARTED) return -EBUSY; ? Yeah I think that would be more future proof, although it won't make a difference with the current code.

Re: [PATCH] cxl: Allow release of contexts which have been OPENED but not STARTED

2015-08-18 Thread Michael Neuling
On Tue, 2015-08-18 at 19:19 +1000, Michael Ellerman wrote: > On Tue, 2015-08-18 at 16:30 +1000, Andrew Donnellan wrote: > > If we open a context but do not start it (either because we do not attempt > > to start it, or because it fails to start for some reason), we are left > > with a context in st

Re: [PATCH] cxl: Allow release of contexts which have been OPENED but not STARTED

2015-08-18 Thread Michael Ellerman
On Tue, 2015-08-18 at 16:30 +1000, Andrew Donnellan wrote: > If we open a context but do not start it (either because we do not attempt > to start it, or because it fails to start for some reason), we are left > with a context in state OPENED. Previously, cxl_release_context() only > allowed releas

Re: [PATCH] cxl: Allow release of contexts which have been OPENED but not STARTED

2015-08-17 Thread Ian Munsie
Acked-by: Ian Munsie ___ Linuxppc-dev mailing list Linuxppc-dev@lists.ozlabs.org https://lists.ozlabs.org/listinfo/linuxppc-dev

[PATCH] cxl: Allow release of contexts which have been OPENED but not STARTED

2015-08-17 Thread Andrew Donnellan
If we open a context but do not start it (either because we do not attempt to start it, or because it fails to start for some reason), we are left with a context in state OPENED. Previously, cxl_release_context() only allowed releasing contexts in state CLOSED, so attempting to release an OPENED co