Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.kernel > #64726
| From | Bernhard Übelacker <bernhardu@mailbox.org> |
|---|---|
| Newsgroups | linux.debian.bugs.dist, linux.debian.kernel |
| Subject | Bug#934304: linux-image-5.2.0-2-amd64: powertop aborts on version 5.2 |
| Date | 2019-08-10 16:30 +0200 |
| Message-ID | <ytAxz-14Z-1@gated-at.bofh.it> (permalink) |
| References | (1 earlier) <ytcOC-2X6-19@gated-at.bofh.it> <ytdrk-3b4-1@gated-at.bofh.it> <ytdrk-3b4-1@gated-at.bofh.it> <ytatr-1mI-5@gated-at.bofh.it> <ytdrk-3b4-1@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Cross-posted to 2 groups.
Dear Maintainer,
this issue seems to start since patch:
features/all/lockdown/0031-tracefs-Restrict-tracefs-when-the-kernel-is-locked-d.patch
Therefore a vanialla build does not show this issue.
With either of the following changes on top of all
debian patches, the exception does not happen.
But the first does also prevent opening the file
when not locked down.
The second allows to open the file, but cannot say
if the intended effect of the patch for lockdowned
kernels is still given.
Kind regards,
Bernhard
diff --git a/fs/tracefs/inode.c b/fs/tracefs/inode.c
index 338c791c9a0e..f446977bf9c8 100644
--- a/fs/tracefs/inode.c
+++ b/fs/tracefs/inode.c
@@ -41,6 +41,8 @@ static int default_open_file(struct inode *inode, struct file *filp)
return -EPERM;
real_fops = dentry->d_fsdata;
+ if (!real_fops->open)
+ return -EINVAL;
return real_fops->open(inode, filp);
}
diff --git a/fs/tracefs/inode.c b/fs/tracefs/inode.c
index 338c791c9a0e..d37c959291ab 100644
--- a/fs/tracefs/inode.c
+++ b/fs/tracefs/inode.c
@@ -438,7 +438,7 @@ struct dentry *tracefs_create_file(const char *name, umode_t mode,
dentry->d_fsdata = (void *)fops;
memcpy(proxy_fops, fops, sizeof(*proxy_fops));
- proxy_fops->open = default_open_file;
+ proxy_fops->open = fops->open ? default_open_file : NULL;
inode->i_mode = mode;
inode->i_fop = proxy_fops;
inode->i_private = data;
Back to linux.debian.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Bug#934304: linux-image-5.2.0-2-amd64: powertop aborts on version 5.2 Reinhard Karcher <reinhard.karcher@gmx.net> - 2019-08-09 12:40 +0200
Bug#934304: linux-image-5.2.0-2-amd64: powertop aborts on version 5.2 Reinhard Karcher <reinhard.karcher@online.de> - 2019-08-09 12:50 +0200
Bug#934304: linux-image-5.2.0-2-amd64: powertop aborts on version 5.2 Bernhard Übelacker <bernhardu@mailbox.org> - 2019-08-09 15:10 +0200
Bug#934304: linux-image-5.2.0-2-amd64: powertop aborts on version 5.2 Reinhard Karcher <reinhard.karcher@gmx.net> - 2019-08-09 15:50 +0200
Bug#934304: linux-image-5.2.0-2-amd64: powertop aborts on version 5.2 Bernhard Übelacker <bernhardu@mailbox.org> - 2019-08-10 16:30 +0200
Bug#934304: linux-image-5.2.0-2-amd64: powertop aborts on version 5.2 Salvatore Bonaccorso <carnil@debian.org> - 2019-08-11 12:00 +0200
Processed: Re: Bug#934304: linux-image-5.2.0-2-amd64: powertop aborts on version 5.2 "Debian Bug Tracking System" <owner@bugs.debian.org> - 2019-08-09 15:10 +0200
Bug#934304: [PATCH] tracefs: Fix potential null dereference in default_file_open() Ben Hutchings <ben@decadent.org.uk> - 2019-08-12 02:40 +0200
csiph-web