Re: [PATCH v3 2/2] fault-inject: use DEFINE_DEBUGFS_ATTRIBUTE to define debugfs fops

From: Greg KH
Date: Sat Nov 02 2019 - 13:11:05 EST


On Thu, Oct 31, 2019 at 09:56:17AM +0800, zhong jiang wrote:
> It is more clearly to use DEFINE_DEBUGFS_ATTRIBUTE to define debugfs file
> operation rather than DEFINE_SIMPLE_ATTRIBUTE.
>
> Meanwhile, debugfs_create_file() in debugfs_create_stacktrace_depth() can
> be replaced by debugfs_create_file_unsafe().

Why is it ok to do this replacement? You should describe in detail how
you determined this was ok to do.

thanks,

greg k-h