From patchwork Tue Mar 17 09:48:30 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adrian Hunter X-Patchwork-Id: 6030411 X-Patchwork-Delegate: rjw@sisk.pl Return-Path: X-Original-To: patchwork-linux-acpi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 98EEDBF90F for ; Tue, 17 Mar 2015 09:50:57 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D126720453 for ; Tue, 17 Mar 2015 09:50:56 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DF4D020426 for ; Tue, 17 Mar 2015 09:50:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934547AbbCQJue (ORCPT ); Tue, 17 Mar 2015 05:50:34 -0400 Received: from mga09.intel.com ([134.134.136.24]:58456 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934530AbbCQJub (ORCPT ); Tue, 17 Mar 2015 05:50:31 -0400 Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga102.jf.intel.com with ESMTP; 17 Mar 2015 02:48:26 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.11,415,1422950400"; d="scan'208";a="699801054" Received: from ahunter-desktop.fi.intel.com ([10.237.72.97]) by orsmga002.jf.intel.com with ESMTP; 17 Mar 2015 02:50:27 -0700 From: Adrian Hunter To: "Rafael J. Wysocki" Cc: linux-kernel@vger.kernel.org, linux-acpi@vger.kernel.org Subject: [PATCH] ACPI: Add acpi_device_uid() for convenience Date: Tue, 17 Mar 2015 11:48:30 +0200 Message-Id: <1426585710-31947-1-git-send-email-adrian.hunter@intel.com> X-Mailer: git-send-email 1.9.1 Organization: Intel Finland Oy, Registered Address: PL 281, 00181 Helsinki, Business Identity Code: 0357606 - 4, Domiciled in Helsinki Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add a nicer way to get the ACPI _UID. Signed-off-by: Adrian Hunter --- include/acpi/acpi_bus.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h index 61e32ec..f8009d9 100644 --- a/include/acpi/acpi_bus.h +++ b/include/acpi/acpi_bus.h @@ -252,6 +252,7 @@ struct acpi_device_pnp { #define acpi_device_bid(d) ((d)->pnp.bus_id) #define acpi_device_adr(d) ((d)->pnp.bus_address) const char *acpi_device_hid(struct acpi_device *device); +#define acpi_device_uid(d) ((d)->pnp.unique_id) #define acpi_device_name(d) ((d)->pnp.device_name) #define acpi_device_class(d) ((d)->pnp.device_class)