@@ -5532,18 +5532,20 @@ static int event_hist_open(struct inode *inode, struct file *file)
5532
5532
{
5533
5533
int ret ;
5534
5534
5535
- ret = security_locked_down ( LOCKDOWN_TRACEFS );
5535
+ ret = tracing_open_file_tr ( inode , file );
5536
5536
if (ret )
5537
5537
return ret ;
5538
5538
5539
+ /* Clear private_data to avoid warning in single_open() */
5540
+ file -> private_data = NULL ;
5539
5541
return single_open (file , hist_show , file );
5540
5542
}
5541
5543
5542
5544
const struct file_operations event_hist_fops = {
5543
5545
.open = event_hist_open ,
5544
5546
.read = seq_read ,
5545
5547
.llseek = seq_lseek ,
5546
- .release = single_release ,
5548
+ .release = tracing_single_release_file_tr ,
5547
5549
};
5548
5550
5549
5551
#ifdef CONFIG_HIST_TRIGGERS_DEBUG
@@ -5809,18 +5811,20 @@ static int event_hist_debug_open(struct inode *inode, struct file *file)
5809
5811
{
5810
5812
int ret ;
5811
5813
5812
- ret = security_locked_down ( LOCKDOWN_TRACEFS );
5814
+ ret = tracing_open_file_tr ( inode , file );
5813
5815
if (ret )
5814
5816
return ret ;
5815
5817
5818
+ /* Clear private_data to avoid warning in single_open() */
5819
+ file -> private_data = NULL ;
5816
5820
return single_open (file , hist_debug_show , file );
5817
5821
}
5818
5822
5819
5823
const struct file_operations event_hist_debug_fops = {
5820
5824
.open = event_hist_debug_open ,
5821
5825
.read = seq_read ,
5822
5826
.llseek = seq_lseek ,
5823
- .release = single_release ,
5827
+ .release = tracing_single_release_file_tr ,
5824
5828
};
5825
5829
#endif
5826
5830
0 commit comments