Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 91dc74e4 authored by Pinkava J's avatar Pinkava J Committed by Ben Dooks
Browse files

ARM: SAMSUNG: fix suspend/resume on if some GPIO banks not present



When saving GPIOs during suspend/resume we need skip missing GPIO banks, not
trying get corresponding chip again and again in infinite loop.

Signed-off-by: default avatarJiri Pinkava <jiri.pinkava@vscht.cz>
[ben-linux@fluff.org: shorten subject]
Signed-off-by: default avatarBen Dooks <ben-linux@fluff.org>
parent fda22577
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -331,8 +331,10 @@ void s3c_pm_save_gpios(void)

	for (gpio_nr = 0; gpio_nr < S3C_GPIO_END;) {
		ourchip = s3c_gpiolib_getchip(gpio_nr);
		if (!ourchip)
		if (!ourchip) {
			gpio_nr++;
			continue;
		}

		s3c_pm_save_gpio(ourchip);

@@ -369,8 +371,10 @@ void s3c_pm_restore_gpios(void)

	for (gpio_nr = 0; gpio_nr < S3C_GPIO_END;) {
		ourchip = s3c_gpiolib_getchip(gpio_nr);
		if (!ourchip)
		if (!ourchip) {
			gpio_nr++;
			continue;
		}

		s3c_pm_resume_gpio(ourchip);