Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753251AbbDQT7W (ORCPT ); Fri, 17 Apr 2015 15:59:22 -0400 Received: from shards.monkeyblade.net ([149.20.54.216]:46682 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751091AbbDQT7T (ORCPT ); Fri, 17 Apr 2015 15:59:19 -0400 Date: Fri, 17 Apr 2015 15:59:16 -0400 (EDT) Message-Id: <20150417.155916.1229306319675431834.davem@davemloft.net> To: linux@roeck-us.net Cc: vivien.didelot@savoirfairelinux.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, kernel@savoirfairelinux.com Subject: Re: [PATCH v2] net: dsa: use DEVICE_ATTR_RW to declare temp1_max From: David Miller In-Reply-To: <20150417194006.GA9538@roeck-us.net> References: <1429297945-26651-1-git-send-email-vivien.didelot@savoirfairelinux.com> <20150417194006.GA9538@roeck-us.net> X-Mailer: Mew version 6.6 on Emacs 24.5 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Fri, 17 Apr 2015 12:59:19 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 862 Lines: 22 From: Guenter Roeck Date: Fri, 17 Apr 2015 12:40:06 -0700 > On Fri, Apr 17, 2015 at 03:12:25PM -0400, Vivien Didelot wrote: >> Since commit da4759c (sysfs: Use only return value from is_visible for >> the file mode), it is possible to reduce the permissions of a file. >> >> So declare temp1_max with the DEVICE_ATTR_RW macro and remove the write >> permission in dsa_hwmon_attrs_visible if set_temp_limit isn't provided. >> >> Signed-off-by: Vivien Didelot > > Looks good. > > Reviewed-by: Guenter Roeck Applied, thanks everyone. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/