lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed,  6 May 2020 20:36:22 +0530
From:   Aishwarya Ramakrishnan <aishwaryarj100@...il.com>
To:     gregkh@...uxfoundation.org
Cc:     aishwaryarj100@...il.com,
        Dmitry Torokhov <dmitry.torokhov@...il.com>,
        Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
        Marco Felsch <m.felsch@...gutronix.de>,
        Ondrej Jirman <megous@...ous.com>,
        Mylène Josserand <mylene.josserand@...tlin.com>,
        Philipp Zabel <p.zabel@...gutronix.de>,
        linux-input@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH] Input: edt-ft5x06: Use DEFINE_DEBUGFS_ATTRIBUTE to define debugfs fops

From: Aishwarya Ramakrishnan <aishwaryarj100@...il.com>

On Tue, May 5, 2020 at 11:49 PM Greg Kroah-Hartman <gregkh@...uxfoundation.org> wrote:
> On Tue, May 05, 2020 at 09:03:24PM +0530, Aishwarya Ramakrishnan wrote:
>> It is more clear to use DEFINE_DEBUGFS_ATTRIBUTE to define debugfs file
>> operation rather than DEFINE_SIMPLE_ATTRIBUTE.

> No it is not, why do you think so?

This change is suggested by Coccinelle software.
Generated by: scripts/coccinelle/api/debugfs/debugfs_simple_attr.cocci

> The two defines do different things, that is why we have 2 different
> defines.  You can not just replace one with the other without
> understanding why one was used and not the other one.

> Did you test this change to verify that everything still works
> properly?  Why is it needed to be changed at all?

DEFINE_SIMPLE_ATTRIBUTE + debugfs_create_file()
imposes some significant overhead as compared to
DEFINE_DEBUGFS_ATTRIBUTE + debugfs_create_file_unsafe().
But I missed to use debugfs_create_file_unsafe() function in the patch.

Powered by blists - more mailing lists