lkml.org 
[lkml]   [2008]   [Nov]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/2] acpiphp: Identify more removable slots
On Thu, Nov 13, 2008 at 01:48:59PM -0700, Matthew Wilcox wrote:

> Why not:
>
> status = acpi_get_handle(handle, "_EJ0", &tmp);
> if (ACPI_SUCCESS(status))
> return 1;
>
> status = acpi_get_handle(handle, "_RMV", &tmp);
> if (ACPI_SUCCESS(status))
> return 1;
>
> return 0;

Oh, yes, that'd work.

> > + if (ACPI_SUCCESS(status) || is_dock_device(handle))
> > + valid = 1;
> > +
> > + if (!valid)
> > return AE_OK;
>
> This looks like almost the same code as above. New helper function?

It's not quite the same, but yes, I'll see if it can be reduced.

--
Matthew Garrett | mjg59@srcf.ucam.org


\
 
 \ /
  Last update: 2008-11-13 21:55    [W:0.479 / U:0.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site