shiftfs: rework how shiftfs opens files
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
linux (Ubuntu) |
Fix Released
|
Undecided
|
Christian Brauner | ||
Eoan |
Fix Released
|
Undecided
|
Christian Brauner |
Bug Description
SRU Justification
Impact: Currently, shiftfs maintains a kmem cache for struct shiftfs_file_info which stashes away a struct path and the struct file for the underlay. The path however is never used anywhere so the struct shiftfs_file_info and therefore the whole kmem cache can go away. This removes code and makes the whole logic simpler to understand and reason about.
Fix: Remove the kmem cache for struct shiftfs_file_info and struct shiftfs_file_info itself and move to the same model as overlayfs and just stash away the struct file for the underlay in file->private_data of the shiftfs struct file
Regression Potential: Limited to shiftfs. The basic logic is unchanged. It is just simplified so regression potential should be fairly low.
Test Case: Tested with LXD on a kernel with the patch applied and running various standard workloads without any observable regressions.
Target Kernels: All LTS kernels with support for shiftfs.
CVE References
Changed in linux (Ubuntu): | |
status: | Incomplete → In Progress |
assignee: | nobody → Christian Brauner (cbrauner) |
Changed in linux (Ubuntu Eoan): | |
status: | In Progress → Fix Committed |
tags: |
added: verification-done-eoan removed: verification-needed-eoan |
This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:
apport-collect 1846265
and then change the status of the bug to 'Confirmed'.
If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.
This change has been made by an automated script, maintained by the Ubuntu Kernel Team.