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


Groups > linux.kernel > #1496445

[PATCH 4.4 91/93] ACPICA: acpi_get_sleep_type_data: Reduce warnings

From Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Newsgroups linux.kernel
Subject [PATCH 4.4 91/93] ACPICA: acpi_get_sleep_type_data: Reduce warnings
Date 2016-10-06 11:10 +0200
Message-ID <spcQI-6wB-87@gated-at.bofh.it> (permalink)
References <spcGZ-6dt-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


4.4-stable review patch.  If anyone has any objections, please let me know.

------------------

From: Prarit Bhargava <prarit@redhat.com>

commit a59b679ab85635737947310323f2f2bcfa0664a7 upstream.

ACPICA commit 7bb77313091e52a846df4c9c2bea90be31bfb9d8

Eliminate warnings for "not found" _Sx errors, since these
are optional. Original NOT_FOUND status is still returned.

Original changes by Prarit Bhargava.
ACPICA BZ 1208.

Link: https://github.com/acpica/acpica/commit/7bb77313
Link: https://bugs.acpica.org/show_bug.cgi?id=1208
Signed-off-by: Prarit Bhargava <prarit@redhat.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Cc: "Charles (Chas) Williams" <ciwillia@brocade.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

---
 drivers/acpi/acpica/hwxface.c |   24 +++++++++++++++++-------
 1 file changed, 17 insertions(+), 7 deletions(-)

--- a/drivers/acpi/acpica/hwxface.c
+++ b/drivers/acpi/acpica/hwxface.c
@@ -504,11 +504,20 @@ acpi_get_sleep_type_data(u8 sleep_state,
 	 * Evaluate the \_Sx namespace object containing the register values
 	 * for this state
 	 */
-	info->relative_pathname =
-	    ACPI_CAST_PTR(char, acpi_gbl_sleep_state_names[sleep_state]);
+	info->relative_pathname = ACPI_CAST_PTR(char,
+						acpi_gbl_sleep_state_names
+						[sleep_state]);
+
 	status = acpi_ns_evaluate(info);
 	if (ACPI_FAILURE(status)) {
-		goto cleanup;
+		if (status == AE_NOT_FOUND) {
+
+			/* The _Sx states are optional, ignore NOT_FOUND */
+
+			goto final_cleanup;
+		}
+
+		goto warning_cleanup;
 	}
 
 	/* Must have a return object */
@@ -517,7 +526,7 @@ acpi_get_sleep_type_data(u8 sleep_state,
 		ACPI_ERROR((AE_INFO, "No Sleep State object returned from [%s]",
 			    info->relative_pathname));
 		status = AE_AML_NO_RETURN_VALUE;
-		goto cleanup;
+		goto warning_cleanup;
 	}
 
 	/* Return object must be of type Package */
@@ -526,7 +535,7 @@ acpi_get_sleep_type_data(u8 sleep_state,
 		ACPI_ERROR((AE_INFO,
 			    "Sleep State return object is not a Package"));
 		status = AE_AML_OPERAND_TYPE;
-		goto cleanup1;
+		goto return_value_cleanup;
 	}
 
 	/*
@@ -570,16 +579,17 @@ acpi_get_sleep_type_data(u8 sleep_state,
 		break;
 	}
 
-cleanup1:
+return_value_cleanup:
 	acpi_ut_remove_reference(info->return_object);
 
-cleanup:
+warning_cleanup:
 	if (ACPI_FAILURE(status)) {
 		ACPI_EXCEPTION((AE_INFO, status,
 				"While evaluating Sleep State [%s]",
 				info->relative_pathname));
 	}
 
+final_cleanup:
 	ACPI_FREE(info);
 	return_ACPI_STATUS(status);
 }

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


Thread

[PATCH 4.4 00/93] 4.4.24-stable review Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:00 +0200
  [PATCH 4.4 68/93] brcmsmac: Initialize power in brcms_c_stf_ss_algo_channel_get() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:00 +0200
  [PATCH 4.4 02/93] mtd: nand: davinci: Reinitialize the HW ECC engine in 4bit hwctl Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:00 +0200
  [PATCH 4.4 63/93] pNFS/files: Fix layoutcommit after a commit to DS Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:00 +0200
  [PATCH 4.4 16/93] pinctrl: uniphier: fix .pin_dbg_show() callback Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:00 +0200
  [PATCH 4.4 92/93] ALSA: hda - Fix headset mic detection problem for several Dell laptops Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 75/93] IB/ipoib: Fix memory corruption in ipoib cm mode connect flow Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 72/93] kernel/fork: fix CLONE_CHILD_CLEARTID regression in nscd Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 46/93] ARM: sa1100: clear reset status prior to reboot Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 84/93] dm log writes: fix bug with too large bios Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 88/93] USB: serial: cp210x: Add ID for a Juniper console Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 77/93] IB/ipoib: Dont allow MC joins during light MC flush Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 83/93] clk: xgene: Add missing parenthesis when clearing divider value Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 82/93] aio: mark AIO pseudo-fs noexec Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 37/93] printk: fix parsing of "brl=" option Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 89/93] Revert "usbtmc: convert to devm_kzalloc" Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 41/93] regulator: qcom_spmi: Update mvs1/mvs2 switches on pm8941 Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 78/93] IB/mlx4: Fix incorrect MC join state bit-masking on SR-IOV Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 45/93] ARM: sa1100: fix 3.6864MHz clock Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 93/93] ALSA: hda - Add the top speaker pin config for HP Spectre x360 Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 85/93] USB: serial: cp210x: fix hardware flow-control disable Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 42/93] regulator: qcom_smd: Fix voltage ranges for pm8x41 Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 76/93] IB/core: Fix use after free in send_leave function Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 90/93] ALSA: hda - Adding one more ALC255 pin definition for headset problem Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 44/93] ARM: sa1100: register clocks early Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 79/93] IB/mlx4: Fix code indentation in QP1 MAD flow Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 87/93] Staging: fbtft: Fix bug in fbtft-core Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 91/93] ACPICA: acpi_get_sleep_type_data: Reduce warnings Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 80/93] IB/mlx4: Use correct subnet-prefix in QP1 mads under SR-IOV Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 65/93] ASoC: Intel: Skylake: Fix error return code in skl_probe() Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 86/93] usb: misc: legousbtower: Fix NULL pointer deference Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:10 +0200
  [PATCH 4.4 55/93] [media] em28xx-i2c: rt_mutex_trylock() returns zero on failure Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:20 +0200
  [PATCH 4.4 56/93] [media] gspca: avoid unused variable warnings Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:20 +0200
  [PATCH 4.4 01/93] cpuset: handle race between CPU hotplug and cpuset_hotplug_work Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:30 +0200
  [PATCH 4.4 21/93] ipvs: fix bind to link-local mcast IPv6 address in backup Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 11:30 +0200
  [PATCH 4.4 27/93] ceph: fix race during filling readdir cache Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-06 12:40 +0200
  Re: [PATCH 4.4 00/93] 4.4.24-stable review Guenter Roeck <linux@roeck-us.net> - 2016-10-06 20:50 +0200
  Re: [PATCH 4.4 00/93] 4.4.24-stable review Shuah Khan <shuah.kh@samsung.com> - 2016-10-06 22:00 +0200
  Re: [PATCH 4.4 00/93] 4.4.24-stable review Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-10-07 15:10 +0200
    Re: [PATCH 4.4 00/93] 4.4.24-stable review Kevin Hilman <khilman@baylibre.com> - 2016-10-08 12:00 +0200

csiph-web