Skip to content

Commit

Permalink
Merge tag 'driver-core-4.11-rc4' of git://git.kernel.org/pub/scm/linu…
Browse files Browse the repository at this point in the history
…x/kernel/git/gregkh/driver-core

Pull driver core fix from Greg KH:
 "Here is a single kernfs fix for 4.11-rc4 that resolves a reported
  issue.

  It has been in linux-next with no reported issues"

* tag 'driver-core-4.11-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core:
  kernfs: Check KERNFS_HAS_RELEASE before calling kernfs_release_file()
  • Loading branch information
torvalds committed Mar 26, 2017
2 parents f1638fc + 966fa72 commit 9e54ef9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion fs/kernfs/file.c
Original file line number Diff line number Diff line change
Expand Up @@ -809,7 +809,8 @@ void kernfs_drain_open_files(struct kernfs_node *kn)
if (kn->flags & KERNFS_HAS_MMAP)
unmap_mapping_range(inode->i_mapping, 0, 0, 1);

kernfs_release_file(kn, of);
if (kn->flags & KERNFS_HAS_RELEASE)
kernfs_release_file(kn, of);
}

mutex_unlock(&kernfs_open_file_mutex);
Expand Down

0 comments on commit 9e54ef9

Please sign in to comment.