File tree Expand file tree Collapse file tree 1 file changed +20
-22
lines changed Expand file tree Collapse file tree 1 file changed +20
-22
lines changed Original file line number Diff line number Diff line change @@ -373,28 +373,6 @@ static int mtrr_close(struct inode *ino, struct file *file)
373
373
return single_release (ino , file );
374
374
}
375
375
376
- static int mtrr_seq_show (struct seq_file * seq , void * offset );
377
-
378
- static int mtrr_open (struct inode * inode , struct file * file )
379
- {
380
- if (!mtrr_if )
381
- return - EIO ;
382
- if (!mtrr_if -> get )
383
- return - ENXIO ;
384
- return single_open (file , mtrr_seq_show , NULL );
385
- }
386
-
387
- static const struct file_operations mtrr_fops = {
388
- .owner = THIS_MODULE ,
389
- .open = mtrr_open ,
390
- .read = seq_read ,
391
- .llseek = seq_lseek ,
392
- .write = mtrr_write ,
393
- .unlocked_ioctl = mtrr_ioctl ,
394
- .compat_ioctl = mtrr_ioctl ,
395
- .release = mtrr_close ,
396
- };
397
-
398
376
static int mtrr_seq_show (struct seq_file * seq , void * offset )
399
377
{
400
378
char factor ;
@@ -426,6 +404,26 @@ static int mtrr_seq_show(struct seq_file *seq, void *offset)
426
404
return 0 ;
427
405
}
428
406
407
+ static int mtrr_open (struct inode * inode , struct file * file )
408
+ {
409
+ if (!mtrr_if )
410
+ return - EIO ;
411
+ if (!mtrr_if -> get )
412
+ return - ENXIO ;
413
+ return single_open (file , mtrr_seq_show , NULL );
414
+ }
415
+
416
+ static const struct file_operations mtrr_fops = {
417
+ .owner = THIS_MODULE ,
418
+ .open = mtrr_open ,
419
+ .read = seq_read ,
420
+ .llseek = seq_lseek ,
421
+ .write = mtrr_write ,
422
+ .unlocked_ioctl = mtrr_ioctl ,
423
+ .compat_ioctl = mtrr_ioctl ,
424
+ .release = mtrr_close ,
425
+ };
426
+
429
427
static int __init mtrr_if_init (void )
430
428
{
431
429
struct cpuinfo_x86 * c = & boot_cpu_data ;
You can’t perform that action at this time.
0 commit comments