From mboxrd@z Thu Jan 1 00:00:00 1970 From: mkl@pengutronix.de (Marc Kleine-Budde) Date: Thu, 24 Jul 2014 11:56:32 +0200 Subject: [PATCH] imx-drm: imx-drm-core: add suspend/resume support In-Reply-To: <1406195275.4590.18.camel@weser.hi.pengutronix.de> References: <1406193474-13695-1-git-send-email-shawn.guo@freescale.com> <1406195275.4590.18.camel@weser.hi.pengutronix.de> Message-ID: <53D0D850.8050201@pengutronix.de> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On 07/24/2014 11:47 AM, Lucas Stach wrote: > Am Donnerstag, den 24.07.2014, 17:17 +0800 schrieb Shawn Guo: >> HDMI currently stops working after a system suspend/resume cycle. It >> turns out that the cause is the imx-hdmi encoder .dpms hook doesn't get >> called from anywhere across suspend/resume cycle. >> >> The patch follows what exynos drm driver does to walk the list of >> connectors and call their .dpms function from suspend/resume hook. And >> the connectors' .dpms function will in turn filter down to the .dpms >> hooks of encoders and CRTCs. >> >> With this change, HDMI can continue working after a suspend/resume >> cycle. >> >> Signed-off-by: Shawn Guo >> --- >> Tested with HDMI and LVDS. It'd be great if someone can help test TVE >> to ensure the patch doesn't break anything. >> >> drivers/staging/imx-drm/imx-drm-core.c | 39 ++++++++++++++++++++++++++++++++++ >> 1 file changed, 39 insertions(+) >> >> diff --git a/drivers/staging/imx-drm/imx-drm-core.c b/drivers/staging/imx-drm/imx-drm-core.c >> index def8280d7ee6..b0ea1f0ed32f 100644 >> --- a/drivers/staging/imx-drm/imx-drm-core.c >> +++ b/drivers/staging/imx-drm/imx-drm-core.c >> @@ -696,6 +696,44 @@ static int imx_drm_platform_remove(struct platform_device *pdev) >> return 0; >> } >> >> +#if CONFIG_PM_SLEEP > > use #ifdef ...or remove #if/#ifdef and mark as __maybe_unused Marc -- Pengutronix e.K. | Marc Kleine-Budde | Industrial Linux Solutions | Phone: +49-231-2826-924 | Vertretung West/Dortmund | Fax: +49-5121-206917-5555 | Amtsgericht Hildesheim, HRA 2686 | http://www.pengutronix.de | -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 242 bytes Desc: OpenPGP digital signature URL: From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marc Kleine-Budde Subject: Re: [PATCH] imx-drm: imx-drm-core: add suspend/resume support Date: Thu, 24 Jul 2014 11:56:32 +0200 Message-ID: <53D0D850.8050201@pengutronix.de> References: <1406193474-13695-1-git-send-email-shawn.guo@freescale.com> <1406195275.4590.18.camel@weser.hi.pengutronix.de> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============6163279926339216501==" Return-path: In-Reply-To: <1406195275.4590.18.camel@weser.hi.pengutronix.de> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=m.gmane.org@lists.infradead.org To: Lucas Stach , Shawn Guo Cc: David Airlie , Russell King , kernel@pengutronix.de, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org List-Id: dri-devel@lists.freedesktop.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --===============6163279926339216501== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Nn6rtGsWSTk9lmVP4DsM42MIQAUnmn8Gp" This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --Nn6rtGsWSTk9lmVP4DsM42MIQAUnmn8Gp Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 07/24/2014 11:47 AM, Lucas Stach wrote: > Am Donnerstag, den 24.07.2014, 17:17 +0800 schrieb Shawn Guo: >> HDMI currently stops working after a system suspend/resume cycle. It >> turns out that the cause is the imx-hdmi encoder .dpms hook doesn't ge= t >> called from anywhere across suspend/resume cycle. >> >> The patch follows what exynos drm driver does to walk the list of >> connectors and call their .dpms function from suspend/resume hook. An= d >> the connectors' .dpms function will in turn filter down to the .dpms >> hooks of encoders and CRTCs. >> >> With this change, HDMI can continue working after a suspend/resume >> cycle. >> >> Signed-off-by: Shawn Guo >> --- >> Tested with HDMI and LVDS. It'd be great if someone can help test TVE= >> to ensure the patch doesn't break anything. >> >> drivers/staging/imx-drm/imx-drm-core.c | 39 +++++++++++++++++++++++++= +++++++++ >> 1 file changed, 39 insertions(+) >> >> diff --git a/drivers/staging/imx-drm/imx-drm-core.c b/drivers/staging/= imx-drm/imx-drm-core.c >> index def8280d7ee6..b0ea1f0ed32f 100644 >> --- a/drivers/staging/imx-drm/imx-drm-core.c >> +++ b/drivers/staging/imx-drm/imx-drm-core.c >> @@ -696,6 +696,44 @@ static int imx_drm_platform_remove(struct platfor= m_device *pdev) >> return 0; >> } >> =20 >> +#if CONFIG_PM_SLEEP >=20 > use #ifdef =2E..or remove #if/#ifdef and mark as __maybe_unused Marc --=20 Pengutronix e.K. | Marc Kleine-Budde | Industrial Linux Solutions | Phone: +49-231-2826-924 | Vertretung West/Dortmund | Fax: +49-5121-206917-5555 | Amtsgericht Hildesheim, HRA 2686 | http://www.pengutronix.de | --Nn6rtGsWSTk9lmVP4DsM42MIQAUnmn8Gp Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: Using GnuPG with Icedove - http://www.enigmail.net/ iEYEARECAAYFAlPQ2FEACgkQjTAFq1RaXHMlKwCeJP2SN9ZIyDWdvkJ4QmWzj+8C d1AAnjrKGzdja1VLzitZjFEXRPoRkYcv =Bjs1 -----END PGP SIGNATURE----- --Nn6rtGsWSTk9lmVP4DsM42MIQAUnmn8Gp-- --===============6163279926339216501== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --===============6163279926339216501==--