Re: [Nouveau] [PATCH NEW 5/9] acpi: Use a single type of errors in evaluate functions

2015-05-27 Thread Pierre Moreau
I wasn't sure how to insert this one into the flow, if I should make it a patch 
4.5 or not. I went with patch 5, so all the following patches are incremented 
by 1 compared to the v1, sorry about that.
What should be the way to go?

Pierre



> On 28 May 2015, at 08:40, Pierre Moreau  wrote:
> 
> Signed-off-by: Pierre Moreau 
> ---
> drm/nouveau/nouveau_acpi.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drm/nouveau/nouveau_acpi.c b/drm/nouveau/nouveau_acpi.c
> index 01dbf1d..b837ab1 100644
> --- a/drm/nouveau/nouveau_acpi.c
> +++ b/drm/nouveau/nouveau_acpi.c
> @@ -92,7 +92,7 @@ static int nouveau_evaluate_optimus_dsm(acpi_handle handle, 
> int func, int arg, u
>  func, &argv4, ACPI_TYPE_BUFFER);
>if (!obj) {
>acpi_handle_info(handle, "failed to evaluate _DSM\n");
> -return AE_ERROR;
> +return -EINVAL;
>} else {
>if (result && obj->buffer.length == 4) {
>*result  = obj->buffer.pointer[0];
> @@ -142,7 +142,7 @@ static int nouveau_evaluate_mux_dsm(acpi_handle handle, 
> int func, int arg)
>  func, &argv4, ACPI_TYPE_INTEGER);
>if (!obj) {
>acpi_handle_info(handle, "failed to evaluate _DSM\n");
> -return AE_ERROR;
> +return -EINVAL;
>} else {
>if (obj->integer.value == 0x8002)
>ret = -ENODEV;
> -- 
> 2.4.2
> 
> ___
> Nouveau mailing list
> Nouveau@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/nouveau
___
Nouveau mailing list
Nouveau@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/nouveau


[Nouveau] [PATCH NEW 5/9] acpi: Use a single type of errors in evaluate functions

2015-05-27 Thread Pierre Moreau
Signed-off-by: Pierre Moreau 
---
 drm/nouveau/nouveau_acpi.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drm/nouveau/nouveau_acpi.c b/drm/nouveau/nouveau_acpi.c
index 01dbf1d..b837ab1 100644
--- a/drm/nouveau/nouveau_acpi.c
+++ b/drm/nouveau/nouveau_acpi.c
@@ -92,7 +92,7 @@ static int nouveau_evaluate_optimus_dsm(acpi_handle handle, 
int func, int arg, u
  func, &argv4, ACPI_TYPE_BUFFER);
if (!obj) {
acpi_handle_info(handle, "failed to evaluate _DSM\n");
-   return AE_ERROR;
+   return -EINVAL;
} else {
if (result && obj->buffer.length == 4) {
*result  = obj->buffer.pointer[0];
@@ -142,7 +142,7 @@ static int nouveau_evaluate_mux_dsm(acpi_handle handle, int 
func, int arg)
  func, &argv4, ACPI_TYPE_INTEGER);
if (!obj) {
acpi_handle_info(handle, "failed to evaluate _DSM\n");
-   return AE_ERROR;
+   return -EINVAL;
} else {
if (obj->integer.value == 0x8002)
ret = -ENODEV;
-- 
2.4.2

___
Nouveau mailing list
Nouveau@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/nouveau