Skip to content

Commit 1fe56e0

Browse files
asprielgregkh
authored andcommitted
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: Arend van Spriel <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent d723522 commit 1fe56e0

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

drivers/base/dd.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -292,8 +292,7 @@ static ssize_t coredump_store(struct device *dev, struct device_attribute *attr,
292292
const char *buf, size_t count)
293293
{
294294
device_lock(dev);
295-
if (dev->driver->coredump)
296-
dev->driver->coredump(dev);
295+
dev->driver->coredump(dev);
297296
device_unlock(dev);
298297

299298
return count;

0 commit comments

Comments
 (0)