Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1465126

Re: [PATCH v1 1/1] x86/platform/intel-mid: Run PWRMU command immediately

From Ingo Molnar <mingo@kernel.org>
Newsgroups linux.kernel
Subject Re: [PATCH v1 1/1] x86/platform/intel-mid: Run PWRMU command immediately
Date 2016-08-18 13:00 +0200
Message-ID <s7tdf-75c-5@gated-at.bofh.it> (permalink)
References <s7sqS-6Jo-43@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


* Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote:

> On some firmwares we have to tell how exactly we want the command to be run.
> The default case for now is to run it immediately.
> 
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> ---
>  arch/x86/platform/intel-mid/pwr.c | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/x86/platform/intel-mid/pwr.c b/arch/x86/platform/intel-mid/pwr.c
> index c901a34..0548741 100644
> --- a/arch/x86/platform/intel-mid/pwr.c
> +++ b/arch/x86/platform/intel-mid/pwr.c
> @@ -44,6 +44,10 @@
>  /* Bits in PM_CMD */
>  #define PM_CMD_CMD(x)		((x) << 0)
>  #define PM_CMD_IOC		(1 << 8)
> +#define PM_CMD_CM_NOP		(0 << 9)
> +#define PM_CMD_CM_IMMEDIATE	(1 << 9)
> +#define PM_CMD_CM_DELAY		(2 << 9)
> +#define PM_CMD_CM_TRIGGER	(3 << 9)
>  #define PM_CMD_D3cold		(1 << 21)
>  
>  /* List of commands */
> @@ -137,7 +141,7 @@ static int mid_pwr_wait(struct mid_pwr *pwr)
>  
>  static int mid_pwr_wait_for_cmd(struct mid_pwr *pwr, u8 cmd)
>  {
> -	writel(PM_CMD_CMD(cmd), pwr->regs + PM_CMD);
> +	writel(PM_CMD_CMD(cmd) | PM_CMD_CM_IMMEDIATE, pwr->regs + PM_CMD);
>  	return mid_pwr_wait(pwr);
>  }

Does this fix a bug? If yes then please also add that to the changelog: what are 
the symptoms of the bug - how does a user notice, etc.

Thanks,

	Ingo

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v1 1/1] x86/platform/intel-mid: Run PWRMU command immediately Andy Shevchenko <andriy.shevchenko@linux.intel.com> - 2016-08-18 12:10 +0200
  Re: [PATCH v1 1/1] x86/platform/intel-mid: Run PWRMU command  immediately Ingo Molnar <mingo@kernel.org> - 2016-08-18 13:00 +0200
    Re: [PATCH v1 1/1] x86/platform/intel-mid: Run PWRMU command  immediately Andy Shevchenko <andriy.shevchenko@linux.intel.com> - 2016-08-18 13:20 +0200
      Re: [PATCH v1 1/1] x86/platform/intel-mid: Run PWRMU command  immediately Ingo Molnar <mingo@kernel.org> - 2016-08-18 15:40 +0200

csiph-web