提交 1fe56e0c 编写于 作者: A Arend van Spriel 提交者: Greg Kroah-Hartman

drivers: base: remove check for callback in coredump_store()

The check for the .coredump() callback in coredump_store() is
redundant. It is already assured the device driver implements
the callback upon creating the coredump sysfs entry.
Signed-off-by: NArend van Spriel <aspriel@gmail.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 d723522b
......@@ -292,8 +292,7 @@ static ssize_t coredump_store(struct device *dev, struct device_attribute *attr,
const char *buf, size_t count)
{
device_lock(dev);
if (dev->driver->coredump)
dev->driver->coredump(dev);
dev->driver->coredump(dev);
device_unlock(dev);
return count;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册