From: Scott Wood <scottwood@freescale.com>
To: Dogra Raghav-B46184 <raghav@freescale.com>
Cc: Kushwaha Prabhakar-B32579 <prabhakar@freescale.com>,
"linuxppc-dev@lists.ozlabs.org" <linuxppc-dev@lists.ozlabs.org>
Subject: Re: [PATCH 1/2] mpc85xx/lbc: modify suspend/resume entry sequence
Date: Mon, 2 Nov 2015 17:00:57 -0600 [thread overview]
Message-ID: <1446505257.22185.43.camel@freescale.com> (raw)
In-Reply-To: <BY2PR0301MB0775A3A01F8585352ED5EFADD22C0@BY2PR0301MB0775.namprd03.prod.outlook.com>
On Mon, 2015-11-02 at 00:12 -0600, Dogra Raghav-B46184 wrote:
> -----Original Message-----
> From: Raghav Dogra [mailto:raghav@freescale.com]
> Sent: Friday, October 30, 2015 11:55 AM
> To: linuxppc-dev@lists.ozlabs.org
> Cc: Wood Scott-B07421 <scottwood@freescale.com>; Kushwaha Prabhakar-B32579 <
> prabhakar@freescale.com>; Dogra Raghav-B46184 <raghav@freescale.com>
> Subject: [PATCH 1/2] mpc85xx/lbc: modify suspend/resume entry sequence
>
> Modify platform driver suspend/resume to syscore suspend/resume. This is
> because p1022ds needs to use localbus when entering the PCIE resume.
>
> Signed-off-by: Raghav Dogra <raghav@freescale.com>
> ---
> arch/powerpc/sysdev/Makefile | 2 +-
> arch/powerpc/sysdev/fsl_lbc.c | 51 +++++++++++++++++++++++++++++++++-------
> ---
> 2 files changed, 40 insertions(+), 13 deletions(-)
>
> diff --git a/arch/powerpc/sysdev/Makefile b/arch/powerpc/sysdev/Makefile
> index f7cb2a1..4c19e614 100644
> --- a/arch/powerpc/sysdev/Makefile
> +++ b/arch/powerpc/sysdev/Makefile
> @@ -18,9 +18,9 @@ obj-$(CONFIG_PPC_PMI) += pmi.o
> obj-$(CONFIG_U3_DART) += dart_iommu.o
> obj-$(CONFIG_MMIO_NVRAM) += mmio_nvram.o
> obj-$(CONFIG_FSL_SOC) += fsl_soc.o fsl_mpic_err.o
> +obj-$(CONFIG_FSL_LBC) += fsl_lbc.o
> obj-$(CONFIG_FSL_PCI) += fsl_pci.o $(fsl-msi-obj-y)
> obj-$(CONFIG_FSL_PMC) += fsl_pmc.o
> -obj-$(CONFIG_FSL_LBC) += fsl_lbc.o
> obj-$(CONFIG_FSL_GTM) += fsl_gtm.o
> obj-$(CONFIG_FSL_85XX_CACHE_SRAM) += fsl_85xx_l2ctlr.o
> fsl_85xx_cache_sram.o
> obj-$(CONFIG_SIMPLE_GPIO) += simple_gpio.o
> diff --git a/arch/powerpc/sysdev/fsl_lbc.c b/arch/powerpc/sysdev/fsl_lbc.c
> index d631022..332d700 100644
> --- a/arch/powerpc/sysdev/fsl_lbc.c
> +++ b/arch/powerpc/sysdev/fsl_lbc.c
> @@ -27,6 +27,7 @@
> #include <linux/platform_device.h>
> #include <linux/interrupt.h>
> #include <linux/mod_devicetable.h>
> +#include <linux/syscore_ops.h>
> #include <asm/prom.h>
> #include <asm/fsl_lbc.h>
>
> @@ -354,24 +355,42 @@ err:
> #ifdef CONFIG_SUSPEND
>
> /* save lbc registers */
> -static int fsl_lbc_suspend(struct platform_device *pdev, pm_message_t
> state)
> +static int fsl_lbc_syscore_suspend(void)
> {
> - struct fsl_lbc_ctrl *ctrl = dev_get_drvdata(&pdev->dev);
> - struct fsl_lbc_regs __iomem *lbc = ctrl->regs;
> + struct fsl_lbc_ctrl *ctrl;
> + struct fsl_lbc_regs __iomem *lbc;
> +
> + ctrl = fsl_lbc_ctrl_dev;
> + if (!ctrl)
> + goto out;
> +
> + lbc = ctrl->regs;
> + if (!lbc)
> + goto out;
>
> ctrl->saved_regs = kmalloc(sizeof(struct fsl_lbc_regs), GFP_KERNEL);
> if (!ctrl->saved_regs)
> return -ENOMEM;
> [Dogra Raghav-B46184] This is the existing upstream code. Are you
> suggesting to modify the upstream code to take care of individual registers?
What specifically do you mean by "the upstream code"? What other tree are we
talking about here?
-Scott
next prev parent reply other threads:[~2015-11-02 23:01 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-30 6:24 [PATCH 1/2] mpc85xx/lbc: modify suspend/resume entry sequence Raghav Dogra
2015-10-30 20:03 ` Scott Wood
2015-11-02 6:12 ` Dogra Raghav
2015-11-02 23:00 ` Scott Wood [this message]
2015-11-03 5:31 ` Dogra Raghav
2015-11-03 5:39 ` Scott Wood
2015-11-03 6:09 ` Dogra Raghav
2015-11-03 6:13 ` Scott Wood
2015-11-03 6:33 ` Dogra Raghav
2015-11-03 7:36 ` Scott Wood
2015-11-03 9:12 ` Dogra Raghav
2015-12-23 21:10 ` Scott Wood
2015-12-24 4:19 ` [1/2] " Scott Wood
2015-12-24 4:38 ` Kushwaha Prabhakar
2015-12-24 4:49 ` Scott Wood
2015-12-24 5:22 ` Kushwaha Prabhakar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1446505257.22185.43.camel@freescale.com \
--to=scottwood@freescale.com \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=prabhakar@freescale.com \
--cc=raghav@freescale.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.