aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/mem.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/char/mem.c')
-rw-r--r--drivers/char/mem.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/char/mem.c b/drivers/char/mem.c
index 4ac70ec697f0..6511012cbdcd 100644
--- a/drivers/char/mem.c
+++ b/drivers/char/mem.c
@@ -551,7 +551,7 @@ static ssize_t write_kmem(struct file * file, const char __user * buf,
551 return virtr + wrote; 551 return virtr + wrote;
552} 552}
553 553
554#if defined(CONFIG_ISA) || !defined(__mc68000__) 554#if (defined(CONFIG_ISA) || defined(CONFIG_PCI)) && !defined(__mc68000__)
555static ssize_t read_port(struct file * file, char __user * buf, 555static ssize_t read_port(struct file * file, char __user * buf,
556 size_t count, loff_t *ppos) 556 size_t count, loff_t *ppos)
557{ 557{
@@ -830,7 +830,7 @@ static const struct file_operations null_fops = {
830 .splice_write = splice_write_null, 830 .splice_write = splice_write_null,
831}; 831};
832 832
833#if defined(CONFIG_ISA) || !defined(__mc68000__) 833#if (defined(CONFIG_ISA) || defined(CONFIG_PCI)) && !defined(__mc68000__)
834static const struct file_operations port_fops = { 834static const struct file_operations port_fops = {
835 .llseek = memory_lseek, 835 .llseek = memory_lseek,
836 .read = read_port, 836 .read = read_port,
@@ -908,7 +908,7 @@ static int memory_open(struct inode * inode, struct file * filp)
908 case 3: 908 case 3:
909 filp->f_op = &null_fops; 909 filp->f_op = &null_fops;
910 break; 910 break;
911#if defined(CONFIG_ISA) || !defined(__mc68000__) 911#if (defined(CONFIG_ISA) || defined(CONFIG_PCI)) && !defined(__mc68000__)
912 case 4: 912 case 4:
913 filp->f_op = &port_fops; 913 filp->f_op = &port_fops;
914 break; 914 break;
@@ -955,7 +955,7 @@ static const struct {
955 {1, "mem", S_IRUSR | S_IWUSR | S_IRGRP, &mem_fops}, 955 {1, "mem", S_IRUSR | S_IWUSR | S_IRGRP, &mem_fops},
956 {2, "kmem", S_IRUSR | S_IWUSR | S_IRGRP, &kmem_fops}, 956 {2, "kmem", S_IRUSR | S_IWUSR | S_IRGRP, &kmem_fops},
957 {3, "null", S_IRUGO | S_IWUGO, &null_fops}, 957 {3, "null", S_IRUGO | S_IWUGO, &null_fops},
958#if defined(CONFIG_ISA) || !defined(__mc68000__) 958#if (defined(CONFIG_ISA) || defined(CONFIG_PCI)) && !defined(__mc68000__)
959 {4, "port", S_IRUSR | S_IWUSR | S_IRGRP, &port_fops}, 959 {4, "port", S_IRUSR | S_IWUSR | S_IRGRP, &port_fops},
960#endif 960#endif
961 {5, "zero", S_IRUGO | S_IWUGO, &zero_fops}, 961 {5, "zero", S_IRUGO | S_IWUGO, &zero_fops},