Re: [PATCH v2] bus: mhi: core: Check state before processing power_down

2021-02-24 Thread Manivannan Sadhasivam
On Wed, Feb 24, 2021 at 08:14:53AM -0700, Jeffrey Hugo wrote: > On 2/24/2021 2:55 AM, Manivannan Sadhasivam wrote: > > On Wed, Feb 17, 2021 at 09:43:31AM -0700, Jeffrey Hugo wrote: > > > We cannot process a power_down if the power state is DISABLED. There is > > > no valid mhi_ctxt in that case,

Re: [PATCH v2] bus: mhi: core: Check state before processing power_down

2021-02-24 Thread Jeffrey Hugo
On 2/24/2021 2:55 AM, Manivannan Sadhasivam wrote: On Wed, Feb 17, 2021 at 09:43:31AM -0700, Jeffrey Hugo wrote: We cannot process a power_down if the power state is DISABLED. There is no valid mhi_ctxt in that case, so attepting to process the power_down will likely result in a null pointer

Re: [PATCH v2] bus: mhi: core: Check state before processing power_down

2021-02-24 Thread Manivannan Sadhasivam
On Wed, Feb 17, 2021 at 09:43:31AM -0700, Jeffrey Hugo wrote: > We cannot process a power_down if the power state is DISABLED. There is > no valid mhi_ctxt in that case, so attepting to process the power_down > will likely result in a null pointer dereference. If the power state is > DISABLED,

[PATCH v2] bus: mhi: core: Check state before processing power_down

2021-02-17 Thread Jeffrey Hugo
We cannot process a power_down if the power state is DISABLED. There is no valid mhi_ctxt in that case, so attepting to process the power_down will likely result in a null pointer dereference. If the power state is DISABLED, there is nothing to do anyways, so just bail early. Signed-off-by: