From patchwork Sat Dec 9 02:34:20 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Limonciello, Mario" X-Patchwork-Id: 10103537 X-Patchwork-Delegate: dvhart@infradead.org Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id CB18360325 for ; Sat, 9 Dec 2017 02:34:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AABB428D52 for ; Sat, 9 Dec 2017 02:34:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8C3E728D68; Sat, 9 Dec 2017 02:34:50 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5E74828D52 for ; Sat, 9 Dec 2017 02:34:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753341AbdLICer (ORCPT ); Fri, 8 Dec 2017 21:34:47 -0500 Received: from esa2.dell-outbound.iphmx.com ([68.232.149.220]:57377 "EHLO esa2.dell-outbound.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752914AbdLICeq (ORCPT ); Fri, 8 Dec 2017 21:34:46 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=dell.com; i=@dell.com; q=dns/txt; s=smtpout; t=1512786886; x=1544322886; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=fja/gFT6vP+VxUGfPu+/QsZp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24C2gTI6siCVv?= =?us-ascii?q?t95kCh2SuT1wzL6uFLP0Q0la3DJpE/2b4/jJQevV7eESDonEX2iLaadkI5+ui0?= =?us-ascii?q?8OvnZajmppmBOINqkA3+M7wumsy6AeU3KAQBQ2+b+eGk2L3i+032XqlKg+U3n6?= =?us-ascii?q?TaqpzWO8oWqrCjDwNI0osu5AyzAjao3dgAmHkINlNFeBaJj4jzPFHOJej1DfKl?= =?us-ascii?q?jFS2kTdrwOrKPrngApXIKXjDlqvufbdj5E5YzAozystS6I9KBbEFJPL/QFP+tN?= =?us-ascii?q?vdDhMhKQy73/7nCMlh1oMZQW+PBq6ZMKXPsV6H/+4vIPeDZJUTuDnjL/go/ODu?= =?us-ascii?q?jXAnll8HZ6Wp3oUYaGq+Hvt4J0WVe33sgs0OEW0SpAoxUPTqiEGeUT5Uf3uyR6?= =?us-ascii?q?Y86SsnCIKoCofDXIWtjKWc0yehH51WeH5JCkqVHXbndIiJWuwBaDydIsB/iDwI?= =?us-ascii?q?T7uhRJE71RGoqgD6z6BrLu3O+i0X5trf0415+e3ajw0a9Dp6Fc2R3miBCWZukS?= =?us-ascii?q?dAbjk6zehEoUFjwVeO16t/y6hRE9BCoehJXxkxNZPazOtSBNX7WwaHddCMHgWI?= =?us-ascii?q?WNKjVBQ4VNM2i/sPZkF7ENSvihTEl36vCqUUkPqPBZkz9Knd0nz1IO5xxnLCkq?= =?us-ascii?q?Imig91EYN0KWS6i/snpEDoDInTnhDczv7yeA=3D=3D?= X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A2GiAQD7Sitahz+a6ERSChkBAQEBAQEBA?= =?us-ascii?q?QEBAQEHAQEBAQGFGCedIZkJghUKhTsChF9BFgEBAQEBAQEBAQECEAEBAQoLCQg?= =?us-ascii?q?oL4I4JAGCRwMDJ1IQPxJXBgESiiipKDqKbAEBAQEGKINbgguBVoFpiBMMhgMgB?= =?us-ascii?q?ZMfj2mCOZJnApNfllyBOyYHgXtvgniCUhAMGYFtWYgAgkgBAQE?= X-IPAS-Result: =?us-ascii?q?A2GiAQD7Sitahz+a6ERSChkBAQEBAQEBAQEBAQEHAQEBAQG?= =?us-ascii?q?FGCedIZkJghUKhTsChF9BFgEBAQEBAQEBAQECEAEBAQoLCQgoL4I4JAGCRwMDJ?= =?us-ascii?q?1IQPxJXBgESiiipKDqKbAEBAQEGKINbgguBVoFpiBMMhgMgBZMfj2mCOZJnApN?= =?us-ascii?q?fllyBOyYHgXtvgniCUhAMGYFtWYgAgkgBAQE?= Received: from esa3.dell-outbound2.iphmx.com ([68.232.154.63]) by esa2.dell-outbound.iphmx.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 08 Dec 2017 20:34:46 -0600 Received: from ausxipps301.us.dell.com ([143.166.148.223]) by esa3.dell-outbound2.iphmx.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 09 Dec 2017 08:29:34 +0600 X-LoopCount0: from 10.208.86.39 X-IronPort-AV: E=Sophos;i="5.45,380,1508821200"; d="scan'208";a="98092405" X-DLP: DLP_GlobalPCIDSS From: Mario Limonciello To: dvhart@infradead.org, Andy Shevchenko Cc: LKML , platform-driver-x86@vger.kernel.org, Andy Lutomirski , Mario Limonciello Subject: [PATCH 1/2] platform/x86: wmi: prefix sysfs files in /sys/bus/wmi with the ACPI device Date: Fri, 8 Dec 2017 20:34:20 -0600 Message-Id: <1512786861-1014-2-git-send-email-mario.limonciello@dell.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1512786861-1014-1-git-send-email-mario.limonciello@dell.com> References: <1512786861-1014-1-git-send-email-mario.limonciello@dell.com> Sender: platform-driver-x86-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: platform-driver-x86@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP It's possible for the same GUID to show up on as system twice. This means using solely the GUID for identify the file will not be sufficient. Signed-off-by: Mario Limonciello --- drivers/platform/x86/wmi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/platform/x86/wmi.c b/drivers/platform/x86/wmi.c index 791449a2370f..45d9010aafcf 100644 --- a/drivers/platform/x86/wmi.c +++ b/drivers/platform/x86/wmi.c @@ -1081,7 +1081,8 @@ static int wmi_create_device(struct device *wmi_bus_dev, wblock->dev.dev.bus = &wmi_bus_type; wblock->dev.dev.parent = wmi_bus_dev; - dev_set_name(&wblock->dev.dev, "%pUL", gblock->guid); + dev_set_name(&wblock->dev.dev, "%s-%pUL", + dev_name(&wblock->acpi_device->dev), gblock->guid); device_initialize(&wblock->dev.dev);