From patchwork Fri Feb 20 13:04:12 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rajkumar Manoharan X-Patchwork-Id: 5855901 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: X-Original-To: patchwork-linux-wireless@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 EF201BF440 for ; Fri, 20 Feb 2015 13:05:55 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 3BE9A20377 for ; Fri, 20 Feb 2015 13:05:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 13F9720379 for ; Fri, 20 Feb 2015 13:05:53 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754454AbbBTNFn (ORCPT ); Fri, 20 Feb 2015 08:05:43 -0500 Received: from wolverine01.qualcomm.com ([199.106.114.254]:23565 "EHLO wolverine01.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754406AbbBTNFj (ORCPT ); Fri, 20 Feb 2015 08:05:39 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=qti.qualcomm.com; i=@qti.qualcomm.com; q=dns/txt; s=qcdkim; t=1424437540; x=1455973540; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version; bh=Gaoh3PqEMUmIsqntuNR7Ws9yc0RjZvGdkt4SPbRHGs8=; b=MX8QfA673S1iUnU0mhVsQZqPyWn4tSsIfHAqAkKCvCR6bLQuqNyTEXzA bcgAuFNSD+84IkUzmeayxufYME2ezty48oPOtEiMpV7m6rIrcHVuAw/Fl uq+7sVKVQCkVp0h1TYRY5YF79+2BAh3kacVM+0nP+Rd+AEJfYbzX8mSqG g=; X-IronPort-AV: E=McAfee;i="5600,1067,7717"; a="104397010" Received: from ironmsg03-r.qualcomm.com ([172.30.46.17]) by wolverine01.qualcomm.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 20 Feb 2015 05:05:39 -0800 X-IronPort-AV: E=Sophos;i="5.09,614,1418112000"; d="scan'208";a="855375930" Received: from nasanexm01e.na.qualcomm.com ([10.85.0.31]) by Ironmsg03-R.qualcomm.com with ESMTP/TLS/RC4-SHA; 20 Feb 2015 05:05:38 -0800 Received: from APHYDEXM01E.ap.qualcomm.com (10.252.127.13) by NASANEXM01E.na.qualcomm.com (10.85.0.31) with Microsoft SMTP Server (TLS) id 15.0.995.29; Fri, 20 Feb 2015 05:05:36 -0800 Received: from qcmail1.qualcomm.com (10.80.80.8) by APHYDEXM01E.ap.qualcomm.com (10.252.127.13) with Microsoft SMTP Server (TLS) id 15.0.995.29; Fri, 20 Feb 2015 05:05:28 -0800 Received: by qcmail1.qualcomm.com (sSMTP sendmail emulation); Fri, 20 Feb 2015 18:35:20 +0530 From: Rajkumar Manoharan To: CC: , Rajkumar Manoharan Subject: [PATCH 3/3] ath10k: add symlink for hwmon device Date: Fri, 20 Feb 2015 18:34:12 +0530 Message-ID: <1424437452-28161-3-git-send-email-rmanohar@qti.qualcomm.com> X-Mailer: git-send-email 2.3.0 In-Reply-To: <1424437452-28161-1-git-send-email-rmanohar@qti.qualcomm.com> References: <1424437452-28161-1-git-send-email-rmanohar@qti.qualcomm.com> MIME-Version: 1.0 X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: NASANEXM01E.na.qualcomm.com (10.85.0.31) To APHYDEXM01E.ap.qualcomm.com (10.252.127.13) Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-7.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,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 symbloic link "thermal_sensors" for hwmon devices for better readability. /sys/class/ieee80211/phyX/device/thermal_sensors -> sys/class/ieee80211/phyX/device/hwmon/hwmonY Signed-off-by: Rajkumar Manoharan --- drivers/net/wireless/ath/ath10k/thermal.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/net/wireless/ath/ath10k/thermal.c b/drivers/net/wireless/ath/ath10k/thermal.c index 7c54bb1..f601e3e 100644 --- a/drivers/net/wireless/ath/ath10k/thermal.c +++ b/drivers/net/wireless/ath/ath10k/thermal.c @@ -276,6 +276,13 @@ int ath10k_thermal_register(struct ath10k *ar) ret = -EINVAL; goto err_remove_file; } + ret = sysfs_create_link(&ar->dev->kobj, &hwmon_dev->kobj, + "thermal_sensors"); + if (ret) { + ath10k_err(ar, "failed to create hwmon symlink\n"); + goto err_remove_file; + } + return 0; err_remove_file: @@ -292,4 +299,5 @@ void ath10k_thermal_unregister(struct ath10k *ar) thermal_cooling_device_unregister(ar->thermal.cdev); sysfs_remove_link(&ar->dev->kobj, "cooling_device"); sysfs_remove_file(&ar->dev->kobj, &dev_attr_quiet_period.attr); + sysfs_remove_link(&ar->dev->kobj, "thermal_sensors"); }